poe-code 3.0.231 → 3.0.233
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent.js +12 -7
- package/dist/agent.js.map +3 -3
- package/dist/index.js +536 -229
- package/dist/index.js.map +4 -4
- package/dist/metafile.json +1 -0
- package/dist/providers/poe-agent.js +424 -126
- package/dist/providers/poe-agent.js.map +4 -4
- package/package.json +6 -1
- package/packages/agent-skill-config/dist/index.d.ts +1 -0
- package/packages/agent-skill-config/dist/index.js +1 -0
- package/packages/memory/dist/explain.js +1 -1
- package/packages/memory/dist/index.js +315 -44
- package/packages/memory/dist/index.js.map +4 -4
- package/packages/memory/dist/query.js +1 -1
- package/packages/memory/dist/tokens.js +1 -1
- package/packages/superintendent/dist/mcp.js +41194 -151
- package/packages/superintendent/dist/mcp.js.map +7 -0
- package/packages/tiny-stdio-mcp-server/dist/index.d.ts +1 -1
- package/packages/tiny-stdio-mcp-server/dist/server.d.ts +12 -2
- package/packages/tiny-stdio-mcp-server/dist/server.js +310 -40
- package/packages/tiny-stdio-mcp-server/dist/types.d.ts +136 -9
- package/packages/tiny-stdio-mcp-server/dist/types.js +2 -1
|
@@ -21,6 +21,7 @@ export declare const JSON_RPC_ERROR_CODES: Readonly<{
|
|
|
21
21
|
readonly METHOD_NOT_FOUND: -32601;
|
|
22
22
|
readonly INVALID_PARAMS: -32602;
|
|
23
23
|
readonly INTERNAL_ERROR: -32603;
|
|
24
|
+
readonly RESOURCE_NOT_FOUND: -32002;
|
|
24
25
|
}>;
|
|
25
26
|
export declare class ToolError extends Error {
|
|
26
27
|
readonly code: number;
|
|
@@ -29,10 +30,19 @@ export declare class ToolError extends Error {
|
|
|
29
30
|
export interface ToolsCapability {
|
|
30
31
|
listChanged?: boolean;
|
|
31
32
|
}
|
|
33
|
+
export interface PromptsCapability {
|
|
34
|
+
listChanged?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export interface ResourcesCapability {
|
|
37
|
+
subscribe?: boolean;
|
|
38
|
+
listChanged?: boolean;
|
|
39
|
+
}
|
|
32
40
|
export interface InitializeResult {
|
|
33
41
|
protocolVersion: string;
|
|
34
42
|
capabilities: {
|
|
35
43
|
tools?: ToolsCapability;
|
|
44
|
+
prompts?: PromptsCapability;
|
|
45
|
+
resources?: ResourcesCapability;
|
|
36
46
|
};
|
|
37
47
|
serverInfo: {
|
|
38
48
|
name: string;
|
|
@@ -41,13 +51,116 @@ export interface InitializeResult {
|
|
|
41
51
|
}
|
|
42
52
|
export interface Tool {
|
|
43
53
|
name: string;
|
|
44
|
-
|
|
54
|
+
title?: string;
|
|
55
|
+
description?: string;
|
|
45
56
|
inputSchema: JSONSchema;
|
|
57
|
+
outputSchema?: JSONSchema;
|
|
58
|
+
annotations?: ToolAnnotations;
|
|
59
|
+
execution?: ToolExecution;
|
|
60
|
+
icons?: Icon[];
|
|
61
|
+
_meta?: Record<string, unknown>;
|
|
46
62
|
}
|
|
47
63
|
export interface CallToolResult {
|
|
48
64
|
content: ContentItem[];
|
|
65
|
+
structuredContent?: Record<string, unknown>;
|
|
49
66
|
isError?: boolean;
|
|
50
67
|
}
|
|
68
|
+
export interface ToolAnnotations {
|
|
69
|
+
title?: string;
|
|
70
|
+
readOnlyHint?: boolean;
|
|
71
|
+
destructiveHint?: boolean;
|
|
72
|
+
idempotentHint?: boolean;
|
|
73
|
+
openWorldHint?: boolean;
|
|
74
|
+
}
|
|
75
|
+
export interface ToolExecution {
|
|
76
|
+
taskSupport?: "optional" | "required" | "forbidden";
|
|
77
|
+
}
|
|
78
|
+
export interface Icon {
|
|
79
|
+
src: string;
|
|
80
|
+
mimeType?: string;
|
|
81
|
+
sizes?: string[];
|
|
82
|
+
theme?: "light" | "dark";
|
|
83
|
+
}
|
|
84
|
+
export interface ContentAnnotations {
|
|
85
|
+
audience?: Array<"user" | "assistant">;
|
|
86
|
+
priority?: number;
|
|
87
|
+
lastModified?: string;
|
|
88
|
+
}
|
|
89
|
+
export interface ResourceLink {
|
|
90
|
+
type: "resource_link";
|
|
91
|
+
uri: string;
|
|
92
|
+
name: string;
|
|
93
|
+
title?: string;
|
|
94
|
+
description?: string;
|
|
95
|
+
mimeType?: string;
|
|
96
|
+
size?: number;
|
|
97
|
+
annotations?: ContentAnnotations;
|
|
98
|
+
}
|
|
99
|
+
export interface PromptArgument {
|
|
100
|
+
name: string;
|
|
101
|
+
description?: string;
|
|
102
|
+
required?: boolean;
|
|
103
|
+
}
|
|
104
|
+
export interface Prompt {
|
|
105
|
+
name: string;
|
|
106
|
+
title?: string;
|
|
107
|
+
description?: string;
|
|
108
|
+
arguments?: PromptArgument[];
|
|
109
|
+
icons?: Icon[];
|
|
110
|
+
_meta?: Record<string, unknown>;
|
|
111
|
+
}
|
|
112
|
+
export interface PromptMessage {
|
|
113
|
+
role: "user" | "assistant";
|
|
114
|
+
content: PromptContentItem;
|
|
115
|
+
}
|
|
116
|
+
export interface GetPromptResult {
|
|
117
|
+
description?: string;
|
|
118
|
+
messages: PromptMessage[];
|
|
119
|
+
}
|
|
120
|
+
export type PromptHandler = (args: Record<string, string>) => Promise<GetPromptResult> | GetPromptResult;
|
|
121
|
+
export interface PromptDefinition extends Prompt {
|
|
122
|
+
handler: PromptHandler;
|
|
123
|
+
}
|
|
124
|
+
export interface Resource {
|
|
125
|
+
uri: string;
|
|
126
|
+
name: string;
|
|
127
|
+
title?: string;
|
|
128
|
+
description?: string;
|
|
129
|
+
mimeType?: string;
|
|
130
|
+
size?: number;
|
|
131
|
+
annotations?: ContentAnnotations;
|
|
132
|
+
icons?: Icon[];
|
|
133
|
+
_meta?: Record<string, unknown>;
|
|
134
|
+
}
|
|
135
|
+
export interface ResourceTemplate {
|
|
136
|
+
uriTemplate: string;
|
|
137
|
+
name: string;
|
|
138
|
+
title?: string;
|
|
139
|
+
description?: string;
|
|
140
|
+
mimeType?: string;
|
|
141
|
+
annotations?: ContentAnnotations;
|
|
142
|
+
icons?: Icon[];
|
|
143
|
+
_meta?: Record<string, unknown>;
|
|
144
|
+
}
|
|
145
|
+
export type ResourceContents = {
|
|
146
|
+
uri: string;
|
|
147
|
+
mimeType?: string;
|
|
148
|
+
text: string;
|
|
149
|
+
} | {
|
|
150
|
+
uri: string;
|
|
151
|
+
mimeType?: string;
|
|
152
|
+
blob: string;
|
|
153
|
+
};
|
|
154
|
+
export interface ReadResourceResult {
|
|
155
|
+
contents: ResourceContents[];
|
|
156
|
+
}
|
|
157
|
+
export type ResourceHandler = (uri: string) => Promise<ReadResourceResult> | ReadResourceResult;
|
|
158
|
+
export interface ResourceDefinition extends Resource {
|
|
159
|
+
handler: ResourceHandler;
|
|
160
|
+
}
|
|
161
|
+
export interface ResourceTemplateDefinition extends ResourceTemplate {
|
|
162
|
+
handler: ResourceHandler;
|
|
163
|
+
}
|
|
51
164
|
export interface HandleResult {
|
|
52
165
|
result?: unknown;
|
|
53
166
|
error?: {
|
|
@@ -55,50 +168,64 @@ export interface HandleResult {
|
|
|
55
168
|
message: string;
|
|
56
169
|
};
|
|
57
170
|
}
|
|
58
|
-
export type
|
|
171
|
+
export type PromptContentItem = {
|
|
59
172
|
type: "text";
|
|
60
173
|
text: string;
|
|
174
|
+
annotations?: ContentAnnotations;
|
|
61
175
|
} | {
|
|
62
176
|
type: "image";
|
|
63
177
|
data: string;
|
|
64
178
|
mimeType: string;
|
|
179
|
+
annotations?: ContentAnnotations;
|
|
65
180
|
} | {
|
|
66
181
|
type: "audio";
|
|
67
182
|
data: string;
|
|
68
183
|
mimeType: string;
|
|
184
|
+
annotations?: ContentAnnotations;
|
|
69
185
|
} | {
|
|
70
186
|
type: "resource";
|
|
187
|
+
annotations?: ContentAnnotations;
|
|
71
188
|
resource: {
|
|
72
189
|
uri: string;
|
|
73
|
-
mimeType
|
|
190
|
+
mimeType?: string;
|
|
74
191
|
text: string;
|
|
75
192
|
} | {
|
|
76
193
|
uri: string;
|
|
77
|
-
mimeType
|
|
194
|
+
mimeType?: string;
|
|
78
195
|
blob: string;
|
|
79
196
|
};
|
|
80
197
|
};
|
|
198
|
+
export type ContentItem = PromptContentItem | ResourceLink;
|
|
81
199
|
export interface JSONSchema {
|
|
82
200
|
type: "object";
|
|
83
|
-
properties
|
|
201
|
+
properties?: Record<string, JSONSchemaProperty>;
|
|
84
202
|
required?: string[];
|
|
203
|
+
[keyword: string]: unknown;
|
|
85
204
|
}
|
|
86
|
-
export interface JSONSchemaProperty {
|
|
87
|
-
type
|
|
205
|
+
export interface JSONSchemaProperty extends Record<string, unknown> {
|
|
206
|
+
type?: string | string[];
|
|
88
207
|
description?: string;
|
|
89
|
-
|
|
208
|
+
[keyword: string]: unknown;
|
|
90
209
|
}
|
|
91
210
|
export interface ServerOptions {
|
|
92
211
|
name: string;
|
|
93
212
|
version: string;
|
|
94
213
|
validateToolArguments?: boolean;
|
|
214
|
+
supportNotifications?: boolean;
|
|
215
|
+
supportResourceSubscriptions?: boolean;
|
|
95
216
|
}
|
|
96
217
|
import type { ToolReturn } from "./content/index.js";
|
|
97
218
|
export type ToolHandler<T = Record<string, unknown>> = (args: T) => Promise<ToolReturn | CallToolResult> | ToolReturn | CallToolResult;
|
|
98
219
|
export interface ToolDefinition<T = Record<string, unknown>> {
|
|
99
220
|
name: string;
|
|
100
|
-
|
|
221
|
+
title?: string;
|
|
222
|
+
description?: string;
|
|
101
223
|
inputSchema: JSONSchema;
|
|
224
|
+
outputSchema?: JSONSchema;
|
|
225
|
+
annotations?: ToolAnnotations;
|
|
226
|
+
execution?: ToolExecution;
|
|
227
|
+
icons?: Icon[];
|
|
228
|
+
_meta?: Record<string, unknown>;
|
|
102
229
|
handler: ToolHandler<T>;
|
|
103
230
|
}
|
|
104
231
|
export interface Transport {
|
|
@@ -4,7 +4,8 @@ export const JSON_RPC_ERROR_CODES = Object.freeze({
|
|
|
4
4
|
INVALID_REQUEST: -32600,
|
|
5
5
|
METHOD_NOT_FOUND: -32601,
|
|
6
6
|
INVALID_PARAMS: -32602,
|
|
7
|
-
INTERNAL_ERROR: -32603
|
|
7
|
+
INTERNAL_ERROR: -32603,
|
|
8
|
+
RESOURCE_NOT_FOUND: -32002
|
|
8
9
|
});
|
|
9
10
|
export class ToolError extends Error {
|
|
10
11
|
code;
|