Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add description to Resource #11

Merged
merged 2 commits into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1106,12 +1106,16 @@
"Resource": {
"description": "A known resource that the server is capable of reading.",
"properties": {
"description": {
"description": "A description of what this resource represents.\n\nThis can be used by clients to improve the LLM's understanding of available resources. It can be thought of like a \"hint\" to the model.",
"type": "string"
},
"mimeType": {
"description": "The MIME type of this resource, if known.",
"type": "string"
},
"name": {
"description": "An optional human-readable name for this resource.\n\nThis can be used by clients to populate UI elements.",
"description": "A human-readable name for this resource.\n\nThis can be used by clients to populate UI elements.",
"type": "string"
},
"uri": {
Expand Down Expand Up @@ -1191,15 +1195,15 @@
"description": "A template description for resources available on the server.",
"properties": {
"description": {
"description": "A human-readable description of what this template is for.",
"description": "A description of what this template is for.\n\nThis can be used by clients to improve the LLM's understanding of available resources. It can be thought of like a \"hint\" to the model.",
"type": "string"
},
"mimeType": {
"description": "The MIME type for all resources that match this template. This should only be included if all resources matching this template have the same type.",
"type": "string"
},
"name": {
"description": "A human-readable name for the type of resource this template refers to.",
"description": "A human-readable name for the type of resource this template refers to.\n\nThis can be used by clients to populate UI elements.",
"type": "string"
},
"uriTemplate": {
Expand Down
18 changes: 16 additions & 2 deletions schema/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -333,12 +333,19 @@ export interface Resource {
uri: string;

/**
* An optional human-readable name for this resource.
* A human-readable name for this resource.
*
* This can be used by clients to populate UI elements.
*/
name: string;

/**
* A description of what this resource represents.
*
* This can be used by clients to improve the LLM's understanding of available resources. It can be thought of like a "hint" to the model.
*/
description?: string;

/**
* The MIME type of this resource, if known.
*/
Expand All @@ -355,14 +362,21 @@ export interface ResourceTemplate {
* @format uri-template
*/
uriTemplate: string;

/**
* A human-readable name for the type of resource this template refers to.
*
* This can be used by clients to populate UI elements.
*/
name: string;

/**
* A human-readable description of what this template is for.
* A description of what this template is for.
*
* This can be used by clients to improve the LLM's understanding of available resources. It can be thought of like a "hint" to the model.
*/
description?: string;

/**
* The MIME type for all resources that match this template. This should only be included if all resources matching this template have the same type.
*/
Expand Down
Loading