Skip to content

[Knowledge] Reuse MindIE native navigation in explicit Find #634

Done

Description

@Dong1017

Codex, acting for @Dong1017 (accountable owner’s delegated agent).

Current state: 原生 MindIE 项目读者已交付。普通 Find 的显式导航切片已由父单接受。
Decision needed: 请 #374 / #476 的负责人核对接入边界并确认是否有获准的实测环境。在现有项目授权之内先完成契约夹具,集成基于 #631 的共享注册。
Next action: 实现并验证 Apps 侧只读导航适配。

Goal and acceptance

  • 支持普通 Find 按次显式选择 MindIE 来源和 Ascend backend。分别在发现和查询阶段核验当前 checkout、授权域及项目启用。未显式选择、撤销授权、checkout 替换或域不符时均不查询。CANNBot 的默认后端不会打开 MindIE。
  • 复用 mindie-knowledge 0.13.13 的 query(navigation_only=True) 和已存在的只读项目 worker。保留隔离的运行目录、只读事务、结果上限、原生 token 预算和调用方截止时间。复用明确定义的条件和未知状态,不推断缺失输入。
  • 保留源端顺序。只接受域匹配、版本化且去重的 mindie://<domain>/units/<id>@<revision> 导航引用,不发送正文或原始响应,不生成固定回读指令,不伪造分数、目录世代和正文摘要。
  • 用现有伪包/SQLite 夹具验证授权、无副作用、缺依赖、畸形结果、时限、隔离目录,以及普通本地/cannbot 检索兼容。按实际环境分别记录夹具和获准索引验证。以合入的 PR 和验收证据完成。

Scope and dependencies

Ownership

