mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Default HARM_CATEGORY_CIVIC_INTEGRITY to OFF
All models support either all BLOCK_NONE, or all OFF.
This commit is contained in:
@ -156,7 +156,7 @@ export const GEMINI_SAFETY = [
|
||||
},
|
||||
{
|
||||
category: 'HARM_CATEGORY_CIVIC_INTEGRITY',
|
||||
threshold: 'BLOCK_NONE',
|
||||
threshold: 'OFF',
|
||||
},
|
||||
];
|
||||
|
||||
|
@ -387,11 +387,6 @@ async function sendMakerSuiteRequest(request, response) {
|
||||
if (['gemini-1.5-pro-001', 'gemini-1.5-flash-001', 'gemini-1.5-flash-8b-exp-0827', 'gemini-1.5-flash-8b-exp-0924'].includes(model)) {
|
||||
safetySettings = GEMINI_SAFETY.map(setting => ({ ...setting, threshold: 'BLOCK_NONE' }));
|
||||
}
|
||||
// Interestingly, Gemini 2.0 Flash does support setting the threshold for HARM_CATEGORY_CIVIC_INTEGRITY to OFF.
|
||||
else if (['gemini-2.0-flash', 'gemini-2.0-flash-001', 'gemini-2.0-flash-exp', 'gemini-2.0-flash-exp-image-generation'].includes(model)) {
|
||||
safetySettings = GEMINI_SAFETY.map(setting => ({ ...setting, threshold: 'OFF' }));
|
||||
}
|
||||
// Most of the other models allow for setting the threshold of filters, except for HARM_CATEGORY_CIVIC_INTEGRITY, to OFF.
|
||||
|
||||
if (enableWebSearch && !useMultiModal && !isGemma && !isLearnLM && !model.includes('gemini-2.0-flash-lite')) {
|
||||
const searchTool = model.includes('1.5') || model.includes('1.0')
|
||||
|
Reference in New Issue
Block a user