sampleLLM
Generate text responses from prompts using the Model Context Protocol's sampling feature to interact with language models.
Instructions
Samples from an LLM using MCP's sampling feature
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"prompt": "<prompt>"
},
"name": "sampleLLM"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | The prompt to send to the LLM | |
| maxTokens | No | Maximum number of tokens to generate |