Skip to content

feat: Phase 2, projects, skills, custom agents, LSP, CI tab, and fixes#6

Merged
alejandro-nexcade merged 2 commits into
mainfrom
alejandro/phase2-projects-skills-lsp-ci
Jul 1, 2026
Merged

feat: Phase 2, projects, skills, custom agents, LSP, CI tab, and fixes#6
alejandro-nexcade merged 2 commits into
mainfrom
alejandro/phase2-projects-skills-lsp-ci

Conversation

@alejandro-nexcade

Copy link
Copy Markdown
Collaborator

Summary

The 15-task program + follow-up fixes, delivered as one green change set. See cockpit-docs/PROGRAM_PLAN.md for the full decision log and per-task detail.

Highlights

  • Phase 2 end to end: plan gate reuses the single Gated loop (no new states), planner generation + plan-doc ingestion, guarded plan-approve fans out N implementers (one worktree each, bounded).
  • Projects: first-class Project grouping PRs; Linear demoted to one optional source.
  • Skills: ~/.cockpit/skills, install/sync via gh api (SHA-idempotent), actually injected into rework prompts.
  • Custom agent prompts per AgentMode; agent_command now live.
  • LSP for pyright / typescript-language-server (axum WS↔stdio bridge + hand-written Monaco client).
  • CI tab with per-pipeline logs + explicit Fix-CI into the rework loop.
  • Paths: worktrees + logs under $HOME/.cockpit (fixes the CWD/inside-worktree bugs).
  • Auth: user's Claude Code login (no API key/SDK); dead config fields removed.
  • UI: new IA (PRs-by-project / Projects / Skills / Agents / Settings), shortcut labels, settings rewrite, PR-Info tab relocated, Monaco first-load theme fix, external links via the opener plugin.

Verification

  • cargo fmt --check, cargo clippy -D warnings, cargo test --all — green (344 core + 13 CLI + 7 integration).
  • npm ci + npx tsc --noEmit — green.

Known follow-ups (not blockers; tracked in PROGRAM_PLAN.md)

  • Per-project plan scoping (plan store still a global singleton).
  • CLI loop daemon seam (core loop + Tauri app are correctly wired). Note: whether to keep the CLI at all is under review.
  • Two dangling backend commands (restack_pr, load_plan_from_path) lack FE entry points.
  • No FE unit-test harness (gate is tsc + build only).
  • Runtime verification needs live claude / pyright / gh.

🤖 Generated with Claude Code

LifeLex and others added 2 commits July 1, 2026 16:18
Large delivery covering the 15-task program plus follow-up fixes. Whole
workspace is green: cargo fmt/clippy/test (344 core + 13 CLI + 7 integration)
and frontend npm ci + tsc.

Core / Tauri:
- Worktrees and agent logs now live under $HOME/.cockpit (config::cockpit_home,
  worktrees_dir, logs_dir); fixed the inside-worktree log + relative-fallback bugs.
- Auth = the user's Claude Code login via the `claude` CLI (login-shell PATH
  resolution); no API key, no SDK. Removed dead config fields.
- Full Phase 2: plan gate reuses the one Gated loop (no new GateState); planner
  generation + plan-doc ingestion; guarded plan-approve fans out N implementers
  (bounded by max_parallel_agents), one worktree each.
- First-class Project concept (groups PRs; Linear is one optional source);
  ProjectId/ProjectSource/Project, ProjectStore, reviews_by_project.
- Skills: ~/.cockpit/skills, install/sync via gh api (SHA-idempotent), now
  actually injected into every rework prompt; filtered by diff.
- Customizable per-AgentMode prompt fragments (verbatim), agent_command made live.
- CI visibility: gh pr checks + per-run logs; explicit Fix-CI into the rework loop.
- LSP bridge (axum WS <-> stdio) for pyright / typescript-language-server, with a
  hand-written Monaco client (no monaco-languageclient coupling).
- Hardened diff-gate Fix loop with a real end-to-end integration test; slashed
  worktree-branch fix.

Frontend:
- New IA: PRs grouped by project, Projects, Skills, Agents, Settings; removed
  Stacks and the batch-approve panel.
- Shortcut registry + Kbd labels; settings rewrite; PR Info tab removed and its
  links/stack relocated to the DiffView header; Monaco first-load theme fix.
