You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/gap-analysis.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -117,19 +117,19 @@ Complete slices:
117
117
118
118
Deferred or optional future slices:
119
119
- Public surface expansion:
120
-
- trace breadth now covers modes, risk labels, and multi-edge-type filtering (Plan 03 complete); `HTTP_CALLS` and `ASYNC_CALLS` edges are now produced via service-pattern call reclassification; remaining gap is `DATA_FLOWS` edges
120
+
- trace breadth now covers modes, risk labels, and multi-edge-type filtering (Plan 03 complete); `HTTP_CALLS` and `ASYNC_CALLS` edges are now produced via service-pattern call reclassification, and decorator-backed `HANDLES` edges are verified on the graph-model route fixture; remaining gap is route-linked`DATA_FLOWS` edges
121
121
- Query/runtime expansion:
122
122
- full Cypher lexer/parser/executor parity beyond the verified shared read-only floor
123
123
- broader traversal and query-analysis parity beyond the current shared `detect_changes` contract
124
124
- Indexing/runtime expansion:
125
125
- deeper usage/type-ref extraction parity beyond the current daily-use slice
- long-tail edges — now implemented: `THROWS`/`RAISES` (JS/TS/TSX throw statements); remaining or out-of-scope gaps: `OVERRIDE` (Go-only), `WRITES`/`READS` (not proven original-overlap by the current C reference fixture), `HANDLES`/`DATA_FLOWS` (deferred route-graph)
129
-
- route nodes — partially implemented (stub `Route` nodes from `HTTP_CALLS`/`ASYNC_CALLS` edges; no `HANDLES` or`DATA_FLOWS` yet)
128
+
- long-tail edges — now implemented: `THROWS`/`RAISES` (JS/TS/TSX throw statements) and decorator-backed `HANDLES`; remaining or out-of-scope gaps: `OVERRIDE` (Go-only), `WRITES`/`READS` (not proven original-overlap by the current C reference fixture), route-linked `DATA_FLOWS` (deferred route-graph)
129
+
- route nodes — partially implemented (stub `Route` nodes from `HTTP_CALLS`/`ASYNC_CALLS` edges plus verified decorator-backed `Route`/`HANDLES`; no route-linked`DATA_FLOWS` yet)
130
130
- config-linking — partially implemented (Strategy 1 key-symbol + Strategy 2 dependency-import; full config normalization surface not yet ported)
131
131
- richer decorator/enrichment promotion
132
-
- current entrypoint: [graph-model-parity-plan.md](/Users/skooch/projects/codebase-memory-zig/docs/plans/new/graph-model-parity-plan.md)
132
+
- current entrypoint: [graph-model-parity-plan.md](/Users/skooch/projects/codebase-memory-zig/docs/plans/in-progress/graph-model-parity-plan.md)
133
133
- Productization beyond the current contract:
134
134
- broader installer/self-update behavior
135
135
- broader agent integration coverage and installer diagnostics
@@ -428,7 +428,7 @@ The Zig store has the schema (tables + indexes + pragmas) and opens in-memory DB
428
428
|`pass_parallel`| 1,427 | MISSING | Thread pool orchestration |
|`pass_route_nodes`| 742 | PARTIAL (stub Route nodes from `HTTP_CALLS`/`ASYNC_CALLS` edges; no `HANDLES` or `DATA_FLOWS`) | HTTP route node creation |
431
+
|`pass_route_nodes`| 742 | PARTIAL (stub Route nodes from `HTTP_CALLS`/`ASYNC_CALLS` edges plus verified decorator-backed `Route`/`HANDLES`; no route-linked `DATA_FLOWS`) | HTTP route node creation and first handler association slice|
432
432
|`pass_tests`| 285 | WORKS for the shared Python `TESTS` / `TESTS_FILE` slice | Test file/function tagging now verified on the local parity fixture; broader language breadth stays follow-on work |
433
433
|`pass_enrichment`|~200 | MISSING (deferred) | Decorator tag enrichment |
-[ ] Re-read the original route, config-linking, and semantic-edge passes and record only the overlapping behavior still missing from the Zig port.
58
-
-[ ] Define fixture-backed acceptance rules for `Route`, `HANDLES`, `HTTP_CALLS`, `ASYNC_CALLS`, route-linked `DATA_FLOWS`, decorator route extraction, and config normalization/linking.
59
-
-[ ] Add minimal JavaScript/TypeScript and Python fixtures under `testdata/interop/graph-model/` before changing extractor behavior.
60
-
-**Status:** pending approval
64
+
-[x] Re-read the original route, config-linking, and semantic-edge passes and record only the overlapping behavior still missing from the Zig port.
65
+
-[x] Define fixture-backed acceptance rules for decorator-backed `Route` and `HANDLES` facts.
66
+
-[ ] Define fixture-backed acceptance rules for `HTTP_CALLS`, `ASYNC_CALLS`, route-linked `DATA_FLOWS`, and config normalization/linking.
67
+
-[x] Add a minimal Python route fixture under `testdata/interop/graph-model/routes/`.
68
+
-[ ] Add minimal JavaScript/TypeScript route fixtures once the shared C/Zig public behavior is established for those registrations.
69
+
-**Status:** partially complete
61
70
62
71
### Phase 2: Complete Route Handler Modeling
63
-
-[ ] Extend route extraction so supported framework registrations and decorators resolve to handler symbols instead of only creating route rendezvous nodes from outbound calls.
64
-
-[ ] Emit `HANDLES` edges from handler functions/methods to `Route` nodes, preserving method/path metadata and duplicate-route suppression.
65
-
-[ ] Add store, extractor, pipeline, and Cypher regression coverage for route node creation, handler association, and route summary exposure.
-[ ] Define the first accepted `DATA_FLOWS` route-link contract from request entry points through handler calls without pretending to solve full local data-flow analysis.
@@ -78,11 +89,11 @@ before implementation starts.
78
89
-**Status:** pending approval
79
90
80
91
### Phase 5: Verify and Reclassify
81
-
-[] Run `zig build`, `zig build test`, `bash scripts/run_interop_alignment.sh --zig-only`, and focused graph-model fixture queries.
82
-
-[] Run the full Zig-vs-C interop harness if the C reference binary is available locally.
83
-
-[] Update `docs/port-comparison.md`, `docs/gap-analysis.md`, and `docs/zig-port-plan.md` only for rows backed by the new fixtures.
92
+
-[x] Run `zig build`, `zig build test`, `bash scripts/run_interop_alignment.sh --zig-only`, and focused graph-model fixture queries.
93
+
-[x] Run the full Zig-vs-C interop harness if the C reference binary is available locally.
94
+
-[x] Update `docs/port-comparison.md`, `docs/gap-analysis.md`, and `docs/zig-port-plan.md` only for rows backed by the new fixtures.
84
95
-[ ] Move this plan and its progress log to `docs/plans/implemented/` only after all required verification passes.
- Moved `docs/plans/new/graph-model-parity-plan.md` to `docs/plans/in-progress/graph-model-parity-plan.md` before implementation.
9
+
- Starting from current main baseline: full Zig-vs-C harness reports 151 comparisons, 86 strict matches, 19 diagnostic-only comparisons, and 10 known mismatches.
10
+
- Re-read the original route-node and service-pattern route registration paths and selected the first shared public contract: decorator-backed routes create `Route` nodes and `HANDLES` edges, with query-visible handler and route rows.
11
+
- Added `testdata/interop/graph-model/routes/app.py` and manifest assertions for `Route` and `HANDLES` query rows.
12
+
13
+
### Phase 2: Complete Route Handler Modeling
14
+
-**Status:** in progress
15
+
- Actions:
16
+
- Extended extractor state so route decorators create `Route` nodes plus `HANDLES` edges during extraction.
17
+
- Added route-registration call metadata for framework calls such as `app.get("/path", handler)` and pipeline emission for `Route`, `CALLS`, and `HANDLES` when the handler resolves.
18
+
- Added focused unit coverage in `src/extractor.zig`, `src/pipeline.zig`, and `src/service_patterns.zig`.
19
+
- Updated Zig golden snapshots; new `graph-model-routes` golden locks `/users` and `list_users -> /users`.
20
+
21
+
### Verification
22
+
-`zig build` -> passed
23
+
-`zig build test` -> passed
24
+
-`bash scripts/run_interop_alignment.sh --update-golden` -> passed, 20/20 golden snapshots updated
25
+
-`bash scripts/run_interop_alignment.sh --zig-only` -> passed, 20/20 golden comparison
26
+
-`bash scripts/run_interop_alignment.sh` -> passed with 20 fixtures, 158 comparisons, 89 strict matches, 20 diagnostic-only comparisons, 10 known mismatches, and `cli_progress: match`
27
+
28
+
## Errors
29
+
| Timestamp | Error | Attempt | Resolution |
30
+
|-----------|-------|---------|------------|
31
+
| 2026-04-16 | Initial `graph-model-routes` manifest used a Zig project name that did not match the indexed directory basename, so query assertions read an empty project. | Ran `--update-golden` and inspected the generated `graph-model-routes` snapshot. | Changed the fixture project to `routes`, regenerated golden snapshots, and verified query rows were populated. |
32
+
| 2026-04-16 | JavaScript route-registration fixture improved Zig but was not emitted by the current C binary, adding a new full-harness mismatch. | Ran the full Zig-vs-C harness and inspected per-fixture route outputs. | Switched the strict shared fixture to a Python decorator route that both implementations expose publicly, while keeping Zig registration support covered by unit tests. |
33
+
| 2026-04-16 | The redirected harness rerun wrapper used `status`, which is read-only in zsh. | Tried to capture the exit code with `status=$?`. | Re-ran with `rc=$?`; both `--zig-only` and full interop passed. |
0 commit comments