graff — a fast agentic coding harness in Zig: multi-provider, MCP, workflows, DGM evolution loop, TS/Python SDKs
Python
fix(gui): clean MCP tool names in the activity feed; smooth Ultra gradient (oklab)
Rach Pradhan2e316ab52616
diff --git a/gui/src/components/chat/utils/chatActivity.ts b/gui/src/components/chat/utils/chatActivity.tsindex 3123e0a9..e676ce25 100644--- a/gui/src/components/chat/utils/chatActivity.ts+++ b/gui/src/components/chat/utils/chatActivity.ts@@ -1,6 +1,20 @@import type { ActivityOperation } from "../types/chatThread";import { classifyUnknownToolName } from "./classifyActivityResult";+// MCP tools arrive as `mcp__<server>__<tool>`; show a readable "server · tool"+// instead of the raw double-underscore name.+function prettifyToolName(name: string): string {+ if (name.startsWith("mcp__")) {+ const parts = name.slice(5).split("__").filter(Boolean);+ if (parts.length >= 2) {+ const [server, ...rest] = parts;+ return `${server} · ${rest.join(" ").replace(/_/g, " ")}`;+ }+ return parts.join(" ").replace(/_/g, " ");+ }+ return name;+}+// Turn a raw tool name like "webfetch" / "web_fetch" into a readable verb// phrase, e.g. "Fetched web content".function formatUnknownToolLabel(name: string): string {@@ -8,9 +22,9 @@ function formatUnknownToolLabel(name: string): string {case "web":return "Fetched web content";case "github":- return `Ran ${name} on GitHub`;+ return `Ran ${prettifyToolName(name)} on GitHub`;default:- return `Ran ${name}`;+ return `Ran ${prettifyToolName(name)}`;}}diff --git a/gui/src/styles/index.css b/gui/src/styles/index.cssindex df177fbb..a4520260 100644--- a/gui/src/styles/index.css+++ b/gui/src/styles/index.css@@ -1186,7 +1186,7 @@content: "";border-radius: inherit;background: linear-gradient(- 90deg,+ 90deg in oklab,#ff5f6d,#ffb347,#ffe66d,@@ -1220,7 +1220,7 @@content: "";border-radius: inherit;background: linear-gradient(- 90deg,+ 90deg in oklab,#ff5f6d,#ffb347,#ffe66d,