MCPcopy Create free account
hub / github.com/astercloud/aster / createDependencies

Function createDependencies

examples/desktop/main.go:149–169  ·  view source on GitHub ↗
(workDir string)

Source from the content-addressed store, hash-verified

147}
148
149func createDependencies(workDir string) *agent.Dependencies {
150 // Create store
151 dataStore, _ := store.NewJSONStore(workDir)
152
153 // Create sandbox factory
154 sandboxFactory := sandbox.NewFactory()
155
156 // Create tool registry
157 toolRegistry := tools.NewRegistry()
158 builtin.RegisterAll(toolRegistry)
159
160 // Create provider factory
161 providerFactory := provider.NewMultiProviderFactory()
162
163 return &agent.Dependencies{
164 Store: dataStore,
165 SandboxFactory: sandboxFactory,
166 ToolRegistry: toolRegistry,
167 ProviderFactory: providerFactory,
168 }
169}

Callers 1

mainFunction · 0.70

Calls 5

NewJSONStoreFunction · 0.92
NewFactoryFunction · 0.92
NewRegistryFunction · 0.92
RegisterAllFunction · 0.92
NewMultiProviderFactoryFunction · 0.92

Tested by

no test coverage detected