// Code generated by Wire. DO NOT EDIT. //go:generate go run -mod=mod github.com/google/wire/cmd/wire //go:build !wireinject // +build !wireinject package main import ( "eino-project/internal/ai" "eino-project/internal/biz" "eino-project/internal/conf" "eino-project/internal/context" "eino-project/internal/data" "eino-project/internal/data/repoimpl" "eino-project/internal/monitor" "eino-project/internal/server" "eino-project/internal/service" "eino-project/internal/session" "eino-project/internal/vector" "github.com/go-kratos/kratos/v2" "github.com/go-kratos/kratos/v2/log" ) import ( _ "go.uber.org/automaxprocs" ) // Injectors from wire.go: // wireApp init kratos application. func wireApp(confServer *conf.Server, confData *conf.Data, bootstrap *conf.Bootstrap, logger log.Logger) (*kratos.App, func(), error) { vectorService, err := vector.NewVectorServiceFromBootstrapConfig(bootstrap, logger) if err != nil { return nil, nil, err } documentProcessor := vector.NewDocumentProcessor(vectorService) knowledgeSearcher := vector.NewKnowledgeSearcher(vectorService) contextManager := context.NewContextManagerFromBootstrapConfig(bootstrap, logger) monitorMonitor := monitor.NewMonitorFromBootstrapConfig(bootstrap, logger) dataData, cleanup, err := data.NewData(confData, logger, vectorService, documentProcessor, knowledgeSearcher, contextManager, monitorMonitor) if err != nil { return nil, nil, err } customerRepo := repoimpl.NewCustomerRepo(dataData, logger) customerUseCase := biz.NewCustomerUseCase(customerRepo, logger, knowledgeSearcher, documentProcessor, contextManager, monitorMonitor) aiService, err := ai.NewAIServiceFromConfig(bootstrap, logger, knowledgeSearcher, contextManager, monitorMonitor) if err != nil { cleanup() return nil, nil, err } sessionManager := session.NewMemorySessionManager(logger) customerService := service.NewCustomerService(customerUseCase, aiService, sessionManager, monitorMonitor, logger) grpcServer := server.NewGRPCServer(confServer, customerService, logger) httpServer := server.NewHTTPServer(confServer, customerService, logger) app := newApp(logger, grpcServer, httpServer) return app, func() { cleanup() }, nil }