feat(files): wire serverFileId for version tracking

Add serverFileId to FileEntry, pass fileId in tool processor formData when
a file originates from the Files page, and set serverFileId on the loaded
entry so subsequent tool runs create new file versions instead of duplicates.
This commit is contained in:
Siddharth Kumar Sah
2026-03-26 01:10:50 +08:00
parent f2ef910a16
commit 20f153d611
3 changed files with 36 additions and 7 deletions
+2
View File
@@ -8,6 +8,7 @@ export interface FileEntry {
originalSize: number;
status: "pending" | "processing" | "completed" | "failed";
error: string | null;
serverFileId?: string;
}
// ---------------------------------------------------------------------------
@@ -23,6 +24,7 @@ function createEntry(file: File): FileEntry {
originalSize: file.size,
status: "pending",
error: null,
serverFileId: undefined,
};
}