Explorar el Código

feat(ui): add option to hide cost below threshold (#1652)

* feat(settings): add cost threshold setting

Introduces a new setting to hide API request costs below a configurable threshold. This feature declutters the chat interface by only displaying costs that meet or exceed the specified value, improving readability for users who are not focused on granular cost tracking.

The changes include:
- Adding the `hideCostBelowThreshold` option to global settings and schema.
- Implementing the logic in `ClineProvider` and `webviewMessageHandler` to manage the setting.
- Updating the webview UI to include a slider for configuring the threshold in `DisplaySettings.tsx`.
- Modifying `ChatRow.tsx` to conditionally display costs based on the new threshold.
- Adding state management for the new setting in `ExtensionStateContext.tsx`.
- Updating internationalization files across multiple languages to support the new setting.

* Default hideCostBelowThreshold to 0

---------

Co-authored-by: Chris Hasson <[email protected]>
Chris Hasson hace 4 meses
padre
commit
b3caf38e44
Se han modificado 32 ficheros con 183 adiciones y 3 borrados
  1. 5 0
      .changeset/twenty-apes-write.md
  2. 1 0
      packages/types/src/global-settings.ts
  3. 3 0
      src/core/webview/ClineProvider.ts
  4. 4 0
      src/core/webview/webviewMessageHandler.ts
  5. 2 0
      src/shared/ExtensionMessage.ts
  6. 1 0
      src/shared/WebviewMessage.ts
  7. 11 1
      webview-ui/src/components/chat/ChatRow.tsx
  8. 38 1
      webview-ui/src/components/settings/DisplaySettings.tsx
  9. 3 0
      webview-ui/src/components/settings/SettingsView.tsx
  10. 5 1
      webview-ui/src/context/ExtensionStateContext.tsx
  11. 5 0
      webview-ui/src/i18n/locales/ar/settings.json
  12. 5 0
      webview-ui/src/i18n/locales/ca/settings.json
  13. 5 0
      webview-ui/src/i18n/locales/cs/settings.json
  14. 5 0
      webview-ui/src/i18n/locales/de/settings.json
  15. 5 0
      webview-ui/src/i18n/locales/en/settings.json
  16. 5 0
      webview-ui/src/i18n/locales/es/settings.json
  17. 5 0
      webview-ui/src/i18n/locales/fr/settings.json
  18. 5 0
      webview-ui/src/i18n/locales/hi/settings.json
  19. 5 0
      webview-ui/src/i18n/locales/id/settings.json
  20. 5 0
      webview-ui/src/i18n/locales/it/settings.json
  21. 5 0
      webview-ui/src/i18n/locales/ja/settings.json
  22. 5 0
      webview-ui/src/i18n/locales/ko/settings.json
  23. 5 0
      webview-ui/src/i18n/locales/nl/settings.json
  24. 5 0
      webview-ui/src/i18n/locales/pl/settings.json
  25. 5 0
      webview-ui/src/i18n/locales/pt-BR/settings.json
  26. 5 0
      webview-ui/src/i18n/locales/ru/settings.json
  27. 5 0
      webview-ui/src/i18n/locales/th/settings.json
  28. 5 0
      webview-ui/src/i18n/locales/tr/settings.json
  29. 5 0
      webview-ui/src/i18n/locales/uk/settings.json
  30. 5 0
      webview-ui/src/i18n/locales/vi/settings.json
  31. 5 0
      webview-ui/src/i18n/locales/zh-CN/settings.json
  32. 5 0
      webview-ui/src/i18n/locales/zh-TW/settings.json

+ 5 - 0
.changeset/twenty-apes-write.md

@@ -0,0 +1,5 @@
+---
+"kilo-code": minor
+---
+
+Add a display setting that hides costs below a user-defined threshold

+ 1 - 0
packages/types/src/global-settings.ts

@@ -96,6 +96,7 @@ export const globalSettingsSchema = z.object({
 	browserViewportSize: z.string().optional(),
 	showAutoApproveMenu: z.boolean().optional(), // kilocode_change
 	showTaskTimeline: z.boolean().optional(), // kilocode_change
+	hideCostBelowThreshold: z.number().min(0).optional(), // kilocode_change
 	localWorkflowToggles: z.record(z.string(), z.boolean()).optional(), // kilocode_change
 	globalWorkflowToggles: z.record(z.string(), z.boolean()).optional(), // kilocode_change
 	localRulesToggles: z.record(z.string(), z.boolean()).optional(), // kilocode_change

+ 3 - 0
src/core/webview/ClineProvider.ts

@@ -1866,6 +1866,7 @@ export class ClineProvider
 			language,
 			showAutoApproveMenu, // kilocode_change
 			showTaskTimeline, // kilocode_change
+			hideCostBelowThreshold, // kilocode_change
 			maxReadFileLine,
 			maxImageFileSize,
 			maxTotalImageSize,
@@ -2020,6 +2021,7 @@ export class ClineProvider
 			showRooIgnoredFiles: showRooIgnoredFiles ?? false,
 			showAutoApproveMenu: showAutoApproveMenu ?? false, // kilocode_change
 			showTaskTimeline: showTaskTimeline ?? true, // kilocode_change
+			hideCostBelowThreshold, // kilocode_change
 			language, // kilocode_change
 			renderContext: this.renderContext,
 			maxReadFileLine: maxReadFileLine ?? -1,
@@ -2273,6 +2275,7 @@ export class ClineProvider
 			showRooIgnoredFiles: stateValues.showRooIgnoredFiles ?? false,
 			showAutoApproveMenu: stateValues.showAutoApproveMenu ?? false, // kilocode_change
 			showTaskTimeline: stateValues.showTaskTimeline ?? true, // kilocode_change
+			hideCostBelowThreshold: stateValues.hideCostBelowThreshold ?? 0, // kilocode_change
 			maxReadFileLine: stateValues.maxReadFileLine ?? -1,
 			maxImageFileSize: stateValues.maxImageFileSize ?? 5,
 			maxTotalImageSize: stateValues.maxTotalImageSize ?? 20,

+ 4 - 0
src/core/webview/webviewMessageHandler.ts

@@ -1730,6 +1730,10 @@ export const webviewMessageHandler = async (
 			await updateGlobalState("showTaskTimeline", message.bool ?? false)
 			await provider.postStateToWebview()
 			break
+		case "hideCostBelowThreshold":
+			await updateGlobalState("hideCostBelowThreshold", message.value)
+			await provider.postStateToWebview()
+			break
 		case "allowVeryLargeReads":
 			await updateGlobalState("allowVeryLargeReads", message.bool ?? false)
 			await provider.postStateToWebview()

+ 2 - 0
src/shared/ExtensionMessage.ts

@@ -301,6 +301,7 @@ export type ExtensionState = Pick<
 	| "browserToolEnabled"
 	| "browserViewportSize"
 	| "showAutoApproveMenu" // kilocode_change
+	| "hideCostBelowThreshold" // kilocode_change
 	| "screenshotQuality"
 	| "remoteBrowserEnabled"
 	| "cachedChromeHostUrl"
@@ -409,6 +410,7 @@ export type ExtensionState = Pick<
 	settingsImportedAt?: number
 	historyPreviewCollapsed?: boolean
 	showTaskTimeline?: boolean // kilocode_change
+	hideCostBelowThreshold?: number // kilocode_change
 
 	cloudUserInfo: CloudUserInfo | null
 	cloudIsAuthenticated: boolean

+ 1 - 0
src/shared/WebviewMessage.ts

@@ -242,6 +242,7 @@ export interface WebviewMessage {
 		| "getUsageData" // kilocode_change
 		| "usageDataResponse" // kilocode_change
 		| "showTaskTimeline" // kilocode_change
+		| "hideCostBelowThreshold" // kilocode_change
 		| "toggleTaskFavorite" // kilocode_change
 		| "fixMermaidSyntax" // kilocode_change
 		| "mermaidFixResponse" // kilocode_change

+ 11 - 1
webview-ui/src/components/chat/ChatRow.tsx

@@ -169,6 +169,16 @@ export const ChatRowContent = ({
 		return [undefined, undefined, undefined]
 	}, [message.text, message.say])
 
+	// kilocode_change start: hide cost display check
+	const { hideCostBelowThreshold } = useExtensionState()
+	const shouldShowCost = useMemo(() => {
+		if (cost === undefined || cost === null || cost <= 0) return false
+		if (isExpanded) return true
+		const threshold = hideCostBelowThreshold ?? 0
+		return cost >= threshold
+	}, [cost, isExpanded, hideCostBelowThreshold])
+	// kilocode_change end: hide cost display check
+
 	// When resuming task, last wont be api_req_failed but a resume_task
 	// message, so api_req_started will show loading spinner. That's why we just
 	// remove the last api_req_started that failed without streaming anything.
@@ -1058,7 +1068,7 @@ export const ChatRowContent = ({
 								</div>
 								<div
 									className="text-xs text-vscode-dropdown-foreground border-vscode-dropdown-border/50 border px-1.5 py-0.5 rounded-lg"
-									style={{ opacity: cost !== null && cost !== undefined && cost > 0 ? 1 : 0 }}>
+									style={{ opacity: shouldShowCost ? 1 : 0 }}>
 									${Number(cost || 0)?.toFixed(4)}
 								</div>
 								{

+ 38 - 1
webview-ui/src/components/settings/DisplaySettings.tsx

@@ -1,3 +1,4 @@
+// kilocode_change - new file
 import { HTMLAttributes, useMemo, useState } from "react"
 import { useAppTranslation } from "@/i18n/TranslationContext"
 import { VSCodeCheckbox } from "@vscode/webview-ui-toolkit/react"
@@ -9,12 +10,16 @@ import { SectionHeader } from "./SectionHeader"
 import { Section } from "./Section"
 import { TaskTimeline } from "../chat/TaskTimeline"
 import { generateSampleTimelineData } from "../../utils/timeline/mockData"
+import { Slider } from "../ui"
 
 type DisplaySettingsProps = HTMLAttributes<HTMLDivElement> & {
 	showTaskTimeline?: boolean
 	ghostServiceSettings?: any
 	reasoningBlockCollapsed: boolean
-	setCachedStateField: SetCachedStateField<"showTaskTimeline" | "ghostServiceSettings" | "reasoningBlockCollapsed">
+	setCachedStateField: SetCachedStateField<
+		"showTaskTimeline" | "ghostServiceSettings" | "reasoningBlockCollapsed" | "hideCostBelowThreshold"
+	>
+	hideCostBelowThreshold?: number
 }
 
 export const DisplaySettings = ({
@@ -22,6 +27,7 @@ export const DisplaySettings = ({
 	ghostServiceSettings,
 	setCachedStateField,
 	reasoningBlockCollapsed,
+	hideCostBelowThreshold,
 	...props
 }: DisplaySettingsProps) => {
 	const { t } = useAppTranslation()
@@ -120,6 +126,37 @@ export const DisplaySettings = ({
 					</div>
 				</div>
 			</Section>
+
+			<Section>
+				<div>
+					<div className="font-medium">{t("settings:display.costThreshold.label")}</div>
+					<div className="text-vscode-descriptionForeground text-sm mt-1">
+						{t("settings:display.costThreshold.description")}
+					</div>
+
+					<div className="mt-3">
+						<div className="flex items-center gap-2">
+							<Slider
+								min={0}
+								max={1}
+								step={0.01}
+								value={[hideCostBelowThreshold ?? 0]}
+								onValueChange={([value]) => setCachedStateField("hideCostBelowThreshold", value)}
+								data-testid="cost-threshold-slider"
+								className="flex-1"
+							/>
+							<span className="text-sm text-vscode-foreground min-w-[60px]">
+								${(hideCostBelowThreshold ?? 0).toFixed(2)}
+							</span>
+						</div>
+						<div className="text-xs text-vscode-descriptionForeground mt-1">
+							{t("settings:display.costThreshold.currentValue", {
+								value: (hideCostBelowThreshold ?? 0).toFixed(2),
+							})}
+						</div>
+					</div>
+				</div>
+			</Section>
 		</div>
 	)
 }

+ 3 - 0
webview-ui/src/components/settings/SettingsView.tsx

@@ -210,6 +210,7 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
 		maxReadFileLine,
 		showAutoApproveMenu, // kilocode_change
 		showTaskTimeline, // kilocode_change
+		hideCostBelowThreshold, // kilocode_change
 		maxImageFileSize,
 		maxTotalImageSize,
 		terminalCompressProgressBar,
@@ -439,6 +440,7 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
 			vscode.postMessage({ type: "alwaysAllowModeSwitch", bool: alwaysAllowModeSwitch })
 			vscode.postMessage({ type: "alwaysAllowSubtasks", bool: alwaysAllowSubtasks })
 			vscode.postMessage({ type: "showTaskTimeline", bool: showTaskTimeline }) // kilocode_change
+			vscode.postMessage({ type: "hideCostBelowThreshold", value: hideCostBelowThreshold }) // kilocode_change
 			vscode.postMessage({ type: "alwaysAllowFollowupQuestions", bool: alwaysAllowFollowupQuestions })
 			vscode.postMessage({ type: "alwaysAllowUpdateTodoList", bool: alwaysAllowUpdateTodoList })
 			vscode.postMessage({ type: "followupAutoApproveTimeoutMs", value: followupAutoApproveTimeoutMs })
@@ -828,6 +830,7 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
 							reasoningBlockCollapsed={reasoningBlockCollapsed ?? true}
 							showTaskTimeline={showTaskTimeline}
 							ghostServiceSettings={ghostServiceSettings}
+							hideCostBelowThreshold={hideCostBelowThreshold}
 							setCachedStateField={setCachedStateField}
 						/>
 					)}

+ 5 - 1
webview-ui/src/context/ExtensionStateContext.tsx

@@ -30,9 +30,11 @@ import { convertTextMateToHljs } from "@src/utils/textMateToHljs"
 import { ClineRulesToggles } from "@roo/cline-rules" // kilocode_change
 
 export interface ExtensionStateContextType extends ExtensionState {
-	historyPreviewCollapsed?: boolean // Add the new state property
+	historyPreviewCollapsed?: boolean
 	showTaskTimeline?: boolean // kilocode_change
 	setShowTaskTimeline: (value: boolean) => void // kilocode_change
+	hideCostBelowThreshold?: number // kilocode_change
+	setHideCostBelowThreshold: (value: number) => void // kilocode_change
 	hoveringTaskTimeline?: boolean // kilocode_change
 	setHoveringTaskTimeline: (value: boolean) => void // kilocode_change
 	systemNotificationsEnabled?: boolean // kilocode_change
@@ -582,6 +584,8 @@ export const ExtensionStateContextProvider: React.FC<{ children: React.ReactNode
 			setState((prevState) => ({ ...prevState, commitMessageApiConfigId: value })),
 		setShowAutoApproveMenu: (value) => setState((prevState) => ({ ...prevState, showAutoApproveMenu: value })),
 		setShowTaskTimeline: (value) => setState((prevState) => ({ ...prevState, showTaskTimeline: value })),
+		setHideCostBelowThreshold: (value) =>
+			setState((prevState) => ({ ...prevState, hideCostBelowThreshold: value })),
 		setHoveringTaskTimeline: (value) => setState((prevState) => ({ ...prevState, hoveringTaskTimeline: value })),
 		// kilocode_change end
 		setAutoApprovalEnabled: (value) => setState((prevState) => ({ ...prevState, autoApprovalEnabled: value })),

+ 5 - 0
webview-ui/src/i18n/locales/ar/settings.json

@@ -599,6 +599,11 @@
 		"taskTimeline": {
 			"label": "إظهار خط الزمن للمهمة",
 			"description": "يعرض مخطط زمني ملون لرسائل المهمة لتتبع التقدّم بسرعة."
+		},
+		"costThreshold": {
+			"label": "إخفاء التكلفة أقل من الحد الأدنى",
+			"currentValue": "الحد الحالي: ${{value}}",
+			"description": "إظهار تكاليف الطلب فقط عندما تتجاوز هذا المبلغ. التكاليف تكون مرئية دائمًا عندما تكون لوحة التفاصيل مفتوحة."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/ca/settings.json

@@ -923,6 +923,11 @@
 		"taskTimeline": {
 			"label": "Mostra la línia temporal de la tasca",
 			"description": "Mostra una línia de temps visual dels missatges de tasques, acolorida per tipus, que et permet veure ràpidament el progrés de la tasca i desplaçar-te cap enrere a punts específics de l'historial de la tasca."
+		},
+		"costThreshold": {
+			"label": "Amaga el cost per sota del llindar",
+			"description": "Mostra només els costos de sol·licituds superiors a aquesta quantitat. Els costos sempre són visibles quan el panell de detalls està obert.",
+			"currentValue": "Llindar actual: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/cs/settings.json

@@ -599,6 +599,11 @@
 		"taskTimeline": {
 			"label": "Zobrazit časovou osu úkolu",
 			"description": "Zobrazit vizuální časovou osu zpráv úkolu, barevně odlišenou podle typu, což vám umožní rychle zobrazit průběh úkolu a posunout se zpět na konkrétní body v historii úkolu."
+		},
+		"costThreshold": {
+			"label": "Skrýt cenu pod prahem",
+			"currentValue": "Aktuální práh: ${{value}}",
+			"description": "Zobrazovat pouze náklady na požadavky převyšující tuto částku. Náklady jsou vždy viditelné, když je panel podrobností otevřený."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/de/settings.json

@@ -919,6 +919,11 @@
 		"taskTimeline": {
 			"label": "Aufgabenzeitplan anzeigen",
 			"description": "Zeigt eine visuelle Zeitleiste der Aufgabennachrichten an, farblich nach Typ gekennzeichnet, sodass du den Fortschritt der Aufgabe schnell überblicken und zu bestimmten Punkten in der Aufgabenhistorie zurückspringen kannst."
+		},
+		"costThreshold": {
+			"label": "Kosten unter Schwellenwert ausblenden",
+			"description": "Nur Anforderungskosten über diesem Betrag anzeigen. Kosten sind immer sichtbar, wenn der Detailbereich geöffnet ist.",
+			"currentValue": "Aktueller Schwellenwert: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/en/settings.json

@@ -558,6 +558,11 @@
 		"taskTimeline": {
 			"label": "Show task timeline",
 			"description": "Display a visual timeline of task messages, colorized by type, allowing you to quickly view task progress and scroll back to specific points in the task's history."
+		},
+		"costThreshold": {
+			"label": "Hide cost below threshold",
+			"description": "Only show request costs above this amount. Costs are always visible when the details pane is open.",
+			"currentValue": "Current threshold: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/es/settings.json

@@ -923,6 +923,11 @@
 		"taskTimeline": {
 			"label": "Mostrar cronología de tareas",
 			"description": "Muestra una línea de tiempo visual de los mensajes de tareas, colorizados por tipo, permitiéndote ver rápidamente el progreso de la tarea y desplazarte hacia atrás hasta puntos específicos en el historial de la tarea."
+		},
+		"costThreshold": {
+			"label": "Ocultar costo por debajo del umbral",
+			"description": "Solo mostrar los costos de solicitud superiores a este monto. Los costos siempre son visibles cuando el panel de detalles está abierto.",
+			"currentValue": "Umbral actual: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/fr/settings.json

@@ -923,6 +923,11 @@
 		"taskTimeline": {
 			"label": "Afficher la chronologie des tâches",
 			"description": "Afficher une chronologie visuelle des messages de tâches, colorés selon leur type, permettant de voir rapidement la progression des tâches et de revenir à des points spécifiques dans l'historique de la tâche."
+		},
+		"costThreshold": {
+			"label": "Masquer le coût en dessous du seuil",
+			"currentValue": "Seuil actuel : ${{value}}",
+			"description": "N'afficher que les coûts de requête supérieurs à ce montant. Les coûts sont toujours visibles lorsque le volet de détails est ouvert."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/hi/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "कार्य टाइमलाइन दिखाएँ",
 			"description": "कार्य संदेशों की एक दृश्य समयरेखा प्रदर्शित करें, जो प्रकार के अनुसार रंगीन हैं, जिससे आप कार्य की प्रगति को जल्दी से देख सकें और कार्य के इतिहास में विशिष्ट बिंदुओं पर वापस स्क्रॉल कर सकें।"
+		},
+		"costThreshold": {
+			"label": "थ्रेशोल्ड से नीचे की लागत छिपाएं",
+			"currentValue": "वर्तमान थ्रेशोल्ड: ${{value}}",
+			"description": "केवल इस राशि से अधिक के अनुरोध की लागतों को दिखाएं। जब विवरण पेन खुला होता है, तो लागतें हमेशा दिखाई देती हैं।"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/id/settings.json

@@ -945,6 +945,11 @@
 		"taskTimeline": {
 			"label": "Tampilkan linimasa tugas",
 			"description": "Tampilkan timeline visual dari pesan-pesan tugas, diwarnai berdasarkan jenisnya, memungkinkan Anda untuk melihat kemajuan tugas dengan cepat dan menggulir kembali ke titik-titik tertentu dalam riwayat tugas."
+		},
+		"costThreshold": {
+			"label": "Sembunyikan biaya di bawah ambang batas",
+			"currentValue": "Ambang batas saat ini: ${{value}}",
+			"description": "Hanya tampilkan biaya permintaan di atas jumlah ini. Biaya selalu terlihat saat panel detail terbuka."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/it/settings.json

@@ -925,6 +925,11 @@
 		"taskTimeline": {
 			"label": "Mostra cronologia attività",
 			"description": "Visualizza una cronologia visiva dei messaggi delle attività, colorati per tipologia, permettendoti di visualizzare rapidamente i progressi delle attività e scorrere indietro fino a punti specifici nella cronologia dell'attività."
+		},
+		"costThreshold": {
+			"label": "Nascondi costo sotto la soglia",
+			"currentValue": "Soglia attuale: ${{value}}",
+			"description": "Mostra solo i costi delle richieste superiori a questo importo. I costi sono sempre visibili quando il riquadro dei dettagli è aperto."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/ja/settings.json

@@ -925,6 +925,11 @@
 		"taskTimeline": {
 			"label": "タスクのタイムラインを表示",
 			"description": "タスクメッセージの視覚的なタイムラインを表示し、種類ごとに色分けすることで、タスクの進捗状況を素早く確認したり、タスク履歴の特定のポイントまでスクロールバックしたりすることができます。"
+		},
+		"costThreshold": {
+			"label": "しきい値以下のコストを非表示にする",
+			"currentValue": "現在のしきい値: ${{value}}",
+			"description": "この金額を超えるリクエストコストのみを表示します。詳細パネルが開いている場合、コストは常に表示されます。"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/ko/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "작업 타임라인 표시",
 			"description": "작업 메시지의 시각적 타임라인을 유형별로 색상화하여 표시하므로, 작업 진행 상황을 빠르게 확인하고 작업 기록의 특정 지점으로 스크롤하여 돌아갈 수 있습니다."
+		},
+		"costThreshold": {
+			"description": "해당 금액 이상의 요청비용만 표시합니다. 세부정보 창이 열려있을 때는 항상 비용이 표시됩니다.",
+			"label": "임계값 이하 비용 숨기기",
+			"currentValue": "현재 임계값: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/nl/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "Taaktijdlijn weergeven",
 			"description": "Toon een visuele tijdlijn van taakmeldingen, gekleurd per type, waardoor je snel de voortgang van taken kunt bekijken en terug kunt scrollen naar specifieke punten in de geschiedenis van de taak."
+		},
+		"costThreshold": {
+			"label": "Kosten onder drempel verbergen",
+			"currentValue": "Huidige drempelwaarde: ${{value}}",
+			"description": "Toon alleen aanvraagkosten hoger dan dit bedrag. Kosten zijn altijd zichtbaar wanneer het detailpaneel is geopend."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/pl/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "Pokaż oś czasu zadania",
 			"description": "Wyświetlaj wizualną oś czasu wiadomości zadania, oznaczoną kolorami według typu, co pozwala na szybki przegląd postępu zadania i przewijanie do określonych punktów w historii zadania."
+		},
+		"costThreshold": {
+			"currentValue": "Aktualny próg: ${{value}}",
+			"label": "Ukryj koszt poniżej progu",
+			"description": "Pokaż koszty zapytań tylko powyżej tej kwoty. Koszty są zawsze widoczne, gdy panel szczegółów jest otwarty."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/pt-BR/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "Mostrar linha do tempo da tarefa",
 			"description": "Exibe uma linha do tempo visual das mensagens de tarefas, coloridas por tipo, permitindo que você visualize rapidamente o progresso da tarefa e volte para pontos específicos no histórico da tarefa."
+		},
+		"costThreshold": {
+			"label": "Ocultar custo abaixo do limite",
+			"currentValue": "Limiar atual: ${{value}}",
+			"description": "Apenas mostrar custos de solicitação acima deste valor. Os custos estão sempre visíveis quando o painel de detalhes está aberto."
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/ru/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "Показать временную шкалу задачи",
 			"description": "Отображение визуальной временной шкалы сообщений задачи с цветовым разделением по типам, позволяющее быстро просматривать прогресс выполнения и перематывать к определенным моментам в истории задачи."
+		},
+		"costThreshold": {
+			"label": "Скрыть стоимость ниже порога",
+			"description": "Показывать только расходы на запросы выше этой суммы. Расходы всегда видны, когда открыта панель подробностей.",
+			"currentValue": "Текущее пороговое значение: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/th/settings.json

@@ -584,6 +584,11 @@
 		"taskTimeline": {
 			"label": "แสดงไทม์ไลน์ของงาน",
 			"description": "แสดงไทม์ไลน์ภาพของข้อความงาน โดยมีสีตามประเภท ช่วยให้คุณสามารถดูความคืบหน้าของงานได้อย่างรวดเร็วและเลื่อนกลับไปยังจุดเฉพาะในประวัติของงาน"
+		},
+		"costThreshold": {
+			"label": "ซ่อนต้นทุนที่ต่ำกว่าเกณฑ์",
+			"currentValue": "เกณฑ์ปัจจุบัน: ${{value}}",
+			"description": "แสดงค่าใช้จ่ายคำขอเฉพาะที่เกินกว่าจำนวนนี้ ค่าใช้จ่ายจะมองเห็นได้เสมอเมื่อเปิดบานหน้าต่างรายละเอียด"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/tr/settings.json

@@ -925,6 +925,11 @@
 		"taskTimeline": {
 			"description": "Görev mesajlarını türe göre renklendirilmiş görsel bir zaman çizelgesi olarak görüntüleyin, böylece görevin ilerlemesini hızlıca görebilir ve görevin geçmişindeki belirli noktalara geri dönmek için kaydırabilirsiniz.",
 			"label": "Görev zaman çizelgesini göster"
+		},
+		"costThreshold": {
+			"label": "Eşik değerin altındaki maliyeti gizle",
+			"description": "Sadece bu miktarın üzerindeki istek maliyetlerini göster. Ayrıntılar paneli açıkken maliyetler her zaman görünür.",
+			"currentValue": "Mevcut eşik: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/uk/settings.json

@@ -601,6 +601,11 @@
 		"taskTimeline": {
 			"label": "Показувати хронологію завдань",
 			"description": "Відображати візуальну хронологію повідомлень завдання, розфарбовану за типом, що дозволяє швидко переглядати хід виконання завдання та повертатися до певних моментів у історії завдання."
+		},
+		"costThreshold": {
+			"label": "Сховати вартість нижче порогового значення",
+			"currentValue": "Поточний поріг: ${{value}}",
+			"description": "Показувати лише витрати на запити, що перевищують цю суму. Витрати завжди видно, коли відкрита панель деталей."
 		}
 	},
 	"notifications": {

+ 5 - 0
webview-ui/src/i18n/locales/vi/settings.json

@@ -924,6 +924,11 @@
 		"taskTimeline": {
 			"label": "Hiển thị dòng thời gian công việc",
 			"description": "Hiển thị dòng thời gian trực quan của các tin nhắn công việc, được phân loại theo màu sắc theo từng loại, cho phép bạn nhanh chóng xem tiến độ công việc và cuộn lại các điểm cụ thể trong lịch sử của công việc."
+		},
+		"costThreshold": {
+			"label": "Ẩn chi phí dưới ngưỡng",
+			"description": "Chỉ hiển thị chi phí yêu cầu trên mức này. Chi phí luôn được hiển thị khi khung thông tin chi tiết được mở.",
+			"currentValue": "Ngưỡng hiện tại: ${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/zh-CN/settings.json

@@ -929,6 +929,11 @@
 		"taskTimeline": {
 			"label": "显示任务时间轴",
 			"description": "显示任务消息的可视化时间线,按类型进行颜色区分,让您能够快速查看任务进度并滚动回溯到任务历史中的特定节点。"
+		},
+		"costThreshold": {
+			"label": "隐藏低于阈值的费用",
+			"description": "仅显示超过此金额的请求成本。当详情面板打开时,成本始终可见。",
+			"currentValue": "当前阈值:${{value}}"
 		}
 	},
 	"ghost": {

+ 5 - 0
webview-ui/src/i18n/locales/zh-TW/settings.json

@@ -925,6 +925,11 @@
 		"taskTimeline": {
 			"label": "顯示任務時間軸",
 			"description": "顯示任務訊息的視覺化時間軸,按類型著色,讓您能夠快速查看任務進度並回滾到任務歷史中的特定節點。"
+		},
+		"costThreshold": {
+			"description": "仅显示超过此金额的请求费用。当详细信息面板打开时,费用始终可见。",
+			"label": "隐藏低于阈值的费用",
+			"currentValue": "当前阈值:${{value}}"
 		}
 	},
 	"ghost": {