sloplint 0.8.1 → 0.10.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7b924df142be1939d6da4e27d2e925b2de378cbe835e5c9ea41e3c3b0b046633
4
- data.tar.gz: 128a3a13dd8d4dc81610266ede34b52e73293b61af560ff7fa26d9dbd9708dd5
3
+ metadata.gz: 104eaad3b0c8de01284f36733d607140b606feb03b9f216225e62f2a25ade435
4
+ data.tar.gz: b6d8cf5cf2eb4bcaa01b99e2889f4aaa5f0fbbbce6c5663cdaf79bff45dcbc76
5
5
  SHA512:
6
- metadata.gz: ffc7954ff2c5ccab7e431e007be51bddbb0a42cf27fe54a1c8629ec90c9c0c47c9a7ceba91bc03116f38303241efcf7b4263a84376aedae67a95dae2877d3db8
7
- data.tar.gz: f0c893e80441a5e738a5a037897a064b9cf201fb1bca6f5ca5e1b160eabbf2d5c7d870800a0d8ac36263b00a8dbc0ca331673da4f302a3e2e4a3f41346248e3e
6
+ metadata.gz: 590f441d103f51d263e8eb073c48f363ffceae3619b52b68360c7bf973daf38cbf3e31c18a0816d61d2f1bddc03207bafa19b4f709535ce1dc67eb7a0694aaa1
7
+ data.tar.gz: 247c89c135fa14d90b2e37f67753451cc0c9d945f149bee17186ee8ebdd5faacc87db25e72d682a9a4500659e75c9b79810bec44478816776cefaf0f7a22e17a
data/CHANGELOG.md CHANGED
@@ -3,7 +3,236 @@
3
3
  All notable changes to this project are documented here. Format loosely
4
4
  follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
5
5
 
