Commit graph

1269 commits

Author SHA1 Message Date
Bryan Helmkamp
0587fae2e5 Docs: add auto-merge config, auto-merge to GitHub features, turn-level retries
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 19:06:15 -04:00
Bryan Helmkamp
8586e54596 Add March 16 changelog and update March 15 with new entries
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 19:03:47 -04:00
Bryan Helmkamp
3bd2a43499 Roadmap: replace inline shipped descriptions with hover tooltip
Saves vertical space by showing only date + title in shipped rows,
with an info icon that reveals the description on hover.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 18:27:58 -04:00
Bryan Helmkamp
38ec5d2846 Add blog and redesign blog/roadmap pages
- Add blog collection (content config, prose styles, introducing-fabro post)
- Add Blog link to homepage nav and footer
- Make Layout description prop dynamic for per-page meta/OG tags
- Extract shared Nav, Footer, PageScripts components from duplicated markup
- Blog index: compact header, featured card for latest post, row list for older posts
- Blog post: clean reading surface (no grid/noise overlay), reading time, better header
- Roadmap: improved card contrast with tinted backgrounds, conditional section rendering

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 18:26:10 -04:00
Bryan Helmkamp
d8155a305c Reduce default patch generation concurrency to 75
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 16:05:24 -04:00
Bryan Helmkamp
0ea22dafe8 Handle assistant output replay on stream retries 2026-03-16 15:59:00 -04:00
Bryan Helmkamp
a1497aa19b Fix typos in docs: "appliction" and "an Fabro"
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 15:57:33 -04:00
Bryan Helmkamp
fb3b7bc9c7 Fix broken link and stale badge label in README
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 15:25:31 -04:00
Bryan Helmkamp
06603fc579 Add turn-level retry for stream-ended-without-Finish errors
When an LLM stream drops mid-response (e.g. under high concurrency with
OpenAI), retry the same turn up to 3 times instead of failing the entire
agent session. Conversation history is preserved across retries.

Previously this killed the whole stage and restarted from scratch.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 15:16:35 -04:00
Bryan Helmkamp
dfcece9a0d Record Opus 4.6 20min timeout: 58.0% on SWE-Bench-Lite ($218.65)
100% patch rate, 0 timeouts. Only +1 instance over Sonnet at 4x the cost.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 14:43:20 -04:00
Bryan Helmkamp
d13972e195 Update install instructions to show Claude Code, Codex, and Bash methods
Match the marketing website's tabbed install widget across README, docs
quick-start, and CLAUDE.md. Add marketing site build/deploy commands.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 14:03:53 -04:00
Bryan Helmkamp
26d0a6a562 Add tabbed install widget (Claude/Codex/Bash) with copy buttons, show hero screenshot on load
Replace single curl command with a tabbed install widget defaulting to Claude,
with Codex and Bash alternatives. Each tab has a copy-to-clipboard button.
Remove scroll-reveal animation from hero screenshot so it's visible immediately.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 13:56:42 -04:00
Bryan Helmkamp
165742d7fa Record Sonnet 4.6 20min timeout: 57.7% on SWE-Bench-Lite ($55.22)
20min timeout vs 10min: 173 vs 167 resolved (+6), patch rate 99% vs 94%.
Also fixes: revert to v4 snapshots, concurrency default to 100, preflight
uses actual 4 CPU per sandbox.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 13:36:26 -04:00
Bryan Helmkamp
0cc02c294d Move install files to apps/marketing/public, symlink from repo root
Vercel deploys only the apps/marketing/ subtree, so the real files
need to live there. Repo root now symlinks into marketing/public.
Also add .vercel to gitignore.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 13:23:58 -04:00
Bryan Helmkamp
5fad662651 Temporarily hide Roadmap from nav while content is being written
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:51:55 -04:00
Bryan Helmkamp
4d93fa55df Improve marketing site mobile layout: reduce hero top spacing and hide curl command
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:46:22 -04:00
Bryan Helmkamp
0db08b937c Fix snapshot CPU mismatch: use v4 snapshots (4 CPU), reduce concurrency to 100
Daytona bakes CPU/memory at snapshot creation time. v4 snapshots have
4 CPU / 8 GB. Preflight now checks against 4 CPU per sandbox.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:44:14 -04:00
Bryan Helmkamp
241be62cde Reduce default concurrency to 150, increase default timeout to 20min
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:32:18 -04:00
Bryan Helmkamp
5d2f4c0828 Add llms.txt and additional meta tags for marketing site
- Add llms.txt with structured overview of Fabro docs for LLM consumption
- Add canonical link, application-name, apple-mobile-web-app-title
- Add twitter:image dimensions
- Make og:url dynamic per page

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:30:16 -04:00
Bryan Helmkamp
7b452a0783 Add OG image and meta tags for link sharing, remove comma from tagline
- Add 1200x630 branded OG image matching Mintlify docs card style
- Add Open Graph and Twitter Card meta tags to Layout.astro
- Save og-image-template.html for easy regeneration
- Remove comma from "open source, dark software factory" everywhere

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:24:58 -04:00
Bryan Helmkamp
582fe2b0c4 Fix marketing site mobile layout: responsive nav and content overflow
Nav links, icons, and CTA button overflowed the viewport on mobile.
Text in Workflow-as-Code and Multi-model sections was clipped because
wide SVG/pre children caused CSS grid blowout (min-width: auto default).

