Skip to content

Commit 1c54a77

Browse files
committed
Encourage title properties/usage for objects/resources likely to be represented in a UI
1 parent ede1960 commit 1c54a77

File tree

6 files changed

+105
-51
lines changed

6 files changed

+105
-51
lines changed

docs/specification/draft/basic/lifecycle.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ The client **MUST** initiate this phase by sending an `initialize` request conta
6666
},
6767
"clientInfo": {
6868
"name": "ExampleClient",
69+
"title": "Example Client Display Name",
6970
"version": "1.0.0"
7071
}
7172
}
@@ -101,6 +102,7 @@ The server **MUST** respond with its own capabilities and information:
101102
},
102103
"serverInfo": {
103104
"name": "ExampleServer",
105+
"title": "Example Server Display Name",
104106
"version": "1.0.0"
105107
},
106108
"instructions": "Optional instructions for the client"

docs/specification/draft/server/prompts.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ supports [pagination](/specification/draft/server/utilities/pagination).
7373
"prompts": [
7474
{
7575
"name": "code_review",
76+
"title": "Request Code Review",
7677
"description": "Asks the LLM to analyze code quality and suggest improvements",
7778
"arguments": [
7879
{
@@ -172,6 +173,7 @@ sequenceDiagram
172173
A prompt definition includes:
173174

174175
- `name`: Unique identifier for the prompt
176+
- `title`: Optional human-readable name of the prompt for display purposes.
175177
- `description`: Optional human-readable description
176178
- `arguments`: Optional list of arguments for customization
177179

@@ -234,6 +236,8 @@ Embedded resources allow referencing server-side resources directly in messages:
234236
"type": "resource",
235237
"resource": {
236238
"uri": "resource://example",
239+
"name": "example",
240+
"title": "My Example Resource",
237241
"mimeType": "text/plain",
238242
"text": "Resource content"
239243
}

docs/specification/draft/server/resources.mdx

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ supports [pagination](/specification/draft/server/utilities/pagination).
111111
{
112112
"uri": "file:///project/src/main.rs",
113113
"name": "main.rs",
114+
"title": "Rust Software Application Main File",
114115
"description": "Primary application entry point",
115116
"mimeType": "text/x-rust"
116117
}
@@ -147,6 +148,8 @@ To retrieve resource contents, clients send a `resources/read` request:
147148
"contents": [
148149
{
149150
"uri": "file:///project/src/main.rs",
151+
"name": "main.rs",
152+
"title": "Rust Software Application Main File",
150153
"mimeType": "text/x-rust",
151154
"text": "fn main() {\n println!(\"Hello world!\");\n}"
152155
}
@@ -182,6 +185,7 @@ auto-completed through [the completion API](/specification/draft/server/utilitie
182185
{
183186
"uriTemplate": "file:///{path}",
184187
"name": "Project Files",
188+
"title": "📁 Project Files",
185189
"description": "Access files in the project directory",
186190
"mimeType": "application/octet-stream"
187191
}
@@ -227,7 +231,8 @@ to specific resources and receive notifications when they change:
227231
"jsonrpc": "2.0",
228232
"method": "notifications/resources/updated",
229233
"params": {
230-
"uri": "file:///project/src/main.rs"
234+
"uri": "file:///project/src/main.rs",
235+
"title": "Rust Software Application Main File"
231236
}
232237
}
233238
```
@@ -264,7 +269,8 @@ sequenceDiagram
264269
A resource definition includes:
265270

266271
- `uri`: Unique identifier for the resource
267-
- `name`: Human-readable name
272+
- `name`: The name of the resource.
273+
- `title`: Optional human-readable name of the resource for display purposes.
268274
- `description`: Optional description
269275
- `mimeType`: Optional MIME type
270276
- `size`: Optional size in bytes
@@ -278,6 +284,8 @@ Resources can contain either text or binary data:
278284
```json
279285
{
280286
"uri": "file:///example.txt",
287+
"name": "example.txt",
288+
"title": "Example Text File",
281289
"mimeType": "text/plain",
282290
"text": "Resource content"
283291
}
@@ -288,6 +296,8 @@ Resources can contain either text or binary data:
288296
```json
289297
{
290298
"uri": "file:///example.png",
299+
"name": "example.png",
300+
"title": "Example Image",
291301
"mimeType": "image/png",
292302
"blob": "base64-encoded-data"
293303
}

docs/specification/draft/server/tools.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ To discover available tools, clients send a `tools/list` request. This operation
8080
"tools": [
8181
{
8282
"name": "get_weather",
83+
"title": "Weather Information Provider",
8384
"description": "Get current weather information for a location",
8485
"inputSchema": {
8586
"type": "object",
@@ -181,6 +182,7 @@ sequenceDiagram
181182
A tool definition includes:
182183

183184
- `name`: Unique identifier for the tool
185+
- `title`: Optional human-readable name of the tool for display purposes.
184186
- `description`: Human-readable description of functionality
185187
- `inputSchema`: JSON Schema defining expected parameters
186188
- `outputSchema`: Optional JSON Schema defining expected output structure
@@ -238,6 +240,7 @@ or data, behind a URI that can be subscribed to or fetched again by the client l
238240
"type": "resource",
239241
"resource": {
240242
"uri": "resource://example",
243+
"title": "My Plain-text Resource",
241244
"mimeType": "text/plain",
242245
"text": "Resource content"
243246
}
@@ -264,6 +267,7 @@ Example tool with output schema:
264267
```json
265268
{
266269
"name": "get_weather_data",
270+
"title": "Weather Data Retriever",
267271
"description": "Get current weather data for a location",
268272
"inputSchema": {
269273
"type": "object",

schema/draft/schema.json

Lines changed: 55 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)