]> dreyeck.freedombox.rocks Git - topic-maps.git/blob - docs/slice-1a-validation.md
Support XTM topic name reification (Slice 21M)
[topic-maps.git] / docs / slice-1a-validation.md
1 # Slice 1a: name error classification
2
3 Base: `1805023b5c5690f224a2bb556af46a4af7c36687`, observed clean on
4 `codex/ctm-slice-1`. This correction does not begin Slice 2.
5
6 CTM 3.11 requires a string after the optional name type and colon. CTM 3.3.1
7 allows whitespace between tokens. Both `a - type:"Name".` and
8 `a - type: "Name".` are valid typed-name syntax, whose deserialization remains
9 unsupported. References: ISO/IEC 13250-6:2010,
10 <https://www.isotopicmaps.org/ctm/ctm.html>, clauses 3.3.1, 3.3.4 and 3.11.
11
12 The lexer forms a QName only when a local part immediately follows its colon;
13 otherwise the colon remains a separate token. The reader checks for a name
14 string, or a type followed by colon and string, before classifying typed names
15 as unsupported. It does not resolve name types or add typed-name semantics.
16
17 Before/after observations were reproduced in fresh SBCL processes, loading
18 source from the base Git commit and the corrected checkout respectively:
19
20 | Source | Before | After | Character offset / line / column |
21 | --- | --- | --- | --- |
22 | `a - .` | CTM-UNSUPPORTED / :TYPED-NAME | CTM-REJECTION / :EXPECTED-NAME-VALUE | 4 / 1 / 5 |
23 | `a -` | CTM-UNSUPPORTED / :TYPED-NAME | CTM-REJECTION / :EXPECTED-NAME-VALUE | 3 / 1 / 4 |
24 | `a - type:"Name".` | CTM-UNSUPPORTED / :TYPED-NAME | CTM-UNSUPPORTED / :TYPED-NAME | 4 / 1 / 5 |
25 | `a - type: "Name".` | CTM-REJECTION / :INVALID-QNAME | CTM-UNSUPPORTED / :TYPED-NAME | 4 / 1 / 5 |
26
27 The regression suite asserts exact classes, codes, offsets, line/column,
28 character position units, source labels and meaningful diagnostics for all
29 four inputs. Further checks cover a missing type separator, a missing typed
30 name value, and newline/comment layout. All original 100 semantic check labels
31 remain; 23 checks were added.
32
33 ## Validation executed
34
35 Both complete runs passed: **123 semantic checks, 54 foundation checks and 2
36 Python integrity tests**, zero failures. Each used a fresh SBCL process with
37 OS-denied networking. The second used a relocated copy excluding `.git` and
38 Python caches. Exact commands:
39
40 ```sh
41 # Working directory: /Users/rgb/workspace/topic-maps
42 /usr/bin/sandbox-exec -p '(version 1)(allow default)(deny network*)' /usr/bin/env PYTHONDONTWRITEBYTECODE=1 SBCL=/nix/store/hlsiblxpxr1hax3dw9x8znd6zy097ddj-sbcl-2.5.4/bin/sbcl TOPIC_MAPS_REPORT=/private/tmp/ctm-slice-1a-2.5.4.json scripts/test.sh
43
44 # Working directory: /private/tmp/ctm-slice-1a-relocated-yfcaz7au/checkout
45 /usr/bin/sandbox-exec -p '(version 1)(allow default)(deny network*)' /usr/bin/env PYTHONDONTWRITEBYTECODE=1 SBCL=/nix/store/y96nx8571mpdvjd40krkdim2av0in972-sbcl-2.4.10/bin/sbcl TOPIC_MAPS_REPORT=/private/tmp/ctm-slice-1a-2.4.10.json /private/tmp/ctm-slice-1a-relocated-yfcaz7au/checkout/scripts/test.sh
46
47 cmp /private/tmp/ctm-slice-1a-2.5.4.json /private/tmp/ctm-slice-1a-2.4.10.json
48 cmp /private/tmp/ctm-slice-1a-2.5.4.json.semantics.json /private/tmp/ctm-slice-1a-2.4.10.json.semantics.json
49 ```
50
51 All commands exited zero. Both report pairs are byte-identical. The five
52 positive semantic case records, including actual object properties and
53 parent/type reference observations, are unchanged from the committed Slice 1
54 semantic report. The selected frozen-baseline property checker also passes.
55
56 Imported statuses remain PASS 1, FAIL 0, UNSUPPORTED 0, NOT-RUN 272. All five
57 positive CXTM-EQUAL contracts remain NOT-RUN; only the specific undefined-prefix
58 rejection is PASS. No canonical output was produced.
59
60 All 2,006 pinned corpus files still match their original sizes and hashes;
61 inputs, baselines and pin files are unchanged. No TMDM source was changed.
62
63 No remaining discrepancy was observed for the four requested inputs. Existing
64 Slice 1 boundaries remain, including unsupported typed-name deserialization,
65 full IRI validation and general merging, and absent CXTM canonicalization.
66 The pinned corpus targets draft 2010-03-31 and does not establish full ISO
67 conformity. No HyperDoc integration, server, SSH or deployment was performed.