- Add hamburger menu for mobile nav on both pages (hidden md:, toggle JS)
- Add overflow-x-hidden to html/body/main to prevent horizontal scroll
- Add .grid > * { min-width: 0 } to prevent grid children from expanding
  beyond their container

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:23:35 -04:00
Bryan Helmkamp
adf6594b97 Add Daytona CPU preflight check before starting eval runs
Checks running sandboxes against the 500 CPU org limit with 20% buffer.
Exits with a suggested --max-workers value if capacity is insufficient.
Default concurrency set to 200 (safe with 2 CPU per sandbox).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:20:36 -04:00
Bryan Helmkamp
d6041b9c18 Migrate roadmap data to Astro content collections
Replace inline arrays with a `roadmap` collection using glob loader
and Zod schema. Each item is a YAML file in src/content/roadmap/ with
title, description, status, date, and sortOrder fields.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:17:31 -04:00
Bryan Helmkamp
b86851c51a Add REPL Handoff example workflow to docs
Documents the pattern of planning interactively in Claude Code and
delegating implementation to Fabro via the /fabro-implement slash
command, with multi-model simplification and verification gates.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:13:05 -04:00
Bryan Helmkamp
4c86c87c78 Add /roadmap page to marketing site with timeline layout
Shipped/Building/Next sections with sample content, vertical timeline,
scroll reveal animations, and matching dark factory aesthetic. Linked
from top nav and footer on both pages.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:04:48 -04:00
Bryan Helmkamp
830bd2cefe Update marketing site: copyright to Qlty Software Inc. and allow ngrok hosts
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 11:58:29 -04:00
Bryan Helmkamp
942054c43a Record timeout and sandbox resources in scoreboard metadata
Adds --timeout, --sandbox-cpu, --sandbox-memory flags to record_results.py.
Re-recorded both existing runs with the new fields.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 11:24:56 -04:00
Bryan Helmkamp
5eccf9701b Record Sonnet 4.6 baseline: 55.7% on SWE-Bench-Lite ($39.78)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 11:23:23 -04:00
Bryan Helmkamp
06ce28bcea Add install.md for AI agent-driven installation
Self-contained installation instructions following the install.md spec.
Decoupled from install.sh — handles platform detection, binary download,
PATH setup in shell dotfiles, and verification independently. Prompts
the user to run `fabro install` interactively to complete setup.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 11:07:21 -04:00
Bryan Helmkamp
939fd58a49 Skip shell config modification in non-interactive mode
Prevents install.sh from silently writing to dotfiles (.zshrc, .bashrc,
config.fish) when run non-interactively (e.g. by an AI coding agent).
In non-interactive mode, it now prints the manual PATH export instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 11:01:42 -04:00
Bryan Helmkamp
2cf15d0a8d Add status.py for quick progress checks on generation and eval runs
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:59:49 -04:00
Bryan Helmkamp
777358e8d6 Add Discord and Changelog links to marketing site nav and footer
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:56:10 -04:00
Bryan Helmkamp
7f95d5f518 Switch display font from Barlow Condensed to Space Grotesk
Replace aggressive uppercase/wide-tracking headings with sentence-case
tight-tracking for a more natural, geometric-techy feel.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:50:53 -04:00
Bryan Helmkamp
6403ab029a Redesign marketing site with industrial-refined visual identity
Replace Sora with Barlow Condensed uppercase headings, add cross-hatch grid
and noise atmosphere, swap emoji for custom SVG line-art icons, add scroll
animation variants (reveal-left/right/scale), animated trace bars and workflow
graph draw-in, convert images to WebP with picture fallbacks, expand footer
to 3-column layout, and consolidate sections from 12 to 8.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:48:52 -04:00
Bryan Helmkamp
e26286d966 Add best-effort Daytona sandbox cleanup on timeout and disable PR creation
On timeout, finds the orphaned sandbox via fabro ps --label and deletes
it. Non-fatal if cleanup fails. Also adds [pull_request] enabled=false
to generated workflow.toml configs to prevent eval runs from opening PRs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:42:47 -04:00
Bryan Helmkamp
cd786bb875 Add install.sh serving and /discord, /docs redirects to marketing site
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:33:25 -04:00
Bryan Helmkamp
b491542e95 Make SWE-bench patch generation and evaluation resumable
On restart, reads existing output JSONL files to find completed instance
IDs, skips them, and appends new results. Final summary recomputes from
the full results file so it reflects all runs combined.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:33:06 -04:00
Bryan Helmkamp
2924968a8a Add screenshots, workflow diagram, lightbox, and fix logotype viewBox
- Add runs-board.png below hero as product showcase
- Add plan-implement.svg workflow diagram in Workflow-as-Code section
  above the DOT code block, with dark-mode contrast fix
- Replace verification 2x2 card grid with run-detail.png screenshot
- Add click-to-expand lightbox for all three visual assets
- Fix logotype SVG viewBox (0 0 1455 → 0 0 1500) across all 5 files
  to prevent "O" in FABRO from being clipped
- Increase Docs link contrast in nav (text-ice-100, font-medium)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 10:09:57 -04:00
Bryan Helmkamp
c2a89a5898 Add SWE-bench eval README with setup, usage, and monitoring instructions
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 09:59:03 -04:00
Bryan Helmkamp
0431ad1a05 Add scoreboard system and record Haiku 4.5 baseline: 54.0% on SWE-Bench-Lite
record_results.py combines generation + eval results into a git-tracked
scoreboard. Per run: README, meta.json, instances.jsonl. Auto-generates
leaderboard.json ranked by resolve rate.

Haiku 4.5 baseline: 162/300 (54.0%), $26.13 total ($0.087/instance).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 09:56:43 -04:00
Bryan Helmkamp
7acbcb41b3 Use full logotype in nav/footer and improve header layout
Replace symbol+text logo with full FABRO logotype SVG in both nav and
footer. Move Docs link to left side next to logo. Replace GitHub text
link with GitHub SVG icon on the right side.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 09:54:59 -04:00
Bryan Helmkamp
3b8e8f5f23 Update marketing website with Fabro branding and current product content
Replace Arc logo/favicon with Fabro isometric symbol, update hero tagline
to "dark software factory", add install command, and rewrite all sections
to match current README and docs: use cases, key features (workflow graphs,
human-in-the-loop, multi-model routing, cloud sandboxes, git checkpointing,
retros), workflow-as-code example, CLI showcase, and sandbox section.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 09:52:55 -04:00
Bryan Helmkamp
fe1f4f346c Add Daytona-based SWE-bench evaluator and bump default concurrency to 100
evaluate_daytona.py runs the swebench test harness on Daytona sandboxes
instead of local Docker. Reuses the same snapshots from the generation
phase. Applies model patch + test patch, runs tests, grades with
swebench's log parsers. No local Docker needed.

