Show live task progress while agents work (#3227)
* feat(agents): surface live task progress Keep current task state above the composer and turn task snapshots into semantic timeline activity. Normalize provider task protocols while preserving genuine plan flows. * fix(agents): admit tasks through stream sequencing * test(agents): expect normalized task status
This commit is contained in:
@@ -117,6 +117,40 @@ describe("wire schema compatibility", () => {
|
||||
});
|
||||
});
|
||||
|
||||
test("task progress fields are optional on the wire", () => {
|
||||
expect(
|
||||
AgentTimelineItemPayloadSchema.parse({
|
||||
type: "todo",
|
||||
items: [{ text: "Legacy task", completed: false }],
|
||||
}),
|
||||
).toEqual({ type: "todo", items: [{ text: "Legacy task", completed: false }] });
|
||||
expect(
|
||||
AgentTimelineItemPayloadSchema.parse({
|
||||
type: "todo",
|
||||
items: [
|
||||
{
|
||||
id: "task-1",
|
||||
text: "Current task",
|
||||
activeForm: "Working on current task",
|
||||
status: "in_progress",
|
||||
completed: false,
|
||||
},
|
||||
],
|
||||
}),
|
||||
).toEqual({
|
||||
type: "todo",
|
||||
items: [
|
||||
{
|
||||
id: "task-1",
|
||||
text: "Current task",
|
||||
activeForm: "Working on current task",
|
||||
status: "in_progress",
|
||||
completed: false,
|
||||
},
|
||||
],
|
||||
});
|
||||
});
|
||||
|
||||
test("sub_agent tool-call payload still parses against the v0.1.65-beta.3 schema", () => {
|
||||
const parsed = LegacySubAgentToolCallSchema.parse({
|
||||
type: "tool_call",
|
||||
|
||||
Reference in New Issue
Block a user