fix: 模型设置增加针对Vertex渠道过滤content[].part[].functionResponse.id的选项,默认启用

This commit is contained in:
Seefs
2025-12-21 17:09:49 +08:00
parent cc3ba39e72
commit 5a64ae2a29
12 changed files with 86 additions and 1 deletions

View File

@@ -46,6 +46,7 @@ const DEFAULT_GEMINI_INPUTS = {
'gemini.thinking_adapter_enabled': false,
'gemini.thinking_adapter_budget_tokens_percentage': 0.6,
'gemini.function_call_thought_signature_enabled': true,
'gemini.remove_function_response_id_enabled': true,
};
export default function SettingGeminiModel(props) {
@@ -186,6 +187,23 @@ export default function SettingGeminiModel(props) {
/>
</Col>
</Row>
<Row>
<Col span={16}>
<Form.Switch
label={t('移除 functionResponse.id 字段')}
field={'gemini.remove_function_response_id_enabled'}
extraText={t(
'Vertex AI 不支持 functionResponse.id 字段,开启后将自动移除该字段',
)}
onChange={(value) =>
setInputs({
...inputs,
'gemini.remove_function_response_id_enabled': value,
})
}
/>
</Col>
</Row>
<Row>
<Col xs={24} sm={12} md={8} lg={8} xl={8}>
<Form.TextArea