realLoganLuo/dsh-session-cost--packages-ui-session-cost ↗★ 1
@logan-luo/dsh-client-ui-session-cost
Session-cost surfaces: dock cost strip, cost view tab, and the usage dashboard over the cost Remote
AI 분석
核心用途是在 Web UI 中直观展示当前会话的预估花费、模型费率和历史趋势。适合需要实时监控 API 消费额度的用户。需配合后台账本服务运行。
설치
검증된 bundle이 없거나 호환성 검사에 실패했습니다. 먼저 저장소 설명을 읽어 주세요. 전체 README 읽기 ↗
@logan-luo/dsh-client-ui-session-cost
English | 中文
Session cost surfaces, browser half: the dock cost strip, the per-session cost view tab, and the usage dashboard. The pricing, projection, and ledger live in @logan-luo/dsh-session-cost.
Shipped surfaces
- Dock cost strip (
src/client/CostDockRow.tsx): the secondconversation.composer.dockrow under the built-in stats line — estimated cost, the dominant model's current rate, and an unpriced count. ReadsuseProjection('costStats'). - Cost view tab (
src/client/CostViewTab.tsx): aconversation.viewtab with totals, per-model rows, per-day trend, and the rate versions that produced the figures. - Usage dashboard (
src/client/DashboardTrigger.tsx): asidebar.footer.actionentry opening the global usage dialog — project / time-range (today, week, month, all) / grouping (day, week, month, model, project) selection over thecost.dashboardRemote, with totals, per-model buckets, and groups. TheDashboardController(src/client/controller.ts) owns the view state and the refresh/selection verbs.
Model Experience
None: the package renders host-computed projection values and Remote rollups; it assembles no model request.
KV Cache effect
None; the package neither assembles nor sends a provider request.
Known Limitations and Deferred Work
- Time-range presets are calendarized in the same fixed Beijing offset as the rate card; a named timezone stays a deferred config option shared with the node half.
- The dashboard's project list is the distinct set of ledger projects; project renames on disk split history into two rows.