Orchestrata Ultimate › Plans › kg-project-scoped-identity

Project-scoped KG identity — migration plan (session 227)

Source: plans/kg-project-scoped-identity.md at 8a2cb42ad · last changed 2026-07-27 · first committed 2026-07-12 · 51 lines.

Prose pending.

Plan text

Project-scoped KG identity — migration plan (session 227)

User rulings 2026-07-12: (1) "the graph must take multiple projects, 100 even"; (2) "projects have specs, user stories, requirements, and ast unique to them". Every project-derived entity is unique PER PROJECT — bare natural ids (relative paths, qualified names, spec/req ids) must never be global MERGE identity. Memory: project-kg-multi-project-invariant.

Identity rule

Canonical id for project-derived labels = "{project}:{natural_id}". Genuinely global registries keep their keys: Volk(alias), Tool(name), Pattern(name), Portfolio(name). Session-scoped records key on their own ids.

Status by label (writer-verified)

Label Writer key today Verdict Wave
Package {project}:{path} (sync.py) FIXED — canon key → id (7eee8a46) done
Module {project}:module:{path} (sync.py) already qualified done
File / Directory bare relative path (2 diverging writers) builder in flight W1
Class / Function bare qualified_name (sync.py:342/376) COLLIDES W2
Spec / Requirement / RequirementItem bare "023" / "023::REQ-…" (_stage_specs_traces.py:129-153, sync.py:491) COLLIDES W2
UserStory / Specification / Requirement (kg_design.py:208-296) bare story_id/spec_id/req_id + divergent key names COLLIDES + key drift W2
Requirement (kernel/pipeline_kg.py:330) req_id divergent key, bare COLLIDES + key drift W2
Test {?} sync.py:805 — verify id shape verify in W2 W2
TestRun / TestResult run_id (uuid — inherently unique) / bare name (test_results_store.py:171) TestResult.name COLLIDES W2
Scenario harness scenario_id — verify uniqueness scope verify in W2 W2
Component name — unverified watch item W3

Waves

Constraint drops owed (after each wave's writers land)