Skip to content

agent_loop: pre-existing loop behaviours flagged during the #318 refactor review #322

Closed

Description

@senamakel

During review of #318, a refactor that changed no behaviour, Tiny Sweeper flagged the behaviours below. Each one already existed before the refactor, so they were left out of that PR. Each needs a decision and possibly a fix:

  • tool_search bridge: it checks only the registry, so it does not suppress a duplicate tool_search name.
  • Graceful mixed turn: it ignores ContinueLoop from a control point, and it resets no recovery counters before continue_from_queue_at_finish can start another turn.
  • Dropped-tool-call nudge: it does not check the model-call budget before scheduling the nudge.
  • Length stops: unterminated text-dialect blocks are dropped under a length stop, with no recovery attempt.
  • Mixed structured-and-tools turns: they skip output validation.
  • Promoted tools: their schemas are never prepared (prepare) the way direct tool schemas are.

Context: tinyagents harness uplift (pi/OpenClaw comparison).

Activity

  1. added
    priority: p3Whenever. Cosmetic, a nicety, or a cleanup with no user visible effect.
    on Oct 7, 2026
  2. tinysweeper commented on Oct 7, 2026

    @tinysweeper

    Pre-existing agent_loop behaviours (tool_search bridge, mixed turn handling, dropped-tool-call nudge, length stops, mixed turns, promoted tool schemas) flagged during #318 review; each needs a decision and possibly a fix.

    Labelled priority: p3.

  3. added theissue type on Oct 7, 2026
  4. M3gA-Mind commented on Nov 11, 2026

    @M3gA-Mind
    Collaborator

    Triage (team#45), against main b6ed460: (c) is fixed by #339 (the nudge checks the model-call budget, response_recovery.rs:241/:551), and (d) is fixed by #532 when text_dialect_calls_recoverable is set (:282, :474-485).
    Still present: (a) the bridge de-duplication (tool_surface.rs:271-285); (b) Graceful mixed turns drop ContinueLoop (mixed_turn.rs:143-149; the helper is now settle_natural_finish); (e) mixed turns skip output validation.
    For (f): provider schema projection is applied (tools.rs:431-439), but the per-step PreparedToolSet transform isn't. Which did you mean?
    Suggest splitting (a), (b), (e) and (f) into their own issues.

  5. M3gA-Mind commented on Nov 11, 2026

    @M3gA-Mind
    Collaborator

    Done. Items (c) and (d) were already fixed on main (#339, #532). The rest landed in four merged PRs:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p3Whenever. Cosmetic, a nicety, or a cleanup with no user visible effect.

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions