Select the types of activity you want to include in your feed.
remove .claude/ and dist/ from repository
These directories are already in .gitignore but were committed before the ignore rules were added. Removed from tracking while keeping local files intact.
···11-# Project Subagents Configuration
22-# Domain-specific agents for working on different parts of the codebase.
33-#
44-# When working on a specific domain, spawn a Task with subagent_type="Explore" or
55-# "general-purpose" and include the relevant agent's context in the prompt.
66-#
77-# Customize this file for YOUR project's structure. The domains below are examples.
88-99-# Example: Backend/Core agent
1010-# [agents.backend]
1111-# name = "Backend Agent"
1212-# description = "API routes, database models, business logic"
1313-# file_patterns = [
1414-# "src/**/*.rs",
1515-# "src/**/*.py",
1616-# "app/**/*.py"
1717-# ]
1818-# focus_areas = [
1919-# "Database operations",
2020-# "API endpoints",
2121-# "Business logic"
2222-# ]
2323-# instructions = """
2424-# When working on backend:
2525-# - Run tests before and after changes
2626-# - Follow existing patterns for new endpoints
2727-# - Maintain backwards compatibility
2828-# """
2929-3030-# Example: Frontend agent
3131-# [agents.frontend]
3232-# name = "Frontend Agent"
3333-# description = "UI components, state management, styling"
3434-# file_patterns = [
3535-# "web/src/**/*.ts",
3636-# "web/src/**/*.tsx",
3737-# "src/components/**"
3838-# ]
3939-# focus_areas = [
4040-# "React components",
4141-# "State management",
4242-# "Styling and layout"
4343-# ]
4444-# instructions = """
4545-# When working on frontend:
4646-# - Test in browser after changes
4747-# - Follow component patterns
4848-# - Keep accessibility in mind
4949-# """
5050-5151-# Example: Infrastructure agent
5252-# [agents.infra]
5353-# name = "Infrastructure Agent"
5454-# description = "CI/CD, deployment, configuration"
5555-# file_patterns = [
5656-# ".github/workflows/**",
5757-# "Dockerfile",
5858-# "docker-compose.yml",
5959-# "scripts/**"
6060-# ]
6161-# focus_areas = [
6262-# "GitHub Actions",
6363-# "Docker configuration",
6464-# "Deployment scripts"
6565-# ]
6666-# instructions = """
6767-# When working on infrastructure:
6868-# - Test workflows locally when possible
6969-# - Keep builds fast with caching
7070-# - Document any manual steps
7171-# """
-274
.claude/commands/deciduous.decision.md
···11----
22-description: Manage decision graph - track algorithm choices and reasoning
33-allowed-tools: Bash(deciduous:*)
44-argument-hint: <action> [args...]
55----
66-77-# Decision Graph Management
88-99-**Log decisions IN REAL-TIME as you work, not retroactively.**
1010-1111-## When to Use This
1212-1313-| You're doing this... | Log this type | Command |
1414-|---------------------|---------------|---------|
1515-| Starting a new feature | `goal` **with -p** | `/decision add goal "Add user auth" -p "user request"` |
1616-| Choosing between approaches | `decision` | `/decision add decision "Choose auth method"` |
1717-| Considering an option | `option` | `/decision add option "JWT tokens"` |
1818-| About to write code | `action` | `/decision add action "Implementing JWT"` |
1919-| Noticing something | `observation` | `/decision add obs "Found existing auth code"` |
2020-| Finished something | `outcome` | `/decision add outcome "JWT working"` |
2121-2222-## Quick Commands
2323-2424-Based on $ARGUMENTS:
2525-2626-### View Commands
2727-- `nodes` or `list` -> `deciduous nodes`
2828-- `edges` -> `deciduous edges`
2929-- `graph` -> `deciduous graph`
3030-- `commands` -> `deciduous commands`
3131-3232-### Create Nodes (with optional metadata)
3333-- `add goal <title>` -> `deciduous add goal "<title>" -c 90`
3434-- `add decision <title>` -> `deciduous add decision "<title>" -c 75`
3535-- `add option <title>` -> `deciduous add option "<title>" -c 70`
3636-- `add action <title>` -> `deciduous add action "<title>" -c 85`
3737-- `add obs <title>` -> `deciduous add observation "<title>" -c 80`
3838-- `add outcome <title>` -> `deciduous add outcome "<title>" -c 90`
3939-4040-### Optional Flags for Nodes
4141-- `-c, --confidence <0-100>` - Confidence level
4242-- `-p, --prompt "..."` - Store the user prompt that triggered this node
4343-- `-f, --files "src/main.py,lib/utils.js"` - Associate files with this node
4444-- `-b, --branch <name>` - Git branch (auto-detected by default)
4545-- `--no-branch` - Skip branch auto-detection
4646-- `--commit <hash|HEAD>` - Link to a git commit (use HEAD for current commit)
4747-4848-### ⚠️ CRITICAL: Link Commits to Actions/Outcomes
4949-5050-**After every git commit, link it to the decision graph!**
5151-5252-```bash
5353-git commit -m "feat: add auth"
5454-deciduous add action "Implemented auth" -c 90 --commit HEAD
5555-deciduous link <goal_id> <action_id> -r "Implementation"
5656-```
5757-5858-## CRITICAL: Capture VERBATIM User Prompts
5959-6060-**Prompts must be the EXACT user message, not a summary.** When a user request triggers new work, capture their full message word-for-word.
6161-6262-**BAD - summaries are useless for context recovery:**
6363-```bash
6464-# DON'T DO THIS - this is a summary, not a prompt
6565-deciduous add goal "Add auth" -p "User asked: add login to the app"
6666-```
6767-6868-**GOOD - verbatim prompts enable full context recovery:**
6969-```bash
7070-# Use --prompt-stdin for multi-line prompts
7171-deciduous add goal "Add auth" -c 90 --prompt-stdin << 'EOF'
7272-I need to add user authentication to the app. Users should be able to sign up
7373-with email/password, and we need OAuth support for Google and GitHub. The auth
7474-should use JWT tokens with refresh token rotation.
7575-EOF
7676-7777-# Or use the prompt command to update existing nodes
7878-deciduous prompt 42 << 'EOF'
7979-The full verbatim user message goes here...
8080-EOF
8181-```
8282-8383-**When to capture prompts:**
8484-- Root `goal` nodes: YES - the FULL original request
8585-- Major direction changes: YES - when user redirects the work
8686-- Routine downstream nodes: NO - they inherit context via edges
8787-8888-**Updating prompts on existing nodes:**
8989-```bash
9090-deciduous prompt <node_id> "full verbatim prompt here"
9191-cat prompt.txt | deciduous prompt <node_id> # Multi-line from stdin
9292-```
9393-9494-Prompts are viewable in the TUI detail panel (`deciduous tui`) and web viewer.
9595-9696-## Branch-Based Grouping
9797-9898-**Nodes are automatically tagged with the current git branch.** This enables filtering by feature/PR.
9999-100100-### How It Works
101101-- When you create a node, the current git branch is stored in `metadata_json`
102102-- Configure which branches are "main" in `.deciduous/config.toml`:
103103- ```toml
104104- [branch]
105105- main_branches = ["main", "master"] # Branches not treated as "feature branches"
106106- auto_detect = true # Auto-detect branch on node creation
107107- ```
108108-- Nodes on feature branches (anything not in `main_branches`) can be grouped/filtered
109109-110110-### CLI Filtering
111111-```bash
112112-# Show only nodes from specific branch
113113-deciduous nodes --branch main
114114-deciduous nodes --branch feature-auth
115115-deciduous nodes -b my-feature
116116-117117-# Override auto-detection when creating nodes
118118-deciduous add goal "Feature work" -b feature-x # Force specific branch
119119-deciduous add goal "Universal note" --no-branch # No branch tag
120120-```
121121-122122-### Web UI Branch Filter
123123-The graph viewer shows a branch dropdown in the stats bar:
124124-- "All branches" shows everything
125125-- Select a specific branch to filter all views (Chains, Timeline, Graph, DAG)
126126-127127-### When to Use Branch Grouping
128128-- **Feature work**: Nodes created on `feature-auth` branch auto-grouped
129129-- **PR context**: Filter to see only decisions for a specific PR
130130-- **Cross-cutting concerns**: Use `--no-branch` for universal notes
131131-- **Retrospectives**: Filter by branch to see decision history per feature
132132-133133-### Create Edges
134134-- `link <from> <to> [reason]` -> `deciduous link <from> <to> -r "<reason>"`
135135-136136-### Sync Graph
137137-- `sync` -> `deciduous sync`
138138-139139-### Multi-User Sync (Diff/Patch)
140140-- `diff export -o <file>` -> `deciduous diff export -o <file>` (export nodes as patch)
141141-- `diff export --nodes 1-10 -o <file>` -> export specific nodes
142142-- `diff export --branch feature-x -o <file>` -> export nodes from branch
143143-- `diff apply <file>` -> `deciduous diff apply <file>` (apply patch, idempotent)
144144-- `diff apply --dry-run <file>` -> preview without applying
145145-- `diff status` -> `deciduous diff status` (list patches in .deciduous/patches/)
146146-- `migrate` -> `deciduous migrate` (add change_id columns for sync)
147147-148148-### Export & Visualization
149149-- `dot` -> `deciduous dot` (output DOT to stdout)
150150-- `dot --png` -> `deciduous dot --png -o graph.dot` (generate PNG)
151151-- `dot --nodes 1-11` -> `deciduous dot --nodes 1-11` (filter nodes)
152152-- `writeup` -> `deciduous writeup` (generate PR writeup)
153153-- `writeup -t "Title" --nodes 1-11` -> filtered writeup
154154-155155-## Node Types
156156-157157-| Type | Purpose | Example |
158158-|------|---------|---------|
159159-| `goal` | High-level objective | "Add user authentication" |
160160-| `decision` | Choice point with options | "Choose auth method" |
161161-| `option` | Possible approach | "Use JWT tokens" |
162162-| `action` | Something implemented | "Added JWT middleware" |
163163-| `outcome` | Result of action | "JWT auth working" |
164164-| `observation` | Finding or data point | "Existing code uses sessions" |
165165-166166-## Edge Types
167167-168168-| Type | Meaning |
169169-|------|---------|
170170-| `leads_to` | Natural progression |
171171-| `chosen` | Selected option |
172172-| `rejected` | Not selected (include reason!) |
173173-| `requires` | Dependency |
174174-| `blocks` | Preventing progress |
175175-| `enables` | Makes something possible |
176176-177177-## Graph Integrity - CRITICAL
178178-179179-**Every node MUST be logically connected.** Floating nodes break the graph's value.
180180-181181-### Connection Rules
182182-| Node Type | MUST connect to | Example |
183183-|-----------|----------------|---------|
184184-| `outcome` | The action/goal it resolves | "JWT working" → links FROM "Implementing JWT" |
185185-| `action` | The decision/goal that spawned it | "Implementing JWT" → links FROM "Add auth" |
186186-| `option` | Its parent decision | "Use JWT" → links FROM "Choose auth method" |
187187-| `observation` | Related goal/action/decision | "Found existing code" → links TO relevant node |
188188-| `decision` | Parent goal (if any) | "Choose auth" → links FROM "Add auth feature" |
189189-| `goal` | Can be a root (no parent needed) | Root goals are valid orphans |
190190-191191-### Audit Checklist
192192-Ask yourself after creating nodes:
193193-1. Does every **outcome** link back to what caused it?
194194-2. Does every **action** link to why you did it?
195195-3. Does every **option** link to its decision?
196196-4. Are there **dangling outcomes** with no parent action/goal?
197197-198198-### Find Disconnected Nodes
199199-```bash
200200-# List nodes with no incoming edges (potential orphans)
201201-deciduous edges | cut -d'>' -f2 | cut -d' ' -f2 | sort -u > /tmp/has_parent.txt
202202-deciduous nodes | tail -n+3 | awk '{print $1}' | while read id; do
203203- grep -q "^$id$" /tmp/has_parent.txt || echo "CHECK: $id"
204204-done
205205-```
206206-Note: Root goals are VALID orphans. Outcomes/actions/options usually are NOT.
207207-208208-### Fix Missing Connections
209209-```bash
210210-deciduous link <parent_id> <child_id> -r "Retroactive connection - <why>"
211211-```
212212-213213-### When to Audit
214214-- Before every `deciduous sync`
215215-- After creating multiple nodes quickly
216216-- At session end
217217-- When the web UI graph looks disconnected
218218-219219-## Multi-User Sync
220220-221221-**Problem**: Multiple users work on the same codebase, each with a local `.deciduous/deciduous.db` (gitignored). How to share decisions?
222222-223223-**Solution**: jj-inspired dual-ID model. Each node has:
224224-- `id` (integer): Local database primary key, different per machine
225225-- `change_id` (UUID): Globally unique, stable across all databases
226226-227227-### Export Workflow
228228-```bash
229229-# Export nodes from your branch as a patch file
230230-deciduous diff export --branch feature-x -o .deciduous/patches/alice-feature.json
231231-232232-# Or export specific node IDs
233233-deciduous diff export --nodes 172-188 -o .deciduous/patches/alice-feature.json --author alice
234234-```
235235-236236-### Apply Workflow
237237-```bash
238238-# Apply patches from teammates (idempotent - safe to re-apply)
239239-deciduous diff apply .deciduous/patches/*.json
240240-241241-# Preview what would change
242242-deciduous diff apply --dry-run .deciduous/patches/bob-refactor.json
243243-```
244244-245245-### PR Workflow
246246-1. Create nodes locally while working
247247-2. Export: `deciduous diff export --branch my-feature -o .deciduous/patches/my-feature.json`
248248-3. Commit the patch file (NOT the database)
249249-4. Open PR with patch file included
250250-5. Teammates pull and apply: `deciduous diff apply .deciduous/patches/my-feature.json`
251251-6. **Idempotent**: Same patch applied twice = no duplicates
252252-253253-### Patch Format (JSON)
254254-```json
255255-{
256256- "version": "1.0",
257257- "author": "alice",
258258- "branch": "feature/auth",
259259- "nodes": [{ "change_id": "uuid...", "title": "...", ... }],
260260- "edges": [{ "from_change_id": "uuid1", "to_change_id": "uuid2", ... }]
261261-}
262262-```
263263-264264-## The Rule
265265-266266-```
267267-LOG BEFORE YOU CODE, NOT AFTER.
268268-CONNECT EVERY NODE TO ITS PARENT.
269269-AUDIT FOR ORPHANS REGULARLY.
270270-SYNC BEFORE YOU PUSH.
271271-EXPORT PATCHES FOR YOUR TEAMMATES.
272272-```
273273-274274-**Live graph**: https://notactuallytreyanastasio.github.io/deciduous/
-192
.claude/commands/deciduous.recover.md
···11----
22-description: Recover context from decision graph and recent activity - USE THIS ON SESSION START
33-allowed-tools: Bash(deciduous:*, git:*, cat:*, tail:*)
44-argument-hint: [focus-area]
55----
66-77-# Context Recovery
88-99-**RUN THIS AT SESSION START.** The decision graph is your persistent memory.
1010-1111-## Step 1: Query the Graph
1212-1313-```bash
1414-# See all decisions (look for recent ones and pending status)
1515-deciduous nodes
1616-1717-# Filter by current branch (useful for feature work)
1818-deciduous nodes --branch $(git rev-parse --abbrev-ref HEAD)
1919-2020-# See how decisions connect
2121-deciduous edges
2222-2323-# What commands were recently run?
2424-deciduous commands
2525-```
2626-2727-**Branch-scoped context**: If working on a feature branch, filter nodes to see only decisions relevant to this branch. Main branch nodes are tagged with `[branch: main]`.
2828-2929-## Step 1.5: Audit Graph Integrity
3030-3131-**CRITICAL: Check that all nodes are logically connected.**
3232-3333-```bash
3434-# Find nodes with no incoming edges (potential missing connections)
3535-deciduous edges | cut -d'>' -f2 | cut -d' ' -f2 | sort -u > /tmp/has_parent.txt
3636-deciduous nodes | tail -n+3 | awk '{print $1}' | while read id; do
3737- grep -q "^$id$" /tmp/has_parent.txt || echo "CHECK: $id"
3838-done
3939-```
4040-4141-**Review each flagged node:**
4242-- Root `goal` nodes are VALID without parents
4343-- `outcome` nodes MUST link back to their action/goal
4444-- `action` nodes MUST link to their parent goal/decision
4545-- `option` nodes MUST link to their parent decision
4646-4747-**Fix missing connections:**
4848-```bash
4949-deciduous link <parent_id> <child_id> -r "Retroactive connection - <reason>"
5050-```
5151-5252-## Step 2: Check Git State
5353-5454-```bash
5555-git status
5656-git log --oneline -10
5757-git diff --stat
5858-```
5959-6060-## Step 3: Check Session Log
6161-6262-```bash
6363-cat git.log | tail -30
6464-```
6565-6666-## After Gathering Context, Report:
6767-6868-1. **Current branch** and pending changes
6969-2. **Branch-specific decisions** (filter by branch if on feature branch)
7070-3. **Recent decisions** (especially pending/active ones)
7171-4. **Last actions** from git log and command log
7272-5. **Open questions** or unresolved observations
7373-6. **Suggested next steps**
7474-7575-### Branch Configuration
7676-7777-Check `.deciduous/config.toml` for branch settings:
7878-```toml
7979-[branch]
8080-main_branches = ["main", "master"] # Which branches are "main"
8181-auto_detect = true # Auto-detect branch on node creation
8282-```
8383-8484----
8585-8686-## REMEMBER: Real-Time Logging Required
8787-8888-After recovering context, you MUST follow the logging workflow:
8989-9090-```
9191-EVERY USER REQUEST → Log goal/decision first
9292-BEFORE CODE CHANGES → Log action
9393-AFTER CHANGES → Log outcome, link nodes
9494-BEFORE GIT PUSH → deciduous sync
9595-```
9696-9797-**The user is watching the graph live.** Log as you go, not after.
9898-9999-### Quick Logging Commands
100100-101101-```bash
102102-# Root goal with user prompt (capture what the user asked for)
103103-deciduous add goal "What we're trying to do" -c 90 -p "User asked: <their request>"
104104-105105-deciduous add action "What I'm about to implement" -c 85
106106-deciduous add outcome "What happened" -c 95
107107-deciduous link FROM TO -r "Connection reason"
108108-109109-# Capture prompt when user redirects mid-stream
110110-deciduous add action "Switching approach" -c 85 -p "User said: use X instead"
111111-112112-deciduous sync # Do this frequently!
113113-```
114114-115115-**When to use `--prompt`:** On root goals (always) and when user gives new direction mid-stream. Downstream nodes inherit context via edges.
116116-117117----
118118-119119-## Focus Areas
120120-121121-If $ARGUMENTS specifies a focus, prioritize context for:
122122-123123-- **auth**: Authentication-related decisions
124124-- **ui** / **graph**: UI and graph viewer state
125125-- **cli**: Command-line interface changes
126126-- **api**: API endpoints and data structures
127127-128128----
129129-130130-## The Memory Loop
131131-132132-```
133133-SESSION START
134134- ↓
135135-Run /recover → See past decisions
136136- ↓
137137-AUDIT → Fix any orphan nodes first!
138138- ↓
139139-DO WORK → Log BEFORE each action
140140- ↓
141141-CONNECT → Link new nodes immediately
142142- ↓
143143-AFTER CHANGES → Log outcomes, observations
144144- ↓
145145-AUDIT AGAIN → Any new orphans?
146146- ↓
147147-BEFORE PUSH → deciduous sync
148148- ↓
149149-PUSH → Live graph updates
150150- ↓
151151-SESSION END → Final audit
152152- ↓
153153-(repeat)
154154-```
155155-156156-**Live graph**: https://notactuallytreyanastasio.github.io/deciduous/
157157-158158----
159159-160160-## Multi-User Sync
161161-162162-If working in a team, check for and apply patches from teammates:
163163-164164-```bash
165165-# Check for unapplied patches
166166-deciduous diff status
167167-168168-# Apply all patches (idempotent - safe to run multiple times)
169169-deciduous diff apply .deciduous/patches/*.json
170170-171171-# Preview before applying
172172-deciduous diff apply --dry-run .deciduous/patches/teammate-feature.json
173173-```
174174-175175-Before pushing your branch, export your decisions for teammates:
176176-177177-```bash
178178-# Export your branch's decisions as a patch
179179-deciduous diff export --branch $(git rev-parse --abbrev-ref HEAD) \
180180- -o .deciduous/patches/$(whoami)-$(git rev-parse --abbrev-ref HEAD).json
181181-182182-# Commit the patch file
183183-git add .deciduous/patches/
184184-```
185185-186186-## Why This Matters
187187-188188-- Context loss during compaction loses your reasoning
189189-- The graph survives - query it early, query it often
190190-- Retroactive logging misses details - log in the moment
191191-- The user sees the graph live - show your work
192192-- Patches share reasoning with teammates
-78
.claude/skills/deciduous/SKILL.md
···11----
22-name: deciduous
33-description: Plan, implement, track, and reflect on your work goals and decisions.
44----
55-66-# Planning & Decision Graph Logging
77-88-Track every goal, decision, and outcome in the decision graph. This creates persistent memory that survives context loss.
99-1010-- ALWAYS LOG BEFORE YOU CODE, NOT AFTER.
1111-- Log at the granularity of TODOs or task items.
1212-- When drafting a plan create the GOAL node.
1313-- User Decisions should be tracked
1414-1515-## When to Log (Automatic Triggers)
1616-1717-| Situation | Node Type | Example |
1818-|-----------|-----------|---------|
1919-| In plan mode | `goal` | "Add user authentication" |
2020-| TODO / Task Item | `action` | "Implementing JWT auth middleware" |
2121-| User requests new feature | `goal` | "Add user authentication" |
2222-| Choosing between approaches | `decision` | "Choose between JWT vs sessions" |
2323-| Considering an option | `option` | "Use JWT with refresh tokens" |
2424-| About to write/edit code | `action` | "Implementing JWT auth middleware" |
2525-| Work completed or failed | `outcome` | "JWT auth working" or "JWT approach failed" |
2626-| Important observation | `observation` | "Existing code uses cookie-based sessions" |
2727-2828-## Commands
2929-3030-```bash
3131-# Create nodes (always include confidence -c)
3232-deciduous add goal "Title" -c 90 -p "User's exact request"
3333-deciduous add decision "Title" -c 75
3434-deciduous add action "Title" -c 85
3535-deciduous add outcome "Title" -c 90
3636-deciduous add observation "Title" -c 80
3737-3838-# CRITICAL: Link nodes immediately after creation
3939-deciduous link <parent_id> <child_id> -r "Reason for connection"
4040-4141-# After git commits, link to the graph
4242-deciduous add action "Committed feature X" -c 90 --commit HEAD
4343-4444-# View the graph
4545-deciduous nodes
4646-deciduous edges
4747-```
4848-4949-## Rules
5050-5151-1. **Log BEFORE acting** - Create the action node before writing code
5252-2. **Link IMMEDIATELY** - Every node except root goals must have a parent
5353-3. **Capture verbatim prompts** - Use `-p` with the user's exact words for goals
5454-4. **Include confidence** - Always use `-c` flag (0-100)
5555-5. **Log outcomes** - Both successes AND failures get logged
5656-5757-## Confidence Guidelines
5858-5959-- 90-100: Certain, verified, tested
6060-- 75-89: High confidence, likely correct
6161-- 50-74: Moderate confidence, some uncertainty
6262-- Below 50: Experimental, speculative
6363-6464-## The Memory Loop
6565-6666-```
6767-User Request → Log goal with -p
6868- ↓
6969-Choose Approach → Log decision + options
7070- ↓
7171-Start Coding → Log action FIRST
7272- ↓
7373-Complete Work → Log outcome, link to parent
7474- ↓
7575-Git Commit → Log with --commit HEAD
7676-```
7777-7878-**Remember**: The decision graph is your persistent memory. Log as you work, not after.