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
Codex provides three annotation storage locations, each serving different purposes:
135
135
@@ -151,7 +151,7 @@ All annotation layers are **outside the content hash boundary** — adding annot
151
151
152
152
**Implementation note**: Core annotations live in `security/annotations.json` because they share the security directory's "outside content hash" semantics. When migrating from core annotations to the collaboration extension, implementations SHOULD convert existing annotations to the collaboration format and remove the core annotations file. The two formats SHOULD NOT coexist in the same document to avoid confusion.
153
153
154
-
### 1.6 Specification Organization
154
+
### 1.7 Specification Organization
155
155
156
156
This specification is organized into the following sections:
157
157
@@ -173,8 +173,9 @@ Extension specifications (optional modules) are defined separately:
173
173
- Phantom Extension
174
174
- Forms Extension
175
175
- Semantic Extension
176
+
- Legal Extension
176
177
177
-
### 1.7 Versioning
178
+
### 1.8 Versioning
178
179
179
180
This specification uses semantic versioning (MAJOR.MINOR.PATCH):
Copy file name to clipboardExpand all lines: spec/core/03-content-blocks.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1003,6 +1003,15 @@ Example:
1003
1003
}
1004
1004
```
1005
1005
1006
+
### 5.1 Extension Mark Types
1007
+
1008
+
Extensions MAY define additional mark types for use within text nodes. Unlike block types, extension marks are NOT required to use a namespace prefix — marks operate within the text node's `marks` array where the collision risk is lower. However, extensions MAY use a namespace prefix (e.g., `legal:cite`) when the unqualified name could cause confusion with marks from other extensions.
1009
+
1010
+
Extension marks:
1011
+
- SHOULD be documented in the extension specification
1012
+
- MUST define their field table (type, required fields, optional fields)
1013
+
- SHOULD avoid names that collide with core marks or marks from commonly-paired extensions
Copy file name to clipboardExpand all lines: spec/core/03a-anchors-and-references.md
+15Lines changed: 15 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -295,6 +295,8 @@ Extensions extend the base Person type with additional fields via schema composi
295
295
296
296
All Person objects MUST include at minimum the `name` field. Extensions SHOULD include the base fields alongside their extension-specific fields. The naming distinction between "author" and "signer" is intentional to reflect the semantic difference in their contexts.
297
297
298
+
Extensions MAY add domain-specific identity fields to the Person object. The core `identifier` field remains available for persistent scholarly or decentralized identifiers. Extension-specific identity fields are additive — they do not replace `identifier`. For example, the collaboration extension adds `userId` for session-level identity, and the security extension adds `keyId` for cryptographic key association. A Person object MAY include both `identifier` and extension-specific fields simultaneously.
299
+
298
300
## 10. Relationship to Extensions
299
301
300
302
The anchor system is defined in the core specification but is primarily consumed by extensions:
@@ -307,3 +309,16 @@ The anchor system is defined in the core specification but is primarily consumed
307
309
| Semantic (`codex.semantic`) | Internal `semantic:ref``target` fields use Content Anchor URI syntax |
308
310
309
311
See the respective extension specifications for details.
312
+
313
+
## 11. Cross-Reference Mechanism Selection
314
+
315
+
Multiple mechanisms exist for cross-referencing within Codex documents. Use the following guidance:
|`semantic:ref`| Semantic | Scholarly cross-references (e.g., 'see Section 3', 'as shown in Figure 2') with automatic label generation |
321
+
|`presentation:reference`| Presentation | Layout-aware references that need presentation-specific formatting or page numbers |
322
+
|`academic:theoremRef` / `academic:equationRef`| Academic | References to theorems, equations, or other numbered academic elements |
323
+
324
+
For simple internal links, use the core `link` mark. For documents requiring automatic numbering and label generation (e.g., 'Figure 3', 'Theorem 2.1'), use extension-specific reference marks. When multiple reference types apply, prefer the most semantically specific mechanism.
Copy file name to clipboardExpand all lines: spec/core/06-document-hashing.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -122,9 +122,12 @@ The following table summarizes what is included in and excluded from the documen
122
122
| Security | No | Signatures reference the hash — not part of it |
123
123
| Timestamps | No | Administrative metadata (`created`, `modified`) |
124
124
| Provenance | No | Lineage tracking and derivation history |
125
+
| CRDT metadata | No | Transient synchronization state from collaboration extension |
125
126
126
127
This boundary ensures that the document's identity represents its **semantic content** — what the document says — rather than how it appears or administrative metadata about it.
127
128
129
+
> **Note:** CRDT metadata added by the collaboration extension (`crdt` fields on content blocks) is excluded from the content hash. CRDT data represents transient synchronization state and MUST be stripped before computing the document hash.
The `version` field in Dublin Core metadata refers to the Dublin Core Metadata Element Set standard version (currently 1.1), not the Codex specification version. The Codex specification version is declared in the manifest's `specVersion` field.
@@ -690,10 +690,16 @@ This produces: Theorem 1, Lemma 2, Proposition 3, Theorem 4, etc.
690
690
691
691
### 10.3 Reset Triggers
692
692
693
+
The `resetOn` field accepts heading level identifiers: `heading1` through `heading6`, corresponding to the core `heading` block's `level` attribute. For example, `"heading1"` resets numbering at each level-1 heading.
Copy file name to clipboardExpand all lines: spec/extensions/collaboration/README.md
+39-3Lines changed: 39 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -64,6 +64,8 @@ Each content block can carry CRDT metadata:
64
64
}
65
65
```
66
66
67
+
**Hashing:** CRDT metadata (`crdt` fields on content blocks) MUST be stripped before computing the document content hash (see Core Specification, Section 6 — Document Hashing). CRDT metadata represents transient synchronization state, not document content. Implementations MUST materialize CRDT operations to plain content before hashing.
68
+
67
69
### 3.4 Text CRDTs
68
70
69
71
For rich text editing within blocks, integrate with text CRDTs:
|`resolved`| boolean | No | Whether comment is resolved |
232
234
|`replies`| array | No | Reply comments |
233
235
234
-
### 4.3a Author Object
236
+
### 4.3a Reply Object
237
+
238
+
The `replies` array contains reply objects. Replies are flat — they do not nest (a reply cannot contain further replies). Replies do not have their own anchors; they inherit the anchor context of the parent comment.
0 commit comments