Also bumps default --max-workers from 20 to 100 in run_eval.py.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 09:13:09 -04:00
Bryan Helmkamp
0ef79bfd3e Fix run_eval.py: resolve output-dir to absolute path
When --output-dir is relative and fabro runs from /tmp, generated
workflow.toml paths were unresolvable.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 08:39:24 -04:00
Bryan Helmkamp
e246b7f4bb Add SWE-bench evaluation harness
Python scripts for running SWE-bench Lite evals against Fabro agent
in Daytona sandboxes: instance orchestration, Dockerfile generation,
and result evaluation via the official swebench harness.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 08:37:24 -04:00
Bryan Helmkamp
c9656e8a8f add background brand asset 2026-03-16 08:37:24 -04:00
Bryan Helmkamp
8716d235d1 Add auto-merge support for pull requests via GitHub GraphQL API
When `auto_merge = true` is set in `[pull_request]` config, Fabro enables
GitHub's auto-merge on created PRs using the `enablePullRequestAutoMerge`
GraphQL mutation. Auto-merge implies `draft = false` since GitHub doesn't
allow auto-merge on draft PRs. A `merge_strategy` field (squash/merge/rebase,
default squash) controls the merge method. Failures to enable auto-merge
(e.g. repo doesn't have the setting enabled) warn but don't fail the run.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 08:37:24 -04:00
brynary-fabro[bot]
e3967183c6 Fix: Sub-agent file writes not tracked in API backend (#17)
This PR fixes a bug where files written by sub-agents were missing from
`outcome.files_touched`, causing downstream pipeline nodes like
`simplify_opus` to receive incomplete file lists. The root cause was
that `spawn_event_forwarder` only matched top-level
`ToolCallStarted`/`ToolCallCompleted` events, while sub-agent tool calls
arrived wrapped in `AgentEvent::SubAgentEvent` and fell through to the
`_ => {}` catch-all.

The fix extracts the file-tracking logic into a standalone
`track_file_event` function that recursively unwraps `SubAgentEvent`
layers before matching on the inner tool call events. This handles
arbitrarily nested sub-agent hierarchies (sub-sub-agents, etc.). The
three separate `Arc<Mutex<...>>` fields for pending calls, touched
files, and last file are consolidated into a single `FileTracking`
struct behind one lock, simplifying the forwarder signature and reducing
lock contention.

Four new unit tests verify the behavior: top-level write tracking,
single-level sub-agent unwrapping, double-nested sub-sub-agent
unwrapping, and proper cleanup of pending entries on tool call errors.

### Fabro Details

<details>
<summary>Ran 10 stages in 22m 1s for $4.18</summary>

| Stage | Duration | Cost | Retries |
|---|---|---|---|
| start | 0s | – | 0 |
| toolchain | 0s | – | 0 |
| preflight_compile | 0s | – | 0 |
| preflight_lint | 0s | – | 0 |
| implement | 0s | $0.91 | 0 |
| simplify_opus | 0s | $0.89 | 0 |
| simplify_gemini | 0s | $1.44 | 0 |
| simplify_gpt | 0s | $0.94 | 0 |
| verify | 0s | – | 0 |
| fmt | 0s | – | 0 |
| **Total** | **22m 1s** | **$4.18** | **0** |

</details>

<details>
<summary>Ran <code>ImplementAndSimplify.fabro</code> (13 nodes and 16
edges)</summary>

```dot
digraph ImplementAndSimplify {
    graph [
        goal="Implement and simplify",
        model_stylesheet="
            * { backend: api; model: claude-opus-4-6;}
        "
    ]
    rankdir=LR

    start [shape=Mdiamond, label="Start"]
    exit  [shape=Msquare, label="Exit"]

    toolchain         [label="Toolchain", shape=parallelogram, script="command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1", max_retries=0]
    preflight_compile [label="Preflight Compile", shape=parallelogram, script="cargo check -q --workspace 2>&1", max_retries=0]
    preflight_lint    [label="Preflight Lint", shape=parallelogram, script="cargo clippy -q --workspace -- -D warnings 2>&1", max_retries=0]
    fix_lints         [label="Fix Lints", prompt="The preflight lint step failed. Read the build output from context and fix all clippy lint warnings.", max_visits=3]
    implement         [label="Implement", prompt="Read the plan file referenced in the goal and implement every step. Make all the code changes described in the plan. Use red/green TDD."]
    simplify_opus     [label="Simplify (Opus)", prompt="@prompts/simplify.md"]
    simplify_gemini   [label="Simplify (Gemini)", prompt="@prompts/simplify.md", model="gemini-3.1-pro-preview-customtools"]
    simplify_gpt      [label="Simplify (GPT-54)", prompt="@prompts/simplify.md", model="gpt-54"]
    verify            [label="Verify", shape=parallelogram, script="cargo clippy -q --workspace -- -D warnings 2>&1 && cargo nextest run --cargo-quiet --workspace --status-level fail 2>&1", goal_gate=true, retry_target="fixup"]
    fixup             [label="Fixup", prompt="The verify step failed. Read the build output from context and fix all clippy lint warnings and test failures.", max_visits=3]
    fmt               [label="Format", shape=parallelogram, script="cargo fmt --all 2>&1", goal_gate=true, max_retries=0]

    start -> toolchain
    toolchain -> preflight_compile [condition="outcome=success"]
    toolchain -> exit
    preflight_compile -> preflight_lint [condition="outcome=success"]
    preflight_compile -> exit
    preflight_lint -> implement [condition="outcome=success"]
    preflight_lint -> fix_lints
    fix_lints -> preflight_lint
    implement -> simplify_opus -> simplify_gemini -> simplify_gpt -> verify
    verify -> fmt   [condition="outcome=success"]
    verify -> fixup
    fixup -> verify
    fmt -> exit
}

```

</details>

⚒️ Generated with [Fabro](https://fabro.sh)

---------

Co-authored-by: Fabro <noreply@fabro.sh>
2026-03-15 23:18:40 -04:00
brynary-fabro[bot]
9a48c61d3e Limit command stdout/stderr to last N lines in preamble (#16)
This PR limits command stdout/stderr output in the preamble to the last
N lines, reducing token waste from verbose build progress and download
noise. Command nodes like `cargo check` or `cargo clippy` can produce
300+ lines of output, but the useful content (errors, summaries) is
almost always at the tail. Compact and summary:medium fidelity levels
now keep the last 25 lines, while summary:high keeps the last 50 lines.
Truncated output displays an `(N lines omitted)` indicator consistent
with the existing omission pattern used for stages.

The implementation adds a `tail_lines` helper that skips leading lines
beyond the limit, prepends an omission notice, and applies the
appropriate indentation to each retained line. This is applied only to
inline stdout/stderr rendering—artifact pointer branches and other
fidelity levels (summary:low, truncate, full) are intentionally
untouched. The PR includes unit tests for the `tail_lines` helper itself
as well as integration tests verifying truncation behavior at compact
and summary:high fidelity, and confirming artifact pointers remain
untruncated.

### Fabro Details

<details>
<summary>Ran 10 stages in 18m 4s for $3.45</summary>

| Stage | Duration | Cost | Retries |
|---|---|---|---|
| start | 0s | – | 0 |
| toolchain | 0s | – | 0 |
| preflight_compile | 0s | – | 0 |
| preflight_lint | 0s | – | 0 |
| implement | 0s | $0.84 | 0 |
| simplify_opus | 0s | $0.95 | 0 |
| simplify_gemini | 0s | $0.81 | 0 |
| simplify_gpt | 0s | $0.85 | 0 |
| verify | 0s | – | 0 |
| fmt | 0s | – | 0 |
| **Total** | **18m 4s** | **$3.45** | **0** |

</details>

<details>
<summary>Ran <code>ImplementAndSimplify.fabro</code> (13 nodes and 16
edges)</summary>

```dot
digraph ImplementAndSimplify {
    graph [
        goal="Implement and simplify",
        model_stylesheet="
            * { backend: api; model: claude-opus-4-6;}
        "
    ]
    rankdir=LR

    start [shape=Mdiamond, label="Start"]
    exit  [shape=Msquare, label="Exit"]

    toolchain         [label="Toolchain", shape=parallelogram, script="command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1", max_retries=0]
    preflight_compile [label="Preflight Compile", shape=parallelogram, script="cargo check -q --workspace 2>&1", max_retries=0]
    preflight_lint    [label="Preflight Lint", shape=parallelogram, script="cargo clippy -q --workspace -- -D warnings 2>&1", max_retries=0]
    fix_lints         [label="Fix Lints", prompt="The preflight lint step failed. Read the build output from context and fix all clippy lint warnings.", max_visits=3]
    implement         [label="Implement", prompt="Read the plan file referenced in the goal and implement every step. Make all the code changes described in the plan. Use red/green TDD."]
    simplify_opus     [label="Simplify (Opus)", prompt="@prompts/simplify.md"]
    simplify_gemini   [label="Simplify (Gemini)", prompt="@prompts/simplify.md", model="gemini-3.1-pro-preview-customtools"]
    simplify_gpt      [label="Simplify (GPT-54)", prompt="@prompts/simplify.md", model="gpt-54"]
    verify            [label="Verify", shape=parallelogram, script="cargo clippy -q --workspace -- -D warnings 2>&1 && cargo nextest run --cargo-quiet --workspace --status-level fail 2>&1", goal_gate=true, retry_target="fixup"]
    fixup             [label="Fixup", prompt="The verify step failed. Read the build output from context and fix all clippy lint warnings and test failures.", max_visits=3]
    fmt               [label="Format", shape=parallelogram, script="cargo fmt --all 2>&1", goal_gate=true, max_retries=0]

    start -> toolchain
    toolchain -> preflight_compile [condition="outcome=success"]
    toolchain -> exit
    preflight_compile -> preflight_lint [condition="outcome=success"]
    preflight_compile -> exit
    preflight_lint -> implement [condition="outcome=success"]
    preflight_lint -> fix_lints
    fix_lints -> preflight_lint
    implement -> simplify_opus -> simplify_gemini -> simplify_gpt -> verify
    verify -> fmt   [condition="outcome=success"]
    verify -> fixup
    fixup -> verify
    fmt -> exit
}

```

</details>

⚒️ Generated with [Fabro](https://fabro.sh)

---------

Co-authored-by: Fabro <noreply@fabro.sh>
2026-03-15 23:18:13 -04:00
brynary-fabro[bot]
bd636a16cd Add --direction flag to fabro graph (#15)
This PR adds a `--direction` (`-d`) flag to the `fabro graph` CLI
command, bringing it to parity with the web UI's LR/TB toggle buttons.
Users can now pass `--direction lr` or `--direction tb` to override the
`rankdir` declared in the DOT source before it's handed off to the `dot`
renderer.

The implementation introduces a `GraphDirection` enum (with `ValueEnum`
and `Display` derives for clap integration), an optional `--direction`
field on `GraphArgs`, and an `apply_direction` helper that uses a
lazy-compiled regex to rewrite `rankdir=…` in the DOT source—mirroring
the same approach used by the web UI. The CLI docs are updated with the
new flag, and two unit tests verify that the rewrite works correctly and
that omitting the flag leaves the source unchanged.

### Fabro Details

<details>
<summary>Ran 10 stages in 17m 6s for $3.60</summary>

| Stage | Duration | Cost | Retries |
|---|---|---|---|
| start | 0s | – | 0 |
| toolchain | 0s | – | 0 |
| preflight_compile | 0s | – | 0 |
| preflight_lint | 0s | – | 0 |
| implement | 0s | $0.68 | 0 |
| simplify_opus | 0s | $1.02 | 0 |
| simplify_gemini | 0s | $0.83 | 0 |
| simplify_gpt | 0s | $1.06 | 0 |
| verify | 0s | – | 0 |
| fmt | 0s | – | 0 |
| **Total** | **17m 6s** | **$3.60** | **0** |

</details>

<details>
<summary>Ran <code>ImplementAndSimplify.fabro</code> (13 nodes and 16
edges)</summary>

```dot
digraph ImplementAndSimplify {
    graph [
        goal="Implement and simplify",
        model_stylesheet="
            * { backend: api; model: claude-opus-4-6;}
        "
    ]
    rankdir=LR

    start [shape=Mdiamond, label="Start"]
    exit  [shape=Msquare, label="Exit"]

    toolchain         [label="Toolchain", shape=parallelogram, script="command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1", max_retries=0]
    preflight_compile [label="Preflight Compile", shape=parallelogram, script="cargo check 2>&1", max_retries=0]
    preflight_lint    [label="Preflight Lint", shape=parallelogram, script="cargo clippy -- -D warnings 2>&1", max_retries=0]
    fix_lints         [label="Fix Lints", prompt="The preflight lint step failed. Read the build output from context and fix all clippy lint warnings.", max_visits=3]
    implement         [label="Implement", prompt="Read the plan file referenced in the goal and implement every step. Make all the code changes described in the plan."]
    simplify_opus     [label="Simplify (Opus)", prompt="@prompts/simplify.md"]
    simplify_gemini   [label="Simplify (Gemini)", prompt="@prompts/simplify.md", model="gemini-3.1-pro-preview-customtools"]
    simplify_gpt      [label="Simplify (GPT-54)", prompt="@prompts/simplify.md", model="gpt-54"]
    verify            [label="Verify", shape=parallelogram, script="cargo clippy -- -D warnings 2>&1 && cargo test 2>&1", goal_gate=true, retry_target="fixup"]
    fixup             [label="Fixup", prompt="The verify step failed. Read the build output from context and fix all clippy lint warnings and test failures.", max_visits=3]
    fmt               [label="Format", shape=parallelogram, script="cargo fmt --all 2>&1", goal_gate=true, max_retries=0]

    start -> toolchain
    toolchain -> preflight_compile [condition="outcome=success"]
    toolchain -> exit
    preflight_compile -> preflight_lint [condition="outcome=success"]
    preflight_compile -> exit
    preflight_lint -> implement [condition="outcome=success"]
    preflight_lint -> fix_lints
    fix_lints -> preflight_lint
    implement -> simplify_opus -> simplify_gemini -> simplify_gpt -> verify
    verify -> fmt   [condition="outcome=success"]
    verify -> fixup
    fixup -> verify
    fmt -> exit
}

```

</details>

⚒️ Generated with [Fabro](https://fabro.sh)

---------

Co-authored-by: Fabro <noreply@fabro.sh>
2026-03-15 23:18:05 -04:00