fix(reactive): synthesise execution route for type:llm actors in ReactiveConfigParser #10818

Merged
HAL9000 merged 1 commits from bugfix/m3-actor-run-missing-llm-route into master 2026-04-28 03:37:27 +00:00

1 Commits

Author SHA1 Message Date
hurui200320 0127b6f745 fix(reactive): synthesise execution route for type:llm actors in ReactiveConfigParser
CI / lint (pull_request) Successful in 1m7s
CI / typecheck (pull_request) Successful in 1m13s
CI / security (pull_request) Successful in 1m13s
CI / benchmark-publish (pull_request) Has been skipped
CI / push-validation (pull_request) Successful in 33s
CI / helm (pull_request) Successful in 35s
CI / build (pull_request) Successful in 51s
CI / quality (pull_request) Successful in 56s
CI / e2e_tests (pull_request) Successful in 4m33s
CI / integration_tests (pull_request) Successful in 5m4s
CI / unit_tests (pull_request) Successful in 6m24s
CI / docker (pull_request) Successful in 1m29s
CI / coverage (pull_request) Successful in 11m42s
CI / status-check (pull_request) Successful in 5s
CI / build (push) Successful in 50s
CI / helm (push) Successful in 30s
CI / push-validation (push) Successful in 28s
CI / lint (push) Successful in 1m6s
CI / quality (push) Successful in 1m10s
CI / typecheck (push) Successful in 1m33s
CI / security (push) Successful in 1m37s
CI / benchmark-publish (push) Failing after 48s
CI / e2e_tests (push) Successful in 3m54s
CI / integration_tests (push) Successful in 4m3s
CI / unit_tests (push) Successful in 6m6s
CI / docker (push) Successful in 1m32s
CI / coverage (push) Successful in 12m3s
CI / status-check (push) Successful in 3s
When _build_from_v3() creates agents for type:llm or type:tool actors, and
when _build() processes the nested actors: map format (cleveragents version
3.0 YAML), no RouteConfig is produced. run_single_shot() then falls through
to the RxPY stream path which has no subscribers, causing the LLM to never
be invoked and the command to silently return empty output.

Fix A: after creating the agent in _build_from_v3() for type:llm/tool, call
_synthesise_single_node_route() to add a graph route with a message_router
node (catch-all rule), an actor node, and an edge to "end".

Fix B: after the agent loop in _build(), if rc.agents is non-empty and
rc.routes is empty, synthesise a default route using the cleveragents
default_actor (or the first agent).

Fix C: in _build(), the nested actors: map path now translates the v3
actor: "provider/model" key into separate provider and model keys in the
agent config dict. SimpleLLMAgent._resolve_llm() expects these keys; without
this translation, the LLM provider defaults to None (OpenAI) regardless of
the configured actor reference.

13 BDD scenarios in actor_v3_route_synthesis.feature:
- Flat v3 LLM/tool builds produce non-empty routes
- Route structure has router + actor nodes with edge to end
- Nested actors: map format produces routes, respects default_actor
- Explicit routes are not duplicated
- run_single_shot returns non-empty output with synthesised routes
- Graph actor regression guard
- Nested actors: map with actor key infers provider and model
- Nested actors: map with actor key without slash sets model only
- Nested actors: map with explicit provider/model keeps them unchanged

ISSUES CLOSED: #10807
2026-04-28 03:22:06 +00:00