Commit Graph

37 Commits

Author SHA1 Message Date
Julius Brussee 9aa1905f7d team: kit-level Files column scopes claims, plus install fix for team subcommand
Add an optional trailing `Files` column to build-site task tables declaring
each task's expected file footprint (comma- or semicolon-separated globs).

- Parser: Task gains Files []string; trailing column parsed for tier 0
  (cell[5]) and tier N (cell[6]). Empty / "-" treated as unset.
- Scheduler: replaces substring heuristic with real PathsOverlap check when
  Files is present; falls back to the old spec-substring hint for legacy
  sites. NextSuggestion now returns the task's Files as Paths.
- Claim: if --paths is omitted and the kit declares Files, Claim defaults
  to those globs. Removes the "user forgot --paths" failure mode and means
  the pre-commit guard gets correct scope without anyone guessing.
- Tests: parser Files parsing (both tiers, both separators, placeholder
  dashes); Claim_DefaultsPathsFromSiteFiles asserts the claim event records
  the kit's Files in the ledger.

Install: `scripts/cavekit` never dispatched `team` to the Go binary, so
`cavekit team init` failed on every fresh install. Fixed by:
- install.sh builds cmd/cavekit → $INSTALL_DIR/bin/cavekit-bin (warn if
  `go` is missing).
- scripts/cavekit delegates team/version/debug/reset/status/monitor to the
  Go binary via a delegate_to_bin helper.

Docs: README gets a "Teams" section describing setup, the Files column,
day-to-day commands, and where configuration lives.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-18 18:13:06 +02:00
Julius Brussee a71317eb1d Add 'team' subcommand and team support
Introduce a new team coordination feature: adds a `team` subcommand to the cavekit CLI, the internal team implementation, and documentation/spec kits. Changes include:

- CLI: register `team` in cmd/cavekit/main.go and implement subcommands in cmd/cavekit/team.go (init, join, status, claim, release, sync, internal heartbeat). Supports --json output and deterministic exit codes with exit helpers.
- Internal: new internal/team package (config, identity, lease, ledger, manager, gitpatch, tests) to implement file-based ledger, leases, and claim/release protocol.
- Docs: new / updated docs and kits under commands/ and context/kits/ describing slash-command wrappers (/ck:team), TUI integration, CLI spec, and make-loop dispatch/heartbeat semantics.
- Integration: update commands (make, make-parallel, status) to document and allow invoking cavekit team for task claim/heartbeat/release and add allowed-tools entries. Add commands/team.md wrapper.
- Misc: update scripts/setup-build.sh and site/frontend pieces to reflect team mode; add JSON marshal helpers and argument normalization utilities in CLI.

This commit wires team-mode into the build loop (claim → heartbeat → release), adds the union-merged ledger and lease semantics, and provides machine-readable JSON outputs and docs for TUI and CLI integration.
2026-04-18 17:15:10 +02:00
Julius Brussee 74cb27b1c4 Update sync-codex-plugin.sh 2026-04-18 12:31:12 +02:00
Julius Brussee ff0bac1199 v3.0.1: inline-by-default /ck:make; add /ck:make-parallel opt-in
Fix two bugs that could break /ck:make under the quality preset:

1. Caveman mode was telling task-builder subagents to apply caveman-speak
   to their *reasoning*, which corrupted <tool_use> formatting — subagents
   emitted tool calls as body text and terminated with 0 tool_uses.
   Scope caveman to final prose output only (status reports, summaries).
   Reasoning, tool calls, tool arguments, code, commits, and structured
   fields are explicitly excluded. Fixed in make.md, task-builder.md,
   check.md, map.md.

2. Parallel ck:task-builder dispatch with isolation: "worktree" can hit
   a Claude-Code-harness worktree race, returning "[Tool result missing
   due to internal error]" with no agentId. Avoid the race by defaulting
   /ck:make to inline sequential execution: no subagent, no worktree, no
   merge. The parent session implements tasks directly on the current
   branch — the path the user confirmed works.

New command /ck:make-parallel keeps the parallel-subagent path available
as explicit opt-in. It forces TB_ISOLATION=worktree + MAX_PARALLEL=3
(tunable via --concurrency N) for a single run without touching config.
Adds a one-time retry-on-harness-error rule: harness failures re-dispatch
once sequentially, then mark BLOCKED.

Config knob: task_builder_isolation (worktree/inline, default inline).
parallelism defaults lowered: max_agents=1, max_per_repo=1.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-18 12:27:20 +02:00
Julius Brussee 0fa227f1ee Bump plugin to v3.0 and overhaul docs
Bump plugin to version 3.0 and update plugin/marketplace metadata (description and keywords). Major README rewrite: reorganized into a clear "loop" (sketch → map → make → check), added first-run and brownfield flows, new/renamed commands (e.g. /ck:ship, /ck:review, /ck:revise, /ck:init, /ck:config, /ck:status, /ck:help), expanded CLI and configuration docs, and clarified Codex integration and review modes. Rename/clarify backpropagation → revision flows (commands and docs updated to use /ck:revise --trace), update verifier routing in commands/check.md, and adjust Codex-related command names (/ck:review --codex). Update agent metadata (architect, drafter) to reflect new command names. Update runtime and tooling docs and scripts (install.sh, scripts/cavekit-tools.cjs) and several context/kit implementation files to reflect the Codex review loop, tier gating, and make/mapping command changes. Misc: README copy edits, skills docs updates, and small doc/path adjustments throughout the repository to match the new workflow and naming.
2026-04-18 02:34:25 +02:00
Claude 0934103ca2 Wire autonomous runtime into the Hunt lifecycle (v2.2.0)
The runtime from 2.1.0 shipped as a standalone engine; this change wires
it through every existing command so /ck:make drives itself under the
stop-hook once /ck:init has been run. No breaking changes — every command
detects .cavekit/ and falls back to the pre-2.2 path when absent.

Correctness:
- Fix sentinel mismatch: stop-hook, cavekit-tools, docs now match
  setup-build.sh's <promise>CAVEKIT COMPLETE</promise> (space, not
  underscore). Without this, the loop could never terminate.
- .gitignore: add the transient runtime files (.loop.json, .loop.lock,
  .progress.json, tool-cache/, state.md, ledgers, etc.) while leaving
  .cavekit/config.json and .cavekit/history/ under version control.

Command wiring:
- /ck:init — calls cavekit-tools init + discover; seeds .cavekit/; appends
  runtime entries to .gitignore if missing; prints detected capabilities.
- /ck:config — surfaces new runtime keys (session_budget, task_budget_*,
  auto_backprop, tool_cache, parallelism_*, model_routing, graphify) and
  accepts get/set directly for any bp-config.sh key.
- /ck:progress — prints `cavekit-tools status` block first when .cavekit/
  is present; legacy impl-based rollup follows.
- /ck:sketch — dispatches ck:complexity per approved kit to auto-fill the
  complexity: frontmatter; tags novelty-heavy kits for research.
- /ck:map — emits .cavekit/tasks.json and calls init-registry; inserts
  ck:researcher dependency tasks for kits tagged needs_research.
- /ck:make — documents runtime mode: setup-loop activates the stop-hook,
  the hook routes waves automatically, task-builders mark completions
  via cavekit-tools, and the final message emits
  <promise>CAVEKIT COMPLETE</promise>. Legacy Ralph-loop path preserved.
- /ck:check — dispatches ck:verifier for goal-backward verification and
  falsely_complete detection; routes gaps through /ck:backprop.
- /ck:review-branch — adds a fix-cycle section: blocking findings become
  fix tasks on the next loop iteration; max 2 cycles, then
  ADVANCE_WITH_FINDINGS.
- /ck:backprop — consumes .cavekit/.auto-backprop-pending.json when
  invoked with no args, in addition to --from-flag / --from-finding.
- /ck:revise — preferred path: route each manual fix through /ck:backprop
  when .cavekit/ is present (regression test + audit log).
- /ck:research — prefers a single ck:researcher dispatch for narrow
  briefs; multi-agent fan-out for broad topics.

Scripts:
- setup-build.sh — calls cavekit-tools init + setup-loop when node is
  available, activating the stop-hook mid-/ck:make. Keeps the legacy
  .claude/ralph-loop.local.md file for back-compat.
