mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-01-12 02:58:34 +08:00
chore: remove dead code and consolidate duplicate types (#555)
- Delete unused files: lib/ai-config.ts, components/ui/card.tsx, lib/token-counter.ts - Remove js-tiktoken dependency (only used by deleted token-counter.ts) - Consolidate ProviderName type: add "ollama" to model-config.ts, import in ai-providers.ts - Consolidate DiagramOperation type: keep in chat/types.ts, import in utils.ts and hook
This commit is contained in:
@@ -6,6 +6,7 @@ export type ProviderName =
|
||||
| "google"
|
||||
| "azure"
|
||||
| "bedrock"
|
||||
| "ollama"
|
||||
| "openrouter"
|
||||
| "deepseek"
|
||||
| "siliconflow"
|
||||
@@ -76,6 +77,10 @@ export const PROVIDER_INFO: Record<
|
||||
google: { label: "Google" },
|
||||
azure: { label: "Azure OpenAI" },
|
||||
bedrock: { label: "Amazon Bedrock" },
|
||||
ollama: {
|
||||
label: "Ollama",
|
||||
defaultBaseUrl: "http://localhost:11434",
|
||||
},
|
||||
openrouter: { label: "OpenRouter" },
|
||||
deepseek: { label: "DeepSeek" },
|
||||
siliconflow: {
|
||||
@@ -99,7 +104,7 @@ export const PROVIDER_INFO: Record<
|
||||
}
|
||||
|
||||
// Suggested models per provider for quick add
|
||||
export const SUGGESTED_MODELS: Record<ProviderName, string[]> = {
|
||||
export const SUGGESTED_MODELS: Partial<Record<ProviderName, string[]>> = {
|
||||
openai: [
|
||||
"gpt-5.2-pro",
|
||||
"gpt-5.2-chat-latest",
|
||||
|
||||
Reference in New Issue
Block a user