Skip to content

Commit

Permalink
Chat AI: change utility model
Browse files Browse the repository at this point in the history
  • Loading branch information
enricoros committed Feb 12, 2025
1 parent b393469 commit 5928c84
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions src/apps/settings-modal/AppChatSettingsAI.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,20 @@ import { ExternalLink } from '~/common/components/ExternalLink';
import { FormLabelStart } from '~/common/components/forms/FormLabelStart';
import { GoodTooltip } from '~/common/components/GoodTooltip';

import { llmsStoreActions } from '~/common/stores/llms/store-llms';
import { useDefaultLLMIDs } from '~/common/stores/llms/llms.hooks';
import { useLLMSelect } from '~/common/components/forms/useLLMSelect';

import { useChatAutoAI } from '../chat/store-app-chat';


export function AppChatSettingsAI() {

// external state
const { fastLLMId } = useDefaultLLMIDs();
const { setFastLLMId } = llmsStoreActions();
const [_llm, llmComponent] = useLLMSelect(fastLLMId, setFastLLMId, '', true);

const {
autoSuggestAttachmentPrompts, setAutoSuggestAttachmentPrompts,
autoSuggestDiagrams, setAutoSuggestDiagrams,
Expand All @@ -36,6 +44,25 @@ export function AppChatSettingsAI() {

return <>

<FormControl orientation='horizontal' sx={{ justifyContent: 'space-between' }}>
<FormLabelStart
title='Utility Model'
description='Fast, see info'
tooltip={<>
Lightweight model used for &quot;fast&quot;, low-cost operations, such as:
<ul>
<li>Chat title generation</li>
<li>Attachment prompts</li>
<li>Diagrams generation</li>
<li>Drawing prompts</li>
<li>And more</li>
</ul>
For chat messages and similar high-quality content, the chat model is used instead.
</>}
/>
{llmComponent}
</FormControl>

<FormControl orientation='horizontal' sx={{ justifyContent: 'space-between' }}>
<FormLabelStart title='Auto Chat Title'
description={autoTitleChat ? 'LLM Titling' : 'Manual only'} />
Expand Down

0 comments on commit 5928c84

Please sign in to comment.