Repository navigation
Description
Summary
The connect dialogs hand a person four prompts (#4958, #4959, #4965, #4966). Three of them restate a workflow that the MCP server already carries as a prompt, and each is stated a third time in the instructions every agent reads when it connects. The texts are written for different moments, so they differ on purpose: a first message the person pastes, a command an agent client lists, and the lines an agent reads at initialize. Nothing ties them to one another except a check that the tools they name exist. This issue lists the overlaps and what holds them together today. It states no preference.
What the repository says (main at 8a0732529c)
| Workflow | Server instructions (services/platform/lib/mcp/instructions.ts) |
MCP prompt (lib/mcp/prompts.ts) |
Dialog prompt (messages/en/codingAgent.yml) |
|---|---|---|---|
| Change an automation | :27 the loop get_automation, edit, validate, run, test, save; :38 read get_docs once; :59 save with baseVersion |
edit_automation with a name (:85-159) |
prompt.edit (:28) |
| Create an automation | :59 "create: true for a new automation" |
edit_automation without a name (the same spec) |
prompt.create (:30) |
| Look into a failed run | :81-84 read it with get_run and the record, fix the document, reproduce with run_automation |
debug_failed_run (:161-199) |
prompt.run (:29) |
| A first look at what the agent can do here | prompt.general (:27) |
The dialog texts have German and French twins; the server's texts are English only ("Agent-facing English, a public API like the tool descriptions", instructions.ts:7-8).
Where they differ today
- The dialog's edit prompt does not include a mock run (
run_automation) or thebaseVersionand message guidance;edit_automationhas both (prompts.ts:85-159), and the instructions givebaseVersion(instructions.ts:59). - The dialog's run prompt does not name
list_connectors,list_agent_secretsandlist_models, whichdebug_failed_runnames for a cause outside the document; it keeps "never ask me to paste a secret". - The MCP prompts attach the automation or the run record to the message as resources; a pasted prompt cannot.
What holds them together
- The instructions are assembled from fragments that each name their tools, and a fragment ships only when every one of its tools exists (
instructions.ts:10-15; the guard also keeps the text inside the 2,048 characters Claude Code reads). - The MCP prompts and the dialog prompts are each checked against the tool inventory (
lib/mcp/prompts.test.ts,app/features/coding-agent/lib/prompts.test.ts). - Nothing compares the steps of one place with those of another.
What was not examined
- How clients other than Claude Code surface MCP prompts (the guide covers Claude Code at
docs/en/develop/use-tale-from-your-editor.md:419). - Whether an agent that reads both a pasted prompt and the server's instructions behaves differently from one that reads one.
- Whether the differences above matter to the result.
Options (no preference stated)
- Accept the three places.
- A guard: the tools each text names, in order, must agree between a dialog prompt and its MCP prompt, or differ only by a written allow-list.
- One source: render the dialog's text from the MCP prompt's spec, without the attached resources.
- Have the dialog's prompt call the MCP prompt for clients that list prompts, and keep text only for the others. Which clients list prompts was not examined.
- Shorten the dialog's prompt to a line that points the agent at the server's instructions.
Questions
- Which place is the source of truth for a workflow?
- Do the dialogs' prompts need to differ from the MCP prompts at all?
Activity
yannickmonney commentedon Nov 14, 2026
Decision
Rule: the MCP prompt spec (
services/platform/lib/mcp/prompts.ts) is the single source of truth for a workflow's steps and their order:edit_automationfor edit and create,debug_failed_runfor a failed run. Each other place that restates a workflow is held to the spec by a test:lib/mcp/skill.ts, a fourth place this issue did not list) keeps its teaching sections./tale:edit_automation <name>,/tale:edit_automation,/tale:debug_failed_run <runId>). It is built in code from the server name and the spec. The choice follows the selected tab, not the client name the connection reports about itself.prompt.generalstays as it is.The guard: for each workflow, the core sequence is the tools the spec's lines name, in order, each kept at its last mention. Every place must contain that sequence in the same order. It may add or repeat tools. It may leave one out only through an allow-list entry with a written reason, and a stale entry fails the test.
Answers
run_automation;baseVersion;list_connectors,list_agent_secretsandlist_models;get_docsplaced before the read of the automation.Rationale
Agents act on these texts, and the pasted edit prompt today skips the mock run and
baseVersion. A guard tied to the spec catches drift like that, but only if its rule is precise. The spec namessave_automationtwice for create, and its lines depend on the branch taken. The last-mention, subsequence rule handles both and still lets places add tools. Handing Claude Code the command removes a copy. In edit_automation's not-readable branch, the agent asks before creating under the given name. Without that, ataleserver signed in to another organization would turn an edit into a stray create.Why not the other options:
Implementation units
get_automation, thenget_docs, validate, mockrun_automation, test, then save withbaseVersionand a one-line message.list_automations, thenget_docs, validate, mock run, test, then save withcreate: true.lib/mcp/workflows.test.ts: the subsequence rule over the dialog locales, the skill's two sections and the instructions' two fragments.MCP_SERVER_NAMEandMCP_PROMPTS, with a schema test.Cross-issue amendments (decisions taken together with #4975, #4972):