Pricing tab shows "No pricing overrides" but provides no UI to add custom model prices
#2175 aperta il 4 ago 2026
Metriche repository
- Star
- (1 stella)
- Metriche merge PR
- (Nessuna PR mergiata in 30 g)
Descrizione
Problem
The Usage → Pricing tab shows an empty state reading "No pricing overrides" with the body copy "Without pricing overrides, costs use the built-in model pricing table. Add custom prices here for specific models." However, the pricing panel is a read-only table with no UI to add, edit, or delete custom pricing overrides. The empty-state copy promises a capability the interface does not deliver.
The backend is fully implemented but the renderer cannot reach it:
- IPC handlers (
apps/desktop/src/main/usage-ipc-main.ts):usage:pricing:list,usage:pricing:put,usage:pricing:reset, and ausage:pricing:changedpush event are all registered. - Preload bridge (
apps/desktop/src/preload/preload.ts): Does not expose any pricing IPC methods — the renderer cannot call them. - Pricing panel (
apps/desktop/src/renderer/settings/usage-settings-page.tsx):UsagePricingPanelis a read-only table; there is no add/edit/delete form or action button.
Desired outcome
A user can:
- Add a custom pricing override for a specific model (entering
modelKey,inputUsdPer1M,outputUsdPer1M, and optionallycacheReadUsdPer1M/cacheWriteUsdPer1M). - Edit an existing pricing override.
- Delete a pricing override (revert to the built-in pricing table).
- See the panel refresh automatically after each mutation (the
usage:pricing:changedevent is already wired on the main-process side).
Alternatives or workarounds
None available today. Users cannot customize model prices through the UI. All costs are settled using the built-in model pricing table, with no override capability despite the backend infrastructure being fully in place.
How to reproduce
- Open Settings → Usage
- Click the "Pricing" tab
- Observe the empty state: "No pricing overrides" / "Without pricing overrides, costs use the built-in model pricing table. Add custom prices here for specific models."
- Notice there is no "Add" button, form, or any way to create a pricing override.
Environment
- Maka version or commit:
1b0137c1 - OS: All platforms
- Surface: Desktop
问题
使用统计 → 定价配置 tab 显示空状态"暂无定价覆盖配置",说明文字为"未配置定价覆盖时,费用按内置模型定价表结算;在此可为特定模型登记自定义价格。"但定价面板只是一个只读表格,没有任何添加、编辑或删除自定义价格的入口。空状态文案承诺了一个界面并未提供的能力。
后端已完整实现,但渲染进程无法调用:
- IPC 处理器(
apps/desktop/src/main/usage-ipc-main.ts):已注册usage:pricing:list、usage:pricing:put、usage:pricing:reset以及usage:pricing:changed推送事件。 - Preload bridge(
apps/desktop/src/preload/preload.ts):未暴露任何定价 IPC 方法——渲染进程无法调用。 - 定价面板(
apps/desktop/src/renderer/settings/usage-settings-page.tsx):UsagePricingPanel是只读表格,没有添加/编辑/删除表单或操作按钮。
期望结果
用户可以:
- 为特定模型添加自定义定价覆盖(输入
modelKey、inputUsdPer1M、outputUsdPer1M,可选cacheReadUsdPer1M/cacheWriteUsdPer1M)。 - 编辑已有的定价覆盖。
- 删除定价覆盖(恢复使用内置定价表)。
- 每次操作后面板自动刷新(
usage:pricing:changed事件已在主进程侧接好)。
替代方案
目前无任何替代方案。用户无法通过 UI 自定义模型价格,所有费用只能按内置定价表结算。
复现步骤
- 打开设置 → 使用统计
- 点击"定价配置"tab
- 观察空状态:"暂无定价覆盖配置" / "未配置定价覆盖时,费用按内置模型定价表结算;在此可为特定模型登记自定义价格。"
- 注意没有"添加"按钮、表单或任何创建定价覆盖的方式。
环境
- Maka 版本或 commit:
1b0137c1 - 操作系统:所有平台
- 界面:Desktop