Skip to content

Commit

Permalink
Support multiple uploads
Browse files Browse the repository at this point in the history
  • Loading branch information
peterszerzo committed Oct 25, 2024
1 parent b96b83b commit 7994f38
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/chat-core/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ export interface StructuredRequest {
/**
* Upload ID
*/
uploadId?: string;
uploadIds?: string[];
/**
* Upload utterance
*/
Expand Down
3 changes: 2 additions & 1 deletion packages/chat-widget/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -620,9 +620,10 @@ export const Widget = forwardRef<WidgetRef, Props>(function Widget(props, ref) {
(() => {
if (activeUpload !== null) {
chat.conversationHandler.sendStructured({
uploadId: activeUpload.uploadId,
uploadIds: [activeUpload.uploadId],
utterance: chat.inputValue,
});
chat.setInputValue("");
return;
}
chat.conversationHandler.sendText(chat.inputValue);
Expand Down

0 comments on commit 7994f38

Please sign in to comment.