One-shot a CLI coding agent on top of a Python LLM library

Simon Willison had the Fable model more or less one-shot a CLI coding agent built on his LLM Python library. Task: Simon Willison initialized a repository from a Python library template and provided two prompts to Claude Code for web. The first prompt generated a specification for a coding agent dependent on the 'llm' alpha library, including file and command tools. The second prompt instructed the agent to implement the spec using red/green TDD, create documentation, and perform manual tests with an OpenAI key. Willison reviewed the output and shipped the result as an alpha package.; tools: custom-built or unnamed agent. Human role: Not stated in the source; limitations: The demonstration used the '--yolo' flag, which bypasses approval steps for commands, posing a security risk. The README suggests using '--allow' patterns (e.g., 'pytest*') for narrower permissions. The source is a personal blog post, indicating a prototype rather than a production-ready tool. The 'llm' library dependency is in alpha, implying potential instability. Human review is required to validate the generated code and security configurations..

Tools

custom-built or unnamed agent

Published on Agent Work Atlas:

Overview

Simon Willison had the Fable model more or less one-shot a CLI coding agent built on his LLM Python library.

Workflow

Simon Willison initialized a repository from a Python library template and provided two prompts to Claude Code for web. The first prompt generated a specification for a coding agent dependent on the 'llm' alpha library, including file and command tools. The second prompt instructed the agent to implement the spec using red/green TDD, create documentation, and perform manual tests with an OpenAI key. Willison reviewed the output and shipped the result as an alpha package.

Reported result

The project was released as 'llm-coding-agent 0.1a0' on PyPI. Willison described it as 'pretty good for a first attempt'. The agent implemented six specific tools for file editing, command execution, and searching. It also generated an unrequested Python API class 'CodingAgent' which Willison noted he was 'delighted to see implemented'. A demo showed the agent creating a Swift CLI app, though the model correctly identified that SwiftUI was unsuitable for a true CLI.

Human role

Not stated in the source

Limitations

The demonstration used the '--yolo' flag, which bypasses approval steps for commands, posing a security risk. The README suggests using '--allow' patterns (e.g., 'pytest*') for narrower permissions. The source is a personal blog post, indicating a prototype rather than a production-ready tool. The 'llm' library dependency is in alpha, implying potential instability. Human review is required to validate the generated code and security configurations.

Try it

Act as a coding agent to build a CLI tool from a Python library template. Inputs: [GitHub template URL], [Target library name], [Feature spec]. Steps: 1. Initialize repo from template. 2. Generate spec.md for a coding agent with file/command tools. 3. Implement using red/green TDD with sensible commits. 4. Add docs and manual test instructions. 5. Output: PyPI-ready alpha package. Constraints: Do NOT use --yolo; use --allow patterns for safety. Verify all generated code manually before publishing. If inputs are missing, ask for the template URL and specific tool requirements. Deliverables: spec.md, source code, README, and test suite. Success metric: All tests pass, and the CLI runs without errors in a sandboxed environment.

Original source

Source reports are not independently verified. Publication date is the catalog publication date, not the original article date.

More cases · Software & development