2
0

🐛 (openai) Fix ask assistant not correctly referencing uploaded f… (#1469)

…iles

Closes #1468, closes #1467, closes #1211
This commit is contained in:
Baptiste Arnaud
2024-04-24 16:11:06 +02:00
committed by GitHub
parent a45e8ec8a8
commit dc1929e15b
57 changed files with 1576 additions and 448 deletions

View File

@ -1,6 +1,6 @@
import { Anthropic } from '@anthropic-ai/sdk'
import { options as createMessageOptions } from '../actions/createChatMessage'
import { ReadOnlyVariableStore } from '@typebot.io/forge'
import { VariableStore } from '@typebot.io/forge'
import { isNotEmpty } from '@typebot.io/lib'
import { z } from '@typebot.io/forge/zod'
@ -9,7 +9,7 @@ export const parseChatMessages = ({
variables,
}: {
options: Pick<z.infer<typeof createMessageOptions>, 'messages'>
variables: ReadOnlyVariableStore
variables: VariableStore
}): Anthropic.Messages.MessageParam[] => {
const parsedMessages = messages
?.flatMap((message) => {

View File

@ -11,10 +11,10 @@
"@typebot.io/lib": "workspace:*",
"@typebot.io/tsconfig": "workspace:*",
"@types/react": "18.2.15",
"typescript": "5.3.2"
"typescript": "5.4.5"
},
"dependencies": {
"@anthropic-ai/sdk": "0.18.0",
"ai": "3.0.12"
"@anthropic-ai/sdk": "0.20.6",
"ai": "3.0.31"
}
}