- New views: PlanView, NewProjectView, SkillsView, AgentEditor, CiPanel.
- External links routed through the opener plugin (with the URL scope), replacing
  no-op target=_blank anchors.

Known follow-ups (tracked in cockpit-docs/PROGRAM_PLAN.md): per-project plan
scoping (plan store still global), CLI loop daemon seam, two dangling backend
commands, no FE unit-test harness, runtime verification with live claude/pyright/gh.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…tests

The Tauri app + cockpit-core integration tests (fix_loop_e2e, batch_fan_out_e2e) are now the product and validation surfaces. The CLI's Stop-hook loop was broken across processes and its role is covered by the integration suite.

Also removes CLI-only orphans: store file-persistence API + store::Error, the batch module, and the clap workspace dep. CLAUDE.md/SPEC.md/README updated.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@alejandro-nexcade alejandro-nexcade merged commit ddc1996 into main Jul 1, 2026
2 checks passed
@alejandro-nexcade alejandro-nexcade deleted the alejandro/phase2-projects-skills-lsp-ci branch July 1, 2026 16:08
alejandro-nexcade added a commit that referenced this pull request Jul 2, 2026
* core+app: foundational shapes for phases B-E

- CiSummary moves to model (domain rollup); AgentMode::Review (advisory
  pre-pass, never advances the gate); FindingSeverity/ReviewFinding;
  ConversationKind/ConversationItem (read-only GitHub context, distinct
  from ephemeral Comments per §0.4)
- Review gains ci_summary, review_findings, conversation,
  last_reviewed_sha (all serde-default; legacy state loads clean)
- AgentPrompts.review override; Config.notify_poll_secs; REVIEW_INSTRUCTION
- bindings regenerated; FE exhaustive switches extended

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* core: stub diff_signals and findings modules for parallel wave

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* docs: interaction-patterns research synthesis (round 2) + roadmap Phase F

Verified competitor teardowns (Graphite taxonomy/downvote/rules model,
CodeRabbit price band + review/rework collapse, the ~58% critical-bug
ceiling), HCI evidence for the gated loop (four oversight surfaces,
2.1-steps-per-prompt chunking, zero-of-99 autonomy trust), the
trust-miscalibration hazard binding our evidence/trajectory UI, and Cisco
sizing mechanics. Locks 10 design decisions; adds roadmap Phase F.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* core: file-at-rev adapters for full-file diff context

git2 blob reads at a revision (binary/oversize/missing-path -> None, bad
rev -> Err) and a gh api contents fallback with pure, tested response
parsing. 512 KiB cap guards Monaco full-file rendering.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* core: advisory findings contract — parser, review prompt, findings path

Tolerant JSON-array extraction (string-aware balanced scan, junk-wrapped
agent output survives), skip-malformed entries, stable content-hashed ids,
200-finding cap. assemble_review_prompt mirrors the plan prompt sections
with a golden; findings_file_path shares the plan slug sanitizer.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* core: deterministic diff signal engine — size, risk paths, test delta, weakening

Pure single-pass unified-diff analysis: size classes at documented
boundaries, priority-ordered per-file risk flags, assertion counting, and
seven test-weakening detectors with jump targets. 16 tests + regenerated
bindings.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* app: wire evidence, pre-review, and full-file commands

- get_evidence: deterministic signals + CI rollup (trajectory slot ready
  for Phase D)
- pre_review: explicit reviewer-agent spawn (AgentMode::Review); findings
  ingested on completion, file deleted after transport, gate state never
  touched; findings cleared when the head advances
- get_file_pair: worktree git2 reads with gh contents fallback and honest
  full:false degradation

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* app(fe): Phase B — evidence strip, advisory pins, pre-review, full-file view

EvidenceStrip (CI/size/test-delta/risk/weakening chips with jump-to-hunk),
advisory finding pins on parallel zone machinery (dashed severity rail,
local dismiss, never counted as comments), Pre-review button, full-file
toggle with identity line maps + per-head cache, TS signal mirror with
Rust-fixture parity tests.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* app: clear advisory findings even when the post-rework diff refresh fails

Stale pins on changed content mislead; the head has moved regardless of
whether the gh re-fetch succeeded (reviewer minor #6).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Alejandro Perez <alejandro.perez.gancedo@gmail.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants