Skip to content

Commit

Permalink
vision_model_only
Browse files Browse the repository at this point in the history
  • Loading branch information
KSnow616 authored Feb 28, 2024
1 parent bd19e97 commit e705135
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/components/chat.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1102,6 +1102,8 @@ function _Chat() {
}, []);

const handlePaste = useCallback(
const currentModel = chatStore.currentSession().mask.modelConfig.model;
if(!isVisionModel(currentModel)){return;}
async (event: React.ClipboardEvent<HTMLTextAreaElement>) => {
const items = (event.clipboardData || window.clipboardData).items;
for (const item of items) {
Expand Down Expand Up @@ -1137,7 +1139,7 @@ function _Chat() {
}
}
},
[attachImages],
[attachImages, chatStore],
);

async function uploadImage() {
Expand Down

0 comments on commit e705135

Please sign in to comment.