Exporting Your Work
The decision graph lives in a local SQLite database. To share it with others, you export it—as JSON for the web, as DOT for visualizations, or as markdown for pull requests.
Sync — Export for GitHub Pages
The deciduous sync command exports your entire graph as JSON files suitable for static hosting:
This creates two files in your docs/ directory:
| File | Contents |
|---|---|
docs/graph-data.json |
All nodes, edges, metadata, and prompts |
docs/git-history.json |
Commit messages, authors, and dates for nodes linked via --commit |
The web viewer (docs/index.html) reads these JSON files. Once synced and pushed to GitHub, anyone can browse the decision graph in a browser—no deciduous installation needed.
Deploying to GitHub Pages
After running deciduous sync, deploying is three steps:
Then in your GitHub repository settings, go to Pages, select Deploy from branch, and choose the /docs folder. Your graph will be live at https://<user>.github.io/<repo>/.
PR Writeups
The deciduous writeup command generates a markdown summary of a set of nodes, suitable for pasting into a pull request body:
The writeup pulls goal titles, decision rationales, action summaries, and outcome statuses directly from the graph. The --auto flag detects a branch-specific PNG and embeds it as an image link.
Key flags for deciduous writeup:
| Flag | Effect |
|---|---|
-t, --title |
PR title used in the summary header |
-n, --nodes |
Node IDs or ranges to include (e.g., 57-61 or 57,58,60) |
-r, --roots |
Root node IDs—BFS traverses all children |
--auto |
Auto-detect branch-specific PNG for embedding |
--png |
Specify a PNG filename manually |
--no-dot |
Skip the DOT graph section |
--no-test-plan |
Skip the test plan checklist |
-o, --output |
Write to file instead of stdout |
Attaching Writeups to the Graph
You can attach the generated writeup back to the graph as a document, creating a permanent record:
Backups
Before any major export or sync operation, it is good practice to create a backup of the database:
Backups are timestamped SQLite copies stored in .deciduous/backups/. If anything goes wrong during a sync or export, you can restore from the most recent backup by copying it over the main database.
The SQLite database at .deciduous/deciduous.db is the source of truth. Always use deciduous backup before risky operations, and never delete the database file directly.