@rubytech/create-maxy 1.0.746 → 1.0.747
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -848,3 +848,43 @@ FOR (c:Credential) REQUIRE (c.accountId, c.name, c.authority) IS UNIQUE;
|
|
|
848
848
|
|
|
849
849
|
CREATE INDEX credential_account IF NOT EXISTS
|
|
850
850
|
FOR (c:Credential) ON (c.accountId);
|
|
851
|
+
|
|
852
|
+
// ----------------------------------------------------------
|
|
853
|
+
// Provenance indexes (Task 800) — back the shim's per-write
|
|
854
|
+
// orphan check. Task 797's `executeWrite` runs an unanchored
|
|
855
|
+
// `MATCH (n) WHERE n.createdBySession = $autoSession AND
|
|
856
|
+
// n.createdAt >= $autoStartTimestamp AND NOT (n)--()` after
|
|
857
|
+
// every operator write. Without an index this is `AllNodesScan`
|
|
858
|
+
// — sub-millisecond on the current ~10K-node graph, but a
|
|
859
|
+
// per-write tax that grows with graph size.
|
|
860
|
+
//
|
|
861
|
+
// Neo4j 5 property indexes require a label clause; there is no
|
|
862
|
+
// label-free range/text/point index. The orphan check is
|
|
863
|
+
// unanchored, so the planner relies on `UnionNodeByLabelsScan`
|
|
864
|
+
// (Neo4j 5.6+) to combine per-label seeks. If a future EXPLAIN
|
|
865
|
+
// shows `AllNodesScan` despite these indexes, the orphan-check
|
|
866
|
+
// Cypher in `cypher-shim-write.ts` should be anchored with an
|
|
867
|
+
// explicit label union — that's the structural fallback.
|
|
868
|
+
//
|
|
869
|
+
// Coverage: the five labels written most often through the raw
|
|
870
|
+
// Cypher write path (Person, Organization, KnowledgeDocument,
|
|
871
|
+
// Section, Task). Other written labels (Project, Position,
|
|
872
|
+
// Credential, ToolCall, Conversation, etc.) still hit
|
|
873
|
+
// `AllNodesScan` for the orphan check; extending coverage is a
|
|
874
|
+
// separate decision, not a default.
|
|
875
|
+
// ----------------------------------------------------------
|
|
876
|
+
|
|
877
|
+
CREATE INDEX person_created_by_session IF NOT EXISTS
|
|
878
|
+
FOR (n:Person) ON (n.createdBySession);
|
|
879
|
+
|
|
880
|
+
CREATE INDEX organization_created_by_session IF NOT EXISTS
|
|
881
|
+
FOR (n:Organization) ON (n.createdBySession);
|
|
882
|
+
|
|
883
|
+
CREATE INDEX knowledge_doc_created_by_session IF NOT EXISTS
|
|
884
|
+
FOR (n:KnowledgeDocument) ON (n.createdBySession);
|
|
885
|
+
|
|
886
|
+
CREATE INDEX section_created_by_session IF NOT EXISTS
|
|
887
|
+
FOR (n:Section) ON (n.createdBySession);
|
|
888
|
+
|
|
889
|
+
CREATE INDEX task_created_by_session IF NOT EXISTS
|
|
890
|
+
FOR (n:Task) ON (n.createdBySession);
|