Files
DeepTutor/deeptutor/services/partners
Bingxi Zhao (Frank) 352f7d1793 fix(partners): refuse turn-owning KB kinds, and finish connected provisioning
#1261 taught `_copy_knowledge_base` that a pointer KB has no folder to copy,
which is right and is what the reported WeKnora case needed. It also made
three kinds assignable that had previously failed for want of a folder, and
left the other half of the feature unbuilt.

Obsidian, MarginNote and subagent KBs are each driven by an *exclusive*
`KnowledgeCapability`: when one is in a turn's KB selection it replaces the
entire tool surface. A partner passes ALL of its knowledge bases as that
selection on every turn, so a single assigned vault would silently seize
every partner turn, and a `subagent` entry with `agent_kind: partner` would
let a partner consult another partner — or itself. They are refused now, by
the set that already names them (`NON_RETRIEVABLE_KB_TYPES`), with a message
that says why instead of a bare FileNotFoundError.

The rest is the half that made a successful assignment look like a failed
one. `list_assets` scanned directories, so a pointer KB was invisible in the
partner's library — and therefore never in `excluded`, so the picker kept
offering it and the user kept assigning it to no visible effect.
`remove_asset` returned False when the folder was missing, which the router
turns into a 404, so it could not be un-assigned either. Both now treat the
folder and the config row as independent, because for a pointer KB only the
row exists.

The two existing connected-KB tests used `obsidian` as their sample, which
this change refuses; they use `weknora` now — the kind actually reported, and
one a partner may legitimately hold.
2026-09-08 00:42:30 +08:00
..
2026-08-25 02:24:35 +08:00
2026-08-25 02:24:35 +08:00
2026-08-25 02:24:35 +08:00
2026-08-25 02:24:35 +08:00
2026-09-02 04:09:11 +08:00
2026-09-02 04:09:11 +08:00