From 414fad13ed10d0f381212b485cd71cd6621ff5f1 Mon Sep 17 00:00:00 2001 From: kwaroran Date: Mon, 8 Jan 2024 09:14:28 +0900 Subject: [PATCH] Update price calculation in openRouterModels function --- src/ts/model/openrouter.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ts/model/openrouter.ts b/src/ts/model/openrouter.ts index 860b3694..be1cbce4 100644 --- a/src/ts/model/openrouter.ts +++ b/src/ts/model/openrouter.ts @@ -15,7 +15,7 @@ export async function openRouterModels() { const res = await (await aim).json() return res.data.map((model: any) => { let name = model.name - let price = model.pricing.prompt + let price = ((model.pricing.prompt * 3) + model.pricing.completion) / 4 if(price > 0){ name += ` - $${(price*1000).toFixed(5)}/1k` }