6
- ## [Unreleased]
6
+ ## sloplint-judge
7
+
8
+ ### [0.2.0] - 2026-10-13
9
+
10
+ - New sentence rule `positive-form` (`info`, `low`, off by default): a claim
11
+ made by denial instead of a plain positive statement (Strunk and White,
12
+ rule 15) --
13
+ a correction with "not", "nothing" or "nobody" as subject or object, or an
14
+ instruction not to do something. A negative outside the claim passes: a
15
+ condition, a bound, a fixed name, a standard's MUST NOT, quoted speech, or
16
+ a denied option a decision names on its way to a different one. A verb
17
+ that performs an absence ("publishes no salary band") still flags; an
18
+ absence stated as a property of the thing ("has no salary band", "without
19
+ a salary band") passes, and so does an expected behavior denied on its own
20
+ ("does not retry") with nothing set against it. A routing instruction
21
+ (which tool to use for which job) and a design choice given with its
22
+ reason also pass. Off by default because reference documentation states
23
+ limits as negatives on purpose.
24
+ - New sentence rule `name-the-thing` (`info`, `low`, off by default): referring to a
25
+ thing by anything other than its name when a name is available --
26
+ a position (the latter, the second one), a stand-in noun or figure (the
27
+ engine for a named service), an allusion to a divide it never names, or
28
+ the document pointing at itself ("this entire writeup"). A position that
29
+ is the thing's own name (step 4, the second retry, Q3), a which-clause
30
+ about named things, and a pronoun pointing at something just named pass.
31
+ - New sentence rule `device-before-claim` (`info`, `medium`): a sentence
32
+ that makes its claim through a device -- a mirror or matched pair, a
33
+ riddle, a held-back answer, a singled-out position in a list, a coined
34
+ figure, or a maxim -- instead of stating it plainly. Detection only; the
35
+ calling model decides whether the device earns its keep.
36
+ - New sentence rule `maxim` (`info`, `medium`): a sentence that states a
37
+ general saying in place of the fact the case needs, often as a
38
+ paragraph's closing line.
39
+ - New sentence rule `dressed-pair` (`info`, `low`, off by default): one
40
+ fact said as if it were two -- a second clause that echoes the first
41
+ clause's verb, or a "both" / "those two things" summing up an earlier
42
+ pair and handed a verdict. It catches pairs that `matched-shape` and
43
+ `name-the-thing` miss.
44
+ - New sentence rule `mirrored-opposites` (`info`, `low`, off by default):
45
+ opposite words joining two separate claims so they read as a contrast
46
+ ("identical everywhere it runs and documented nowhere"). Opposites that
47
+ compare one thing across two cases ("runs in staging and never in
48
+ production") pass. The narrow case of `matched-shape`.
49
+ - `no-news` also flags a sentence that tells the reader, in the second
50
+ person, about their own past actions or their own past words. A fact is
51
+ not news to the reader who lived it, even when the sentence is specific.
52
+ - `names-nothing` judges each sentence with its paragraph. A sentence
53
+ passes when its paragraph makes the claim checkable, and so does a short
54
+ label or verbless fragment that the next sentence spells out. Pointing
55
+ back at things the paragraph named ("these", "this design") does not by
56
+ itself make a new general claim checkable.
57
+ - `stock-figure` passes names the writer chose: a command or identifier in
58
+ code, one of a set of options, statuses or modes the paragraph lists, and
59
+ a term the paragraph defines, the defining sentence included. Bold counts
60
+ only when the paragraph sets the phrase up as a name. A stock figure
61
+ elsewhere in the same sentence still flags.
62
+ - `unnamed-authority` also flags a claim called known with no source ("a
63
+ known cause", "it is well known that"). A known fact passes when the
64
+ sentence or its paragraph cites a source for it. In an abstract, a result
65
+ the field is said to know is prior work and passes; a person described as
66
+ well known is a reputation, not a claim.
67
+ - Graveyard: `stand-in-verb`, a rule for a verb of holding, carrying or
68
+ keeping standing in for a plain verb ("holds the history of a job"), was
69
+ added and reverted. Its only real specimens were two labelled rows, and
70
+ the maintainer ruled that their verbs are worn figures in their own
71
+ trades, not this tell. A version widened to any figurative main verb
72
+ read as ornate prose (`stock-figure`'s job) rather than a stand-in for
73
+ who knows, wrote or decides.
74
+ - The default `--register` is now "the reader this document is written
75
+ for", in place of "an engineer on the team reading a design document".
76
+ The model infers the reader from the text, so a run without `--register`
77
+ can flag different sentences than before. Name the reader when you know
78
+ it.
79
+ - `script/calibrate run --reader TEXT` asks every register's questions for
80
+ one reader, to measure a candidate default against each register's own
81
+ reader.
82
+ - `script/calibrate` retries API errors with backoff, including the
83
+ compare calls, and gains a `blogs` register (HAP-E) alongside RAID's news
84
+ and abstracts. A failed HAP-E download now stops with an error. `script/score-labels`
85
+ is a new script that scores a rule against a synthetic or real label set
86
+ by name.
87
+
88
+ ### [0.1.0] - 2026-09-21
89
+
90
+ - New sentence rule `unnamed-authority` (`info`, `medium`): a claim handed to
91
+ experts, studies, research, critics or many, an authority the reader could
92
+ not find and that speaks for nobody. Officials, a spokesperson and the
93
+ other sources news quotes by convention pass, and so does an abstract's
94
+ prior work. The reading behind the regex `vague-attribution`.
95
+ - New sentence rule `stated-stakes` (`info`, `low`, off by default): a sentence
96
+ that says something is crucial, vital or key and gives no fact, number or
97
+ consequence, in it or in the sentence after it. Off by default because the
98
+ model rarely answers it above low confidence; `--select stated-stakes` or
99
+ `--strict` runs it.
100
+ - A rule at `low` confidence (`same-weight`, `matched-shape`) now reports its
101
+ notes when `--select` names it; before, they ran and printed nothing
102
+ without `--strict`. The rule's `low` caps the note's confidence; what a
103
+ default run drops is an answer the model itself gave at low confidence.
104
+ - `check --judge` always writes the `{"notes", "judge"}` object, with 0
105
+ requests when no judge rule survived selection. `compare` accepts
106
+ `--drift` after the two files and refuses a third. `status` refuses a key
107
+ with a control character the way `check --judge` does.
108
+ - Graveyard: `owned-claim` was retried as `no-actor` and stays out, and
109
+ `buried-verbs`, the paragraph reading of the nominalization shift, joins
110
+ it; neither crossed the flag on any side. The entries in `docs/JUDGE.md`
111
+ say so.
112
+ - New paragraph rule `promotional` (`warning`, `medium`): a paragraph in
113
+ which every judgment is favorable, none comes with a measure and no
114
+ drawback appears. The paragraph-level reading behind `puffery-words`,
115
+ which catches the register after the watch words have aged out.
116
+ - New paragraph rule `self-narration` (`info`, `medium`): a paragraph whose
117
+ sentences signpost the document, what comes first, what a section covers,
118
+ what the reader should take away, instead of saying something about the
119
+ subject. `throat-clearing` sees the first sentence; this is the paragraph.
120
+ - `script/calibrate run` also prints how many units each side would have
121
+ flagged at the confidence `check` reports. A rare flag barely moves the
122
+ rank statistic, so for such a rule the count is the number to quote.
123
+ - New paragraph rule `same-weight` (`info`, `low`, off by default): a paragraph
124
+ that states its inferences and opinions as flatly as its measurements, with
125
+ no probably, no we think, and no reason given. Separates model from human
126
+ text in news and abstracts; off by default because a design document argues
127
+ in flat sentences on purpose. `--select same-weight` or `--strict` runs it.
128
+ - New sentence rule `trailing-gloss` (`info`, `medium`): a sentence that ends
129
+ on a comma and an -ing clause that interprets the fact before it
130
+ ("highlighting the value of", "underscoring the importance of") rather than
131
+ adding a fact or a consequence. The reading the regex
132
+ `trailing-significance-participle` could not do.
133
+ - Graveyard: `redundancy` was retried as `restatement` with the fairness
134
+ reading it was owed, reversed in news against every model side, and stays
135
+ out. The entry in `docs/JUDGE.md` says why.
136
+ - `wrap-up` also flags a last sentence that admits problems and then
137
+ promises a bright future ("Despite these challenges, the future looks
138
+ promising"). Its flagged level says so, its message now reads "Paragraph
139
+ ends on a summary, a moral or a hope", and fixtures pin both sides: the
140
+ hope that names nothing is flagged, the same frame closing on a dated
141
+ fact is not. Wikipedia's field guide documents the formula across
142
+ unrelated topics, and the GPT family ends documents on it.
143
+
144
+ - First release of the judge gem: the rule catalog in `docs/JUDGE.md`, the
145
+ Jev backend, `check`, `compare`, `rules`, `explain`, and `script/calibrate`.
146
+ Requires sloplint 0.9; see "Phase two" in `docs/JUDGE.md` for what is next.
147
+ - `check` reports what the judge spent: JSON output is `{"notes", "judge"}`
148
+ with the backend, request count, token counts and cost in dollars under
149
+ `judge`, and the same line goes to stderr. Jev returns no price, so the
150
+ cost is computed from TypeSafe's public price: $42 per billion input
151
+ tokens, output tokens free.
152
+ - The key can live in the OS keychain instead of the environment.
153
+ `sloplint-judge key set` stores it once (the keychain tool prompts, so the
154
+ key is never on a command line), the Jev adapter reads it after
155
+ `TYPESAFE_API_KEY`, and `sloplint-judge status` says whether a run could
156
+ happen and where the key is, without reading it. `sloplint-judge key
157
+ unset` removes the item. The check skill probes with `status`.
158
+ - `SYSTEMONE_URL` must point at a `typesafe.ai` host, not only be `https`:
159
+ the key and the document go there, so an injected URL on the sanctioned
160
+ command is refused with exit 2.
161
+
162
+ ## sloplint
163
+
164
+ ## [0.10.0] - 2026-10-13
165
+
166
+ ### Added
167
+
168
+ - New rule `the-x-is-not-the-x` (cadence, `warning`, `medium`): one head noun on both sides of
169
+ a negated copula, split in two by a clause and never told apart ("the
170
+ one you want is not the one that runs the studio"). The negated twin of
171
+ `the-x-is-the-x`.
172
+ - New rule `negative-subject` (cadence, `warning`, `medium`): a negative pronoun (Nothing,
173
+ Nobody, No one, None) standing as the subject of a clause, dressed up
174
+ with a second negative-subject clause joined by "and", or a negated
175
+ relative clause on the object ("nothing gets merged that
176
+ does not get reviewed."). Bare "Nothing happened." and "No one knows."
177
+ are left alone.
178
+
179
+ ### Changed
180
+
181
+ - Full output (`-o full`) shows each note's confidence next to its
182
+ severity. The `--strict` help, in `sloplint check` and `sloplint-judge check`,
183
+ says it also reports low-confidence notes, and that those are places to
184
+ look, not findings.
185
+ - `--register` under `--judge` now defaults to "the reader this document
186
+ is written for" instead of a design-document reader, and its help asks
187
+ you to name the real reader. The check skill passes one.
188
+ - `sloplint explain ID` also explains the judge's rules when sloplint-judge
189
+ is installed, so every rule id in a `check --judge` note explains from
190
+ one command. `--help` and the check skill say so.
191
+ - Under `--strict`, a run that reports low-confidence notes says on stderr
192
+ how many there are and that they are places to look, not findings.
193
+ stdout is unchanged, so JSON output still parses. The check skill no
194
+ longer adds `--strict` unless asked, and puts a low-confidence note to
195
+ the person as a question instead of editing on it.
196
+
197
+ ### Fixed
198
+
199
+ - `rule-of-three` no longer flags the last three words of a longer list,
200
+ including a list hard-wrapped onto an indented line. A real triad after
201
+ an introductory comma ("in a word, fast, cheap, and simple") is now
202
+ missed too: a regex cannot tell a list comma from any other comma.
203
+ - `negative-subject`'s frames now accept a clause break (a comma before a
204
+ coordinating conjunction, or a bare comma, semicolon or colon) as well
205
+ as the end of the sentence, so a real clause followed by more of the
206
+ same sentence still matches; and its relative-clause tail now allows one
207
+ to ten words instead of at most three, so a real "that does not X" tail
208
+ isn't cut short.
209
+
210
+ ## [0.9.0] - 2026-09-21
211
+
212
+ ### Added
213
+
214
+ - `sloplint check --judge` runs the rules of sloplint-judge alongside the
215
+ regex catalog and merges the notes in document order. The judge is a second
216
+ gem built from this repository (`sloplint-judge.gemspec`, `exe/sloplint-judge`)
217
+ whose rules are questions put to a System One model. sloplint loads it by
218
+ name only and exits 2 with an install hint when it is missing. A backend
219
+ failure under `--judge` is exit 3 and writes no notes. See `docs/JUDGE.md`.
220
+ - `Sloplint::Split`, a paragraph and sentence splitter that keeps offsets into
221
+ the source, and `Engine.context_window`, the note's context drawn for any
222
+ span rather than only a regex match. Both are used by the judge.
223
+ - `script/calibrate`, which measures a judge backend against RAID and a
224
+ current-model side generated from RAID's own prompts, and reports the
225
+ pass lines from `docs/JUDGE.md`.
226
+
227
+ ### Fixed
228
+
229
+ - `--markdown` opens and closes a fenced code block only at the start of a
230
+ line, at any indent, so a fence under `10. ` or a nested bullet still
231
+ pairs. A fence quoted inside a sentence (```` ``` ````) used to open a
232
+ block there, and every fence after it paired wrong for the rest of the file.
233
+ - The splitter also drops indented code blocks (four spaces or a tab), lines
234
+ that are one HTML tag, and YAML front matter under `--markdown`, so none of
235
+ them reach the judge as prose.
7
236
 
8
237
  ## [0.8.1] - 2026-09-20
9
238