Second pass with the avoid-ai-writing detector

The skill's detector scored the README, PARITY.md and the extracted
comment prose. Fixed what it flagged: hollow intensifiers, "in order
to", "additionally", "the whole point", bold sentences in docs, and
bold that had wrapped across comment lines. Comment prose scores a
maximum of 4 out of 100 across the repo.

One sweep rule mangled four comments ("which is the entire point of X"
lost its clause); repaired, and the rule now keeps the clause.

Comments and strings only. 1208 tests pass, counted from the XML.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
Paul Hitt
2026-09-08 19:20:07 -04:00
co-authored by Claude Fable 5.1
parent 4dd544083c
commit 8a7f40fb13
131 changed files with 521 additions and 525 deletions
@@ -12,8 +12,8 @@ import kotlin.test.assertTrue
/**
* Which attachment ids the device still has a reason to hold bytes for.
*
* **This set is the input to a DELETE, so the dangerous error is the one
* that omits something.** A missing id means a cleanup removes a file that is
* This set is the input to a DELETE, so the dangerous error is the one
* that omits something. A missing id means a cleanup removes a file that is
* still in use, a worse failure than the leak it was written to fix, because
* the leak only wastes space and this loses somebody's photo.
*
@@ -9,7 +9,7 @@ import kotlin.test.assertTrue
/**
* Disappearing messages (§6.11), at the vault.
*
* Expiry runs on read, and that is the point. A sweep on a timer leaves
* Expiry runs on read. A sweep on a timer leaves
* expired messages on disk between runs, and a "disappearing" message still
* sitting in the vault is a claim rather than a feature. Reading is the one
* path every caller shares.
@@ -10,8 +10,8 @@ import org.json.JSONObject
/**
* Interop for the Files vault, against the published reference vectors.
*
* **These vectors were produced by the JavaScript engine that runs in the
* browser, a third implementation, not the Swift one.** Nothing here checks
* These vectors were produced by the JavaScript engine that runs in the
* browser, a third implementation, not the Swift one. Nothing here checks
* that this code is self-consistent. It checks that a vault written by the
* software people already use opens on an Android phone, which is the only
* question that matters: a framing, authenticated-data or key-hierarchy mistake
@@ -30,7 +30,7 @@ class ForwardWithoutProvenanceTest {
}
/**
* The whole point: the envelope says THAT it was forwarded and nothing
*the envelope says THAT it was forwarded and nothing
* about who wrote it or what it answered.
*/
@Test
@@ -7,8 +7,8 @@ import kotlin.test.assertTrue
/**
* Stories posted to a group (spec §6.24, ios#55).
*
* **The group's roster is the audience, and the sender's story audience does
* not apply.** Two different lists making two different statements, who may
* The group's roster is the audience, and the sender's story audience does
* not apply. Two different lists making two different statements, who may
* see this account's stories, and who is in a conversation. They will disagree,
* and the roster wins.
*/
@@ -10,8 +10,8 @@ import kotlin.test.assertTrue
/**
* From a recovery phrase to an address somebody can be paid at.
*
* **The property that matters most here is that the signing key and the
* displayed address come from the same derivation.** If they ever disagreed,
* The property that matters most here is that the signing key and the
* displayed address come from the same derivation. If they ever disagreed,
* the wallet would sign with a key that does not own the address it showed. The
* transaction being rejected is the GOOD outcome; the bad one is signing for an
* address somebody else controls.
@@ -160,8 +160,8 @@ class HdAccountTest {
}
/**
* **The limit, asserted as a passing test so nobody reads
* `looksLikeAddress` as stronger than it is.**
* The limit, asserted as a passing test so nobody reads
* `looksLikeAddress` as stronger than it is.
*
* A Solana address carries NO checksum. A mistyped character that still
* decodes to 32 bytes is a perfectly valid address that nobody holds the
@@ -57,7 +57,7 @@ class HybridSessionTest {
*
* `copy(proto = 2)` alone would NOT do: the capability signature commits
* to the version, so a bundle whose proto was edited reads as v1 to every
* peer. It has to be re-signed for 2 to be a genuine v2 device.
* peer. It has to be re-signed for 2 to be a v2 device.
*/
private fun publishedV2(device: DeviceIdentity, withOneTime: Boolean = true): PeerBundle =
published(device, withOneTime).copy(
@@ -9,8 +9,8 @@ import kotlin.test.assertTrue
/**
* The security lattice, and the two Bell–LaPadula rules it exists to enforce.
*
* **The encoding vectors were computed independently, not read off this
* implementation.** The ten bytes are authenticated data for every construction
* The encoding vectors were computed independently, not read off this
* implementation. The ten bytes are authenticated data for every construction
* that uses a label, so an encoding that differs between platforms does not warn
* it produces a decryption failure, or plaintext that quietly belongs to the
* wrong sensitivity. A vector taken from the code under test would pin whatever
@@ -148,8 +148,8 @@ class LabelTest {
// ---- Writing ---------------------------------------------------------
/**
* **Writing is gated by the same range check as reading, and the
* -property is NOT enforced, on either platform.**
* Writing is gated by the same range check as reading, and the
* -property is NOT enforced, on either platform.
*
* Bell–LaPadula says somebody cleared to read sensitive material must not
* write *below* their clearance, because they would carry what they read
@@ -12,8 +12,8 @@ import org.json.JSONObject
/**
* A timer on one message rather than the whole conversation (§6.17).
*
* **The rule that keeps this from making the product worse is that the
* shorter timer always wins.** A per-message timer may only take life away,
* The rule that keeps this from making the product worse is that the
* shorter timer always wins. A per-message timer may only take life away,
* never add it. Without that, a sender could defeat the recipient's
* conversation timer by putting a long one on every message, turning a setting
* the recipient chose, on their own device, into something the other party gets
@@ -17,7 +17,7 @@ import kotlin.test.assertTrue
* from the one file rather than copied here, a vector transcribed into the
* test that checks it is a vector that agrees with itself.
*
* This is the whole point of starting Android with the engine. A third
* This is the point of starting Android with the engine. A third
* implementation is only worth anything if it can be checked against something
* other than a reading of our own code.
*/
@@ -51,11 +51,11 @@ class SealedRosterTest {
* The property the whole change rests on: the stored bytes say nothing.
* A dump that yields the member ids has bought nobody anything.
*
* **The values are long on purpose, and the search covers the decoded
* bytes.** This sealed ids `41`/`42` and looked for `"41"`/`"42"` in the
* The values are long on purpose, and the search covers the decoded
* bytes. This sealed ids `41`/`42` and looked for `"41"`/`"42"` in the
* BASE64, two characters out of a 64-symbol alphabet, so each had about a
* 1-in-4096 chance at any position and roughly a **14% chance across a blob
* this size**. It failed on exactly that, having passed for days: a coin
* 1-in-4096 chance at any position and roughly a 14% chance across a blob
* this size. It failed on exactly that, having passed for days: a coin
* flip wearing the clothes of an assertion. The iOS twin had the same bug
* and was fixed the same way; this one was missed because only one engine
* was looked at.
@@ -10,8 +10,8 @@ import kotlin.test.assertTrue
/**
* Zeroing key material once it has been used (ios#39, Android half).
*
* **The claim being tested is narrow, and the tests are shaped to keep it
* narrow.** What this buys is that a derived key is not left sitting in the
* The claim being tested is narrow, and the tests are shaped to keep it
* narrow. What this buys is that a derived key is not left sitting in the
* heap after the one moment it was needed. It is not "the key is gone", a
* compacting collector can have moved the array, Android has compressed swap,
* and there is no `memset_s` on the JVM. `SecureBytes` says all of that in
@@ -19,7 +19,7 @@ class StorySaveTest {
assertTrue(Vault.isSaveable(mine = true, hasBlob = true))
}
/** The whole point: never somebody else's, whatever the UI offers. */
/**never somebody else's, whatever the UI offers. */
@Test
fun `somebody elses story can never be saved`() {
assertFalse(Vault.isSaveable(mine = false, hasBlob = true))
@@ -119,8 +119,8 @@ class VaultTest {
}
/**
* **A failed decrypt damages the session object it was handed, so the
* thing that gets retired must be re-read from the vault.**
* A failed decrypt damages the session object it was handed, so the
* thing that gets retired must be re-read from the vault.
*
* This is the bug the first version of the retirement fix shipped with, and
* the reason `a retired session is kept and still opens its chain` did not
@@ -11,8 +11,8 @@ import kotlin.test.assertTrue
/**
* Creating, importing and reading back a wallet.
*
* **The property worth guarding hardest is a negative one: the wallet must
* NOT be derivable from the account.** Deriving it from the passphrase would be
* The property worth guarding hardest is a negative one: the wallet must
* NOT be derivable from the account. Deriving it from the passphrase would be
* convenient, would need no backup at all, and would tie every payment somebody
* ever received to their handle on a public ledger for ever. There is no way to
* undo that later, the chain does not forget, so it is asserted rather than