Excelius-Wang opened a new pull request, #894: URL: https://github.com/apache/burr/pull/894
The `Graph` / `Application` split example on the applications page cannot be copy-pasted: it raises a `SyntaxError` before it gets anywhere. ## Changes Two lines in `docs/concepts/state-machine.rst`: - `with_state(chat_history=[])` was missing its leading dot, so the builder chain broke mid-expression. - The import read `from burr.core import ApplicationBuilder, default, expr`, which brings in two names the snippet never uses while leaving `GraphBuilder` undefined. Changed to `from burr.core import ApplicationBuilder, GraphBuilder`. ## How I tested this Ran the corrected snippet with a `human_input` / `ai_response` action pair defined as in the surrounding docs. It builds the graph and the application without error. The original raises `SyntaxError` at the `with_state` line, and after fixing only that, `NameError: name 'GraphBuilder' is not defined`. ## Notes Docs only, and deliberately separate from #893 so this one can go in on its own. Both branches touch `state-machine.rst` but not the same lines, so there is no conflict either way round. ## Checklist - [x] PR has an informative and human-readable title (this will be pulled into the release notes) - [x] Changes are limited to a single goal (no scope creep) - [x] Code passed the pre-commit check & code is left cleaner/nicer than when first encountered. - [x] Any _change_ in functionality is tested - [x] New functions are documented (with a description, list of inputs, and expected output) - [x] Placeholder code is flagged / future TODOs are captured in comments - [x] Project documentation has been updated if adding/changing functionality. Made with [Cursor](https://cursor.com) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
