Skip to content

Canonical Neo4j projection contract: merge labels, body-node model, can:// grammar #36

Description

@rahlk

Parent: #35 · Roadmap: docs/design/roadmap.md (candidates 1, 2, 4)

Skeleton — bodies to be filled in by the maintainer.

Problem

Canonical v2 is specified, but each analyzer projects it differently and nothing states which projection is correct. codeanalyzer-python uses 9 Neo4j merge labels and splits the body model across PyCallSite and PyCFGNode; codeanalyzer-typescript uses 2 (Application, CanNode) with a unified TSBodyNode; codeanalyzer-java has no statement-level nodes in Neo4j at all (.claude/SCHEMA_DECISIONS.md #9) and no can:// ids.

Scope boundary

Writes the contract. Does not migrate any analyzer, does not build the conformance suite or the parity gate (separate sub-issues), and does not settle the entrypoint vocabulary (its own design session).

Goals

  • Neo4j projection contract: merge-label strategy, language namespacing, what "always full-depth" obliges
  • Unified body-node model — one node with a kind discriminant, and what Java must add
  • can:// grammar conformance: per-language signatureOf() pinned, including Java which has none today
  • Committed to docs/design/specs/

Caveats and known risks

  • TODO
  • Java's statement-level CPG was deliberately deferred, not overlooked — the contract must state what it now requires and at what cost.

Definition of done

  • TODO — exact conditions, not "spec written".

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions