feat(identity): open identity_unresolved decisions for resources with no candidates
no_match resources (and lookup failures after auto-review gives up) now
open a decision in the inbox with options to set a TMDB ID, pick a local
work, or dismiss; ambiguous decisions get the same manual options.
Resolve accepts identity {tmdb | mediaEntityId} and assigns with a manual
lock. The inbox option dialog collects the TMDB type/ID or searches local
works; the identity pool links each pending item to its inbox filter.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
a0b0a64246
commit
fb7727cf66
14 files changed
+280
-37
No files matched your search
@@ -148,7 +148,7 @@ export function registerAgentTasks(registry: TaskRegistry, env: () => AgentEnv)
|
||||
}
|
||||
|
||||
/**
|
||||
* 执行 decision 的处理结果(身份歧义由 sources-identity 在处理端点里直接执行,这里跳过):
|
||||
* 执行 decision 的处理结果(身份类由 sources-identity 在处理端点里直接执行,这里跳过):
|
||||
* - 选项带 capabilityId → 经注册中心调用(仍走授权/审计/账本);
|
||||
* - retry → 重试关联任务;reevaluate / accept → 按对象重发 evaluateAcquisition;dismiss / ignore → 无动作。
|
||||
*/
|
||||
@@ -156,7 +156,8 @@ export async function executeResolution(ctx: ServerContext, decisionId: string)
|
||||
const d = await ctx.db.selectFrom("decision").selectAll().where("id", "=", decisionId).executeTakeFirst();
|
||||
if (!d) return { executed: false, reason: "not_found" };
|
||||
if (d.status !== "resolved") return { executed: false, reason: `status_${d.status}` };
|
||||
if (d.kind === "identity_ambiguous") return { executed: false, reason: "handled_by_sources_identity" };
|
||||
if (d.kind === "identity_ambiguous" || d.kind === "identity_unresolved")
|
||||
return { executed: false, reason: "handled_by_sources_identity" };
|
||||
const res = (d.resolution ?? {}) as { optionKey?: string | null; by?: string; execution?: unknown };
|
||||
if (res.execution) return { executed: false, reason: "already_executed" };
|
||||
const key = res.optionKey ?? null;
|
||||
|
||||
Reference in new issue
Block a user