Gateway: show subagent requests on the parent's card, and settle threads
This commit is contained in:
1 parent
a8b6375afe
commit
a4754b65b0
7 files changed
+183
-21
No files matched your search
@@ -91,10 +91,13 @@ export class Notifier {
|
||||
]);
|
||||
const project = host.projects.get(thread.projectId)?.title;
|
||||
const requestId = thread.pendingRuntimeRequest?.id;
|
||||
// A subagent's push is about the thread that delegated to it, which is the one the user knows.
|
||||
const parent = thread.delegatedFrom?.title;
|
||||
const text = body(phase, thread.lastError ?? null, summary);
|
||||
await this.send({
|
||||
title: thread.title,
|
||||
title: parent ?? thread.title,
|
||||
subtitle: project ? `${host.label} · ${project}` : host.label,
|
||||
body: body(phase, thread.lastError ?? null, summary),
|
||||
body: parent ? `Subagent ${thread.title}: ${text}` : text,
|
||||
category: category(phase),
|
||||
data: { hostId: host.id, threadId: thread.id, ...(requestId ? { requestId } : {}) },
|
||||
collapseId: `${host.id}:${thread.id}`.slice(0, 64),
|
||||
|
||||
Reference in new issue
Block a user