feat(loop): cross-platform /goal + /loop, external-runner wiring, v0.20.0 - #61
Merged
Conversation
…20.0 Rewire /loop to LAUNCH the external runner (knitbrain loop) detached instead of the in-agent run_loop tool, and bring both front doors to full parity on every host with a slash surface: - /loop: background-launch knitbrain loop <goalfile> (owns control flow, fresh agent per iteration, survives context window) — Claude, Codex, Gemini, VS Code, Windsurf; Cursor via terminal (documented in rules). - /goal: in-session gate orchestration (knitbrain_run -> knitbrain_run_loop), now emitted for all slash-capable platforms via a shared goalOrchestrationInstructions() helper (was Claude-only). - Per-platform native formats: Gemini .gemini/commands/*.toml, VS Code .github/prompts/*.prompt.md, Windsurf .windsurf/workflows/*.md, Codex ~/.codex/prompts (snippet). Formats verified against live docs. - slashCommands() registers /goal + /loop on all five slash platforms (claude-code was missing /goal in the registry). - Onboarding hints + README platform table updated to the honest split. - +7 tests (618 green), consistency + bench pass. Claude-Session: https://claude.ai/code/session_01Mnwx3jqRivG66r1aneoZYf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Bring both loop front doors to full parity on every platform with a slash surface, and wire
/loopto the external runner (knitbrain loop) instead of the in-agentrun_looptool./loop— launches the external runner (owns control flow)Background-launches
knitbrain loop <goalfile>detached: spawns a fresh agent per checkbox, verify-gated, survives the context window, doesn't depend on any model choosing to continue. A slash command can't be an hour-long loop, so it launches the runner and hands back a watch handle (PID + log)./goal— in-session gate orchestration (was Claude-only)knitbrain_run→ adopt skill → driveknitbrain_run_loopeach cycle until the verify gate exits 0. Now emitted for all slash-capable platforms via a sharedgoalOrchestrationInstructions()helper.Per-platform native formats (verified against live docs)
/goal+/loop.claude/commands/*.md.gemini/commands/*.toml.github/prompts/*.prompt.md.windsurf/workflows/*.md~/.codex/prompts/*.md(global, snippet)knitbrain loop— no slash API, documented in rulesslashCommands()registers/goal+/loopon all five slash platforms (claude-code was missing/goal).Honest caveats (baked into the command text)
claude -p, override--agent).https://claude.ai/code/session_01Mnwx3jqRivG66r1aneoZYf