Repository navigation
An example app built on the CLI and the socket alone - #666
Conversation
examples/triage is a small issue-triage service, written the way an outside program would build on Agent: the agent CLI's JSON and the daemon's JSONL socket, no SDK and nothing from Sonny. Each issue goes to a fork of a template bot whose only tools are two the app declares and answers (search_issues, set_triage). offline.sh runs it against a scripted Responses endpoint, and tests/test_examples.py runs that in the runtime suite, so a protocol change that breaks an adopter's app fails CI. The example's README records what it took (102 code lines, 74 of them integration, and eleven protocol facts) and the three gaps it hit, each with a proposed fix. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013jkdGGf29tQRUx1AhX6DWy
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8e2c94377c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…t 1 on a failed turn offline.sh sets AGENT_SOCKET in its throwaway folder, so an inherited socket override can no longer point it at, and its trap shut down, the caller's own daemon. triage.py waits on at most 64 handles at a time, as the protocol's wait allows, and exits 1 when any triage did not complete. The README's counts follow (108 code lines, 80 of them integration) and its facts now say that a wait takes 64 handles. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013jkdGGf29tQRUx1AhX6DWy
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dd1d8e71d8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…it reports pending
configure now sends AGENT_MODEL with the instructions and tools, so a
template made by an earlier run takes the model this run names. A handle the
wait timed out on comes back as {"pending": true} with no status; the app
reads it as pending instead of failing on the missing field.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013jkdGGf29tQRUx1AhX6DWy
Requested by George · project thread
Option B from the Pi review: one small app outside Sonny, built only on the
agentCLI's JSON output and the daemon's JSONL socket, to measure what it takes to build on Agent.What's here
examples/triage/triage.pyis an issue-triage service in standard-library Python. A template bot has no tools of its own and two declared tools,search_issuesandset_triage, which the app answers (answered_by). Each issue goes to its own fork throughrun --fork --detach --request-id. The app collects the results withwait, 64 handles at a time, and exits 1 if any triage does not complete. A rerun updates the template's model, instructions and tools.examples/triage/offline.shruns it againstscripted_model.py, a local Responses endpoint with scripted words, so it needs no key. It runs in a throwaway store and socket. Everything else is real.tests/test_examples.pyrunsoffline.shin the runtime suite. If a protocol change breaks the app, CI fails.examples/triage/README.mdrecords what it took, measured at 7ea7b7a (protocol 48):run --new --declare FILE(CLI only).tool_callsandtool_result, asapprovalsandanswerare for gates (CLI only).workspace_requiredcomes withdetail: nulland arrives late, at the first fork's turn rather than atcreate. Fix: a detail and a CLI hint. This one is a daemon text change.This PR implements none of the fixes. They wait for George's call.
There are no daemon changes. The one top-level README line links the example.
Checks
AGENT_TEST_RUNTIME=1 python3 -m unittest tests.test_examplespasses against a release build. The test takes 0.46 s.offline.shwithAGENT_SOCKETpointed elsewhere still uses only its own daemon.AGENT_MODELmoves the template to that model, asinspectshows.🤖 Generated with Claude Code
https://claude.ai/code/session_013jkdGGf29tQRUx1AhX6DWy