Variable CreateMessageRequestSchemaConst
CreateMessageRequestSchema: ZodObject<
extendShape<
{
method: ZodString;
params: ZodOptional<
ZodObject<
{
_meta: ZodOptional<
ZodObject<
{ progressToken: ZodOptional<ZodUnion<(...)>> },
"passthrough",
ZodTypeAny,
objectOutputType<
{ progressToken: ZodOptional<(...)> },
ZodTypeAny,
"passthrough",
>,
objectInputType<
{ progressToken: ZodOptional<(...)> },
ZodTypeAny,
"passthrough",
>,
>,
>;
},
"passthrough",
ZodTypeAny,
objectOutputType<
{
_meta: ZodOptional<
ZodObject<
{ progressToken: ZodOptional<(...)> },
"passthrough",
ZodTypeAny,
objectOutputType<{ progressToken: ... }, ZodTypeAny, "passthrough">,
objectInputType<{ progressToken: ... }, ZodTypeAny, "passthrough">,
>,
>;
},
ZodTypeAny,
"passthrough",
>,
objectInputType<
{
_meta: ZodOptional<
ZodObject<
{ progressToken: ZodOptional<(...)> },
"passthrough",
ZodTypeAny,
objectOutputType<{ progressToken: ... }, ZodTypeAny, "passthrough">,
objectInputType<{ progressToken: ... }, ZodTypeAny, "passthrough">,
>,
>;
},
ZodTypeAny,
"passthrough",
>,
>,
>;
},
{
method: ZodLiteral<"sampling/createMessage">;
params: ZodObject<
extendShape<
{
_meta: ZodOptional<
ZodObject<
{ progressToken: ZodOptional<ZodUnion<(...)>> },
"passthrough",
ZodTypeAny,
objectOutputType<
{ progressToken: ZodOptional<(...)> },
ZodTypeAny,
"passthrough",
>,
objectInputType<
{ progressToken: ZodOptional<(...)> },
ZodTypeAny,
"passthrough",
>,
>,
>;
},
{
includeContext: ZodOptional<
ZodEnum<["none", "thisServer", "allServers"]>,
>;
maxTokens: ZodNumber;
messages: ZodArray<
ZodObject<
{
content: ZodUnion<[(...), (...), (...)]>;
role: ZodEnum<[(...), (...)]>;
},
"strip",
ZodTypeAny,
{
content: | { _meta?: ...; text: ...; type: ... }
| { _meta?: ...; data: ...; mimeType: ...; type: ... }
| { _meta?: ...; data: ...; mimeType: ...; type: ... };
role: "user" | "assistant";
},
{
content: | { _meta?: ...; text: ...; type: ... }
| { _meta?: ...; data: ...; mimeType: ...; type: ... }
| { _meta?: ...; data: ...; mimeType: ...; type: ... };
role: "user" | "assistant";
},
>,
"many",
>;
metadata: ZodOptional<ZodType<object, ZodTypeDef, object>>;
modelPreferences: ZodOptional<
ZodObject<
{
costPriority: ZodOptional<ZodNumber>;
hints: ZodOptional<ZodArray<(...), (...)>>;
intelligencePriority: ZodOptional<ZodNumber>;
speedPriority: ZodOptional<ZodNumber>;
},
"strip",
ZodTypeAny,
{
costPriority?: number;
hints?: (...)[];
intelligencePriority?: number;
speedPriority?: number;
},
{
costPriority?: number;
hints?: (...)[];
intelligencePriority?: number;
speedPriority?: number;
},
>,
>;
stopSequences: ZodOptional<ZodArray<ZodString, "many">>;
systemPrompt: ZodOptional<ZodString>;
temperature: ZodOptional<ZodNumber>;
},
>,
"strip",
ZodTypeAny,
{
_meta?: objectOutputType<
{ progressToken: ZodOptional<ZodUnion<[(...), (...)]>> },
ZodTypeAny,
"passthrough",
>;
includeContext?: "none" | "thisServer" | "allServers";
maxTokens: number;
messages: {
content:
| { _meta?: Record<(...), (...)>; text: string; type: "text" }
| {
_meta?: Record<(...), (...)>;
data: string;
mimeType: string;
type: "image";
}
| {
_meta?: Record<(...), (...)>;
data: string;
mimeType: string;
type: "audio";
};
role: "user"
| "assistant";
}[];
metadata?: object;
modelPreferences?: {
costPriority?: number;
hints?: { name?: (...)
| (...) }[];
intelligencePriority?: number;
speedPriority?: number;
};
stopSequences?: string[];
systemPrompt?: string;
temperature?: number;
},
{
_meta?: objectInputType<
{ progressToken: ZodOptional<ZodUnion<[(...), (...)]>> },
ZodTypeAny,
"passthrough",
>;
includeContext?: "none" | "thisServer" | "allServers";
maxTokens: number;
messages: {
content:
| { _meta?: Record<(...), (...)>; text: string; type: "text" }
| {
_meta?: Record<(...), (...)>;
data: string;
mimeType: string;
type: "image";
}
| {
_meta?: Record<(...), (...)>;
data: string;
mimeType: string;
type: "audio";
};
role: "user"
| "assistant";
}[];
metadata?: object;
modelPreferences?: {
costPriority?: number;
hints?: { name?: (...)
| (...) }[];
intelligencePriority?: number;
speedPriority?: number;
};
stopSequences?: string[];
systemPrompt?: string;
temperature?: number;
},
>;
},
>,
"strip",
ZodTypeAny,
{
method: "sampling/createMessage";
params: {
_meta?: objectOutputType<
{ progressToken: ZodOptional<ZodUnion<[ZodString, ZodNumber]>> },
ZodTypeAny,
"passthrough",
>;
includeContext?: "none" | "thisServer" | "allServers";
maxTokens: number;
messages: {
content:
| { _meta?: Record<string, unknown>; text: string; type: "text" }
| {
_meta?: Record<string, unknown>;
data: string;
mimeType: string;
type: "image";
}
| {
_meta?: Record<string, unknown>;
data: string;
mimeType: string;
type: "audio";
};
role: "user"
| "assistant";
}[];
metadata?: object;
modelPreferences?: {
costPriority?: number;
hints?: { name?: string }[];
intelligencePriority?: number;
speedPriority?: number;
};
stopSequences?: string[];
systemPrompt?: string;
temperature?: number;
};
},
{
method: "sampling/createMessage";
params: {
_meta?: objectInputType<
{ progressToken: ZodOptional<ZodUnion<[ZodString, ZodNumber]>> },
ZodTypeAny,
"passthrough",
>;
includeContext?: "none" | "thisServer" | "allServers";
maxTokens: number;
messages: {
content:
| { _meta?: Record<string, unknown>; text: string; type: "text" }
| {
_meta?: Record<string, unknown>;
data: string;
mimeType: string;
type: "image";
}
| {
_meta?: Record<string, unknown>;
data: string;
mimeType: string;
type: "audio";
};
role: "user"
| "assistant";
}[];
metadata?: object;
modelPreferences?: {
costPriority?: number;
hints?: { name?: string }[];
intelligencePriority?: number;
speedPriority?: number;
};
stopSequences?: string[];
systemPrompt?: string;
temperature?: number;
};
},
> = ...
A request from the server to sample an LLM via the client. The client has full discretion over which model to select. The client should also inform the user before beginning sampling, to allow them to inspect the request (human in the loop) and decide whether to approve it.