Set default provider from constants
Browse files
app/components/chat/BaseChat.tsx
CHANGED
@@ -7,7 +7,7 @@ import { Menu } from '~/components/sidebar/Menu.client';
|
|
7 |
import { IconButton } from '~/components/ui/IconButton';
|
8 |
import { Workbench } from '~/components/workbench/Workbench.client';
|
9 |
import { classNames } from '~/utils/classNames';
|
10 |
-
import { MODEL_LIST } from '~/utils/constants';
|
11 |
import { Messages } from './Messages.client';
|
12 |
import { SendButton } from './SendButton.client';
|
13 |
import { useState } from 'react';
|
@@ -25,7 +25,7 @@ const EXAMPLE_PROMPTS = [
|
|
25 |
const providerList = [...new Set(MODEL_LIST.map((model) => model.provider))]
|
26 |
|
27 |
const ModelSelector = ({ model, setModel, modelList, providerList }) => {
|
28 |
-
const [provider, setProvider] = useState(
|
29 |
return (
|
30 |
<div className="mb-2">
|
31 |
<select
|
|
|
7 |
import { IconButton } from '~/components/ui/IconButton';
|
8 |
import { Workbench } from '~/components/workbench/Workbench.client';
|
9 |
import { classNames } from '~/utils/classNames';
|
10 |
+
import { MODEL_LIST, DEFAULT_PROVIDER } from '~/utils/constants';
|
11 |
import { Messages } from './Messages.client';
|
12 |
import { SendButton } from './SendButton.client';
|
13 |
import { useState } from 'react';
|
|
|
25 |
const providerList = [...new Set(MODEL_LIST.map((model) => model.provider))]
|
26 |
|
27 |
const ModelSelector = ({ model, setModel, modelList, providerList }) => {
|
28 |
+
const [provider, setProvider] = useState(DEFAULT_PROVIDER);
|
29 |
return (
|
30 |
<div className="mb-2">
|
31 |
<select
|