Skip to content

Commit 71e92fa

Browse files
tomek-iarmada-lookout
andauthored
XS⚠️ ◾ Simplify MCP tools permission prompt copy (#995)
Simplify MCP tools permission prompt copy The dialog explaining each MCP tool request was verbose: a two-clause description plus a full-sentence explanation of each of the three buttons. Trim it to short, scannable copy that states what YakShaver wants and why, and makes clear what happens if you don't allow it, matching the terser tone used elsewhere (e.g. the screen recording permission dialog). Relates to #968 Co-authored-by: armada-lookout <armada-lookout@users.noreply.github.com>
1 parent 930722d commit 71e92fa

1 file changed

Lines changed: 13 additions & 14 deletions

File tree

src/ui/src/components/workflow/ApprovalDialog.tsx

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,17 @@ function getServiceIcon(serverName: string | null): ReactElement {
4242

4343
/**
4444
* Plain-language explanations of why specific tools are needed, so non-technical
45-
* users can make an informed choice (issue #783 AC2). Returns null for tools
46-
* without a bespoke explanation, in which case the generic description is used.
45+
* users can make an informed choice (issue #783 AC2, shortened further per #968).
46+
* Returns null for tools without a bespoke explanation, in which case the generic
47+
* description is used.
4748
*
4849
* Keyed on the raw, unformatted tool id (the segment after any server prefix) via
4950
* the shared {@link splitToolName} so it survives both MCP separators ("__" and ".").
5051
*/
5152
function getToolPurpose(rawToolName: string): string | null {
5253
switch (splitToolName(rawToolName).tool) {
5354
case "capture_video_frame":
54-
return "YakShaver wants to capture a still frame from your screen recording so it can see what you're pointing at and keep working on your task accurately. It only runs when you say it's OK.";
55+
return "YakShaver wants to grab a frame from your recording, so it can see what you're pointing at.";
5556
default:
5657
return null;
5758
}
@@ -154,20 +155,20 @@ export function ApprovalDialog({ request, onSubmit, error: pError }: ApprovalDia
154155
const isOpen = true;
155156

156157
const readableToolInfo = toolName ? parseToolName(toolName) : null;
157-
const toolLabel = readableToolInfo?.tool ?? "an action";
158158
const dialogTitle = readableToolInfo
159159
? `Can YakShaver use "${readableToolInfo.tool}"?`
160160
: "Can YakShaver perform this action?";
161161

162162
// Some tools have a clear, user-facing purpose that non-technical users benefit
163-
// from understanding (issue #783 AC2). Keyed on the raw, unformatted tool id so it
164-
// survives both MCP separators ("__" and ".") and any display-label changes.
163+
// from understanding (issue #783 AC2, shortened further per #968). Keyed on the raw,
164+
// unformatted tool id so it survives both MCP separators ("__" and ".") and any
165+
// display-label changes.
165166
const toolPurpose = toolName ? getToolPurpose(toolName) : null;
166167
const dialogDescription =
167168
toolPurpose ??
168169
(readableToolInfo?.server
169-
? `To keep working on your task, YakShaver needs to use the "${readableToolInfo.tool}" tool (from ${readableToolInfo.server}). It only runs when you say it's OK.`
170-
: `To keep working on your task, YakShaver needs to perform an action. It only runs when you say it's OK.`);
170+
? `YakShaver needs to use "${readableToolInfo.tool}" (from ${readableToolInfo.server}) to keep going.`
171+
: `YakShaver needs to perform an action to keep going.`);
171172

172173
return (
173174
<AlertDialog open={isOpen}>
@@ -184,17 +185,15 @@ export function ApprovalDialog({ request, onSubmit, error: pError }: ApprovalDia
184185
{!showCorrectionForm && (
185186
<ul className="space-y-1.5 text-sm text-white/70">
186187
<li>
187-
<span className="font-medium text-white/90">Allow</span> &mdash; let YakShaver use{" "}
188-
{`"${toolLabel}"`} this one time.
188+
<span className="font-medium text-white/90">Allow</span> &mdash; use it this once.
189189
</li>
190190
<li>
191-
<span className="font-medium text-white/90">Allow Always</span> &mdash; let YakShaver
192-
use {`"${toolLabel}"`} now and skip this prompt next time.
191+
<span className="font-medium text-white/90">Allow Always</span> &mdash; use it now and
192+
don't ask again.
193193
</li>
194194
<li>
195195
<span className="font-medium text-white/90">Review / Correct&hellip;</span> &mdash;
196-
don't run {`"${toolLabel}"`} as-is. You can leave a note telling YakShaver what to
197-
change and try again, or stop the step entirely.
196+
don't run it yet. Tell YakShaver what to change, or stop this step.
198197
</li>
199198
</ul>
200199
)}

0 commit comments

Comments
 (0)