feat(agents): inherit tool timeout ceilings from parent LLM agent #141
No reviewers
Labels
No labels
auto/blocked-by-deps
auto/ci-timeout
auto/claimed-implementer
auto/claimed-merge
auto/claimed-reviewer
auto/driver-down
auto/invariant-violation
auto/last-attempt-tier-0
auto/last-attempt-tier-1
auto/last-attempt-tier-2
auto/last-attempt-tier-min
Automation Tracking
auto/needs-conflict-resolution
auto/needs-implementer
auto/postmortem
auto/ready-to-merge
auto/restart-throttled
auto/revert
auto/sentinel
auto/stale-inactivity
auto/unstable
Blocked
Bounty
$100
Bounty
$1000
Bounty
$10000
Bounty
$20
Bounty
$2000
Bounty
$250
Bounty
$50
Bounty
$500
Bounty
$5000
Bounty
$750
MoSCoW
Could have
MoSCoW
Must have
MoSCoW
Should have
Needs Feedback
Points
1
Points
13
Points
2
Points
21
Points
3
Points
34
Points
5
Points
55
Points
8
Points
88
Priority
Backlog
Priority
CI Blocker
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Signed-off: Owner
Signed-off: Scrum Master
Signed-off: Tech Lead
Spike
State
Completed
State
Duplicate
State
In Progress
State
In Review
State
Paused
State
Unverified
State
Verified
State
Wont Do
Type
Automation
Type
Bug
Type
Discussion
Type
Documentation
Type
Epic
Type
Feature
Type
Legendary
Type
Refactor
Type
Support
Type
Task
Type
Testing
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Blocks
#140 Ephemeral tool-call ToolAgent instances do not inherit
tools_max_timeout/shell_max_timeout from the parent LLM agent
cleveragents/cleveractors-core
Reference
cleveragents/cleveractors-core!141
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feature/m1-inherit-tool-timeout-ceilings"
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?
Summary
type: llmagent'stools_max_timeout/shell_max_timeoutconfig now bounds the per-invocationtimeouttool-call argument forshell/http_requestcalls that agent dispatches internally, exactly as it already does for a directly-configuredtype: toolagent.timeoutitself already inherited correctly and is untouched.ToolAgent-construction sites inLLMAgent._execute_tool_loopnow share one_build_ephemeral_tool_config()helper (Template/Factory Method) instead of three near-identical inline dict literals, closing the drift that lettools_max_timeout/shell_max_timeoutdiverge fromtimeoutin the first place.docs/adr/ADR-2030-tool-calling-spec-extensions.mdwith D-10 anddocs/index.md§4.4 (Version 1.6.0, §21.1 Revision History) per the spec-revision procedure, since this makes the two fields usable/discoverable on atype: llmagent for the first time.timeouttool-call argument mechanism (ADR-2030 D-9,TimeoutPolicy) is unaffected: a model-supplied override still takes precedence over the (now possibly inherited) default/ceiling for that one call.Closes #140
Test plan
nox -s lint/nox -s format -- --check— greennox -s typecheck— green (0 errors)nox -s security_scan/nox -s dead_code— green, no findingsnox -s unit_tests— 154 features, 3089 scenarios, 0 failed (6 new scenarios infeatures/llm_agent_tool_loop.feature)nox -s coverage_report— 96.9% (threshold 96.5%); no new uncovered linesnox -s integration_tests— 364 Robot tests, 0 failed (2 new tests inrobot/llm_tool_calling.robot)nox -s benchmark_regression -- --quick— BENCHMARKS NOT SIGNIFICANTLY CHANGED (expected: config-threading only, no perf-sensitive path touched)🤖 Generated with Claude Code
tools_max_timeout/shell_max_timeoutfrom the parent LLM agent9eb8378d6449e7e263a0PR Review: !141 (Ticket #140)
Verdict: Approve
The implementation correctly threads
tools_max_timeoutandshell_max_timeoutfrom a parenttype: llmagent into the ephemeralToolAgentinstances it constructs per dispatched tool call, satisfying the functional requirements of #140. The code is clean, well-documented, and the spec/ADR updates are consistent. No critical or major issues were found.Critical Issues
None
Major Issues
None
Minor Issues
Missing Behave coverage for the post-loop stuck-model synthesis dispatch site
features/llm_agent_tool_loop.feature_build_ephemeral_tool_config()helper, the functional risk is low, but the requirement coverage is incomplete.tools_max_timeoutceiling is honored there.Invalid ceiling test only exercises
tools_max_timeout: 0features/llm_agent_tool_loop.featuretools_max_timeoutorshell_max_timeoutmust raiseAgentCreationErrorat ephemeral-agent construction. The new scenario only teststools_max_timeout: 0; it does not cover non-numeric, negative, non-finite, orshell_max_timeoutinvalid values.shell_max_timeoutcases.Robot integration tests do not exercise inherited
shell_max_timeoutrobot/llm_tool_calling.robottools_max_timeoutinheritance but does not include a case forshell_max_timeoutoverriding the shell-only ceiling.shell_max_timeouton the LLM agent and verifies a per-calltimeoutabovetools_max_timeoutbut belowshell_max_timeoutis accepted for ashellcall.Nits
ToolAgentdefaultssrc/cleveractors/agents/llm.py_build_ephemeral_tool_config()hardcodes120.0andNoneas fallbacks. These matchToolAgent.__init__defaults today, but if those defaults ever change, this helper could silently drift out of sync.ToolAgentdefaults via module constants or a shared helper to make the coupling explicit. (This is consistent with the existingtimeout: 1pattern, so purely a nit.)Summary
This is a focused, well-scoped change. Extracting the ephemeral-tool-agent config construction into
_build_ephemeral_tool_config()removes the drift that allowed the timeout ceilings to diverge, and the ADR/spec updates follow the established process. The implementation is functionally correct and backward-compatible. Addressing the minor test-coverage gaps would make the PR fully satisfy the acceptance criteria, but the current state is safe to approve.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.