让内部资料能被问,撑不住的那句会被标出来
Ask your internal documents, and unsupported sentences get flagged
答案里每一句都拿去和检索到的段落比对,撑不住的那句当场标出来。这一步是自动的,也是看得见的,不靠人事后抽查。
Every sentence is scored against the retrieved passages, and the ones the sources do not support are flagged in the answer itself. Automatic, and visible.
为什么这件事值得单独做
Why this needs building rather than buying a chat box
资料不是没有,是散着。合同在一个网盘,工艺参数在某个人的电脑上,去年那次返工的结论只留在一封邮件里。新人问一句,老人要翻二十分钟。
The knowledge exists, it is just scattered. Contracts on one drive, process parameters on somebody's laptop, the conclusion from last year's rework sitting in a single email. A new hire asks one question and a senior person spends twenty minutes digging.
直接丢给大模型答,它会编。更麻烦的是挂上引用之后编得更像:引用就摆在旁边,读的人默认那句有据,于是反而不去查了。
Hand the question straight to a language model and it will invent things. Citations make that worse, not better. A citation sitting next to an invented sentence reads as evidence, so the reader stops checking.
所以真正值钱的不是「会答」,是没把握的那句会被指出来。这套东西的工程量基本都花在这一件事上。
So the part worth paying for is not that it answers. It is that the shaky sentence gets pointed at. Almost all the engineering goes there.
现在能跑出来的数
Numbers you can reproduce today
| 指标Metric | k=3 | k=5 | k=10 |
|---|---|---|---|
| 命中率 recall@krecall@k | 0.867 | 0.867 | 1.000 |
| 平均倒数排名 MRRMRR | 0.789 | 0.789 | 0.810 |
15 道金标问题跑在 254 个分块上,语料是三篇公共版权文献。命令 npm run eval,2026-08-31 现跑。k=3 和 k=5 命中的是同一批,所以那两列一样。另一条:npm test 出 223 项通过,另有 9 项要装 Postgres 才跑,没装就自动跳过。
15 golden questions over 254 chunks of public-domain text. Command npm run eval, run on 2026-08-31. k=3 and k=5 hit the same set, which is why those two columns match. Separately, npm test reports 223 passing and 9 skipped, the ones that need Postgres.
建索引和检索这两步跑在你自己的机器上,用的是本地嵌入模型,不需要任何 API key,资料不出门。只有最后生成答案那一步才走模型。
Indexing and retrieval run on your own machine with a local embedding model. No API key, and the documents do not leave. Only the final answer generation calls a model.
它什么时候会错
Where it gets things wrong
验证器是个启发式判断,不是逻辑证明。下面三条是已知的失效方式。
The verifier is a heuristic, not a proof of entailment. These three failure modes are known.
- 看不出否定。「X 会导致 Y」和「X 不会导致 Y」在向量空间里挨得很近,所以被反过来说的一句,仍然可能算成有据。 Negation blindness. "X causes Y" and "X does not cause Y" embed close together, so a contradicted claim can still score as supported.
- 会误伤。改写得厉害、或者要跨好几段综合才成立的句子,本来是有据的,也可能掉到阈值下面被标红。 False flags. Heavy paraphrase or a claim that combines several passages can fall under the threshold even when it is genuinely grounded.
- 它量的是对不对得上原文,不是对不对。原文自己写错了,照抄过来一样算有据。 It measures traceability, not truth. A sentence that faithfully echoes a wrong source passage scores as supported.
交付边界
What each side brings
你给
You bring
- 一批文档,md 和 txt 起步
- A set of documents, md and txt to start
- 一个具体的问法场景,比如客服要查工艺参数
- One concrete situation, such as support staff looking up process parameters
- 一个人负责判断答得对不对
- One person who can judge whether an answer is right
我们给
We bring
- 索引和检索,跑在你自己机器上,不用 key
- Indexing and retrieval on your own machine, no key needed
- 带引用的问答端点,出处可点回去,撑不住的句子带标记
- A cited answer endpoint: citations you can click back to, and unsupported sentences carry a flag
- 一行 script 标签挂进你现有页面
- One script tag that drops into your existing page template
不接
Not this
- 要它替你拍板的场景。它是查资料的,不是签字的
- Anything where it makes the decision. It looks things up, it does not sign off
- 把出处链接拆掉只留结论。那一拆,上面写的保证全部作废
- Stripping the citations and keeping only the conclusion. That voids everything above