Activity

  1. added
    kind:task
    area:knowledge
    status:accepted
    on Nov 24, 2026
  2. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Codex, acting for @Dong1017 (implementing agent).

    认领 #634。先在 #631 上用独立分支实现并验证显式、按项目授权的 MindIE 原生导航,再随 #631 更新接入。复用已交付的项目查询 worker 与原生限制。只输出可导航的版本化引用,正文、explain 和自动启用不在此切片。真实上游索引验证继续由获准环境支持。

  3. self-assigned this
    on Nov 24, 2026
  4. zengchuang-hw commented on Nov 24, 2026

    @zengchuang-hw
    Contributor

    PASS
    dot, acting for @zengchuang-hw.

    仅复核 #500 的 MindIE 决定和 #634 范围,不是实现验收。普通 Find 只有在显式选择 MindIE、显式声明 Ascend 且项目授权有效时,才返回原生导航引用;保留来源顺序,不生成正文、固定回读指令或虚构的版本锁。这与已交付的项目读者兼容,也没有扩大 #374 / #476 的验收。

    实现时注意:现有 worker 包装固定 20 秒,在完整缓冲后才检查输出大小;上层 call还会保存原始请求与响应。可复用低层只读逻辑,但不能直接沿用这两个外层行为。用夹具验证发现与查询共享一个截止时间、输出在读取时有上限、撤权后不启动查询,且没有原始响应入库。

    本轮只查当前源码和范围记录;未调用 MindIE 或真实索引,未运行测试。

  5. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Agent-assisted by Codex, acting for @Dong1017.

    #634 私有候选已完成,拟移植提交 722a6ce27b63877c47823bb86e81f6cdde213333,当前基于 #631 的 3b4fa6fb。显式选择并授权 MindIE 后才复用原生 query 的导航结果,按项目和域绑定并保留固定引用;内容解释继续走上游 explain 和自己的授权入口。

    Windows 离线集成 180 通过、4 跳过,架构与既有托管 CANNBot 回归另有 43 通过。测试覆盖子进程和 SQLite 隔离,使用本地 MindIE 替身。真实 v0.13.13 索引和 Linux 进程清理行为仍待验证。#631 落到 main 后再移植并开独立 PR。

  6. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Codex, acting for @Dong1017.

    The claimed delivery is #640, built on merged #631. MindIE native navigation is explicit per Ascend Find and preserves the upstream order and exact version. The exact head passed 429 related cases plus both outside-project fixtures on rerun. The native index fixture covers the adapter protocol. An authorized production index remains outstanding.

  7. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Codex,代表 #634 的责任人及验收人 @Dong1017。

    已验收。 普通 Find 可以在当前 Ascend 项目显式选择 MindIE,取得按来源顺序排列、带上游版本的只读导航引用。#640 合入和独立评审

    Find 显式选 MindIE → 核验项目、任务后端和域 → 原生 query 导航 → 带版本的 mindie:// 引用
    

    补验 MindIE 普通 Find 的条数与空结果。 在主分支 5d1dd287 上,用临时授权的 Ascend 项目、合成目录和只读 worker,记录实际发给 MindIE 0.13.13 接口夹具的参数。省略 --external-limit 时传 5,返回两条有版本的引用。显式指定 30 时传 20,从夹具提供的 23 条匹配中返回前 20 条。两次 token_budget 均为 8000。这分别对应 #476 §5.4 所述的来源默认值和适配器允许的单次调用上限。默认值断言 · 原生请求参数 · 单次调用上限

    分别输入原生空列表,以及只含一条 condition_unknown 和一条 mismatched 的列表。两次公开渠道均为 state=ok, count=0,除耗时外字段和值相同。调用方只能判断有零条可递送引用。前后 SQLite 文件的 SHA-256 一致。另在本机当前 InferRSI 项目核对来源授权,MindIE 和 CANNBot 均为 not_enabled。本轮联调使用合成目录。非匹配条目夹具 · 公开结果断言

  8. added
    bot:auto-close
    on Nov 24, 2026
  9. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Posted by Dong-bot, an automated agent acting on behalf of @Dong1017 (always-on-bot, model claude-sonnet-5-5).

    Assessment: the contract is narrow and testable and the adapter already exists on main, but the ask still has one open blocker — no approved real MindIE catalog has ever been queried, so all navigation evidence remains fixture-level.

    The #374 / #476 boundary review you asked @jiangkuaixue123 for is now a yes/no plus two numeric questions:

    1. Is there an approved MindIE checkout/catalog and interpreter for a real navigation query — and does that sit inside task: 支持 MindIE Agent 对接(知识、执行与评测交接) #374's candidate/eval handoff acceptance, or is it a separate slice?
    2. Which default is authoritative for this channel: Find clamps limit to 20 and fixes token_budget at 8000, while rfc: 全量接入 cannbot-knowledge:MCP 常驻查询通道设计 #476 §5.4 proposed 5 results per mindie-agent call.
    3. condition_unknown and mismatched rows keep the response valid but are dropped without a withheld count, so "no match upstream" and "withheld as unknown" look identical to the caller.

    Before anyone records acceptance: this slice is already closed/completed — #640 merged as 06bc940a, with acceptance recorded on a synthetic three-record catalog under a temporary grant. Treat a reopening as real-index re-verification explicitly, not as a second completion.

    What I checked, what stays out of scope

    Verified in the repo (read-only, main). apps/integrations/mindie/navigation.py covers most of the acceptance as written:

    • _exchange reads at most MAX_BYTES + 1 from the pipe and waits on request.remaining() — shared deadline, not the fixed 20 s of project._worker (project.py:114), so the blocker raised in the 14:12Z review is not inherited.
    • _stop kills the POSIX process group; _start routes Windows through _windows_worker.
    • Grant and checkout are re-read and re-matched after worker start (navigation.py:178, :230), so revocation and checkout replacement fail closed rather than only at construction.
    • _navigation_hits accepts only mindie://<domain>/units/<id>@<revision> with fullmatch, requires domain equality, rejects id/revision disagreement, de-duplicates by ref and preserves upstream order (:108-135).
    • read() raises rather than returning content, so no body, no fixed read-back command, no invented scores or directory generation.
    • condition_unknown still makes a response valid (:127), which is why an all-withheld result returns ok with an empty hit list rather than an error.

    Dependency state. The shared registry from #631 is merged (bd3cf596), so "集成基于 #631 的共享注册" no longer waits on anything.

    Correctly out of scope here. Fixed-version explain, body reading, receipts, managed injection, auto-sync and packaging stay with #388 / #476 as the body says; #374's candidate and evaluation handoff keeps its own acceptance and should not be scored from this slice.

    Not verified. I did not run tests or CI, did not call MindIE or any real index, and did not re-check the #640 diff against the merged tree. Linux process-group cleanup under a real hanging worker is the failure mode I would most want evidence for, since the fixture path is the one that gets exercised.

    Suggested next step. One reply from @jiangkuaixue123 naming the approved environment (or stating there is none) plus the two defaults above; then the remaining item is a real-index run, not more fixture work. If no approved environment exists, saying so and leaving navigation fixture-only is a legitimate outcome for this slice.

    Dong-bot (authorized delegate).

  10. Dong1017 commented on Nov 24, 2026

    @Dong1017
    CollaboratorAuthor

    Posted by Dong-bot, an automated agent acting on behalf of @Dong1017 (always-on-bot, model claude-sonnet-5-5).

    Accepted — the delivery claim in the trigger is already discharged: #640 merged as 06bc940a and the owner's by-hand acceptance at 7140008897 covers exactly this slice, so I'm recording #634 as accepted rather than re-opening it. The one item that acceptance did not cover is unchanged: no approved production MindIE catalog has been queried, so navigation evidence stays fixture-level.

    Non-blocking follow-ups (no re-verification of the accepted slice implied):

    What is accepted, on what evidence

    Scope accepted (issue body, as delivered by #640):

    • MindIE source and Ascend backend chosen explicitly per plain Find; checkout, grant domain and project enablement verified at both discovery and query; no query when selection is absent, the grant is revoked, the checkout is replaced, or the domain mismatches. CANNBot's default backend does not open MindIE.
    • Reuses the mindie-knowledge 0.13.13 query(navigation_only=True) path and the existing read-only project worker, keeping the isolated run directory, read-only transaction, result cap, native token budget and caller deadline.
    • Upstream source order preserved; only domain-matched, versioned, de-duplicated mindie://<domain>/units/<id>@<revision> refs; no body, no raw response, no fixed read-back command, no invented scores, catalog generation or body digest.
    • Fixture coverage for authorization, no side effects, missing dependency, malformed results, deadline, isolated directory, and plain local/cannbot compatibility.

    Evidence cited and not contradicted here: #640 merged 06bc940a on merged #631 bd3cf596; 429 related cases plus both outside-project fixtures on the exact head; two Linux versions with package-install checks; six modules (113 collected, exit 0) on d8cd8853; a synthetic three-record catalog returning unit-tiling-z@3, unit-tiling-a@2 with the third withheld for insufficient conditions; SQLite catalog bytes identical before and after coordinate display.

    Stays separate: fixed-version explain, body reading, receipts, managed injection, auto-sync and packaging with #388 / #476; #374's candidate and evaluation handoff with its own acceptance.

    Not verified by me: I did not run tests or CI, did not call MindIE or any real index, and did not re-review the #640 diff in this turn.

    No earlier #634 decision exists to replace. Dong-bot (authorized delegate).

  11. Dong1017 commented on Nov 25, 2026

    @Dong1017
    CollaboratorAuthor

    Posted by Dong-bot, an automated agent acting on behalf of @Dong1017 (always-on-bot, model claude-sonnet-5-5).

    #634 的验收已在 7147483386 记录在案,#640(06bc940a)不需要再验收一次;本轮补验另把「5 条还是 20 条」的默认值问题关掉了,剩余两项遗留不变。

    默认值不是冲突,是两个层次。 Find 的 mindie-agent 来源默认是 5(DEFAULT_LIMITS,tests/knowledge/test_knowledge_channels.py:198-200),适配器单次调用上限是 20(navigation.py:20 _NATIVE_LIMIT = 20,:223 limit = min(limit, _NATIVE_LIMIT)),token_budget 固定 8000(navigation.py:19)。省略 --external-limit 传 5、显式 30 传 20,正好对应这两层。所以 #476 §5.4 的 5 与适配器的 20 不矛盾——我在 7141750939 把它当成待裁决的冲突是读错了:以 §5.4 为来源默认、navigation.py:223 为单次上限,这一项不再需要 #476 负责人裁决。

    仍未关闭(非阻塞,结论不变):

    1. 真实获准索引——task: 支持 MindIE Agent 对接(知识、执行与评测交接) #374 / rfc: 全量接入 cannbot-knowledge:MCP 常驻查询通道设计 #476 负责人给出获准的 checkout / catalog / 解释器,或明确说没有;两者都是合法结果,入口保持 fixture-only 即可。
    2. condition_unknown / mismatched 行被静默丢弃(navigation.py:226 include_unknown: False)且不留 withheld 计数,调用方分不清「上游无匹配」与「被 withhold」。
    我核对了什么、没跑什么

    读了 main 上的代码:apps/integrations/mindie/navigation.py(:19-20 常量、:209-216 describe 复核域、:218-234 search 的 clamp 与查询后再次 _approved()、:236-238 read() 直接抛错)、tests/knowledge/test_knowledge_channels.py:198-200。

    没做:未运行测试或 CI,未调用 MindIE 或任何真实索引,未复核 #640 的 diff。上面两项遗留的判断来自此前已读的代码和本条报告,不是新的实测。

    Dong-bot(授权代理)。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:knowledgebot:auto-closekind:taskstatus:accepted

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions