mirror of
https://gitee.com/wanwujie/deer-flow
synced 2026-04-26 23:34:47 +08:00
feat(frontend): display token usage per conversation turn (#1229)
Surface the usage_metadata that PR #1218 added to the streaming API. A compact indicator in the chat header shows cumulative tokens consumed per thread, with a tooltip breakdown of input/output/total counts. Co-authored-by: Matt Van Horn <455140+mvanhorn@users.noreply.github.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
This commit is contained in:
@@ -274,6 +274,12 @@ export const enUS: Translations = {
|
||||
failed: "Subtask failed",
|
||||
},
|
||||
|
||||
// Token Usage
|
||||
tokenUsage: {
|
||||
title: "Token Usage",
|
||||
input: "Input",
|
||||
output: "Output",
|
||||
total: "Total",
|
||||
// Shortcuts
|
||||
shortcuts: {
|
||||
searchActions: "Search actions...",
|
||||
|
||||
@@ -211,6 +211,12 @@ export interface Translations {
|
||||
failed: string;
|
||||
};
|
||||
|
||||
// Token Usage
|
||||
tokenUsage: {
|
||||
title: string;
|
||||
input: string;
|
||||
output: string;
|
||||
total: string;
|
||||
// Shortcuts
|
||||
shortcuts: {
|
||||
searchActions: string;
|
||||
|
||||
@@ -261,6 +261,12 @@ export const zhCN: Translations = {
|
||||
failed: "子任务失败",
|
||||
},
|
||||
|
||||
// Token Usage
|
||||
tokenUsage: {
|
||||
title: "Token 用量",
|
||||
input: "输入",
|
||||
output: "输出",
|
||||
total: "总计",
|
||||
// Shortcuts
|
||||
shortcuts: {
|
||||
searchActions: "搜索操作...",
|
||||
|
||||
Reference in New Issue
Block a user