Skip to content
Source
Sign inSign up
pingdotgg/t3code

feat(web): show when an agent opened a thread #16699

Closedt3dotgg(GitHub profile, opens in a new tab)wants to merge 10 commits intomain fromt3code/agent-created-thread-indicatoropened View on GitHub

Showing 16 changed files with 6 additions and 1 deletion (loading 13).

x
0 of 16 viewed, 16 left
4 additions and 1 deletionapps/server/src/mcp/toolkits/project/handlers.test.tsModified
View file
@@ -29,7 +29,7 @@
import * as ProjectHandlers from "./handlers.ts";
import { ProjectToolkit } from "./tools.ts";
​
-it.effect("attributes a launched thread's first message to the calling thread", () =>
+it.effect("attributes a launched thread and its first message to the calling thread", () =>
Effect.gen(function* () {
const sourceThreadId = ThreadId.make("source-thread");
const projectId = ProjectId.make("project");
@@ -47,6 +47,7 @@
deletedAt: null,
} as OrchestrationV2ThreadShell;
let launchedSender: ThreadId | undefined;
+ let launchedOpener: ThreadId | undefined;
const layerDependencies = Layer.mergeAll(
ServerSettings.layerTest(),
NodeCrypto.layer,
@@ -68,6 +69,7 @@
Layer.mock(ThreadLaunch.ThreadLaunchService)({
launch: (input) => {
launchedSender = input.initialMessage?.senderThreadId;
+ launchedOpener = input.openedByThreadId;
return Effect.succeed({
threadId: input.threadId,
projection: {
@@ -98,6 +100,7 @@
.pipe(Stream.unwrap, Stream.runCollect, Effect.provide(layerDependencies));