- cavekit-tools.cjs — adds `intensity` subcommand that resolves
  lite|full|ultra based on session budget pressure, task depth, and
  phase. Consumed by /ck:make and /ck:check.

Go CLI (cmd/cavekit/main.go):
- runStatus prints `cavekit-tools status` block when .cavekit/state.md
  exists (alongside the existing worktree rollup).
- runReset additionally clears transient runtime files from .cavekit/
  (.loop.json, .loop.lock, .progress.json, .auto-backprop-pending.json,
  .debug.log), leaving config.json and history/ untouched.

Tests:
- tests/intensity.test.cjs — six new assertions covering the caveman-
  internal decision table (session pressure, task pressure, depth clamps,
  phase clamps, explicit override).
- Total: 40/40 passing.

Plugin manifest:
- plugin.json, .claude-plugin/plugin.json, install.sh → 2.2.0.

https://claude.ai/code/session_018edLvsv8JE9947oFiBXyHS
2026-04-17 19:41:38 +00:00
Claude 499205d2e0 Add autonomous runtime layer — hooks, orchestration engine, router, budgets
Introduces the machinery that turns /ck:make into a hands-off autonomous
loop without changing the Hunt methodology. Nothing in existing commands,
skills, or agents breaks; the new layer is additive and opt-in.

New runtime (scripts/):
- cavekit-tools.cjs — state machine, lock with heartbeat, token ledger,
  task registry, routing, capability discovery, backprop directive,
  status-block dashboard. Zero runtime deps.
- cavekit-router.cjs — five-axis task scoring mapped to haiku/sonnet/opus
  tiers with role baselines and budget-pressure demotion.

New hook system (hooks/):
- stop-hook.sh — Stop-event driver; reads .cavekit/state, routes the next
  prompt, returns {decision:"block",reason:...} to keep the session going
  until <promise>CAVEKIT_COMPLETE</promise> is emitted or a budget trips.
- token-monitor.sh — per-task budget (80% warn, 100% halt).
- tool-cache.js / tool-cache-store.js — 120s TTL cache for read-only tools.
- test-output-filter.js — condense test output around failure lines.
- auto-backprop.js — write flag file on test failure; stop-hook prepends
  a backpropagation directive on the next iteration.
- progress-tracker.js — zero-stdout snapshot for /ck:watch.
- hooks.json — registers all of the above (Stop + PreToolUse + PostToolUse).

New skills (skills/):
- karpathy-guardrails — four behavioral rules (think-before-code, simplicity,
  surgical, goal-driven) enforced by reviewer and task-builder.
- caveman-internal — three intensity modes (lite/full/ultra) for
  machine-to-machine artifacts, with budget-pressure auto-selection and a
  verbose-regeneration fallback. Separate from the user-facing /caveman skill.
- backpropagation — six-step bug-to-kit trace; auto-triggered by the
  auto-backprop hook or manually via /ck:backprop.
- complexity-detection — five-axis scoring rubric; depth mapping
  (0-6 quick / 7-13 standard / 14+ thorough).
- autonomous-loop — end-to-end loop reference (state files, sentinels,
  lock protocol, debugging).
- capability-discovery — MCP + plugin + CLI detection, writes
  .cavekit/capabilities.json.
- graphify-integration — optional knowledge-graph queries; degrades to grep
  when graphify-out/graph.json is absent.

New commands (commands/):
- /ck:watch — live dashboard.
- /ck:resume — recover from crash, lock conflict, or interrupt.
- /ck:backprop — manual entry to the backpropagation skill.
- /ck:review-branch — two-pass (kit + code) branch review, optional Codex.
- /ck:setup-tools — run capability discovery and summarize.

New agents (agents/):
- complexity — haiku-only classifier, returns JSON score.
- verifier — goal-backward verification with stub detection.
- researcher — multi-source research brief with citations.

Templates (templates/):
- state.md, config.json, task-status.json, spec-kit.md — seed files that
  commands copy into .cavekit/ or context/ on init.

