Slim subagent runtime surface and remove legacy interfaces

This commit is contained in:
LPF
2026-03-17 13:41:12 +08:00
parent 341e578c9f
commit 0674d85ae1
76 changed files with 778 additions and 8782 deletions

View File

@@ -177,12 +177,10 @@ func gatewayCmd() {
}
configureGatewayNodeP2P(agentLoop, registryServer, cfg)
registryServer.SetGatewayVersion(version)
registryServer.SetWebUIVersion(version)
registryServer.SetConfigPath(getConfigPath())
registryServer.SetToken(cfg.Gateway.Token)
registryServer.SetWorkspacePath(cfg.WorkspacePath())
registryServer.SetLogFilePath(cfg.LogFilePath())
registryServer.SetWebUIDir(filepath.Join(cfg.WorkspacePath(), "webui"))
aistudioRelay := wsrelay.NewManager(wsrelay.Options{
Path: "/v1/ws",
ProviderFactory: func(r *http.Request) (string, error) {
@@ -223,9 +221,6 @@ func gatewayCmd() {
}
return out
})
registryServer.SetSubagentHandler(func(cctx context.Context, action string, args map[string]interface{}) (interface{}, error) {
return loop.HandleSubagentRuntime(cctx, action, args)
})
registryServer.SetNodeDispatchHandler(func(cctx context.Context, req nodes.Request, mode string) (nodes.Response, error) {
return loop.DispatchNodeRequest(cctx, req, mode)
})
@@ -456,7 +451,6 @@ func gatewayCmd() {
registryServer.SetToken(cfg.Gateway.Token)
registryServer.SetWorkspacePath(cfg.WorkspacePath())
registryServer.SetLogFilePath(cfg.LogFilePath())
registryServer.SetWebUIDir(filepath.Join(cfg.WorkspacePath(), "webui"))
configureGatewayNodeP2P(agentLoop, registryServer, cfg)
fmt.Println("Config hot-reload applied (logging/metadata only)")
return nil
@@ -486,7 +480,6 @@ func gatewayCmd() {
registryServer.SetToken(cfg.Gateway.Token)
registryServer.SetWorkspacePath(cfg.WorkspacePath())
registryServer.SetLogFilePath(cfg.LogFilePath())
registryServer.SetWebUIDir(filepath.Join(cfg.WorkspacePath(), "webui"))
configureGatewayNodeP2P(agentLoop, registryServer, cfg)
registryServer.SetWhatsAppBridge(whatsAppBridge, embeddedWhatsAppBridgeBasePath)
sentinelService.Stop()