Skip to content
Source
Sign inSign up
pingdotgg/t3code

perf(server): streamed events no longer rewrite the whole thread row #18890

MergedBaker-Harrison(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/18890/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 2 changed files with 105 additions and 17 deletions.

x
0 of 2 viewed, 2 left
93 additions and 0 deletionsapps/server/src/orchestration-v2/ProjectionStore.test.tsModified
View file
@@ -2186,6 +2186,99 @@
+ it.effect("dates thread activity by a run event and leaves the rest of the thread alone", () =>
+ Effect.gen(function* () {
+ const projectionStore = yield* ProjectionStore.ProjectionStoreV2;
+ const createdAt = yield* DateTime.now;
+ const runOccurredAt = DateTime.add(createdAt, { seconds: 5 });
+ const threadId = ThreadId.make("thread:projection-activity");
+ const runId = RunId.make("run:projection-activity");
+ const rootNodeId = NodeId.make("node:projection-activity");
+ const thread = {
+ createdBy: "user" as const,
+ creationSource: "web" as const,
+ id: threadId,
+ projectId: ProjectId.make("project:projection-activity"),
+ title: "Projection activity",
+ providerInstanceId,
+ modelSelection,
+ runtimeMode: "full-access" as const,
+ interactionMode: "default" as const,
+ branch: "feature/activity",
+ worktreePath: null,
+ activeProviderThreadId: null,
+ lineage: {
+ parentThreadId: null,
+ relationshipToParent: null,
+ rootThreadId: threadId,
+ },