This commit is contained in:
timothycarambat 2025-04-15 12:51:08 -07:00
parent be27299897
commit 1d1fb817b0

View File

@ -152,9 +152,9 @@ class OpenRouterLLM {
const cacheModelPath = path.resolve(cacheFolder, "models.json");
const availableModels = fs.existsSync(cacheModelPath)
? safeJsonParse(
fs.readFileSync(cacheModelPath, { encoding: "utf-8" }),
{}
)
fs.readFileSync(cacheModelPath, { encoding: "utf-8" }),
{}
)
: {};
return availableModels[modelName]?.maxLength || 4096;
}