feat(skills): action env wiring + new service_agent module #127
No reviewers
Labels
No labels
prio_critical
prio_low
type_bug
type_contact
type_issue
type_lead
type_question
type_story
type_task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lhumina_code/hero_skills!127
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "development_mik_action_envs"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes the §4.4 manual
hero_proc action.setpatches in DEPLOYMENT_NU_HERO_OS.md by having each service module forward env-overridable values into the action records whenservice_completeruns.Changes
New
tools/modules/services/service_agent.nuFull lifecycle module (install/start/stop/status) for hero_agent. Until this landed, hero_agent had no nu-shell installer at all on
development— only the docker-era TOML inhero_demo/services/hero_agent.toml.Action env wires:
AIBROKER_API_ENDPOINT— defaults tohttp+unix://$sock_base/hero_aibroker/rpc.sockso the LLM routes through hero_aibroker (Claude); operators can override to OpenRouter direct URLOSIS_URL,OSIS_CONTEXT— conversation/message persistence (defaults match the docker-era TOML)OPENROUTER_API_KEY/GROQ_API_KEY— forwarded from invoking shellHERO_AGENT_AIBROKER_MODELS— comma-separated model list (env-overridable)ENABLE_TELEGRAM/TELEGRAM_TOKEN— optional Telegram channelHERO_AGENT_DATA_DIR/WORKSPACE_DIR/SKILLS_DIR/SOCKETpaths derived fromsvc_homeWired into
mod.nuexports +service_install_allandservice_completeinpackages.nu.service_biz.nuHERO0_BASE_URLonhero_biz_uiis now env-overridable. Defaulthttp://127.0.0.1:6666/hero_osis/uimatches local-dev hero_router. Operators setHERO0_BASE_URL=http://10.1.2.2:9990/hero_osis/uiinenv.shon TF Grid VMs where hero_router moves to port 9990 to free 9988 for nginx basic auth (runbook §4.4 + §12.1).service_router.nuNew env-driven defaults for
--addressand--ui-portflags:HERO_ROUTER_ADDRESS— TF Grid private IP (e.g.10.1.2.2); falls back to mycelium auto-detect if unsetHERO_ROUTER_UI_PORT— TCP port (e.g.9990); falls back to--port(default 9988) if unsetThis lets
service_completedrive the TF Grid binding without per-call CLI args.Validation
Every changed module loads under
nu -c "use ...". Runtime validation requires a TF Grid VM (no opportunity to test locally without spinning up infra).Tracker
home#185.
Signed-off-by: mik-tf
Pre-merge audit caught two correctness bugs in this PR — pushed
a15781f:AIBROKER_API_ENDPOINTscheme. Default washttp+unix://...rpc.sock. hero_agent usesreqwest(TCP-HTTP only — seehero_agent/crates/hero_agent/src/llm_client.rs); it does NOT speak Unix sockets. With the wrong scheme,hero_agentsilently falls through to OpenRouter direct, defeating the broker. Fixed default tohttp://$HERO_ROUTER_ADDRESS:$HERO_ROUTER_UI_PORT/hero_aibroker/rest/v1.HERO0_BASE_URL+OSIS_URLstale port. Defaults were:6666(copied from the legacyhero_demoTOML). hero_router has defaulted to:9988for some time. Without the fix,hero_biz_ui’s/hero0surface 404s against an unbound port. Fixed both to derive fromHERO_ROUTER_ADDRESS+HERO_ROUTER_UI_PORTenv, with direct override still winning.Both are correctness fixes, not stylistic — without them the deploy would look-good-on-paper but actually be broken at runtime.
Squash-merged to
developmentas60375f4. Branch deleted.Pull request closed