mirror of
https://github.com/enricoros/big-AGI.git
synced 2026-05-10 21:50:14 -07:00
LLMs: Moonshot: native search parameter (disabled here and in the model - upstream not good enough)
This commit is contained in:
@@ -164,6 +164,18 @@ export const DModelParameterRegistry = {
|
||||
hidden: true,
|
||||
} as const,
|
||||
|
||||
// Moonshot-specific parameters
|
||||
|
||||
llmVndMoonshotWebSearch: {
|
||||
label: 'Web Search',
|
||||
type: 'enum' as const,
|
||||
description: 'Enable Kimi\'s $web_search builtin function for real-time web search ($0.005 per search)',
|
||||
values: ['auto'] as const,
|
||||
// No initialValue - undefined means off
|
||||
} as const,
|
||||
|
||||
// OpenAI-specific parameters
|
||||
|
||||
llmVndOaiReasoningEffort: {
|
||||
label: 'Reasoning Effort',
|
||||
type: 'enum' as const,
|
||||
|
||||
@@ -49,6 +49,7 @@ export function aixCreateModelFromLLMOptions(
|
||||
llmRef, llmTemperature, llmResponseTokens, llmTopP,
|
||||
llmVndAnt1MContext, llmVndAntSkills, llmVndAntThinkingBudget, llmVndAntWebFetch, llmVndAntWebSearch,
|
||||
llmVndGeminiAspectRatio, llmVndGeminiComputerUse, llmVndGeminiGoogleSearch, llmVndGeminiShowThoughts, llmVndGeminiThinkingBudget,
|
||||
// llmVndMoonshotWebSearch,
|
||||
llmVndOaiReasoningEffort, llmVndOaiReasoningEffort4, llmVndOaiRestoreMarkdown, llmVndOaiVerbosity, llmVndOaiWebSearchContext, llmVndOaiWebSearchGeolocation, llmVndOaiImageGeneration,
|
||||
llmVndOrtWebSearch,
|
||||
llmVndPerplexityDateFilter, llmVndPerplexitySearchMode,
|
||||
@@ -109,6 +110,7 @@ export function aixCreateModelFromLLMOptions(
|
||||
...(llmVndGeminiGoogleSearch ? { vndGeminiGoogleSearch: llmVndGeminiGoogleSearch } : {}),
|
||||
...(llmVndGeminiShowThoughts ? { vndGeminiShowThoughts: llmVndGeminiShowThoughts } : {}),
|
||||
...(llmVndGeminiThinkingBudget !== undefined ? { vndGeminiThinkingBudget: llmVndGeminiThinkingBudget } : {}),
|
||||
// ...(llmVndMoonshotWebSearch === 'auto' ? { vndMoonshotWebSearch: 'auto' } : {}),
|
||||
...(llmVndOaiResponsesAPI ? { vndOaiResponsesAPI: true } : {}),
|
||||
...((llmVndOaiReasoningEffort4 || llmVndOaiReasoningEffort) ? { vndOaiReasoningEffort: llmVndOaiReasoningEffort4 || llmVndOaiReasoningEffort } : {}),
|
||||
...(llmVndOaiRestoreMarkdown ? { vndOaiRestoreMarkdown: llmVndOaiRestoreMarkdown } : {}),
|
||||
|
||||
@@ -94,6 +94,11 @@ const _antWebFetchOptions = [
|
||||
{ value: _UNSPECIFIED, label: 'Off', description: 'Disabled (default)' },
|
||||
] as const;
|
||||
|
||||
// const _moonshotWebSearchOptions = [
|
||||
// { value: 'auto', label: 'On', description: 'Enable Kimi $web_search ($0.005 per search)' },
|
||||
// { value: _UNSPECIFIED, label: 'Off', description: 'Disabled (default)' },
|
||||
// ] as const;
|
||||
|
||||
const _ortWebSearchOptions = [
|
||||
{ value: 'auto', label: 'On', description: 'Enable web search (native for OpenAI/Anthropic, Exa for others)' },
|
||||
{ value: _UNSPECIFIED, label: 'Off', description: 'Disabled (default)' },
|
||||
@@ -164,6 +169,7 @@ export function LLMParametersEditor(props: {
|
||||
llmVndGeminiGoogleSearch,
|
||||
llmVndGeminiShowThoughts,
|
||||
llmVndGeminiThinkingBudget,
|
||||
// llmVndMoonshotWebSearch,
|
||||
llmVndOaiReasoningEffort,
|
||||
llmVndOaiReasoningEffort4,
|
||||
llmVndOaiRestoreMarkdown,
|
||||
@@ -397,6 +403,20 @@ export function LLMParametersEditor(props: {
|
||||
/>
|
||||
)}
|
||||
|
||||
|
||||
{/*{showParam('llmVndMoonshotWebSearch') && (*/}
|
||||
{/* <FormSelectControl*/}
|
||||
{/* title='Web Search'*/}
|
||||
{/* tooltip='Enable Kimi $web_search builtin function for real-time web search. Costs $0.005 per search. Use kimi-k2-turbo-preview for dynamic context handling.'*/}
|
||||
{/* value={llmVndMoonshotWebSearch ?? _UNSPECIFIED}*/}
|
||||
{/* onChange={(value) => {*/}
|
||||
{/* if (value === _UNSPECIFIED || !value) onRemoveParameter('llmVndMoonshotWebSearch');*/}
|
||||
{/* else onChangeParameter({ llmVndMoonshotWebSearch: value });*/}
|
||||
{/* }}*/}
|
||||
{/* options={_moonshotWebSearchOptions}*/}
|
||||
{/* />*/}
|
||||
{/*)}*/}
|
||||
|
||||
{showParam('llmVndPerplexitySearchMode') && (
|
||||
<FormSelectControl
|
||||
title='Search Mode'
|
||||
|
||||
@@ -87,6 +87,7 @@ const ModelParameterSpec_schema = z.object({
|
||||
'llmVndGeminiGoogleSearch',
|
||||
'llmVndGeminiShowThoughts',
|
||||
'llmVndGeminiThinkingBudget',
|
||||
'llmVndMoonshotWebSearch',
|
||||
'llmVndOaiReasoningEffort',
|
||||
'llmVndOaiReasoningEffort4',
|
||||
'llmVndOaiRestoreMarkdown',
|
||||
|
||||
Reference in New Issue
Block a user