V2 Edit pass (#1728)
This commit is contained in:
parent
2d1b9a3462
commit
b283596df1
1 changed files with 263 additions and 251 deletions
|
|
@ -11,7 +11,7 @@ MCP [prompts] allow servers to expose reusable prompt templates to clients. Prom
|
|||
|
||||
[prompts]: https://modelcontextprotocol.io/specification/2025-11-25/server/prompts
|
||||
|
||||
This document covers implementing prompts on the server, consuming them from the client, rich content types, and change notifications.
|
||||
This document covers implementing prompts on the server, consuming prompts from the client, rich content types, and change notifications.
|
||||
|
||||
### Defining prompts on the server
|
||||
|
||||
|
|
@ -70,7 +70,7 @@ builder.Services.AddMcpServer()
|
|||
|
||||
### Rich content in prompts
|
||||
|
||||
Prompt messages can contain more than just text. For text and image content, use `ChatMessage` from Microsoft.Extensions.AI. `DataContent` is automatically mapped to the appropriate MCP content block: image MIME types become <xref:ModelContextProtocol.Protocol.ImageContentBlock>, audio MIME types become <xref:ModelContextProtocol.Protocol.AudioContentBlock>, and all other MIME types become <xref:ModelContextProtocol.Protocol.EmbeddedResourceBlock> with binary resource contents. For text embedded resources specifically, use <xref:ModelContextProtocol.Protocol.PromptMessage> directly.
|
||||
Prompt messages can contain more than just text. For text and image content, use [`ChatMessage`](https://learn.microsoft.com/dotnet/api/microsoft.extensions.ai.chatmessage) from Microsoft.Extensions.AI. `DataContent` is automatically mapped to the appropriate MCP content block: image MIME types become <xref:ModelContextProtocol.Protocol.ImageContentBlock>, audio MIME types become <xref:ModelContextProtocol.Protocol.AudioContentBlock>, and all other MIME types become <xref:ModelContextProtocol.Protocol.EmbeddedResourceBlock> with binary resource contents. For text-embedded resources specifically, use <xref:ModelContextProtocol.Protocol.PromptMessage> directly.
|
||||
|
||||
#### Image content
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue