Bugfix/Add streaming to chatfireworks (#2884)

add streaming to chatfireworks
This commit is contained in:
Henry Heng 2024-07-26 00:22:42 +01:00 committed by GitHub
parent f24b5e8d28
commit c6264a24cc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 1 deletions

View File

@ -59,6 +59,7 @@ class ChatFireworks_ChatModels implements INode {
const cache = nodeData.inputs?.cache as BaseCache
const temperature = nodeData.inputs?.temperature as string
const modelName = nodeData.inputs?.modelName as string
const streaming = nodeData.inputs?.streaming as boolean
const credentialData = await getCredentialData(nodeData.credential ?? '', options)
const fireworksApiKey = getCredentialParam('fireworksApiKey', credentialData, nodeData)
@ -67,7 +68,8 @@ class ChatFireworks_ChatModels implements INode {
fireworksApiKey,
model: modelName,
modelName,
temperature: temperature ? parseFloat(temperature) : undefined
temperature: temperature ? parseFloat(temperature) : undefined,
streaming: streaming ?? true
}
if (cache) obj.cache = cache