feat: update safety settings for specific categories #696
Gemini安全设置是否没有完全关闭
This commit is contained in:
parent
6276890e5b
commit
5b00c21f15
@ -145,13 +145,13 @@ export default class GeminiProvider extends BaseProvider {
|
||||
...this.getCustomParameters(assistant)
|
||||
},
|
||||
safetySettings: [
|
||||
{ category: HarmCategory.HARM_CATEGORY_HATE_SPEECH, threshold: HarmBlockThreshold.BLOCK_NONE },
|
||||
{ category: HarmCategory.HARM_CATEGORY_HATE_SPEECH, threshold: 'OFF' as HarmBlockThreshold },
|
||||
{
|
||||
category: HarmCategory.HARM_CATEGORY_SEXUALLY_EXPLICIT,
|
||||
threshold: HarmBlockThreshold.BLOCK_NONE
|
||||
threshold: 'OFF' as HarmBlockThreshold
|
||||
},
|
||||
{ category: HarmCategory.HARM_CATEGORY_HARASSMENT, threshold: HarmBlockThreshold.BLOCK_NONE },
|
||||
{ category: HarmCategory.HARM_CATEGORY_DANGEROUS_CONTENT, threshold: HarmBlockThreshold.BLOCK_NONE }
|
||||
{ category: HarmCategory.HARM_CATEGORY_HARASSMENT, threshold: 'OFF' as HarmBlockThreshold },
|
||||
{ category: HarmCategory.HARM_CATEGORY_DANGEROUS_CONTENT, threshold: 'OFF' as HarmBlockThreshold }
|
||||
]
|
||||
},
|
||||
this.requestOptions
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user