Skip to content

feat(examples): add coding agent harness example - #886

Open
Agentic-JJ-Web3 wants to merge 2 commits into
apache:mainfrom
Agentic-JJ-Web3:docs/coding-agent-harness-example
Open

feat(examples): add coding agent harness example#886
Agentic-JJ-Web3 wants to merge 2 commits into
apache:mainfrom
Agentic-JJ-Web3:docs/coding-agent-harness-example

Conversation

@Agentic-JJ-Web3

Copy link
Copy Markdown

Part of #885. This is the first of three PRs — steps 1–3 of your outline
(harness loop, basic tools, running it with tests and the Burr UI). CLI and
permissions follow separately.

What's here

examples/coding-agent/ — an agent that reads files, writes files, lists a
directory, and runs shell commands, looping until the model answers without
requesting a tool or the step budget runs out.

The graph is human_input → create_prompt → call_llm, with four bound tool
actions fanning out of call_llm and looping back to it. Each tool is bound
separately rather than dispatched from a registry, so the Burr UI shows which
one ran at each step.

Decisions I made without you

You hadn't replied yet, so these are assumptions rather than agreements —
happy to change any of them:

  1. Scripted LLM client by default. notebook.ipynb is a required file and
    has to execute, so the example falls back to a client replaying a fixed
    sequence of tool calls when OPENAI_API_KEY isn't set. Real OpenAI client
    when it is.
  2. run_bash is not sandboxed. File paths are confined to a workspace
    directory, but a shell command can cd out. The README says so plainly,
    which leaves step 5 something concrete to fix.
  3. Four tools, not three — added list_files, since an agent that can't
    see the directory can't orient itself.
  4. One tool call per iteration. If the model requests several, the extras
    are dropped. Documented as a known simplification.

Notes

  • validate_examples.py passes for coding-agent.
  • The tool schema marks only parameters without defaults as required. The
    tool-calling example marks all of them, which misreports optional args —
    happy to open a separate issue for that.
  • examples/hello-world-counter crashes at app.visualize() unless the
    Graphviz binary is installed, and passing a stale app_id after clearing
    ~/.burr raises a pydantic error on PointerModel.app_id. Both separate
    from this PR; can file them if useful.

@github-actions github-actions Bot added the area/examples Relates to /examples label Aug 16, 2026
@Agentic-JJ-Web3

Copy link
Copy Markdown
Author

Opened #886 with steps 1–3. I made a few calls in the absence of answers to my questions above — they're listed in the PR description, happy to change any of them.

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

Labels

area/examples Relates to /examples

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant