Fix hugging face model description (#5105)
This commit is contained in:
1 parent
31cda0ce5e
commit
fb676add2e
1 file changed
+2
-1
@@ -46,6 +46,7 @@ export async function refreshHuggingFaceModels(
|
||||
|
||||
// Transform HF models to OpenRouter-compatible format
|
||||
for (const rawModel of rawModels) {
|
||||
const providersList = rawModel.providers?.map((provider: { provider: string }) => provider.provider)?.join(", ")
|
||||
const modelInfo = OpenRouterModelInfo.create({
|
||||
maxTokens: 8192, // HF doesn't provide max_tokens, use default
|
||||
contextWindow: 128_000, // FIXME: HF doesn't provide context window, use default
|
||||
@@ -55,7 +56,7 @@ export async function refreshHuggingFaceModels(
|
||||
outputPrice: 0, // Will be set based on providers
|
||||
cacheWritesPrice: 0,
|
||||
cacheReadsPrice: 0,
|
||||
description: `Available on providers: ${rawModel.providers?.join(", ") || "unknown"}`,
|
||||
description: `Available on providers: ${providersList || "unknown"}`,
|
||||
})
|
||||
|
||||
// Add model-specific configurations if we have them in our static models
|
||||
|
||||
Reference in new issue
Block a user