MCProtocol::CreateMessageRequestParams
Inherits JSON::Serializable < Reference < Object
Constructors
new(maxTokens : Int64, messages : Array(SamplingMessage), includeContext : CreateMessageRequestParamsIncludeContext | Nil = Nil, metadata : JSON::Any | Nil = Nil, modelPreferences : ModelPreferences | Nil = Nil, stopSequences : Array(String) | Nil = Nil, systemPrompt : String | Nil = Nil, temperature : Float64 | Nil = Nil)
Sourcenew(pull : JSON::PullParser)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
includeContext
A request to include context from one or more MCP servers (including the caller), to be attached to the prompt. The client MAY ignore this request.
maxTokens
The maximum number of tokens to sample, as requested by the server. The client MAY choose to sample fewer tokens than requested.
messages
Sourcemetadata
Optional metadata to pass through to the LLM provider. The format of this metadata is provider-specific.
modelPreferences
The server's preferences for which model to select. The client MAY ignore these preferences.
stopSequences
SourcesystemPrompt
An optional system prompt the server wants to use for sampling. The client MAY modify or omit this prompt.
temperature
Source