Skip to content

Commit fe188a7

Browse files
authored
docs(stack-encrypt): the query, not the needle, in target_limit's prose
Claude-Session: https://claude.ai/code/session_01VYKAWbd361xDLmqBdLoUcB
1 parent 0a36339 commit fe188a7

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

‎packages/stack-encrypt/CHANGELOG.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
5454
neither, the limit is `Limit::Unbounded`, and the caller pages with a
5555
cursor. A limit never exceeds `op::MAX_ROWS` (`i64::MAX`), the largest
5656
SQL `LIMIT`. The bound assumes a non-matching row shares no token with
57-
the needle, so on natural text its confidence is nominal; `verify` still
57+
the query, so on natural text its confidence is nominal; `verify` still
5858
decides every row.
5959

6060
- **Errors now expose stable codes, help text, and structured details.**

‎packages/stack-encrypt/docs/adr/0009-operators-select-the-index-and-a-query-term-is-not-the-stored-term.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,9 +325,9 @@ positives); the mean fill, 0.25, raised to 6 predicts 245. The number the
325325
bound needs is therefore `p = mean(f_i^b)`, and the statistics the client
326326
holds must let it compute that for the `b` of each query.
327327

328-
The model assumes a non-matching row shares no token with the needle. The
328+
The model assumes a non-matching row shares no token with the query. The
329329
same token sets the same bits in every filter, so a row holding part of the
330-
needle has fewer bits left to chance: "police" already holds two of
330+
query has fewer bits left to chance: "police" already holds two of
331331
"alice"'s three 3-grams, and passes at `f^6` rather than `f^18`. On natural
332332
text the stated confidence is therefore nominal, and a measured histogram
333333
cannot correct it, because it measures fill, not overlap. Correctness does

‎packages/stack-encrypt/src/op/mod.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ pub trait Probabilistic: QueryTerm {
233233
///
234234
/// A probabilistic bound, not a guarantee: at 99% confidence one query
235235
/// in a hundred draws more false positives than it allows for, and the
236-
/// model assumes a non-matching row shares no token with the needle,
236+
/// model assumes a non-matching row shares no token with the query,
237237
/// which natural text does not honour, so the confidence is nominal.
238238
/// The candidate count says which case a fetch is in. If the server
239239
/// returned fewer rows than the limit, the predicate is exhausted, and

0 commit comments

Comments
 (0)