Config (scripts/bp-config.sh):
- Adds session_budget, max_iterations, task_budget_{quick,standard,thorough},
  auto_backprop, tool_cache(+_ttl_ms), test_filter, progress_tracker,
  parallelism_max_{agents,per_repo}, model_routing, graphify_enabled.
- Extends caveman_phases validator to accept review and verify.

Plugin manifest (.claude-plugin/):
- plugin.json + marketplace.json for the marketplace discovery path.
  Existing root plugin.json bumped to 2.1.0; install.sh version strings
  bumped to match.

Tests (tests/):
- 34 zero-dep Node.js tests covering frontmatter round-trip, state
  merging, lock acquire/heartbeat/steal/release, per-task + session
  budget, task registry with dependency ordering, routing sentinels,
  router tier bands, preset matrix, and deep-merged config loading.
- Runner: `node tests/run-tests.cjs`.

No changes to existing /ck:sketch, /ck:map, /ck:make, /ck:check, or any
existing skill/agent — this commit strictly adds the runtime layer beneath
them.

https://claude.ai/code/session_018edLvsv8JE9947oFiBXyHS
2026-04-17 18:46:00 +00:00
Julius Brussee a14362ab22 Rename plugin prefix bp → ck with caveman-themed DABI commands
- Plugin prefix: bp: → ck: (bp: kept as deprecated alias via symlink)
- DABI cycle renamed: sketch (draft), map (architect), make (build), check (inspect)
- Also renamed: scan (gap-analysis), judge (codex-review)
- Old command names preserved as symlinks for backward compatibility
- All commands include deprecation notices pointing to new names
- install.sh registers both ck and bp plugins

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 19:24:24 +02:00
Julius Brussee dd610faa1a Use 'draft' mode and update Caveman README
Simplify Caveman entry in README (remove the skill number and wording) to state it's bundled in Cavekit and enabled by default. Change scripts/codex-design-challenge.sh to query bp_config_caveman_active with 'draft' instead of 'build' so caveman activation reflects the draft phase.
2026-04-06 19:08:56 +02:00
Claude ac813b8e3b Integrate Caveman token-compression skill into CaveKit pipeline
Bundle Caveman as skill #16 with full CaveKit integration:
- Add skills/caveman/SKILL.md with lite/full/ultra intensity levels
- Add caveman_mode (default: on) and caveman_phases (default: build,inspect)
  config options to bp-config.sh with validation and caveman-active helper
- Inject CAVEMAN MODE into subagent prompts in build.md so all inter-agent
  communication is token-compressed (~75% savings across parallel waves)
- Add caveman-aware loop logging: compressed one-liner entries when active
- Apply caveman-speak to Codex review and design challenge prompt framing
  (structured findings tables stay in normal format)
- Update all four phase commands (draft, architect, build, inspect) to
  resolve caveman_active from config at startup
- Update task-builder agent to respect CAVEMAN MODE from dispatch prompt
- Update README with skill #16, config docs, and bundled status

https://claude.ai/code/session_018MDR9vb5fsAKp4c2LtxYb5
2026-04-06 16:57:25 +00:00
Claude 67ad13fce0 Rename Blueprint to Cavekit across entire project
- Rename all files/directories: .blueprint -> .cavekit, cmd/blueprint -> cmd/cavekit,
  context/blueprints -> context/kits, skills/blueprint-writing -> skills/cavekit-writing,
  agents/blueprint-reviewer -> agents/cavekit-reviewer, scripts/blueprint* -> scripts/cavekit*
- Update Go module path: github.com/julb/blueprint-monitor -> github.com/JuliusBrussee/cavekit
- Replace all content references from blueprint/Blueprint to cavekit/Cavekit
- Update plugin.json, install.sh, codex-plugin config, and all documentation
- Add caveman ecosystem link to README
- Binary renamed from blueprint to cavekit

Part of the Caveman ecosystem: https://github.com/JuliusBrussee/caveman

