colregs 0.2.3 → 0.3.0

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.
@@ -0,0 +1,102 @@
1
+ # Timeline
2
+
3
+ When COLREG 1972 changed, and how long each jurisdiction took to catch up.
4
+ Public record, every row cited. Relevant to this package because
5
+ `jurisdiction` (`intl`, `us/inland`, …) is a first-class dimension here, not
6
+ an afterthought — this is the evidence that national texts genuinely lag
7
+ the IMO instrument, by years, and by different amounts per country.
8
+
9
+ ## 1. IMO instrument history
10
+
11
+ | Date | Event | What changed | Source | Verified? |
12
+ |---|---|---|---|---|
13
+ | 1972-10-20 | COLREG 1972 adopted | Replaced 1960 Collision Regs; made TSS mandatory (Rule 10) | [imo.org](https://www.imo.org/en/About/Conventions/Pages/COLREG.aspx) | verified |
14
+ | 1977-07-15 | Entry into force | Binding on ratifying states | [imo.org](https://www.imo.org/en/About/Conventions/Pages/COLREG.aspx) | verified |
15
+ | 1981-11-19 → 1983-06-01 | 1981 amdts, Res. A.464(XII) | Rule 10: exempted safety-operation and cable-laying vessels in TSS | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
16
+ | 1987-11-19 → 1989-11-19 | 1987 amdts, Res. A.626(15) | New Rule 1(e), 8(f); Rule 3(h) def.; Rule 10(c) clarified; Annexes I & IV updated (light positions, GMDSS) | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
17
+ | 1989-10-19 → 1991-04-19 | 1989 amdts, Res. A.678(16) | Rule 10: further restricted inshore-traffic-zone use | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
18
+ | 1993-11-04 → 1995-11-04 | 1993 amdts, Res. A.736(18) | Light-positioning rules revised; Annex IV gained SART signals | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
19
+ | 2001-11-29 → 2003-11-29 | 2001 amdts, Res. A.910(22) | Added Wing-in-Ground (WIG) craft: Rule 3 def., Rules 8(a),18,23,31,33,35; Annex I & III updates | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
20
+ | 2007-11-29 → 2009-12-01 | 2007 amdts, Res. A.1004(25) | Annex IV (distress signals) replaced wholesale: added DSC, Inmarsat, EPIRB signals | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
21
+ | 2013-12-04 → 2016-01-01 | 2013 amdts, Res. A.1085(28) | New Part F (Rules 39–41) appended: compulsory Member State Audit Scheme verification | [imo.org](https://www.imo.org/en/ourwork/safety/pages/preventing-collisions.aspx) | verified |
22
+
23
+ No amendment adopted since 2013; autonomous-ship ("MASS") work is ongoing but has not produced one — [Wikipedia](https://en.wikipedia.org/wiki/Convention_on_the_International_Regulations_for_Preventing_Collisions_at_Sea).
24
+
25
+ **Renumbering:** none of the seven amendments renumbers or deletes an existing rule; each adds a paragraph, a definition, or (2013) an appended Part. Annex IV's 2007 replacement kept its number and position.
26
+
27
+ **Languages:** Article IX makes English and French "equally authentic"; Russian and Spanish are official translations, not authentic text — [Convention text, CIL NUS](https://cil.nus.edu.sg/wp-content/uploads/2019/02/1972-Convention-on-Regulations-for-Preventing-Collisions-at-Sea.pdf), verified. IMO's own official languages (for documents generally, not this treaty) are Arabic, Chinese, English, French, Russian, Spanish — [imo.org](https://www.imo.org/en/About/Conventions/Pages/COLREG.aspx), verified.
28
+
29
+ ## 2. National instruments
30
+
31
+ ### United States
32
+
33
+ | Date | Event | What changed | Source | Verified? |
34
+ |---|---|---|---|---|
35
+ | 1977 | Int'l Navigation Rules Act of 1977 | Adopted COLREG 1972 for international waters | [FR 2014-14413](https://www.federalregister.gov/documents/2014/07/02/2014-14413/changes-to-the-inland-navigation-rules) | verified |
36
+ | enacted 1980-12-24, eff. 1981-12-24 | Inland Navigational Rules Act, Pub. L. 96-591 | Created a separate, COLREG-modeled U.S. Inland Rules | [Pub. L. 96-591](https://www.navcen.uscg.gov/sites/default/files/pdf/navRules/PLaw_96_591_%2094%20_Stat_3415_1980_Inland_Navigation_Rules.pdf) | verified |
37
+ | 2010-04-15 | 75 FR 19544 | Moved Inland Rules from U.S. Code to 33 CFR 83–88; future changes by rulemaking, not statute | [FR 2014-14413](https://www.federalregister.gov/documents/2014/07/02/2014-14413/changes-to-the-inland-navigation-rules) | verified |
38
+ | 2014-08-01 | Final rule, "Changes to the Inland Navigation Rules" | Incorporated the 2001 & 2007 IMO amendments (WIG craft, new Annex IV); renumbered the CFR to track COLREG rule numbers | [FR 2014-14413](https://www.federalregister.gov/documents/2014/07/02/2014-14413/changes-to-the-inland-navigation-rules) | verified |
39
+
40
+ ### United Kingdom
41
+
42
+ | Date | Event | What changed | Source | Verified? |
43
+ |---|---|---|---|---|
44
+ | 1996-05-01 | SI 1996/75 in force | Domestic effect for COLREG as then amended | [legislation.gov.uk](https://www.legislation.gov.uk/uksi/1996/75/made) | verified |
45
+ | 2004-05-28 | MSN 1781 first published | MCA notice carrying the technical Rules text | [gov.uk](https://www.gov.uk/government/publications/msn-1781-distress-signals-and-preventing-collisions) | verified |
46
+ | 2016 | MSN 1781 Amendment 2 | Reissued, superseding the original | [gov.uk PDF](https://assets.publishing.service.gov.uk/media/5dfa3bcced915d54a89bd4ab/MSN1781_Amendment2_2016.pdf) | date verified; which IMO round it applies unverified |
47
+ | 2023-11-21 | MSN 1781 Amendment 3 | Non-COLREG: scope re Watercraft Order 2023 | [gov.uk](https://www.gov.uk/government/publications/msn-1781-mf-amendment-3-the-merchant-shipping-regulations-1996-colreg) | verified |
48
+
49
+ ### Canada
50
+
51
+ | Date | Event | What changed | Source | Verified? |
52
+ |---|---|---|---|---|
53
+ | 1978 base | Collision Regs, C.R.C. c. 1416 | Incorporates COLREG "with Canadian Modifications" | [Justice Laws](https://laws-lois.justice.gc.ca/eng/regulations/C.R.C.,_c._1416/) | verified |
54
+ | ongoing | SOR/78-528, SOR/83-202, etc. | Periodic amendments track IMO and add Canadian mods | [publications.gc.ca](https://publications.gc.ca/site/eng/9.662001/publication.html) | verified |
55
+ | 2023-06-07 | Most recent amendment | Current to 2026-07-21, last amended 2023-06-07 | [Justice Laws](https://laws-lois.justice.gc.ca/eng/regulations/C.R.C.,_c._1416/page-4.html) | verified |
56
+
57
+ ### Finland
58
+
59
+ | Date | Event | What changed | Source | Verified? |
60
+ |---|---|---|---|---|
61
+ | 1977, SopS 30/1977 | Decree bringing COLREG 1972 into force | Ratified 1977-01-28 | [Finlex](https://finlex.fi/fi/sopimukset/sopsteksti/1977/19770030) | verified |
62
+ | 1983-07-04 | Decree incorporating the 1981 amdts | Applied Res. A.464(XII) | [Finlex](https://finlex.fi/fi/sopimukset/sopsteksti/1983/19830037) | verified |
63
+ | approved 2008-12-19, force 2009-12-01 | Decree incorporating the 2007 amdts | Applied Res. A.1004(25); domestic entry into force matches the global date exactly | [Finlex](https://finlex.fi/fi/valtiosopimukset/sopimussarja/2009/12) | verified |
64
+
65
+ ### Spain
66
+
67
+ | Date | Event | What changed | Source | Verified? |
68
+ |---|---|---|---|---|
69
+ | 1977-07-09 | BOE publishes accession instrument | Corrections followed in 1978 and 1981 | [BOE-A-1977-15605](https://www.boe.es/buscar/act.php?id=BOE-A-1977-15605) | verified |
70
+ | adopted 2001-11-29, BOE pub. 2003-02-11, eff. 2003-11-29 | 2001 amdts (A.910(22)) | BOE publication preceded the global entry into force by ~9 months | [BOE-A-2003-2716](https://www.boe.es/buscar/doc.php?id=BOE-A-2003-2716) | verified |
71
+ | adopted 2007-11-29, BOE pub. 2010-03-20, eff. 2009-12-01 | 2007 amdts (A.1004(25)) | BOE publication came ~3.5 months *after* the global entry into force | [BOE-A-2010-4648](https://www.boe.es/buscar/doc.php?id=BOE-A-2010-4648) | verified |
72
+
73
+ ### Germany
74
+
75
+ | Date | Event | What changed | Source | Verified? |
76
+ |---|---|---|---|---|
77
+ | enacted 1976-06-29 | Ratification statute, BGBl. 1976 II S. 1017 | Approved German accession | [dejure.org](https://dejure.org/BGBl/1976/BGBl._II_S._1017) | verified |
78
+ | announced 1977-06-01, eff. 1977-07-15 | Bekanntmachung of entry into force | Matches the global date | [gesetze-im-internet.de](https://www.gesetze-im-internet.de/seestro1972_bk/SeeStrO1972%C3%9Cbk.pdf) | verified |
79
+ | through the 2013 amdt (28th Assembly) | Ordinance updating the Convention annex | Cites the IMO Assembly session directly, not re-legislated | [buzer.de](https://www.buzer.de/gesetz/5250/a72559.htm) | verified |
80
+
81
+ ### Australia
82
+
83
+ | Date | Event | What changed | Source | Verified? |
84
+ |---|---|---|---|---|
85
+ | 2009-12-01 | Marine Orders Part 30, Issue 8 | Repealed Issue 7; timed to match the 2007 amdts' entry into force, same day | [PDF](https://www.marinerescueportjackson.com.au/ddlfiles/colregs.pdf) | verified |
86
+ | 2016-07-19 | Marine Order 30 (2016) | Remade under the Navigation Act 2012, replacing the 1912 Act | [legislation.gov.au](https://www.legislation.gov.au/F2016L01187/asmade) | verified |
87
+
88
+ ### Europe, inland — CEVNI
89
+
90
+ | Date | Event | What changed | Source | Verified? |
91
+ |---|---|---|---|---|
92
+ | 1962 (Res. 4); refounded as Res. 24, 1985-11-15 | Original / refounding resolution | UNECE code adapting COLREG-style rules for inland waterways | [waterways.cz PDF](https://waterways.cz/documents/European_Code_for_Inland_Waterways_E.pdf) | verified |
93
+ | 2009 | CEVNI Rev. 4 | ECE/TRANS/SC.3/115/Rev.4 | [UN Digital Library](https://digitallibrary.un.org/record/1489444) | verified |
94
+ | 2015 | CEVNI Rev. 5 | ECE/TRANS/SC.3/115/Rev.5 | [UN Digital Library](https://digitallibrary.un.org/record/1489444) | verified |
95
+ | 2022 Rev. 6; Amdt 1 in 2025-04 | CEVNI Rev. 6 and first amendment | Latest edition; the amendment issued separately | [UNECE](https://unece.org/transport/documents/2025/04/standards/cevni-european-code-inland-waterways-resolution-no-24) | Rev. 6's 2022 date unverified (year only); Amdt 1 date verified |
96
+
97
+ ## 3. Cadence
98
+
99
+ - **IMO gap between amendments:** seven amendments, 1981–2013 — 6y, 2y, 4y, 8y (max, 1993→2001), 6y, 6y. Mean ≈5.3y. None since 2013.
100
+ - **National lag varies by country and by amendment, not on a fixed schedule.** Finland and Australia both brought the 2007 amendments into force on 1 Dec 2009 — the same day as the global date. The U.S. did not incorporate the 2001 and 2007 amendments until an August 2014 rule: 13- and 7-year lags on the same two rounds.
101
+ - **Gazette date can trail legal effect.** Spain's 2007-amendment text was published in the BOE on 20 Mar 2010, ~3.5 months after it was already binding (1 Dec 2009) — a publishing lag, not two rule-numbering schemes concurrently in force. No case of the latter was found (absence not proven).
102
+ - **Citation style differs by country:** Spain and Finland cite the IMO resolution number and dates directly; the U.S. and Canada cite Federal Register/SOR numbers plus a "current to" date; the UK cites an SI number plus an MSN amendment; CEVNI cites a revision plus amendment number.
@@ -0,0 +1,265 @@
1
+ # The `text_slug` straw man, built on `intl` Rules 1-19
2
+
3
+ ADR 0010 leaves in pencil what a withheld paragraph carries in place of its
4
+ text, and names a slug as a straw man to be built and judged rather than
5
+ argued about. This is the build and the judgement. The research issue is
6
+ colregs#83; nothing here decides the pencil item.
7
+
8
+ Everything below is reproducible from `scripts/text-slug.mjs` over the
9
+ en-US corpus (`data/text/intl/2016/en-US.uscg.json` since ADR 0013 moved the
10
+ words out of `data/rules.json`). Nothing was written into `data/`.
11
+
12
+ ## What the pipeline does
13
+
14
+ Deterministic, no model in the loop, no dependencies:
15
+
16
+ 1. **Citations first.** `Rule 13`, `Rules 4-19`, `Rule 34(c)(i)` become
17
+ `rule-13`, `rules-4-19`, `rule-34ci`. A citation is a fact about which
18
+ provision is invoked, not expression, and it is the most navigable term a
19
+ slug can carry.
20
+ 2. **Terms of art as one term.** A fixed table of multi-word terms collapses
21
+ each to a hyphenated token: `traffic-separation-scheme`, `not-under-command`,
22
+ `restricted-ability-maneuver`, `keep-out-of-way`, `risk-of-collision`,
23
+ `in-sight`, `narrow-channel`. The target form is the applicability
24
+ vocabulary's wherever one exists.
25
+ 3. **Stop words out.** Function words, modals and the words that are in nearly
26
+ every paragraph and say nothing about which one this is: `vessel`, `rule`,
27
+ `shall`, `circumstances`, `practicable`.
28
+ 4. **Lemmatise.** Plurals by rule; every `-ed` and `-ing` form by a table,
29
+ because a suffix rule cannot tell `speed` from `stopped` without a lexicon.
30
+ Gerunds that name an activity in `facts.json` keep the gerund (`fishing`,
31
+ `towing`), so the slug's form is the vocabulary's form.
32
+ 5. **Sorted set.** No order, no syntax, no counts.
33
+
34
+ Numbers keep their unit (`20-meter`, `22-5-degree`).
35
+
36
+ ## Shape of the output
37
+
38
+ | measure | Rules 1-19 |
39
+ |---|---|
40
+ | paragraphs | 122 |
41
+ | terms per slug, min / median / max | 0 / 6 / 34 |
42
+ | empty slugs | 1: `6(a)`, whose text is "By all vessels:" |
43
+ | identical slugs | 3 groups, all in Rule 18: `18(a)(i)=18(b)(i)=18(c)(i)`, `18(a)(ii)=18(b)(ii)=18(c)(ii)`, `18(a)(iii)=18(b)(iii)` |
44
+ | near-duplicates, Jaccard ≥ 0.6 | 1 pair: `13(c)` and `14(c)`, the two "if in doubt, assume" paragraphs |
45
+
46
+ The identical slugs are identical source text: "a vessel not under command"
47
+ under three different chapeaux. No slug can separate them, and neither can
48
+ the text; the path does. That is the ceiling on question 1 for this corpus.
49
+
50
+ ## Question 1: can a reader navigate to the paragraph from the slug alone?
51
+
52
+ Method: the 122 slugs, shuffled by a fixed hash of the path and stripped of
53
+ their paths (`--blind`), were given to two readers with no access to the
54
+ repository or any other file, asked to name the paragraph for each line with
55
+ a confidence from 1 to 3. The readers were two language models chosen as
56
+ proxies for a strong and a weak human reader of the Rules: one that knows
57
+ COLREGS closely (Claude Opus) and one that knows it loosely (Claude Haiku).
58
+ Scored against the key.
59
+
60
+ | reader | exact paragraph | correct rule | wrong while "sure" |
61
+ |---|---|---|---|
62
+ | strong | 115 / 122 | 122 / 122 | 1 |
63
+ | weak | 30 / 122 | 79 / 122 | 38 |
64
+
65
+ The strong reader's seven misses: six are inside the three identical-slug
66
+ groups above, where the answer is one of the group and the slug cannot say
67
+ which; the seventh is `15` for `15(a)`, a citation-form slip on a rule with
68
+ one paragraph. Every miss that the slug could in principle have prevented,
69
+ it prevented.
70
+
71
+ The weak reader reached the right rule in two cases out of three and the
72
+ right paragraph in one out of four, and was confidently wrong 38 times. The
73
+ misses are almost all off-by-one within a rule (`8(b)` read as `8(a)`) or a
74
+ Rule 18 sub-item read as its Rule 3 definition, which is to say the reader
75
+ did not know the paragraph numbering, and the slug does not teach it.
76
+
77
+ Reading: **the slug is an index, not a substitute.** A reader who knows the
78
+ Rules lands on the paragraph from the slug alone, at the ceiling the corpus
79
+ allows. A reader who does not know the Rules lands on the rule, mostly, and
80
+ on the paragraph rarely. For the case ADR 0010 is for, that ordering
81
+ matters: a CEVNI reader will usually be the second kind, the source is not
82
+ English, and the terms would be translations, so the strong-reader number is
83
+ an upper bound and the weak-reader number is the honest expectation.
84
+
85
+ ## Question 2: do the terms overlap the applicability vocabulary?
86
+
87
+ Method: every fact key and enumerated value that `data/applicability.json`
88
+ predicates and `data/facts.json` axes use, 67 terms, mapped to slug space by
89
+ a table that is mostly the four abbreviations (`nuc`, `ram`, `cbd`, `wig`)
90
+ and the underscores.
91
+
92
+ - **59 of 67 terms appear in some slug of Rules 1-19.** The eight that do not
93
+ are terms from outside the range or not terms at all: `activity:diving`,
94
+ `activity:pushing`, `activity:none`, `position:moored`, `propulsion:oars`,
95
+ `fact:composite_unit`, `fact:on_mooring_buoy`, `wind_side:unknown`. Within
96
+ the range the overlap is complete.
97
+ - **Per entry, the cited paragraph's slug carries the term the entry turns
98
+ on.** All 31 entries citing a paragraph in Rules 1-19 were checked
99
+ (`--stats`). `13a` reads `hist:was_overtaking`; `13(a)`'s slug carries
100
+ `overtake`. `9b` reads `length_m`, `propulsion:sail` and
101
+ `confined_to_channel`; `9(b)`'s slug carries `20-meter`, `sailing-vessel`,
102
+ `narrow-channel`, `navigate`. `18d1` reads three Rule 18 classes;
103
+ `18(d)(i)`'s slug carries all three. What the slug does not carry are the
104
+ gates an entry inherits from a chapeau or a scope rule rather than from
105
+ its own paragraph: `pair:geo:in_sight` (Rule 11), `position:underway`
106
+ (`18(a)`'s chapeau), and the derived `fact:rule18_class` key. Those are in
107
+ the chapeau's slug, which is where the text puts them.
108
+
109
+ Reading: **the overlap is real and it runs the useful way.** The
110
+ applicability vocabulary was written from these paragraphs, so the slug of a
111
+ paragraph recovers the terms its entries gate on. A term-set built for a
112
+ withheld jurisdiction the same way would give a consumer a vocabulary-level
113
+ hook into each paragraph without a word of it.
114
+
115
+ ## What this does and does not settle
116
+
117
+ Settled by the build: the pipeline is deterministic, cheap, and produces a
118
+ navigable index for a reader who already knows the Rules, at the corpus's
119
+ own ceiling. The terms line up with the vocabulary.
120
+
121
+ Not settled, and not this document's to settle:
122
+
123
+ - Whether a slug ships for CEVNI at all, alone or beside `text_digest` and
124
+ `mirrors`. The weak-reader result says a slug does not replace the words
125
+ for the reader most likely to need them; `mirrors` does, for the majority
126
+ of CEVNI, and the slug's value is in the remainder.
127
+ - Where the derivative-work line falls. Out of scope on colregs#82; redaction
128
+ ships whatever the answer.
129
+ - The pipeline's tables are hand-built for this corpus. A CEVNI run needs a
130
+ translation step to English counterparts before the same tables apply,
131
+ and a lexicon for forms the tables do not know. That is engineering, not
132
+ a design question.
133
+
134
+ What would move the pencil item: a decision on the first bullet, taken with
135
+ the `mirrors` coverage of CEVNI in hand, since that number is what says how
136
+ much of CEVNI the slug would be the only thing standing in for.
137
+
138
+ ## The slugs
139
+
140
+ `node scripts/text-slug.mjs`, Rules 1-19, at this commit:
141
+
142
+ ```
143
+ 4 apply, rules-4-10, visibility
144
+ 5 appraisal, available, hearing, look-out, maintain, risk-of-collision, sight, situation
145
+ 6 action, avoid, collision, determine, distance, effective, factor, proceed, safe-speed, stop
146
+ 11 apply, in-sight, rules-11-18
147
+ 16 action, direct, early, keep-clear, keep-out-of-way, substantial
148
+ 18 except, rule-10, rule-13, rule-9
149
+ 1(a) apply, connect, high-seas, navigable, seagoing, water
150
+ 1(b) authority, conform, connect, harbor, high-seas, inland, interfere, lake, navigable, operation, river, roadstead, seagoing, waterway
151
+ 1(c) additional, authorize, convoy, elsewhere, engaged-in-fishing, fishing, fleet, government, interfere, light, mistake, operation, proceed, shape, ship, signal, state, station, war, whistle
152
+ 1(d) adopt, organization, traffic-separation-scheme
153
+ 1(e) appliance, arc, characteristic, comply, concern, construction, determine, disposition, government, light, number, position, range, shape, sound-signaling, visibility
154
+ 2(a) comply, consequence, crew, exonerate, master, neglect, owner, practice, precaution, seaman
155
+ 2(b) avoid, collision, comply, construe, danger, departure, immediate, limitation, navigation
156
+ 3(a) craft, non-displacement, seaplane, transportation, water, watercraft, wig-craft
157
+ 3(b) machinery, power-driven, propel
158
+ 3(c) fit, machinery, propel, sail, sailing-vessel
159
+ 3(d) apparatus, engaged-in-fishing, fishing, line, maneuver, net, restrict, trawl, trolling
160
+ 3(e) aircraft, design, maneuver, seaplane, water
161
+ 3(f) exceptional, keep-out-of-way, maneuver, not-under-command, unable
162
+ 3(g) ability, aircraft, cable, cargo, clear, course, deviate, dredging, engage, keep-out-of-way, launch, lay, limit, mark, mine, navigational, operation, person, pick-up, pipeline, recover, replenish, restrict, restricted-ability-maneuver, service, submarine, surveying, tow, towing, transfer, unable, underwater, underway, work
163
+ 3(h) available, constrained-by-draft, course, depth, draft, navigable, power-driven, restricted-ability-maneuver, water, width
164
+ 3(i) aground, anchor, fast, shore, underway
165
+ 3(j) breadth, length, overall
166
+ 3(k) in-sight, observe
167
+ 3(l) fall, fog, mist, rainstorm, restrict, restricted-visibility, sandstorm, snow, visibility
168
+ 3(m) action, close, craft, fly, mode, multimodal, operational, proximity, surface, surface-effect, utilize, wig, wing-in-ground
169
+ 6(a)
170
+ 6(a)(i) state, visibility
171
+ 6(a)(ii) concentration, density, fishing, traffic
172
+ 6(a)(iii) ability, distance, maneuver, stop, turn
173
+ 6(a)(iv) back, background, light, night, scatter, shore
174
+ 6(a)(v) current, hazard, navigational, proximity, sea, state, wind
175
+ 6(a)(vi) available, depth, draft, water
176
+ 6(b) operational, radar
177
+ 6(b)(i) characteristic, efficiency, equipment, limitation, radar
178
+ 6(b)(ii) constraint, impose, radar, range, scale
179
+ 6(b)(iii) detect, effect, interference, radar, sea, source, state, weather
180
+ 6(b)(iv) adequate, detect, float, ice, object, radar, range, small
181
+ 6(b)(v) detect, location, movement, number, radar
182
+ 6(b)(vi) assess, determine, object, radar, range, vicinity, visibility
183
+ 7(a) available, determine, doubt, risk, risk-of-collision
184
+ 7(b) detect, early, equipment, equivalent, fit, long-range, object, observe, operational, plot, radar, risk-of-collision, scan, systematic, warning
185
+ 7(c) assume, information, radar, scanty
186
+ 7(d) consideration, determine, risk-of-collision
187
+ 7(d)(i) approach, change, compass-bearing, risk
188
+ 7(d)(ii) appreciable, approach, bearing, change, close, large, range, risk, tow
189
+ 8(a) action, avoid, collision, observe, positive, rules-4-19, seamanship
190
+ 8(b) alter, avoid, collision, course, large, observe, radar, small, speed, succession
191
+ 8(c) action, alone, alter, avoid, close-quarters, course, effective, room, sea, substantial
192
+ 8(d) action, avoid, check, clear, collision, distance, effective, pass, past, safe
193
+ 8(e) assess, avoid, collision, propulsion, reverse, situation, slacken, speed, stop, way
194
+ 8(f)(i) action, early, impede, passage, room, safe, sea
195
+ 8(f)(ii) action, approach, impede, obligation, passage, relieve, risk-of-collision, rules-4-19, safe
196
+ 8(f)(iii) approach, comply, impede, oblige, passage, risk-of-collision, rules-4-19, two
197
+ 9(a) channel, course, fairway, keep, lie, limit, narrow-channel, near, outer, proceed, safe, side, starboard
198
+ 9(b) 20-meter, fairway, impede, length, narrow-channel, navigate, passage, sailing-vessel
199
+ 9(c) engaged-in-fishing, fairway, impede, narrow-channel, navigate, passage
200
+ 9(d) channel, cross, doubt, fairway, impede, intention, narrow-channel, navigate, passage, prescribe, rule-34d, signal
201
+ 9(e)(i) action, agreement, doubt, fairway, indicate, intend, intention, narrow-channel, overtake, pass, prescribe, rule-34ci, rule-34cii, rule-34d, safe, signal, sound, step
202
+ 9(e)(ii) obligation, overtake, relieve, rule-13
203
+ 9(f) alertness, area, bend, caution, fairway, intervene, narrow-channel, navigate, near, obscure, obstruction, prescribe, rule-34e, signal, sound
204
+ 9(g) anchor, avoid, narrow-channel
205
+ 10(a) adopt, apply, obligation, organization, relieve, traffic-separation-scheme
206
+ 10(b) traffic-separation-scheme
207
+ 10(b)(i) direction, flow, lane, proceed, traffic, traffic-lane
208
+ 10(b)(ii) keep-clear, separation-line, separation-zone, traffic
209
+ 10(b)(iii) angle, direction, flow, join, lane, leave, side, small, termination, traffic, traffic-lane
210
+ 10(c) angle, avoid, cross, direction, flow, heading, oblige, right, traffic, traffic-lane
211
+ 10(d)(i) 20-meter, adjacent, engaged-in-fishing, inshore-traffic-zone, length, sailing-vessel, traffic-lane, traffic-separation-scheme
212
+ 10(d)(ii) avoid, danger, immediate, inshore-traffic-zone, installation, offshore, pilot, port, route, rule-10di, situate, station, structure
213
+ 10(e) cross, enter, except, join, lane, leave, separation-line, separation-zone
214
+ 10(e)(i) avoid, danger, emergency, immediate
215
+ 10(e)(ii) engage, fishing, separation-zone
216
+ 10(f) area, caution, navigate, near, termination, traffic-separation-scheme
217
+ 10(g) anchor, area, avoid, near, termination, traffic-separation-scheme
218
+ 10(h) avoid, margin, traffic-separation-scheme, wide
219
+ 10(i) engaged-in-fishing, impede, passage, traffic-lane
220
+ 10(j) 20-meter, impede, length, passage, power-driven, safe, sailing-vessel, traffic-lane
221
+ 10(k) carry, comply, engage, exempt, maintenance, navigation, operation, restricted-ability-maneuver, safety, traffic-separation-scheme
222
+ 10(l) cable, carry, comply, engage, exempt, lay, operation, pick-up, restricted-ability-maneuver, service, submarine, traffic-separation-scheme
223
+ 12(a) approach, keep-out-of-way, risk-of-collision, sailing-vessel, two
224
+ 12(a)(i) keep-out-of-way, port, side, wind
225
+ 12(a)(ii) keep-out-of-way, leeward, side, wind, windward
226
+ 12(a)(iii) certainty, determine, keep-out-of-way, port, see, side, starboard, wind, windward
227
+ 12(b) carry, fore-and-aft, mainsail, opposite, sail, side, square-rigged, windward
228
+ 13(a) contain, keep-out-of-way, overtake, rules-4-18
229
+ 13(b) 22-5-degree, abaft, beam, come, direction, night, overtake, position, see, sidelight, sternlight
230
+ 13(c) act, assume, doubt, overtake
231
+ 13(d) alter, bearing, clear, cross, duty, keep, overtake, past, relieve, subsequent, two
232
+ 14(a) alter, course, meet, pass, port, power-driven, reciprocal, risk-of-collision, side, starboard, two
233
+ 14(b) ahead, aspect, correspond, day, line, masthead-light, night, observe, see, sidelight, situation
234
+ 14(c) act, assume, doubt, situation
235
+ 15(a) ahead, avoid, cross, keep-out-of-way, power-driven, risk-of-collision, side, starboard, two
236
+ 17(a)(i) course, keep, keep-out-of-way, speed, two
237
+ 17(a)(ii) action, alone, avoid, collision, comply, keep-out-of-way, maneuver
238
+ 17(b) action, aid, alone, avoid, close, collision, course, give-way, keep, speed
239
+ 17(c) action, alter, avoid, collision, course, cross, port, power-driven, rule-17aii, side, situation
240
+ 17(d) give-way, keep-out-of-way, obligation, relieve
241
+ 18(a) keep-out-of-way, power-driven, underway
242
+ 18(a)(i) not-under-command
243
+ 18(a)(ii) restricted-ability-maneuver
244
+ 18(a)(iii) engaged-in-fishing
245
+ 18(a)(iv) sailing-vessel
246
+ 18(b) keep-out-of-way, sailing-vessel, underway
247
+ 18(b)(i) not-under-command
248
+ 18(b)(ii) restricted-ability-maneuver
249
+ 18(b)(iii) engaged-in-fishing
250
+ 18(c) engaged-in-fishing, keep-out-of-way, underway
251
+ 18(c)(i) not-under-command
252
+ 18(c)(ii) restricted-ability-maneuver
253
+ 18(d)(i) avoid, constrained-by-draft, exhibit, impede, not-under-command, passage, restricted-ability-maneuver, rule-28, safe, signal
254
+ 18(d)(ii) caution, constrained-by-draft, navigate
255
+ 18(e) avoid, comply, impede, keep-clear, navigation, risk-of-collision, rules-4-19, seaplane, water
256
+ 18(f)(i) avoid, flight, impede, keep-clear, land, navigation, near, surface, wig-craft
257
+ 18(f)(ii) comply, operate, power-driven, rules-4-19, surface, water, wig-craft
258
+ 19(a) apply, area, in-sight, navigate, near, restricted-visibility
259
+ 19(b) adapt, engine, immediate, maneuver, power-driven, proceed, ready, restricted-visibility, safe-speed
260
+ 19(c) comply, restricted-visibility, rules-4-10
261
+ 19(d) action, alone, alter, avoid, close-quarters, course, detect, determine, develop, radar, risk-of-collision
262
+ 19(d)(i) alter, beam, course, forward, overtake, port
263
+ 19(d)(ii) abaft, abeam, alter, beam, course
264
+ 19(e) avoid, beam, caution, close-quarters, collision, course, danger, determine, except, extreme, fog-signal, forward, hear, keep, minimum, navigate, reduce, risk-of-collision, speed, way
265
+ ```
@@ -3664,6 +3664,84 @@
3664
3664
  }
3665
3665
  }
3666
3666
  }
3667
+ },
3668
+ {
3669
+ "name": "13(d) latch: 13(a)'s sector test suppressed on the newly-gaining vessel",
3670
+ "status": "binding",
3671
+ "narrative": "Own already holds 13(d)'s latch from an earlier overtaking. Since then the pair has closed again from the other direction: the other now sits dead astern of own, gaining at three knots -- 13(a)'s sector test, read on her geometry alone, would newly name her give-way too. The latch forbids it: only own, the latch-holder, gives way (Q-47).",
3672
+ "expect": [
3673
+ "4",
3674
+ "11",
3675
+ "7d1",
3676
+ "8f3",
3677
+ "13a",
3678
+ "13b-overtaken",
3679
+ "13d"
3680
+ ],
3681
+ "situation": {
3682
+ "own": {
3683
+ "fact": {
3684
+ "fact:propulsion": "propulsion:power",
3685
+ "fact:activity": "activity:none",
3686
+ "fact:position": "position:underway",
3687
+ "fact:making_way": true,
3688
+ "fact:length_m": 28
3689
+ },
3690
+ "kin": {
3691
+ "kin:position": {
3692
+ "latitude": 50.0,
3693
+ "longitude": -1.4
3694
+ },
3695
+ "kin:heading_deg": 0,
3696
+ "kin:sog_kn": 10,
3697
+ "kin:rot_deg_min": 0,
3698
+ "kin:dynamics": "dynamics:cargo"
3699
+ },
3700
+ "geo": {
3701
+ "geo:rel_bearing_deg": 180
3702
+ },
3703
+ "hist": {
3704
+ "hist:was_overtaking": true,
3705
+ "hist:latched_at_s": 900
3706
+ }
3707
+ },
3708
+ "other": {
3709
+ "fact": {
3710
+ "fact:propulsion": "propulsion:power",
3711
+ "fact:activity": "activity:none",
3712
+ "fact:position": "position:underway",
3713
+ "fact:making_way": true,
3714
+ "fact:length_m": 16
3715
+ },
3716
+ "kin": {
3717
+ "kin:position": {
3718
+ "latitude": 49.995503,
3719
+ "longitude": -1.4
3720
+ },
3721
+ "kin:heading_deg": 0,
3722
+ "kin:sog_kn": 13,
3723
+ "kin:rot_deg_min": 0,
3724
+ "kin:dynamics": "dynamics:ferry"
3725
+ },
3726
+ "geo": {
3727
+ "geo:rel_bearing_deg": 0
3728
+ },
3729
+ "hist": {
3730
+ "hist:was_overtaking": false,
3731
+ "hist:latched_at_s": null
3732
+ }
3733
+ },
3734
+ "pair": {
3735
+ "geo": {
3736
+ "geo:range_m": 500,
3737
+ "geo:bearing_change_deg_min": 0.0,
3738
+ "geo:cpa_m": 0,
3739
+ "geo:tcpa_s": 324.0,
3740
+ "geo:in_sight": true,
3741
+ "geo:risk_of_collision": true
3742
+ }
3743
+ }
3744
+ }
3667
3745
  }
3668
3746
  ],
3669
3747
  "override_note": "`expect` names every entry whose predicate the situation satisfies, including entries that a rel:overrides then displaces. Applicability and resolution are two steps: 18(a)(iv) really does apply to a WIG craft near the surface -- she is a power-driven vessel underway -- and 18(f)(i) overriding it is what the engine does next. A fixture that hid the overridden entry would make the override unobservable and the relation untestable.",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "colregs",
3
- "version": "0.2.3",
3
+ "version": "0.3.0",
4
4
  "description": "COLREGS 72 and its national amalgamations as language-neutral JSON — rule text, light definitions, and applicability predicates — with cross-implementation fixtures",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -0,0 +1,68 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://github.com/mark-brannan/colregs/schema/corpora.schema.json",
4
+ "title": "data/corpora.json",
5
+ "description": "Index of the text corpora under data/text/: which exist, where each lives, and how many paragraphs it covers. Derived from the corpus files and checked against them by test/data.test.mjs; a consumer that cannot list a directory reads this instead. See docs/adr/0013-corpus-files-with-editions.md.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "corpora"
10
+ ],
11
+ "properties": {
12
+ "note": {
13
+ "type": "string"
14
+ },
15
+ "corpora": {
16
+ "type": "object",
17
+ "additionalProperties": false,
18
+ "patternProperties": {
19
+ "^[a-z]+(/[a-z]+)*@[a-z0-9-]+\\.[A-Za-z0-9-]+\\.[a-z0-9]+$": {
20
+ "type": "object",
21
+ "additionalProperties": false,
22
+ "required": [
23
+ "file",
24
+ "edition",
25
+ "edition_status",
26
+ "language",
27
+ "source_id",
28
+ "tier",
29
+ "paragraphs"
30
+ ],
31
+ "properties": {
32
+ "file": {
33
+ "type": "string",
34
+ "pattern": "^text/.+\\.json$"
35
+ },
36
+ "edition": {
37
+ "type": "string",
38
+ "pattern": "^[a-z]+(/[a-z]+)*@[a-z0-9-]+$"
39
+ },
40
+ "edition_status": {
41
+ "enum": ["verified", "claimed", "unknown"]
42
+ },
43
+ "language": {
44
+ "type": "string",
45
+ "minLength": 2
46
+ },
47
+ "source_id": {
48
+ "type": "string",
49
+ "pattern": "^[a-z0-9]+$"
50
+ },
51
+ "tier": {
52
+ "enum": [
53
+ "authentic",
54
+ "official",
55
+ "national",
56
+ "community"
57
+ ]
58
+ },
59
+ "paragraphs": {
60
+ "type": "integer",
61
+ "minimum": 0
62
+ }
63
+ }
64
+ }
65
+ }
66
+ }
67
+ }
68
+ }