Skip to content

spec: MCP prompts capability: query, discovery, and slash-command dispatch in Warp#11476

Open
oz-for-oss[bot] wants to merge 1 commit into
masterfrom
oz-agent/spec-issue-10740
Open

spec: MCP prompts capability: query, discovery, and slash-command dispatch in Warp#11476
oz-for-oss[bot] wants to merge 1 commit into
masterfrom
oz-agent/spec-issue-10740

Conversation

@oz-for-oss
Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot commented May 21, 2026

Summary

  • Adds a product spec for MCP prompt discovery and invocation in Warp.
  • Adds a tech spec covering MCP prompts/list, active prompt metadata, slash-menu discovery, argument collection, prompts/get, Agent Mode dispatch, telemetry/privacy, and validation.

Validation

  • Reviewed generated spec files for required structure and non-closing issue references.
  • No code changes were made; runtime tests were not run for this spec-only change.

Related issue: #10740

Co-Authored-By: David Engelmann <81196676+david-engelmann@users.noreply.github.com>
Co-Authored-By: Oz <oz-agent@warp.dev>
@oz-for-oss
Copy link
Copy Markdown
Contributor Author

oz-for-oss Bot commented May 21, 2026

@oz-for-oss[bot]

I'm starting a first review of this spec-only pull request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor Author

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

This PR adds product and technical specs for surfacing MCP prompt templates in Warp through prompt listing, slash-command discovery, argument collection, prompts/get, Agent Mode dispatch, telemetry, and validation.

Concerns

  • The tech spec does not define how MCP PromptMessage arrays with multiple roles/messages are flattened into one Agent Mode prompt body, which could lead to incompatible implementations.
  • Generated slash-command collision handling is not deterministic enough to guarantee stable command names across menu refreshes or reconnects.

Security

  • Telemetry currently allows raw MCP prompt names even though those names are server-controlled metadata and may disclose private workflow or repository details.

Verdict

Found: 0 critical, 3 important, 0 suggestions

Request changes

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Comment thread specs/GH10740/tech.md
- Resolve the selected `installation_id` and `prompt_name` against active manager state at invocation time.
- Build `GetPromptRequestParams` with the prompt name and argument map after local validation.
- Call `ReconnectingPeer::get_prompt`.
- Convert the returned prompt messages to a single text prompt body for Agent Mode.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [IMPORTANT] Define how multiple MCP prompt messages and roles are converted into a single Agent Mode prompt body, including whether non-user roles are labeled, rejected, or flattened with delimiters.

Comment thread specs/GH10740/tech.md
- `prompt_description: Option<String>`
- generated `command_name: String`
- argument metadata copied from `rmcp::model::Prompt`
Generate command names as `/mcp.<server-slug>.<prompt-slug>`. Slug generation should be deterministic, slash-safe, and covered by tests. Keep a per-snapshot map to detect generated-name collisions; append a short stable suffix derived from installation id and prompt name when needed.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [IMPORTANT] Specify a deterministic ordering and collision winner before appending suffixes; otherwise the unsuffixed command can change across snapshots depending on active-server iteration order.

Comment thread specs/GH10740/tech.md
- If the queue-next-prompt setting is active and the current conversation is in progress, use the same queuing behavior as typed prompts rather than bypassing the queue.
Do not introduce a new AI action type unless implementation discovers that agent-visible structured results are required. MCP prompt invocation is user-initiated prompt composition, not an agent-requested tool action, so it can live in input/slash-command handling rather than the blocklist action queue.
### 9. Telemetry and privacy
Extend `SlashCommandAcceptedDetails` or add a dedicated metadata event for MCP prompt acceptance. Include only non-content metadata: generated command family, installation id or redacted stable id, prompt name, has_arguments, argument_count, success/failure category, and whether the command was accepted in Agent View. Do not log argument values or rendered prompt content.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [IMPORTANT] [SECURITY] Raw MCP prompt names are server-controlled metadata and can reveal private workflows; require hashing/redaction or explicitly justify why prompt names are safe to send in telemetry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant