MCPcopy Create free account
hub / github.com/ChatLab/ChatLab / getDefaultGeneralAssistantId

Function getDefaultGeneralAssistantId

src/stores/aiChat.ts:203–207  ·  view source on GitHub ↗

* 创建对话时前端已经知道 locale,因此默认助手在这里选择即可。

(locale: string)

Source from the content-addressed store, hash-verified

201 * 创建对话时前端已经知道 locale,因此默认助手在这里选择即可。
202 */
203function getDefaultGeneralAssistantId(locale: string): 'general_cn' | 'general_en' | 'general_ja' {
204 if (locale.startsWith('en')) return 'general_en'
205 if (locale.startsWith('ja')) return 'general_ja'
206 return 'general_cn'
207}
208
209function buildTimeFilterKey(timeFilter?: { startTs: number; endTs: number }): string {
210 if (!timeFilter) return 'all'

Callers 3

resetToSelectorOnEnterFunction · 0.70
sendMessageFunction · 0.70
editCurrentRoundOnlyFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected