agent/cmd/core-agent/main.go
Virgil 547f23a6f0 fix(ax): align core-agent CLI bootstrap
Co-Authored-By: Virgil <virgil@lethean.io>
2026-03-29 21:02:14 +00:00

41 lines
891 B
Go

// SPDX-License-Identifier: EUPL-1.2
package main
import (
"dappco.re/go/core"
"dappco.re/go/agent/pkg/agentic"
"dappco.re/go/agent/pkg/brain"
"dappco.re/go/agent/pkg/monitor"
"dappco.re/go/agent/pkg/runner"
)
func main() {
c := core.New(
core.WithOption("name", "core-agent"),
core.WithService(agentic.ProcessRegister),
core.WithService(agentic.Register),
core.WithService(runner.Register),
core.WithService(monitor.Register),
core.WithService(brain.Register),
core.WithName("mcp", registerMCPService),
)
c.App().Version = appVersion()
c.Cli().SetBanner(func(_ *core.Cli) string {
return core.Concat("core-agent ", c.App().Version, " — agentic orchestration for the Core ecosystem")
})
registerAppCommands(c)
c.Run()
}
// appVersion returns the build version or "dev".
func appVersion() string {
if version != "" {
return version
}
return "dev"
}