Skip to content

feat(capabilities): capability treemap view in Srcly - #503

Draft
byronwall wants to merge 1 commit into
claude/capabilities-proto1-56e1d1from
claude/capabilities-treemap
Draft

byronwall wants to merge 1 commit into
claude/capabilities-proto1-56e1d1from
claude/capabilities-treemap

Conversation

@byronwall

@byronwall byronwall commented Nov 29, 2026 •

Copy link
Copy Markdown
Owner

Srcly now opens a repo that has docs/capabilities/*.yaml on a Capabilities view: every product area is a box of its capabilities, sized by allocated LOC, with unclaimed code as its own box. Select a capability to read its promise, files and tests. A repo with no map shows normal Srcly, with no Capabilities switch.

What you'll see

  • A Capabilities switch first in the view toolbar, only when the repo has area files. With a map and no view= in the URL, Srcly lands on it.
  • Each capability's color says how much test code it links, per 100 LOC of its own code. The check result now carries tests.unit_lines, e2e_lines and lines_per_100_loc (anchor spans when only: narrows a test file). It measures what is linked, not coverage.
  • cap= (selection) and capzoom= (area) stay in the URL; an area's label zooms in.
  • GET /api/capabilities?path=<repo> serves the same result as srcly capabilities check --no-base --format json.

Proof

Capabilities view on Visual Notes with ai-prompts selected
Visual Notes main with the drafted map (byronwall/visual-notes#375): 148 capabilities, 86% of code claimed. ai-prompts is selected: 0.7 linked test lines per 100 LOC across 1,579 LOC.

  • client/e2e/capabilities.spec.ts: a generated repo lands on the map, a capability with no test is marked, a click shows its promise and files, and a repo with no map keeps the treemap with no switch. Full e2e suite: 43 passed.
  • server/tests/test_capabilities.py: 26 passed, including the API's snapshot and no-map answers and the only:-scoped test lines.
  • The API answers in 0.84 s warm on Visual Notes. Srcly holds the file treemap until the answer, so it never flashes before switching.

Survey moves: client traces 104 → 105 and server 224 → 225 are the new corpus files' own exports: a sampled export of client/src/viz/capabilities/ (partial; stops framework-runtime +1, network +1 from fetch, unproven-handoff +2, disconnected +1, unresolved-symbol +1) and server/app/routers/capabilities.py#get_capabilities (assumed). No analysis code changed.

Limits

  • The view is the first cut. The next layer (the 10x pass) changes the colors, adds hover cards, search and a ranked rail.
  • No diff mode yet: capabilities changed by a PR are prototype 2 (W4).

Stack: capabilities, layer 2 of 3

This slice: the API route, the test-strength signal and the Capabilities view.
Why it is its own layer: the bottom layer is a CLI with no UI; this adds the first screen on top of the same result, and the layer above restyles it.
Full story: #502

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@byronwall
byronwall added this pull request to stack #505 November 29, 2026 05:12
@byronwall byronwall changed the title feat(capabilities): capability treemap view with linked-test strength feat(capabilities): capability treemap view in Srcly Nov 29, 2026

This branch has not been deployed

No deployments
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.

1 participant