mirror of
https://github.com/memohai/Memoh.git
synced 2026-04-27 07:16:19 +09:00
feat(web): redesign provider interface (#25)
This commit is contained in:
@@ -66,7 +66,7 @@ export type Model = EmbeddingModel | ChatModel
|
||||
|
||||
|
||||
// 表格当中model的类型
|
||||
export interface ModelTable {
|
||||
export interface ModelList {
|
||||
apiKey: string,
|
||||
baseUrl: string,
|
||||
clientType: 'OpenAI' | 'Anthropic' | 'Google',
|
||||
@@ -77,4 +77,24 @@ export interface ModelTable {
|
||||
defaultChatModel: boolean,
|
||||
defaultEmbeddingModel: boolean,
|
||||
defaultSummaryModel: boolean
|
||||
}
|
||||
}
|
||||
|
||||
export interface ProviderInfo{
|
||||
api_key: string;
|
||||
base_url: string;
|
||||
client_type: string;
|
||||
metadata: Record<'additionalProp1',object>;
|
||||
name: string;
|
||||
}
|
||||
|
||||
export interface ModelInfo{
|
||||
dimensions:number
|
||||
is_multimodal:boolean
|
||||
llm_provider_id:string
|
||||
model_id:string
|
||||
name:string
|
||||
type: string
|
||||
enable_as?:string
|
||||
}
|
||||
|
||||
export const clientType = ['openai', 'anthropic', 'google', 'ollama'] as const
|
||||
|
||||
Reference in New Issue
Block a user