浏览代码

docs: an unmeasured claim inherits the credibility of its neighbours

I answered a consumer's four filter questions citing src/filters.cpp:33-38
for each, and in the same breath recommended field:exists:true as a guard
against nulls in a range filter without checking it. It is wrong - a field
holding an explicit null exists - and they put it in a spec, calling it
strictly better than the pair-of-bounds form they had actually tested.

The shape is worth recording because it is not ordinary carelessness. In a
message where most assertions carry a file and line, the one that does not
reads just as authoritative. I was pleased with having a clean one-operator
answer and did not notice I had stopped citing.

Their half is the mirror and they named it better than I would: they measured
four behaviours precisely so as not to record a guarantee nobody had made,
then took the fifth on trust because it was the answer they wanted. Thanks
are a signal to re-read, not to proceed.

The rule: if a claim has no file, line or measurement behind it, say so in
the same sentence. An unqualified sentence sitting between two cited ones is
the most dangerous shape a wrong claim can take.
fszontagh 1 月之前
父节点
当前提交
de44aadc29
共有 1 个文件被更改,包括 2 次插入 和 0 次删除
  1. 2 0
      CLAUDE.md

+ 2 - 0
CLAUDE.md

@@ -54,6 +54,8 @@ docker run -d --name svapi-dev -p 8080:8080 -e SMARTBOTIC_VECTORAPI_KEY=dev svap
 - **Embedding config precedence:** collection `embedding_model` pin → project override → global default; endpoint + API key are the project override when set, else global. Resolved by the pure `resolveEmbedding()` (`project_settings.hpp`) - unit-test precedence there, not through the handlers.
 - **Every outbound request to an external provider goes through `applyOutboundDefaults()`** (`outbound_http.hpp`): `User-Agent: smartbotic-vectorapi/<version>` and nothing else, TLS verification on, redirects off. Never let cpp-httplib's default UA reach a provider.
 - **A PERMISSIVE TEST ASSERTION'S STRENGTH DEPENDS ON THE SERVER'S STRICTNESS, so tightening a contract can silently promote a sloppy test elsewhere into a blind spot.** A consumer found this while checking whether the `unknown_option` refusal would break them: a test asserting their outgoing body with `expect.objectContaining({...})` tolerated extra keys by construction, so it could only ever fail in the direction that was already safe - add a stray key and the test stays green while production starts refusing every search with 422. They tightened it to an exact match. The lesson for asking consumers about a breaking change: the question is not only "do you send an extra key" but **"would your tests notice if you started"**.
+- **AN UNMEASURED CLAIM INHERITS THE CREDIBILITY OF ITS NEIGHBOURS. In a message where most assertions carry a file and line, the one that does not reads just as authoritative - and is believed just as hard.** 2026-10-13: I answered a consumer's four measured filter questions by citing `src/filters.cpp:33-38` for each, and in the same breath recommended `field:exists:true` as a guard against nulls in a range filter. I had not checked it. It is wrong - a field holding an explicit `null` EXISTS, so `exists` excludes only the absent case, which was never the problem. They put it in a spec and called it "strictly better" than the pair-of-bounds form they had actually tested.
+  **Both halves of that are the same mechanism and worth naming separately.** Mine: I was pleased with a clean one-operator answer and did not notice I had stopped citing. Theirs, in their words: they had measured four behaviours precisely so as not to record a guarantee nobody had made, then took a fifth on trust because it was the answer they wanted - so **"thanks are a signal to re-read, not to proceed."** The practical rule for this file and for any reply to a consumer: **if a claim has no file, line or measurement behind it, say so in the same sentence.** An unqualified sentence sitting between two cited ones is the most dangerous shape a wrong claim can take.
 - **THE ONE QUESTION THAT CATCHES THIS WHOLE FAMILY: "WHAT ELSE WOULD PRODUCE THIS EXACT RESULT?"** It is one line, it costs nothing, and on 2026-10-12 three separate instances of the same defect appeared in a single afternoon - two of them mine - every one of which it would have stopped:
   - **A vector-encryption test** read rows written BEFORE the flag was flipped and concluded about writes after it. What else would produce three rows still searching at 1.0? Pre-flip vectors living in the vector sub-db rather than the body. Which is exactly what was happening, and the new-insert path was broken.
   - **A consumer's page probe** returned 200 at 5.4 MiB and they concluded the size limit was per DOCUMENT. What else would produce that? A per-RESPONSE limit anywhere above 5.4 MiB - which is what it is, 100 MB. A test that passes under both hypotheses cannot choose between them.