mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-19 18:00:15 +01:00
Build/Refactor: lint pre-commit hook and reformat repo to spec (#314)
* build/refactor: move lint/prettier packages to project root, install husky, add pre-commit hook * refactor: reformat files * build: put full eslintrc back with all rules
This commit is contained in:
parent
8d75b25104
commit
7fdc862042
157 changed files with 4836 additions and 2403 deletions
|
|
@ -33,11 +33,13 @@ const buildDefaultConversation = ({
|
|||
'chat-bison',
|
||||
modelLabel: lastConversationSetup?.modelLabel ?? null,
|
||||
promptPrefix: lastConversationSetup?.promptPrefix ?? null,
|
||||
examples: lastConversationSetup?.examples ?? [{ input: { content: '' }, output: { content: '' }}],
|
||||
examples: lastConversationSetup?.examples ?? [
|
||||
{ input: { content: '' }, output: { content: '' } }
|
||||
],
|
||||
temperature: lastConversationSetup?.temperature ?? 0.2,
|
||||
maxOutputTokens: lastConversationSetup?.maxOutputTokens ?? 1024,
|
||||
topP: lastConversationSetup?.topP ?? 0.95,
|
||||
topK: lastConversationSetup?.topK ?? 40,
|
||||
topK: lastConversationSetup?.topK ?? 40
|
||||
};
|
||||
} else if (endpoint === 'bingAI') {
|
||||
conversation = {
|
||||
|
|
@ -125,7 +127,9 @@ const getDefaultConversation = ({ conversation, prevConversation, endpointsConfi
|
|||
|
||||
// if anything happens, reset to default model
|
||||
|
||||
const endpoint = ['openAI', 'azureOpenAI', 'bingAI', 'chatGPTBrowser', 'google'].find(e => endpointsConfig?.[e]);
|
||||
const endpoint = ['openAI', 'azureOpenAI', 'bingAI', 'chatGPTBrowser', 'google'].find(
|
||||
e => endpointsConfig?.[e]
|
||||
);
|
||||
if (endpoint) {
|
||||
conversation = buildDefaultConversation({ conversation, endpoint, endpointsConfig });
|
||||
return conversation;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue