mirror of
https://github.com/QuantumNous/new-api.git
synced 2026-03-30 17:25:02 +00:00
Compare commits
5 Commits
v0.2.3.0
...
v0.2.3.4.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f07ae8139b | ||
|
|
d860289601 | ||
|
|
cf8fe63fb6 | ||
|
|
1568d6481a | ||
|
|
d05a786b4c |
@@ -325,6 +325,9 @@ const LogsTable = () => {
|
||||
title: '详情',
|
||||
dataIndex: 'content',
|
||||
render: (text, record, index) => {
|
||||
if (record.other === '') {
|
||||
record.other = '{}'
|
||||
}
|
||||
let other = JSON.parse(record.other);
|
||||
if (other == null) {
|
||||
return (
|
||||
|
||||
@@ -146,10 +146,11 @@ const ModelPricing = () => {
|
||||
render: (text, record, index) => {
|
||||
let content = text;
|
||||
if (record.quota_type === 0) {
|
||||
let inputRatioPrice = record.model_ratio * record.group_ratio;
|
||||
// 这里的 *2 是因为 1倍率=0.002刀,请勿删除
|
||||
let inputRatioPrice = record.model_ratio * 2 * record.group_ratio;
|
||||
let completionRatioPrice =
|
||||
record.model_ratio *
|
||||
record.completion_ratio *
|
||||
record.completion_ratio * 2 *
|
||||
record.group_ratio;
|
||||
content = (
|
||||
<>
|
||||
|
||||
@@ -149,8 +149,9 @@ export function renderModelPrice(
|
||||
if (completionRatio === undefined) {
|
||||
completionRatio = 0;
|
||||
}
|
||||
// 这里的 *2 是因为 1倍率=0.002刀,请勿删除
|
||||
let inputRatioPrice = modelRatio * 2.0 * groupRatio;
|
||||
let completionRatioPrice = modelRatio * completionRatio * 2.0 * groupRatio;
|
||||
let completionRatioPrice = modelRatio * 2.0 * completionRatio * groupRatio;
|
||||
let price =
|
||||
(inputTokens / 1000000) * inputRatioPrice +
|
||||
(completionTokens / 1000000) * completionRatioPrice;
|
||||
|
||||
Reference in New Issue
Block a user