Skip to content

Commit

Permalink
Update openAI.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
babaohuang committed Dec 14, 2023
1 parent 052e86c commit 1039a34
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/utils/openAI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ export const startChatAndSendMessageStream = async(history: ChatMessage[], newMe
generationConfig: {
maxOutputTokens: 8000,
},
safetySettings: [
{
category: HarmCategory.HARM_CATEGORY_UNSPECIFIED,
threshold: HarmBlockThreshold.BLOCK_NONE,
},
],
})

// Use sendMessageStream for streaming responses
Expand Down

0 comments on commit 1039a34

Please sign in to comment.