https://claude.ai/code/session_012D3nKU3keqDLHpk7ustfUc
2026-04-06 16:12:16 +00:00
Julius Brussee 75a240f804 Add bp-config utility and integrate model presets
Introduce a canonical bp-config.sh tool to manage Blueprint execution presets and resolved models (reasoning, execution, exploration). Add CLI, validation, preset resolution, summary, and listing functions plus a test script (scripts/test-bp-config.sh). Integrate bp-config into the toolchain: update docs (README, help) and add a new command spec (commands/config.md); update command docs (draft, architect, build, quick, inspect, research, gap-analysis, etc.) to resolve and use explicit models via bp-config.sh; add bp-config to allowed-tools where appropriate. Make codex-config.sh a backward-compatible wrapper that sources bp-config.sh, and have setup-build.sh source bp-config.sh and emit the preset summary. This centralizes model preset logic and makes model selection explicit for delegated subagents.
2026-04-02 18:17:35 +02:00
Julius Brussee abc76e20ca Add landing/docs blueprints and site plan
Add website blueprints and planning/implementation tracking for the new marketing site and docs.

- Added blueprints: context/blueprints/blueprint-landing-page.md and blueprint-docs-page.md (detailed requirements & acceptance criteria).
- Added site plan: context/plans/build-site.md (19 tasks across tiers) and moved several context/sites/* files into context/plans/ (renamed). Deleted old context/sites/build-site.md.
- New implementation tracking: context/impl/impl-website.md with task table for landing + docs; updated context/impl/impl-cli.md task list and timestamps.
- Commands/docs updates: commands/build.md (argument hint now includes [FILE] and adds scoped impl-file reading rule) and commands/inspect.md (add Restore Archived Impl Tracking instructions to recover archived impl-*.md files).
- Misc: updated context/blueprints/blueprint-overview.md metadata and domain table to reference the website blueprints; added ignores to .gitignore (/.playwright-mcp, current-site-full.png); modified scripts/setup-build.sh.

These changes prepare the repo for implementing a zero-build, two-file gh-pages site (index.html + docs.html) and ensure the build/inspect workflows handle scoped impl files and archived implementation tracking.
2026-04-01 14:11:53 +02:00
Julius Brussee b43c6ce07d Support plan and frontier files in build, progress, and inspect
Broadened file discovery from *site* only to *site*, *plan*, or *frontier*
(excluding *overview* index files) so /bp:build, /bp:progress, and
/bp:inspect can find buildable task graphs regardless of naming convention.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 13:29:03 +02:00
Julius Brussee 0ec1ba9a61 Prefer context/plans; add bp:init and discovery
Introduce context/plans as the primary location for build sites and add a new /bp:init command to bootstrap the context hierarchy. Add commands/init.md (idempotent, non-destructive scaffolding), update docs and CLI help to reference context/plans (with fallbacks to legacy context/sites and context/frontiers), and add post-build guidance to update per-directory CLAUDE.md mappings. Update site discovery (internal/site/discovery.go), several scripts (blueprint, blueprint-picker.ts, blueprint-status-poller.sh, dashboard-progress.sh, setup-build.sh) to search context/plans first, and adjust inspect/revise/progress docs to use the new convention. Also rewrite the context-architecture SKILL to reflect a DAG-based progressive disclosure model, and add /docs to .gitignore.
2026-03-31 23:54:17 +02:00
Julius Brussee ea7057b0d6 Add Codex blueprints and auto-parallel build
Add Codex integration and update build orchestration: • Add .codex-plugin/plugin.json and sync script to register Codex plugin and expose Codex-related skills. • Introduce multiple new blueprint specs (codex-bridge, command-gate, draft-challenge, speculative-review, tier-gate) and an implementation tracking file for Codex. • Update README to describe auto-parallel /bp:build behavior, remove separate /bp:parallel and /bp:merge flows, and clarify plugin syncing. • Add bp-quick command for end-to-end quick builds. • Improve architect output to include a Mermaid dependency/parallelization graph. • Strengthen builder and task-builder agents with explicit guidance to never falsely mark tasks DONE and to require tests/verification. • Remove commands/merge.md and commands/parallel.md. • Update scripts and tooling (including new scripts/sync-codex-plugin.sh and changes to various blueprint scripts) to support the new flows. Overall: integrate Codex review patterns and move the build loop to an auto-parallel model with clearer gating and review hooks.
2026-03-31 21:56:40 +02:00
Julius Brussee d6c8af168f T-101 through T-110: Command Safety Gate
Complete implementation of PreToolUse command safety gate:
- T-101: Hook scaffold (JSON stdin/args, approve/block protocol)
- T-102: Built-in allowlist (50+ executables, git subcommands) and
  blocklist (14 regex patterns for rm -rf, force push, DROP TABLE, etc.)
- T-103: Config schema (command_gate mode, model, timeout, user lists)
- T-104: Fast-path classifier (allowlist→blocklist→user lists→UNKNOWN)
- T-105: Claude permission integration (skip if pre-allowed/blocked)
- T-106: Command normalizer (strip paths, quotes, hashes for caching)
- T-107: Codex safety classification (JSON prompt, structured verdict)
- T-108: Pattern-based verdict cache (bash3-compatible, session-scoped)
- T-109: Graceful degradation (passthrough on unavailable/timeout/error)
- T-110: User-extensible allowlist/blocklist via config

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:55:19 +02:00
Julius Brussee 1682cb5978 T-201 through T-208: Speculative Pre-Build Review
Complete implementation of speculative (background) Codex review:
- T-201: Config schema (speculative_review on/off, timeout 300s)
- T-202: Session-scoped job ID tracking via temp files
- T-203: Background dispatch of codex-review.sh at tier completion
- T-204: Pipeline overlap status reporting (running/complete/failed)
- T-205: Result retrieval with configurable timeout and sync fallback
- T-206: Finding reconciliation into tier gate flow
- T-207: P0/P1 queuing during active tier builds
- T-208: Impl tracking with review source and time-saved metrics

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:53:21 +02:00
Julius Brussee 5aa16a9674 T-305/T-306/T-307: Auto-fix loop, draft flow integration, graceful degradation
T-305: bp_design_challenge_cycle runs up to 2 challenge-fix cycles,
outputs AWAITING_FIXES with structured critical findings for caller.
T-306: bp_draft_challenge_hook integrates between blueprint-reviewer
(Step 8) and user review gate (Step 9), sets BP_CHALLENGE_ADVISORY_OUTPUT
for user presentation and tracks challenge duration.
T-307: Graceful degradation already in bp_design_challenge (returns 2
when Codex unavailable), bp_draft_challenge_hook logs skip with timing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:51:35 +02:00
Julius Brussee 704589407d T-303/T-304: Design challenge invocation and advisory findings collector
T-303: bp_design_challenge sends all blueprints to Codex with design-level
prompt, parses structured findings with categories and severity.
T-304: bp_collect_challenge_findings separates critical vs advisory,
bp_format_advisory_for_user generates user-facing markdown table,
bp_format_critical_for_fix outputs structured data for auto-fix loop.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:50:44 +02:00
Julius Brussee a41496b7ea T-301/T-302: Design challenge prompt template and output parser
Add codex-design-challenge.sh with purpose-built prompt for adversarial
blueprint review (domain decomposition, coverage, ambiguity, scope,
assumptions) and structured finding parser with category/severity support.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:50:07 +02:00
Julius Brussee 8a2a336ef8 T-012: Review-fix cycle with re-review and max iterations
- scripts/codex-gate.sh: Added bp_review_fix_cycle function that
  orchestrates the review → evaluate → fix → re-review loop with
  configurable max cycles (default 2). Returns 0 (clear), 1 (max
  cycles exhausted), or 2 (awaiting fixes from caller).
- commands/build.md: Updated tier boundary check to use
  bp_review_fix_cycle for the fix loop orchestration.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:45:55 +02:00
Julius Brussee f81c89465b T-011: Severity-based gating with fix-task generation
- scripts/codex-gate.sh: bp_tier_gate evaluates findings against
  tier_gate_mode (severity/strict/permissive/off) and returns
  blocked/proceed. bp_generate_fix_tasks outputs fix task descriptions
  for blocking findings.
- commands/build.md: Updated tier boundary check with severity gating,
  fix-task generation, re-review cycle, and max 2 cycles per tier.
- Fixed grep regex bug in codex-findings.sh and codex-gate.sh where
  pipe character was interpreted as alternation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:44:13 +02:00
Julius Brussee caf5b22799 T-005/T-006/T-007: Codex review invocation, finding parser, and finding format
- T-005: codex_available flag and nudge already in codex-detect.sh
- T-006: scripts/codex-review.sh — Codex adversarial review invocation with
  diff computation, finding parser (P0-P3), source:codex tagging, and
  graceful fallback when Codex unavailable
- T-007: scripts/codex-findings.sh — Finding management with extended format
  (Source, Tier columns), append/update/blocking-list functions, old-format
  migration support

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:12:42 +02:00
Julius Brussee 616db9c917 T-001/T-002: Codex detection, T-003/T-004: Config schema and gate settings
- scripts/codex-detect.sh: Sourceable utility that detects codex binary
  on PATH (CODEX_BINARY_AVAILABLE) and plugin presence (CODEX_PLUGIN_PRESENT).
  Exports codex_available flag and bp_codex_nudge for one-time install hint.

- scripts/codex-config.sh: Sourceable config utility with bp_config_get/set/init.
  Stores settings in .blueprint/config (key=value format).
  T-003: codex_review (auto|off), codex_model, codex_effort
  T-004: tier_gate_mode (severity|strict|permissive|off)
  Bash 3 compatible (no associative arrays).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:08:09 +02:00
Julius Brussee 9ec9fa85ba T-014 to T-018: Overview update, drift detection, health check, TUI health, archive on stop
- revise.md: Step 4b updates blueprint-overview.md after revision (counts,
  descriptions, cross-refs). Step 4c detects build site drift (stale,
  orphaned, out-of-date tasks).
- setup-build.sh: Worktree health check before build (detached HEAD,
  missing path = errors; dirty state, missing env = warnings). Writes
  results to .claude/health-check.json for TUI.
- instance.go: Add HealthStatus/Errors/Warnings fields.
- instancelist.go: Show health indicator (⊘ error, △ warning) in rows.
- lifecycle.go: archiveImplState() archives loop log and impl files to
  context/impl/archive/ on kill. Skips if zero tasks completed.

Blueprint: spec-sync R3/R4, build-lifecycle R3/R4/R5

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 13:23:04 +01:00
Julius Brussee 7aee4e7586 T-011/T-012/T-013: Build failure recovery, abandon cleanup, resume flow
Add recovery detection when worktree has stale ralph-loop state: surface
branch, last commit, and diff stats. Add --abandon flag to remove worktree
and branch. Resume flow cleans stale state then proceeds through normal
merge + env verify path before fresh Ralph Loop.

Blueprint: build-lifecycle R3

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 13:19:37 +01:00
Julius Brussee d10340fe3e T-005/T-006/T-007/T-008: Env forwarding via symlinks, merge conflict handling, merge logging
Forward .env* files from project root to worktree via symlinks so changes
auto-reflect. Verify/restore symlinks on every build start (creation and
resume). T-005/T-006 were already covered by T-004's merge implementation.

Blueprint: build-lifecycle R1 (T-005, T-006), R2 (T-007, T-008)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 13:15:06 +01:00
Julius Brussee 9575b0b9b4 T-004: Auto-merge main into worktree branch on build start
When reusing an existing worktree, merge origin/main into the worktree
branch before the agent begins work. Handles conflict detection (aborts
merge and reports conflicting files) and logs merge results.

Blueprint: build-lifecycle R1

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 13:14:09 +01:00
Julius Brussee 339bccc9a4 Add self-contained visual companion server for Draft phase
Port the browser-based visual companion from superpowers into Blueprint
with Blueprint branding and paths (.blueprint/companion/ instead of
.superpowers/brainstorm/). Zero external dependencies — Node.js only.

Components:
- server.cjs: HTTP + WebSocket server with file watching and live reload
- start-server.sh: Launch script with platform detection (macOS, Windows, Codex)
- stop-server.sh: Graceful shutdown with signal escalation
- frame-template.html: OS-aware dark/light theme with CSS helpers
- helper.js: Client-side WebSocket + selection tracking (XSS-safe, no innerHTML)

Update references/visual-companion.md to point to actual scripts.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 10:45:36 +01:00
Julius Brussee 4f43514621 Replace backpropagation and specs terms
Rename terminology across docs to use "revision" and "blueprints" instead of "backpropagation" and "specs". Updates apply to plugin.json (description), references (git-as-memory, multi-repo-strategy, session-feedback-protocol), and skills (convergence-monitoring, impl-tracking, prompt-pipeline, validation-first) to keep naming consistent and clarify the Blueprint framework workflow.
2026-03-17 12:48:47 +01:00
Julius Brussee 4ffa42198b Rename frontiers→sites and add blueprint specs
Update references from context/frontiers to context/sites across docs and scripts, including commands/* and scripts/* (picker, status poller, dashboard, setup-build). Add a new set of blueprint spec files under context/blueprints/ and a sample build-site at context/sites/build-site.md. Adjust installer (install.sh) to create a local Blueprint marketplace (symlink + metadata) and update settings/paths accordingly. Also remove /context from .gitignore. These changes migrate the project naming from "frontier" to "site" and introduce detailed blueprint specs and marketplace setup.
2026-03-17 12:46:06 +01:00
Julius Brussee 3c0b273385 Rename 'blueprint' commands and plugin to 'bp'
Replace the long 'blueprint' namespace with the shorter 'bp' across docs, command specs, agent descriptions, scripts, and skills. Updated README, command/agent metadata, install/setup scripts, launcher/picker scripts, plugin.json (name -> "bp"), and many SKILL.md cross-references so slash commands (e.g. /blueprint:build) and plugin identifiers consistently use /bp:... and bp@... to avoid mismatches.
2026-03-17 12:42:40 +01:00
Julius Brussee c28d04f55d Rebrand SDD to Blueprint & rename commands
Large rework to rename and restructure the project from "SDD" (Spec-Driven Development) to "Blueprint": update README and .gitignore; rename specs → blueprints and frontiers → sites in context; rename CLI commands and slash commands (sdd:* → blueprint:* and sdd CLI → blueprint); rename agent roles and related files (e.g. plan-architect → architect, implementer → builder, adversarial-reviewer → inspector, gap-analyzer → surveyor), remove spec-writer and execute docs, add drafter agent and a new blueprint-build command; update various command docs, templates, and references to map requirements/acceptance criteria to blueprints; adjust scripts and other renamed files accordingly. This commit realigns naming and workflows to the new "Blueprint" terminology and adds the drafter + build flow while pruning legacy spec/execute artifacts.
2026-03-17 12:27:33 +01:00
Julius Brussee 286a63d330 Improve task ID parsing and frontier selection
Introduce a reusable TASK_ID_PATTERN and replace brittle 'T-[0-9]+' matches across scripts (dashboard-activity, dashboard-progress, sdd, sdd-analytics, sdd-status-poller) to correctly extract varied task IDs. Add helper functions for extracting/lookup/recording task statuses, counting frontier tasks, and resolving script directory. Harden grep fallbacks and use safer pipelines (sort -u, wc -l, true). Revamp setup-execute frontier picker to search only context/frontiers, exclude archives, support --filter, rank candidates by active worktree and incomplete tasks, and list candidates for visibility. Also fix MARKETPLACE_PATH assignment in install.sh and add .DS_Store.
2026-03-17 11:57:55 +01:00
Julius Brussee 3cb48fda92 Add parallel launcher, :command syntax, merge
Introduce a parallel agent launcher and update command syntax across docs and tooling. README now documents the sdd parallel launcher, analytics, status and expanded monitor modes. Replace legacy `/sdd-` command references with `/sdd:` in command docs and help, and update the execute doc to require switching into the created git worktree and extend allowed-tools. Add a new spec-aware sdd-merge command with merge/resolve workflow. Rework installer to expose new CLI options and make new launcher/status/analytics scripts executable; add a scripts npm project, TS picker, and node_modules ignore entry, and remove deprecated launcher scripts.
2026-03-15 14:35:34 +01:00
Julius Brussee 8dbc29a026 Initial commit 2026-03-15 10:12:49 +01:00