Add document-format RFC draft#4264
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new RFC document detailing the .gdd document format for Graphite, which decouples the on-disk layout from the editor's in-memory runtime types using a flat node registry and operation-based CRDT deltas. The review feedback points out several structural discrepancies between the pseudo-code definitions in the RFC and the actual Rust implementation in the codebase (such as in Registry, Node, InputSlot, RegistryDelta, and Delta), providing concrete code suggestions to align them.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
There was a problem hiding this comment.
5 issues found across 1 file
Confidence score: 3/5
- In
node-graph/rfcs/document-format.md, thelibrary::exported_nodes_tssidecar underRegistry.attributesoverlaps with theChangeDocumentAttributewrite path, so a normal attribute edit could silently corrupt the LWW basis for exported nodes updates — reserve/protect that key (or move it out of generic attributes) before merging. - In
node-graph/rfcs/document-format.md,RegistryDelta::RegisterPeerhas no reverse form even thoughDelta.reverseis required, which leaves this operation impossible to represent as a valid reversible delta — add a reverse variant or relax/document reverse semantics for non-reversible ops before merge. - In
node-graph/rfcs/document-format.md,inputs_attributes: Vec<Attributes>has no invariant tying it toinputs: Vec<InputSlot>, so mismatched lengths could silently desynchronize node inputs and their metadata — document and enforce a length invariant (including validation onAddNodeand input-count changes). - In
node-graph/rfcs/document-format.md, the RFC’s delta field names/types diverge fromgraph-storage(node_id/networkvsid,usizevsu32,delta_typevskind), which increases integration and maintenance risk from spec/implementation drift — align the RFC to current code (or add an explicit mapping note) before merging.
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
There was a problem hiding this comment.
1 issue found across 1 file
Confidence score: 3/5
- In
node-graph/rfcs/document-format.md, the proposed add-wins OR-set for the resource source chain is missing tombstone/observation tracking, so the current Vec add/remove behavior is order-dependent rather than add-wins; merging as-is risks baking incorrect CRDT semantics into the spec and causing divergent behavior across implementations — define the required tombstone or causal-observation mechanism and update the RFC semantics before merging.
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
There was a problem hiding this comment.
1 issue found across 1 file (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
…e; fix resurrection mechanism
eb8d12e to
1dbfa26
Compare
No description provided.