Merged
Conversation
`PromptArgument extends BaseMetadata`, which includes both name and title - https://github.com/modelcontextprotocol/modelcontextprotocol/blob/51e093b8ebfde5e968879024566b7380d30c52d0/schema/2025-06-18/schema.ts#L686-L698 - https://github.com/modelcontextprotocol/modelcontextprotocol/blob/51e093b8ebfde5e968879024566b7380d30c52d0/schema/2025-06-18/schema.ts#L294-l309
koic
reviewed
Oct 7, 2025
| name: name_value, | ||
| title: title_value, | ||
| description: description_value, | ||
| arguments: arguments_value&.map(&:to_h), |
Member
There was a problem hiding this comment.
It seems that the tests passes even without safe navigation. Is it necessary?
Suggested change
| arguments: arguments_value&.map(&:to_h), | |
| arguments: arguments_value.map(&:to_h), |
Contributor
Author
There was a problem hiding this comment.
good callout - this is a possible state if a Prompt class doesn't define arguments.
I added a test to exercise and cover this behaviour.
ruby-sdk/test/mcp/prompt_test.rb
Lines 180 to 193 in a1dd3dd
390e6b8 to
8aab228
Compare
> See [General fields: `_meta`](/specification/2025-06-18/basic/index#meta) for notes on `_meta` usage. https://github.com/modelcontextprotocol/modelcontextprotocol/blob/51e093b8ebfde5e968879024566b7380d30c52d0/schema/2025-06-18/schema.ts#L680-L683
8aab228 to
a1dd3dd
Compare
koic
approved these changes
Oct 14, 2025
Member
|
Thanks! |
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation and Context
add
titlefield to prompt argument 701f6faPromptArgument extends BaseMetadata, which includes both name andtitle
add
_metafield toPrompt390e6b8https://github.com/modelcontextprotocol/modelcontextprotocol/blob/51e093b8ebfde5e968879024566b7380d30c52d0/schema/2025-06-18/schema.ts#L680-L683
How Has This Been Tested?
updated existing tests for prompt construction to include meta field and argument titles.
Breaking Changes
None
Types of changes
Checklist
Additional context
simplifying sharing
BaseMetadatabehaviour with a module mixin' coming in follow up PR - wip ; e2a8f27