Skip to content

feat(core): add dependency-free graph serialization - #891

Closed
Whxuan0701 wants to merge 1 commit into
apache:mainfrom
Whxuan0701:agent/graph-to-dict
Closed

Whxuan0701 wants to merge 1 commit into
apache:mainfrom
Whxuan0701:agent/graph-to-dict

Conversation

@Whxuan0701

Copy link
Copy Markdown

Expose a compact graph representation that external tools can consume without installing Graphviz or Burr's tracking dependencies.

Changes

  • add Graph.to_dict() with action, input, tag, and transition metadata
  • add ApplicationGraph.to_dict() with an explicit entrypoint and application_graph type
  • preserve action and transition declaration order while sorting set-like metadata
  • document that the compact export is distinct from the tracking ApplicationModel persistence format
  • cover deterministic ordering, required and optional inputs, conditions, and JSON round trips

How I tested this

  • pre-commit run --all-files
  • python -m pytest tests --ignore=tests/integrations/persisters --ignore=tests/integrations/test_bip0042_bedrock.py -q (645 passed, 1 skipped)
  • python -m sphinx -T -W --keep-going -b dirhtml -d <doctrees> -D language=en . <html> from docs/

Notes

This intentionally omits action source code. It is a dependency-free metadata export, not a replacement for the tracking subsystem's persisted graph schema.

Checklist

  • PR has an informative and human-readable title (this will be pulled into the release notes)
  • Changes are limited to a single goal (no scope creep)
  • Code passed the pre-commit check & code is left cleaner/nicer than when first encountered.
  • Any change in functionality is tested
  • New functions are documented (with a description, list of inputs, and expected output)
  • Placeholder code is flagged / future TODOs are captured in comments
  • Project documentation has been updated if adding/changing functionality.

@github-actions github-actions Bot added area/core Application, State, Graph, Actions area/website burr.apache.org website labels Aug 18, 2026
@github-actions

Copy link
Copy Markdown

This PR has had no activity for 96 days.
Closing to keep the PR list manageable.

Feel free to reopen when you are ready to continue.
If the branch has conflicts, a fresh PR against main might be easier.

@github-actions github-actions Bot closed this Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Application, State, Graph, Actions area/website burr.apache.org website

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant