Files
Jyotisha/docs/tasks/PROGRESS-rectification-declared-uncertainty-20260907.md
T
Jesse_Chen 8e31680b45 fix(rectification): honor declared birth-time uncertainty and split windows over two hours (BUG-571–573)
Intake stores how sure the user is; rectification now searches that range, offers a one-click widen when event fit is low at the edge, and trisects windows longer than two hours before the minute grid.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-07 12:18:50 +08:00

3.9 KiB
Raw Blame History

PROGRESS · 出生时间「有多确定」只问一次(2026-09-07)

工作树:.worktrees/rectification-declared-uncertainty-20260907 分支:codex/rectification-declared-uncertainty-20260907(跟踪 origin/staging 基线:任务书落地 commit ad9283d1(含 BUG-565570);合入前 rebase 到当时 origin/staging(含 BUG-574 b2a8d3a0)。

未改 SKILL.md(仍 10.0.14)、未改采用门 / 确认门 / MIN_SEPARATION_LEAD / 分钟级 _relative_support、未改 page.tsx、未改 jyotish_api_server.py、未改 contracts/probe-question-v1.json。迁移文件为 20260907020000_rectification_declared_uncertainty.sql20260907010000 已被 personal_report_card_summary 占用)。

本单状态:待验收。BUG-571 / 572 / 573 已实现。

任务 状态 BUG
D1 intake 三档 + ±120 完成
D2 校正窗口读档案 完成 BUG-571
D5 子段扫描 完成 BUG-573
D3 放宽窗口一键卡 完成 BUG-572
D6 日级可靠度 + 手测脚本 完成
D4 记录 完成 本文件 / BUG_HISTORY / CHANGELOG / DESIGN / VOICE / testing

实现要点

  • 窗口阶段看 exclusive span04:0006:00 = 120 → minute03:0007:00 = 240 → block_scan)。放宽上限看 inclusive width ≤ 241
  • 子段是当前窗三等分、无共享分钟。unknown 仍先扫五个声明时段(步长 10),赢段再切三段。
  • 放宽卡优先级高于区分卡。hospital_record 答 A 只改窗口。
  • 日级可靠度只在本回合刚写入的 day 事件上问(source_turn_id === askedTurnId),不拦采用门、不改历史账本上的旧日事件采集顺序。

书面偏差

任务书 实际 原因
D6 写回 「用现有证据修订链,不新造 RPC」 薄 RPC set_agentic_rectification_evidence_date_reliability(原地 high/medium revise/supersede 会新开证据行、改指纹,误伤训练门
放宽 D 文案 「说不好」 「说不好 / 先这样」 clippedCopy 最短 4 字
block_scan 全零均分 五段各 20% 100/n(三段 33.3/33.3/33.4 自定义 blocks 时写死 20 只给到 60
迁移时间戳 20260907010000_... 20260907020000_... staging 已占用 20260907010000_personal_report_card_summary.sql

既有断言改动

文件 原值 新值 原因
rectification-v9-case-service 04:4505:15 有钟点一律 family_exact / 医院记录;approximate 另写 BUG-571
database-rectification-block-scan 08:0011:59 选定后 minute 选定后仍 block_scan span 239>120
rectification-block-scan 选下午 进分钟 block_scan 12:0017:59 span 359
birth-time-intake /前后两小时/ 扫组件源码 approximateUncertaintyOptions 文案在 model

测试

命令 结果
非 DB rectification-* + consultation-* + report-* + personal-report-* + birth-time-* + account-api + agent-voice-copy-contract 1913 pass / 0 fail(≥ 1521
.venv/bin/python -m pytest tests/test_rectification_v5_services.py -k 'not seven_events' 33 pass / 0 fail(含自定义三段 100 与 33.3/33.3/33.4
test_block_scan_seven_events_finishes_within_fifteen_seconds 本机连跑偶发超 15s,与 BUG-570 同一 P2,未改断言
npx tsc --noEmit 0 错
./node_modules/.bin/eslint --quiet src tests 0 error
frontend npm run test:db 37 pass / 0 fail547.7s;含 database-rectification-block-scan08:0011:59 选定后仍 block_scan08:0009:00 进 minute,widen 扩大成功 / 缩小失败 / service_role-only

排除 *-database.test.ts 于非 DB 套件。ERR-011Python 用 .venv/bin/python -m pytest。未改 page.tsx。未改分钟级 _relative_support。无 Docker 缺口,未写 BLOCKED.md