test: first-round knowledge quality metrics (#14 P3) #17

Merged
cflmy merged 1 commits from codex/issue-14-quality-metrics into master 2026-11-30 17:46:14 +08:00
Owner

概述

实现 marqdo-knowledge#14 P3 的首轮可执行检索质量口径:固定 fixture 上的 hit@1/hit@3/MRR、navigation role、stale 拒绝/标记,数字来自真实运行;不宣称生产召回/延迟/RSS 门槛。

交付

  • tests/quality.rs:5 文档 fixture + 5 个唯一标题查询;输出一行 QUALITY_METRICS {json} 供 CI 日志归档;断言固定 fixture 的确定性结果。
  • docs/QUALITY.md:指标定义、首轮取值、fixture 范围与明确非承诺。
  • docs/STATUS.md 记录;证据 docs/evidence/2026-11-30-quality-first-round.md。

验证(真实,Linux x86_64 / glibc 2.43)

QUALITY_METRICS {"fixture_documents":5,"hit_at_1":5,"hit_at_3":5,"mrr":1.0,
 "navigation_role":"index","queries":5,"stale_marked_with_snapshot":true,
 "stale_refused":true}
cargo test --workspace --locked(CLI+Bunde 0.3.0 env)  142 passed, 0 failed
fmt / clippy -D warnings                                PASS

边界

  • 指标只对固定 5 文档 fixture 生效,不是生产基准;.mq.md Analysis 索引、语义通道质量与 #55 §15 冷启动评估另行跟踪。
  • 未改 CLI/其它组件;未新增索引/元数据/跨仓依赖;未创建 release。

refs #14 #12

## 概述 实现 `marqdo-knowledge#14` P3 的**首轮可执行检索质量口径**:固定 fixture 上的 hit@1/hit@3/MRR、navigation role、stale 拒绝/标记,数字来自真实运行;不宣称生产召回/延迟/RSS 门槛。 ## 交付 - `tests/quality.rs`:5 文档 fixture + 5 个唯一标题查询;输出一行 `QUALITY_METRICS {json}` 供 CI 日志归档;断言固定 fixture 的确定性结果。 - `docs/QUALITY.md`:指标定义、首轮取值、fixture 范围与明确非承诺。 - `docs/STATUS.md` 记录;证据 `docs/evidence/2026-11-30-quality-first-round.md`。 ## 验证(真实,Linux x86_64 / glibc 2.43) ```text QUALITY_METRICS {"fixture_documents":5,"hit_at_1":5,"hit_at_3":5,"mrr":1.0, "navigation_role":"index","queries":5,"stale_marked_with_snapshot":true, "stale_refused":true} cargo test --workspace --locked(CLI+Bunde 0.3.0 env) 142 passed, 0 failed fmt / clippy -D warnings PASS ``` ## 边界 - 指标只对固定 5 文档 fixture 生效,不是生产基准;`.mq.md` Analysis 索引、语义通道质量与 #55 §15 冷启动评估另行跟踪。 - 未改 CLI/其它组件;未新增索引/元数据/跨仓依赖;未创建 release。 refs #14 #12
cflmy added 1 commit 2026-11-30 17:35:49 +08:00
Implement the P3 part of marqdo-knowledge#14 with an executable, fixture-scoped
quality set instead of unmeasured claims:

- tests/quality.rs: fixed 5-document fixture (navigation index + 4 knowledge
  docs), 5 unique-title queries; computes hit@1, hit@3, MRR, navigation role,
  stale refusal and snapshot stale marking; prints one QUALITY_METRICS JSON
  line so CI logs can archive the numbers.
- docs/QUALITY.md defines each metric, the first-round values, the fixed
  fixture scope and the explicit non-claims (no production recall/latency/RSS
  threshold).
- docs/STATUS.md records the implementation; evidence:
  docs/evidence/2026-11-30-quality-first-round.md (5/5 hit@1, MRR 1.0,
  navigation role index, stale refused/marked on this fixture).

No CLI/other component change, no release, no new index or metadata.
cflmy merged commit 497e4b9198 into master 2026-11-30 17:46:14 +08:00
Author
Owner

合并结果

PR #17 合并:497e4b91985d6bb11f2a0827363a7aeab0c9a606;组件 CI PR #48 success。
QUALITY_METRICS 固定 fixture 结果:hit@1 5/5、hit@3 5/5、MRR 1.0、navigation role index、stale 拒绝与 snapshot 标记 PASS。根 gitlink 晋升在独立根 PR 中执行(下一轮)。

## 合并结果 PR #17 合并:`497e4b91985d6bb11f2a0827363a7aeab0c9a606`;组件 CI PR #48 success。 `QUALITY_METRICS` 固定 fixture 结果:hit@1 5/5、hit@3 5/5、MRR 1.0、navigation role `index`、stale 拒绝与 snapshot 标记 PASS。根 gitlink 晋升在独立根 PR 中执行(下一轮)。
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: cflmy/marqdo-knowledge#17