feat(web): asset upload, task run observer, and session lineage on tasks

Upload binary attachments as project assets, subscribe by run_id after refresh,
and pass session_id/project_id through long-task requests.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
WeiCHEN
2026-09-13 02:50:22 +00:00
committed by weichen
co-authored by Cursor
parent e139b2b267
commit bbd1218922
6 changed files with 310 additions and 86 deletions
+2
View File
@@ -56,8 +56,10 @@ export function buildTaskRequest(task: TaskRunContext): Record<string, unknown>
};
if (task.intendedUse) body.intended_use = task.intendedUse;
if (task.targetMarket) body.target_market = task.targetMarket;
if (task.sessionId) body.session_id = task.sessionId;
if (task.userId) body.user_id = task.userId;
if (task.projectId) body.project_id = task.projectId;
if (task.clientTurnId) body.client_turn_id = task.clientTurnId;
if (task.materials && task.materials.length > 0) {
body.materials = task.materials;
}