Repository navigation
Tell agents to read the whole recipe before running it - #215
Merged
Merged
Conversation
Agents pick a recipe from an index and then read the file. In a test (Haiku, 6 scripts x 2 trials), the docstring alone gave 8 of 12 correct commands; the argument definitions or the full source gave 12 of 12. - README.md: the agent prompt says to read the whole file, not only the header and docstring. - ocr/AGENTS.md: drop `| head -100`, which stops before the argparse block. - jobs-utils/list-recipes.py: print raw URLs (was /resolve/) and a read-first line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Tell agents to read the whole recipe file before they run it, and give them a URL that prints it.
Changes
README.md(agent prompt): "read its header and docstring" becomes "read the whole file: the header sets the hardware, the docstring has an example command, and the argument definitions near the end list every flag."ocr/AGENTS.md: remove| head -100from the curl example. The first 100 lines usually stop before the arguments.jobs-utils/list-recipes.py: print/raw/main/URLs instead of/resolve/URLs, and tell the agent tocurla recipe before running it. Tested locally: it prints 136 raw URLs.No script changes. The hub-sync will republish
ocr/AGENTS.mdandjobs-utils/list-recipes.py.Agent test
Haiku with curl only. Each run got the task, the index text from
main(A) or this branch (B), and the script URL. It had to fetch the script itself. Six tasks (OCR, transcription, classification, training, embeddings), three trials each, 36 runs, $0.24. Scored against each script's real arguments.head,sed,grep)hf jobstakes them as its own flags. The docstring example has the correct order. This PR does not address that.🤖 Generated with Claude Code
https://claude.ai/code/session_016isSPo9kUNVE79vUKWm9i7