openfox 2.0.67 → 2.0.68
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/{chat-handler-72DFHK5K.js → chat-handler-QFEHJBWN.js} +6 -6
- package/dist/{chunk-MQHMT5WF.js → chunk-32KLLK4N.js} +3 -3
- package/dist/{chunk-TMHWQYWE.js → chunk-64GN6OPR.js} +2 -2
- package/dist/{chunk-YU6DZAVA.js → chunk-6LK47TNE.js} +15 -95
- package/dist/{chunk-5EO6SEGV.js → chunk-7OW6X764.js} +2 -2
- package/dist/{chunk-B6JUWVTK.js → chunk-COWJRBV4.js} +5 -5
- package/dist/{chunk-2GRUQN2B.js → chunk-DWZEGLHJ.js} +251 -57
- package/dist/{chunk-B7WGOK7G.js → chunk-E4POUD2M.js} +2 -2
- package/dist/{chunk-PYRH4G2J.js → chunk-FCLCEIY4.js} +5 -5
- package/dist/{chunk-BL5LOLVA.js → chunk-JHGKXQBO.js} +161 -28
- package/dist/{chunk-TJO4QFDQ.js → chunk-QFSDJIUS.js} +2 -2
- package/dist/{chunk-ZLON3JTI.js → chunk-YQ3MEZJL.js} +2 -2
- package/dist/cli/dev.js +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/{client-BUX62J2K.js → client-63U5CTPE.js} +3 -3
- package/dist/{client-pure-U6ZYUPJQ.js → client-pure-XHH4RRLB.js} +2 -2
- package/dist/{compactor-74CZVUWI.js → compactor-IPMMFFHM.js} +4 -4
- package/dist/{orchestrator-FEMPJOZD.js → orchestrator-GNXKJPX4.js} +5 -5
- package/dist/package.json +3 -2
- package/dist/{processor-QB3NMRMO.js → processor-TIQEQDP7.js} +6 -6
- package/dist/{protocol-42f_Png6.d.ts → protocol-DIhV-tAc.d.ts} +1 -1
- package/dist/provider/index.d.ts +4 -4
- package/dist/{provider-BDH6JGZB.js → provider-IBIWR4AI.js} +4 -4
- package/dist/{provider-manager-D3KIOD5E.js → provider-manager-7C3JVOLW.js} +4 -4
- package/dist/{serve-32FAA4FX.js → serve-QVVZ5SJE.js} +10 -10
- package/dist/server/index.d.ts +3 -3
- package/dist/server/index.js +9 -9
- package/dist/{server-OYE7GERR.js → server-ECKS2Y3R.js} +7 -7
- package/dist/shared/index.d.ts +3 -3
- package/dist/{tools-INWP6FGV.js → tools-QAEN5KHA.js} +4 -4
- package/dist/{types-vezAEt_y.d.ts → types-BsfYpEai.d.ts} +2 -1
- package/dist/{types-apiMd7Df.d.ts → types-CBC6lLqc.d.ts} +1 -1
- package/dist/web/assets/{index-BELeAs12.css → index-BA_65WJ5.css} +1 -1
- package/dist/web/assets/{index-C3n65CNu.js → index-CsZQdTAd.js} +74 -74
- package/dist/web/index.html +2 -2
- package/dist/web/sw.js +1 -1
- package/package.json +3 -2
- package/plugins-registry.json +14 -0
|
@@ -1,3 +1,101 @@
|
|
|
1
|
+
// src/server/tools/types.ts
|
|
2
|
+
var OUTPUT_LIMITS = {
|
|
3
|
+
read_file: {
|
|
4
|
+
maxLines: 2e3,
|
|
5
|
+
maxBytes: 1e5,
|
|
6
|
+
maxImageBytes: 2097152,
|
|
7
|
+
// 2MB for images
|
|
8
|
+
maxPdfPages: 50,
|
|
9
|
+
maxFileBytes: 20971520
|
|
10
|
+
// 20MB general file safety limit
|
|
11
|
+
},
|
|
12
|
+
run_command: {
|
|
13
|
+
maxLines: 2e3,
|
|
14
|
+
maxBytes: 5e4
|
|
15
|
+
},
|
|
16
|
+
glob: {
|
|
17
|
+
maxResults: 500
|
|
18
|
+
},
|
|
19
|
+
grep: {
|
|
20
|
+
maxMatches: 200
|
|
21
|
+
},
|
|
22
|
+
web_fetch: {
|
|
23
|
+
maxBytes: 1e5
|
|
24
|
+
}
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
// src/server/tools/pdf-utils.ts
|
|
28
|
+
import { getDocument } from "pdfjs-dist/legacy/build/pdf.mjs";
|
|
29
|
+
var PDF_HEADER = Buffer.from("%PDF");
|
|
30
|
+
function isPdfBuffer(buffer) {
|
|
31
|
+
return buffer.length > 4 && buffer.subarray(0, 4).equals(PDF_HEADER);
|
|
32
|
+
}
|
|
33
|
+
function isPasswordError(err) {
|
|
34
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
35
|
+
return message.toLowerCase().includes("password") || message.toLowerCase().includes("encrypt");
|
|
36
|
+
}
|
|
37
|
+
function formatPdfErrorMessage(err) {
|
|
38
|
+
if (isPasswordError(err)) {
|
|
39
|
+
return "This PDF is password-protected. Unlock it with an external tool first.";
|
|
40
|
+
}
|
|
41
|
+
return `Failed to read PDF: ${err instanceof Error ? err.message : String(err)}`;
|
|
42
|
+
}
|
|
43
|
+
function processPdfContent(text, maxBytes) {
|
|
44
|
+
let output = text;
|
|
45
|
+
let truncated = false;
|
|
46
|
+
if (output.length > maxBytes) {
|
|
47
|
+
output = output.slice(0, maxBytes) + "\n\n[Output truncated due to size limit]";
|
|
48
|
+
truncated = true;
|
|
49
|
+
}
|
|
50
|
+
const isScanned = output.replace(/\[Page \d+\/\d+\]\n/g, "").trim().length === 0;
|
|
51
|
+
return { output, truncated, isScanned };
|
|
52
|
+
}
|
|
53
|
+
async function extractPdfText(buffer) {
|
|
54
|
+
const doc = await getDocument({ data: Uint8Array.from(buffer) }).promise;
|
|
55
|
+
const pageCount = doc.numPages;
|
|
56
|
+
const rawMeta = await doc.getMetadata();
|
|
57
|
+
const info = rawMeta.info;
|
|
58
|
+
const title = info?.["Title"] || null;
|
|
59
|
+
const author = info?.["Author"] || null;
|
|
60
|
+
const pages = [];
|
|
61
|
+
const limitedPageCount = Math.min(pageCount, OUTPUT_LIMITS.read_file.maxPdfPages);
|
|
62
|
+
try {
|
|
63
|
+
for (let i = 1; i <= limitedPageCount; i++) {
|
|
64
|
+
const page = await doc.getPage(i);
|
|
65
|
+
try {
|
|
66
|
+
const content = await page.getTextContent();
|
|
67
|
+
const pageText = content.items.map((item) => "str" in item ? item.str : "").join(" ");
|
|
68
|
+
pages.push(`[Page ${i}/${pageCount}]
|
|
69
|
+
${pageText}`);
|
|
70
|
+
} finally {
|
|
71
|
+
page.cleanup();
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
} finally {
|
|
75
|
+
doc.cleanup();
|
|
76
|
+
}
|
|
77
|
+
let text = pages.join("\n\n");
|
|
78
|
+
if (pageCount > limitedPageCount) {
|
|
79
|
+
text += `
|
|
80
|
+
|
|
81
|
+
[PDF has ${pageCount} pages, showing first ${limitedPageCount}. Use a shell command to process more.]`;
|
|
82
|
+
}
|
|
83
|
+
return { text, pageCount, title, author };
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// src/shared/constants.ts
|
|
87
|
+
var TEXT_MIME_PREFIXES = ["text/"];
|
|
88
|
+
var TEXT_MIME_EXACT = [
|
|
89
|
+
"application/json",
|
|
90
|
+
"application/xml",
|
|
91
|
+
"application/yaml",
|
|
92
|
+
"application/x-yaml",
|
|
93
|
+
"application/javascript",
|
|
94
|
+
"application/xhtml+xml",
|
|
95
|
+
"application/x-sh",
|
|
96
|
+
"image/svg+xml"
|
|
97
|
+
];
|
|
98
|
+
|
|
1
99
|
// src/server/llm/client-pure.ts
|
|
2
100
|
function parseToolArguments(raw, _meta) {
|
|
3
101
|
const input = raw?.trim() ? raw : "{}";
|
|
@@ -22,13 +120,14 @@ function buildModelParams(params) {
|
|
|
22
120
|
...params.maxTokens !== void 0 && { maxTokens: params.maxTokens }
|
|
23
121
|
};
|
|
24
122
|
}
|
|
25
|
-
function buildAttachmentContent(msgContent, attachments, modelSupportsVision) {
|
|
123
|
+
async function buildAttachmentContent(msgContent, attachments, modelSupportsVision) {
|
|
26
124
|
const content = [];
|
|
27
125
|
if (msgContent?.trim()) {
|
|
28
126
|
content.push({ type: "text", text: msgContent });
|
|
29
127
|
}
|
|
30
128
|
for (const attachment of attachments) {
|
|
31
|
-
|
|
129
|
+
const converted = await convertAttachment(attachment, modelSupportsVision);
|
|
130
|
+
content.push(converted);
|
|
32
131
|
}
|
|
33
132
|
return content;
|
|
34
133
|
}
|
|
@@ -62,7 +161,34 @@ function buildAssistantMessage(msg, thinkingField) {
|
|
|
62
161
|
}
|
|
63
162
|
return result;
|
|
64
163
|
}
|
|
65
|
-
function
|
|
164
|
+
async function convertAttachment(attachment, modelSupportsVision) {
|
|
165
|
+
const mimeType = attachment.mimeType;
|
|
166
|
+
if (TEXT_MIME_EXACT.includes(mimeType) || TEXT_MIME_PREFIXES.some((p) => mimeType.startsWith(p))) {
|
|
167
|
+
return {
|
|
168
|
+
type: "text",
|
|
169
|
+
text: `[File: ${attachment.filename || "file"}]
|
|
170
|
+
${attachment.data}`
|
|
171
|
+
};
|
|
172
|
+
}
|
|
173
|
+
if (mimeType === "application/pdf") {
|
|
174
|
+
try {
|
|
175
|
+
const base64Match = attachment.data.match(/^data:.*?;base64,(.+)$/);
|
|
176
|
+
if (base64Match?.[1]) {
|
|
177
|
+
const buffer = Buffer.from(base64Match[1], "base64");
|
|
178
|
+
const result = await extractPdfText(buffer);
|
|
179
|
+
return {
|
|
180
|
+
type: "text",
|
|
181
|
+
text: `[PDF: ${attachment.filename || "document.pdf"}]
|
|
182
|
+
${result.text}`
|
|
183
|
+
};
|
|
184
|
+
}
|
|
185
|
+
} catch {
|
|
186
|
+
}
|
|
187
|
+
return {
|
|
188
|
+
type: "text",
|
|
189
|
+
text: `[PDF: ${attachment.filename || "document.pdf"}] (could not extract text)`
|
|
190
|
+
};
|
|
191
|
+
}
|
|
66
192
|
if (modelSupportsVision) {
|
|
67
193
|
return {
|
|
68
194
|
type: "image_url",
|
|
@@ -80,41 +206,43 @@ function convertAttachmentSync(attachment, modelSupportsVision) {
|
|
|
80
206
|
text: `[Image: ${attachment.filename || "image"}] (vision not supported, cannot describe)`
|
|
81
207
|
};
|
|
82
208
|
}
|
|
83
|
-
function convertMessages(messages, modelSupportsVision, thinkingField) {
|
|
209
|
+
async function convertMessages(messages, modelSupportsVision, thinkingField) {
|
|
84
210
|
const filtered = messages.filter((msg) => {
|
|
85
211
|
return !(msg.role === "assistant" && !msg.content?.trim() && (!msg.toolCalls || msg.toolCalls.length === 0));
|
|
86
212
|
});
|
|
87
|
-
|
|
213
|
+
const result = [];
|
|
214
|
+
for (const msg of filtered) {
|
|
88
215
|
if (msg.role === "tool") {
|
|
89
216
|
if (msg.attachments && msg.attachments.length > 0) {
|
|
90
|
-
const content = buildAttachmentContent(msg.content, msg.attachments, modelSupportsVision);
|
|
91
|
-
|
|
217
|
+
const content = await buildAttachmentContent(msg.content, msg.attachments, modelSupportsVision);
|
|
218
|
+
result.push({
|
|
92
219
|
role: "tool",
|
|
93
220
|
content,
|
|
94
221
|
tool_call_id: msg.toolCallId
|
|
95
|
-
};
|
|
222
|
+
});
|
|
223
|
+
} else {
|
|
224
|
+
result.push({
|
|
225
|
+
role: "tool",
|
|
226
|
+
content: msg.content,
|
|
227
|
+
tool_call_id: msg.toolCallId
|
|
228
|
+
});
|
|
96
229
|
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
}
|
|
103
|
-
if (msg.role === "assistant") {
|
|
104
|
-
return buildAssistantMessage(msg, thinkingField);
|
|
105
|
-
}
|
|
106
|
-
if (msg.role === "user" && msg.attachments && msg.attachments.length > 0) {
|
|
107
|
-
const content = buildAttachmentContent(msg.content, msg.attachments, modelSupportsVision);
|
|
108
|
-
return {
|
|
230
|
+
} else if (msg.role === "assistant") {
|
|
231
|
+
result.push(buildAssistantMessage(msg, thinkingField));
|
|
232
|
+
} else if (msg.role === "user" && msg.attachments && msg.attachments.length > 0) {
|
|
233
|
+
const content = await buildAttachmentContent(msg.content, msg.attachments, modelSupportsVision);
|
|
234
|
+
result.push({
|
|
109
235
|
role: "user",
|
|
110
236
|
content
|
|
111
|
-
};
|
|
237
|
+
});
|
|
238
|
+
} else {
|
|
239
|
+
result.push({
|
|
240
|
+
role: msg.role,
|
|
241
|
+
content: msg.content
|
|
242
|
+
});
|
|
112
243
|
}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
content: msg.content
|
|
116
|
-
};
|
|
117
|
-
});
|
|
244
|
+
}
|
|
245
|
+
return result;
|
|
118
246
|
}
|
|
119
247
|
function convertTools(tools) {
|
|
120
248
|
return tools.map((tool) => ({
|
|
@@ -129,7 +257,7 @@ function convertTools(tools) {
|
|
|
129
257
|
async function buildChatCompletionCreateParams(model, request, profile, capabilities, reasoningEffort, isStreaming, thinkingField) {
|
|
130
258
|
const userVisionOverride = request.modelSettings?.supportsVision;
|
|
131
259
|
const modelSupportsVision = userVisionOverride ?? profile.supportsVision ?? false;
|
|
132
|
-
const convertedMessages = convertMessages(request.messages, modelSupportsVision, thinkingField);
|
|
260
|
+
const convertedMessages = await convertMessages(request.messages, modelSupportsVision, thinkingField);
|
|
133
261
|
const temperature = request.modelSettings?.temperature ?? request.temperature ?? profile.temperature;
|
|
134
262
|
const maxTokens = request.modelSettings?.maxTokens ?? request.maxTokens ?? profile.defaultMaxTokens;
|
|
135
263
|
const topP = request.modelSettings?.topP ?? profile.topP;
|
|
@@ -210,6 +338,11 @@ function mapFinishReason(reason) {
|
|
|
210
338
|
}
|
|
211
339
|
|
|
212
340
|
export {
|
|
341
|
+
OUTPUT_LIMITS,
|
|
342
|
+
isPdfBuffer,
|
|
343
|
+
formatPdfErrorMessage,
|
|
344
|
+
processPdfContent,
|
|
345
|
+
extractPdfText,
|
|
213
346
|
parseToolArguments,
|
|
214
347
|
buildModelParams,
|
|
215
348
|
getThinking,
|
|
@@ -219,4 +352,4 @@ export {
|
|
|
219
352
|
buildStreamingCreateParams,
|
|
220
353
|
mapFinishReason
|
|
221
354
|
};
|
|
222
|
-
//# sourceMappingURL=chunk-
|
|
355
|
+
//# sourceMappingURL=chunk-JHGKXQBO.js.map
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
} from "./chunk-YHEQTVFV.js";
|
|
13
13
|
import {
|
|
14
14
|
buildModelParams
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-JHGKXQBO.js";
|
|
16
16
|
import {
|
|
17
17
|
logger
|
|
18
18
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -678,4 +678,4 @@ export {
|
|
|
678
678
|
createChatDoneEvent,
|
|
679
679
|
consumeStreamGenerator
|
|
680
680
|
};
|
|
681
|
-
//# sourceMappingURL=chunk-
|
|
681
|
+
//# sourceMappingURL=chunk-QFSDJIUS.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
COMPACTION_PROMPT,
|
|
3
3
|
createMessageStartEvent
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-QFSDJIUS.js";
|
|
5
5
|
import {
|
|
6
6
|
getCurrentWindowMessageOptions
|
|
7
7
|
} from "./chunk-TFDK6VSG.js";
|
|
@@ -31,4 +31,4 @@ export {
|
|
|
31
31
|
shouldCompact,
|
|
32
32
|
getCompactionTarget
|
|
33
33
|
};
|
|
34
|
-
//# sourceMappingURL=chunk-
|
|
34
|
+
//# sourceMappingURL=chunk-YQ3MEZJL.js.map
|
package/dist/cli/dev.js
CHANGED
package/dist/cli/index.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createLLMClient
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-E4POUD2M.js";
|
|
4
4
|
import "./chunk-V4IE7HJY.js";
|
|
5
5
|
import "./chunk-YHEQTVFV.js";
|
|
6
6
|
import "./chunk-HNCM3D7Y.js";
|
|
7
|
-
import "./chunk-
|
|
7
|
+
import "./chunk-JHGKXQBO.js";
|
|
8
8
|
import "./chunk-ZO5EXQMG.js";
|
|
9
9
|
import "./chunk-K44MW7JJ.js";
|
|
10
10
|
import "./chunk-5WRI5ZAA.js";
|
|
11
11
|
export {
|
|
12
12
|
createLLMClient
|
|
13
13
|
};
|
|
14
|
-
//# sourceMappingURL=client-
|
|
14
|
+
//# sourceMappingURL=client-63U5CTPE.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getThinking,
|
|
8
8
|
mapFinishReason,
|
|
9
9
|
parseToolArguments
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-JHGKXQBO.js";
|
|
11
11
|
import "./chunk-5WRI5ZAA.js";
|
|
12
12
|
export {
|
|
13
13
|
buildModelParams,
|
|
@@ -19,4 +19,4 @@ export {
|
|
|
19
19
|
mapFinishReason,
|
|
20
20
|
parseToolArguments
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=client-pure-
|
|
22
|
+
//# sourceMappingURL=client-pure-XHH4RRLB.js.map
|
|
@@ -2,8 +2,8 @@ import {
|
|
|
2
2
|
appendCompactionPrompt,
|
|
3
3
|
getCompactionTarget,
|
|
4
4
|
shouldCompact
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-YQ3MEZJL.js";
|
|
6
|
+
import "./chunk-QFSDJIUS.js";
|
|
7
7
|
import "./chunk-TFDK6VSG.js";
|
|
8
8
|
import "./chunk-C3VLGVSQ.js";
|
|
9
9
|
import "./chunk-X5DOUA3Z.js";
|
|
@@ -12,7 +12,7 @@ import "./chunk-GMXKJGJ2.js";
|
|
|
12
12
|
import "./chunk-J2GP3J3X.js";
|
|
13
13
|
import "./chunk-V4IE7HJY.js";
|
|
14
14
|
import "./chunk-YHEQTVFV.js";
|
|
15
|
-
import "./chunk-
|
|
15
|
+
import "./chunk-JHGKXQBO.js";
|
|
16
16
|
import "./chunk-K44MW7JJ.js";
|
|
17
17
|
import "./chunk-5WRI5ZAA.js";
|
|
18
18
|
export {
|
|
@@ -20,4 +20,4 @@ export {
|
|
|
20
20
|
getCompactionTarget,
|
|
21
21
|
shouldCompact
|
|
22
22
|
};
|
|
23
|
-
//# sourceMappingURL=compactor-
|
|
23
|
+
//# sourceMappingURL=compactor-IPMMFFHM.js.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runAgentTurn,
|
|
3
3
|
runChatTurn
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-FCLCEIY4.js";
|
|
5
|
+
import "./chunk-6LK47TNE.js";
|
|
6
6
|
import {
|
|
7
7
|
TurnMetrics,
|
|
8
8
|
createChatDoneEvent,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
createMessageStartEvent,
|
|
11
11
|
createToolCallEvent,
|
|
12
12
|
createToolResultEvent
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-QFSDJIUS.js";
|
|
14
14
|
import "./chunk-4QBDV6LX.js";
|
|
15
15
|
import "./chunk-KXVFHMSM.js";
|
|
16
16
|
import "./chunk-TFCHWMOJ.js";
|
|
@@ -28,7 +28,7 @@ import "./chunk-EU3WWTFH.js";
|
|
|
28
28
|
import "./chunk-J2GP3J3X.js";
|
|
29
29
|
import "./chunk-V4IE7HJY.js";
|
|
30
30
|
import "./chunk-YHEQTVFV.js";
|
|
31
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-JHGKXQBO.js";
|
|
32
32
|
import "./chunk-K44MW7JJ.js";
|
|
33
33
|
import "./chunk-YD6NDTKF.js";
|
|
34
34
|
import "./chunk-WGAAQASA.js";
|
|
@@ -44,4 +44,4 @@ export {
|
|
|
44
44
|
runAgentTurn,
|
|
45
45
|
runChatTurn
|
|
46
46
|
};
|
|
47
|
-
//# sourceMappingURL=orchestrator-
|
|
47
|
+
//# sourceMappingURL=orchestrator-GNXKJPX4.js.map
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "openfox",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.68",
|
|
4
4
|
"description": "Local-LLM-first agentic coding assistant",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -25,7 +25,8 @@
|
|
|
25
25
|
"dist",
|
|
26
26
|
"!dist/**/*.map",
|
|
27
27
|
"dist/**/*.md",
|
|
28
|
-
"package.json"
|
|
28
|
+
"package.json",
|
|
29
|
+
"plugins-registry.json"
|
|
29
30
|
],
|
|
30
31
|
"scripts": {
|
|
31
32
|
"dev": "OPENFOX_DEV=true tsx watch src/cli/dev.ts --no-browser",
|
|
@@ -2,9 +2,9 @@ import {
|
|
|
2
2
|
buildRunChatTurnParams,
|
|
3
3
|
finalizeTurnCompletion,
|
|
4
4
|
generateSessionNameForSession
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-64GN6OPR.js";
|
|
6
|
+
import "./chunk-6LK47TNE.js";
|
|
7
|
+
import "./chunk-QFSDJIUS.js";
|
|
8
8
|
import "./chunk-4QBDV6LX.js";
|
|
9
9
|
import "./chunk-KXVFHMSM.js";
|
|
10
10
|
import "./chunk-TFCHWMOJ.js";
|
|
@@ -27,7 +27,7 @@ import "./chunk-EU3WWTFH.js";
|
|
|
27
27
|
import "./chunk-J2GP3J3X.js";
|
|
28
28
|
import "./chunk-V4IE7HJY.js";
|
|
29
29
|
import "./chunk-YHEQTVFV.js";
|
|
30
|
-
import "./chunk-
|
|
30
|
+
import "./chunk-JHGKXQBO.js";
|
|
31
31
|
import {
|
|
32
32
|
logger
|
|
33
33
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -178,7 +178,7 @@ var QueueProcessor = class {
|
|
|
178
178
|
backend: provider?.backend ?? llmClient.getBackend(),
|
|
179
179
|
model: llmClient.getModel()
|
|
180
180
|
};
|
|
181
|
-
const { runChatTurn } = await import("./orchestrator-
|
|
181
|
+
const { runChatTurn } = await import("./orchestrator-GNXKJPX4.js");
|
|
182
182
|
const runChatTurnParams = buildRunChatTurnParams({
|
|
183
183
|
sessionManager,
|
|
184
184
|
sessionId,
|
|
@@ -226,4 +226,4 @@ var QueueProcessor = class {
|
|
|
226
226
|
export {
|
|
227
227
|
QueueProcessor
|
|
228
228
|
};
|
|
229
|
-
//# sourceMappingURL=processor-
|
|
229
|
+
//# sourceMappingURL=processor-TIQEQDP7.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as Attachment, K as ToolMode, O as ToolResult, M as Message, T as Todo, b as ContextState, d as Criterion, h as Diagnostic, q as MetadataEntry, y as SessionMode, z as SessionPhase, t as Project, B as SessionSummary, w as Session } from './types-
|
|
1
|
+
import { A as Attachment, K as ToolMode, O as ToolResult, M as Message, T as Todo, b as ContextState, d as Criterion, h as Diagnostic, q as MetadataEntry, y as SessionMode, z as SessionPhase, t as Project, B as SessionSummary, w as Session } from './types-BsfYpEai.js';
|
|
2
2
|
|
|
3
3
|
type ClientMessageType = 'session.load' | 'context.compact' | 'context.checkDynamic' | 'context.applyDynamic' | 'runner.launch' | 'path.confirm' | 'ask.answer';
|
|
4
4
|
interface ClientMessage<T = unknown> {
|
package/dist/provider/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { r as ModelConfig } from '../types-
|
|
2
|
-
export { J as ToolCall } from '../types-
|
|
3
|
-
import { L as LLMCompletionRequest, a as LLMCompletionResponse, b as LLMStreamEvent } from '../types-
|
|
4
|
-
export { c as LLMMessage, d as LLMToolDefinition } from '../types-
|
|
1
|
+
import { r as ModelConfig } from '../types-BsfYpEai.js';
|
|
2
|
+
export { J as ToolCall } from '../types-BsfYpEai.js';
|
|
3
|
+
import { L as LLMCompletionRequest, a as LLMCompletionResponse, b as LLMStreamEvent } from '../types-CBC6lLqc.js';
|
|
4
|
+
export { c as LLMMessage, d as LLMToolDefinition } from '../types-CBC6lLqc.js';
|
|
5
5
|
|
|
6
6
|
type ProviderAuthState = 'disconnected' | 'pending' | 'connected' | 'expired' | 'error';
|
|
7
7
|
interface ProviderAuthStatus {
|
|
@@ -11,13 +11,13 @@ import {
|
|
|
11
11
|
import {
|
|
12
12
|
detectModel,
|
|
13
13
|
fetchAvailableModelsFromBackend
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-7OW6X764.js";
|
|
15
15
|
import "./chunk-J2GP3J3X.js";
|
|
16
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-E4POUD2M.js";
|
|
17
17
|
import "./chunk-V4IE7HJY.js";
|
|
18
18
|
import "./chunk-YHEQTVFV.js";
|
|
19
19
|
import "./chunk-HNCM3D7Y.js";
|
|
20
|
-
import "./chunk-
|
|
20
|
+
import "./chunk-JHGKXQBO.js";
|
|
21
21
|
import "./chunk-ZO5EXQMG.js";
|
|
22
22
|
import "./chunk-K44MW7JJ.js";
|
|
23
23
|
import {
|
|
@@ -396,4 +396,4 @@ export {
|
|
|
396
396
|
runProviderRemove,
|
|
397
397
|
runProviderUse
|
|
398
398
|
};
|
|
399
|
-
//# sourceMappingURL=provider-
|
|
399
|
+
//# sourceMappingURL=provider-IBIWR4AI.js.map
|
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
fetchAvailableModelsFromBackend,
|
|
4
4
|
fetchModelsWithContext,
|
|
5
5
|
parseDefaultModelSelection
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7OW6X764.js";
|
|
7
7
|
import "./chunk-J2GP3J3X.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-E4POUD2M.js";
|
|
9
9
|
import "./chunk-V4IE7HJY.js";
|
|
10
10
|
import "./chunk-YHEQTVFV.js";
|
|
11
11
|
import "./chunk-HNCM3D7Y.js";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-JHGKXQBO.js";
|
|
13
13
|
import "./chunk-ZO5EXQMG.js";
|
|
14
14
|
import "./chunk-K44MW7JJ.js";
|
|
15
15
|
import "./chunk-5WRI5ZAA.js";
|
|
@@ -19,4 +19,4 @@ export {
|
|
|
19
19
|
fetchModelsWithContext,
|
|
20
20
|
parseDefaultModelSelection
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=provider-manager-
|
|
22
|
+
//# sourceMappingURL=provider-manager-7C3JVOLW.js.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
VERSION,
|
|
3
3
|
createServer
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-DWZEGLHJ.js";
|
|
5
|
+
import "./chunk-COWJRBV4.js";
|
|
6
|
+
import "./chunk-FCLCEIY4.js";
|
|
7
|
+
import "./chunk-YQ3MEZJL.js";
|
|
8
|
+
import "./chunk-6LK47TNE.js";
|
|
9
|
+
import "./chunk-QFSDJIUS.js";
|
|
10
10
|
import "./chunk-4QBDV6LX.js";
|
|
11
11
|
import "./chunk-KXVFHMSM.js";
|
|
12
12
|
import "./chunk-TFCHWMOJ.js";
|
|
@@ -23,13 +23,13 @@ import "./chunk-X5DOUA3Z.js";
|
|
|
23
23
|
import "./chunk-XUPKS5FL.js";
|
|
24
24
|
import "./chunk-GMXKJGJ2.js";
|
|
25
25
|
import "./chunk-EU3WWTFH.js";
|
|
26
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-7OW6X764.js";
|
|
27
27
|
import "./chunk-J2GP3J3X.js";
|
|
28
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-E4POUD2M.js";
|
|
29
29
|
import "./chunk-V4IE7HJY.js";
|
|
30
30
|
import "./chunk-YHEQTVFV.js";
|
|
31
31
|
import "./chunk-HNCM3D7Y.js";
|
|
32
|
-
import "./chunk-
|
|
32
|
+
import "./chunk-JHGKXQBO.js";
|
|
33
33
|
import "./chunk-ZO5EXQMG.js";
|
|
34
34
|
import {
|
|
35
35
|
logger
|
|
@@ -207,4 +207,4 @@ async function runServe(options) {
|
|
|
207
207
|
export {
|
|
208
208
|
runServe
|
|
209
209
|
};
|
|
210
|
-
//# sourceMappingURL=serve-
|
|
210
|
+
//# sourceMappingURL=serve-QVVZ5SJE.js.map
|
package/dist/server/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { h as Diagnostic, u as Provider, r as ModelConfig, w as Session, B as SessionSummary, t as Project, y as SessionMode, z as SessionPhase, M as Message, d as Criterion, f as CriterionStatus, q as MetadataEntry, A as Attachment, b as ContextState, D as DangerLevel$1, H as StatsIdentity, O as ToolResult, a as Config } from '../types-
|
|
1
|
+
import { h as Diagnostic, u as Provider, r as ModelConfig, w as Session, B as SessionSummary, t as Project, y as SessionMode, z as SessionPhase, M as Message, d as Criterion, f as CriterionStatus, q as MetadataEntry, A as Attachment, b as ContextState, D as DangerLevel$1, H as StatsIdentity, O as ToolResult, a as Config } from '../types-BsfYpEai.js';
|
|
2
2
|
import { Server } from 'node:http';
|
|
3
|
-
import { e as LLMClient, d as LLMToolDefinition } from '../types-
|
|
4
|
-
import { a0 as QueuedMessage, a1 as ServerMessage } from '../protocol-
|
|
3
|
+
import { e as LLMClient, d as LLMToolDefinition } from '../types-CBC6lLqc.js';
|
|
4
|
+
import { a0 as QueuedMessage, a1 as ServerMessage } from '../protocol-DIhV-tAc.js';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Model-specific configuration profiles.
|
package/dist/server/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createServer,
|
|
3
3
|
createServerHandle
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
4
|
+
} from "../chunk-DWZEGLHJ.js";
|
|
5
|
+
import "../chunk-COWJRBV4.js";
|
|
6
|
+
import "../chunk-FCLCEIY4.js";
|
|
7
|
+
import "../chunk-YQ3MEZJL.js";
|
|
8
|
+
import "../chunk-6LK47TNE.js";
|
|
9
|
+
import "../chunk-QFSDJIUS.js";
|
|
10
10
|
import "../chunk-4QBDV6LX.js";
|
|
11
11
|
import "../chunk-KXVFHMSM.js";
|
|
12
12
|
import "../chunk-TFCHWMOJ.js";
|
|
@@ -21,13 +21,13 @@ import "../chunk-X5DOUA3Z.js";
|
|
|
21
21
|
import "../chunk-XUPKS5FL.js";
|
|
22
22
|
import "../chunk-GMXKJGJ2.js";
|
|
23
23
|
import "../chunk-EU3WWTFH.js";
|
|
24
|
-
import "../chunk-
|
|
24
|
+
import "../chunk-7OW6X764.js";
|
|
25
25
|
import "../chunk-J2GP3J3X.js";
|
|
26
|
-
import "../chunk-
|
|
26
|
+
import "../chunk-E4POUD2M.js";
|
|
27
27
|
import "../chunk-V4IE7HJY.js";
|
|
28
28
|
import "../chunk-YHEQTVFV.js";
|
|
29
29
|
import "../chunk-HNCM3D7Y.js";
|
|
30
|
-
import "../chunk-
|
|
30
|
+
import "../chunk-JHGKXQBO.js";
|
|
31
31
|
import "../chunk-ZO5EXQMG.js";
|
|
32
32
|
import "../chunk-K44MW7JJ.js";
|
|
33
33
|
import "../chunk-VUQCQXXJ.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createWebSocketServer,
|
|
3
3
|
signalMcpReady
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-COWJRBV4.js";
|
|
5
|
+
import "./chunk-FCLCEIY4.js";
|
|
6
|
+
import "./chunk-YQ3MEZJL.js";
|
|
7
|
+
import "./chunk-6LK47TNE.js";
|
|
8
|
+
import "./chunk-QFSDJIUS.js";
|
|
9
9
|
import "./chunk-4QBDV6LX.js";
|
|
10
10
|
import "./chunk-KXVFHMSM.js";
|
|
11
11
|
import "./chunk-TFCHWMOJ.js";
|
|
@@ -23,7 +23,7 @@ import "./chunk-EU3WWTFH.js";
|
|
|
23
23
|
import "./chunk-J2GP3J3X.js";
|
|
24
24
|
import "./chunk-V4IE7HJY.js";
|
|
25
25
|
import "./chunk-YHEQTVFV.js";
|
|
26
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-JHGKXQBO.js";
|
|
27
27
|
import "./chunk-K44MW7JJ.js";
|
|
28
28
|
import "./chunk-VUQCQXXJ.js";
|
|
29
29
|
import "./chunk-YD6NDTKF.js";
|
|
@@ -34,4 +34,4 @@ export {
|
|
|
34
34
|
createWebSocketServer,
|
|
35
35
|
signalMcpReady
|
|
36
36
|
};
|
|
37
|
-
//# sourceMappingURL=server-
|
|
37
|
+
//# sourceMappingURL=server-ECKS2Y3R.js.map
|
package/dist/shared/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { M as Message, S as SessionStats } from '../types-
|
|
2
|
-
export { A as Attachment, C as CallStatsDataPoint, a as Config, b as ContextState, c as ContextWindow, d as Criterion, e as CriterionAttempt, f as CriterionStatus, g as CriterionValidation, D as DangerLevel, h as Diagnostic, E as EditContextEdit, i as EditContextLine, j as EditContextRegion, k as ElementData, l as ExecutionState, F as FileReadEntry, I as InjectedFile, L as LLMCallStats, m as LlmBackend, n as MessageRole, o as MessageSegment, p as MessageStats, q as MetadataEntry, r as ModelConfig, s as ModelSessionStats, P as PreparingToolCall, t as Project, u as Provider, v as ProviderBackend, R as RecentUserPrompt, w as Session, x as SessionMetadata, y as SessionMode, z as SessionPhase, B as SessionSummary, G as StatsDataPoint, H as StatsIdentity, T as Todo, J as ToolCall, K as ToolMode, N as ToolName, O as ToolResult, V as ValidationResult } from '../types-
|
|
3
|
-
export { A as AgentEvent, a as AskAnswerPayload, b as AskUserEvent, B as BackgroundProcess, c as BackgroundProcessExitedPayload, d as BackgroundProcessOutputPayload, e as BackgroundProcessRemovedPayload, f as BackgroundProcessStartedPayload, g as BackgroundProcessStatus, C as ChatAskUserPayload, h as ChatDeltaPayload, i as ChatDonePayload, j as ChatErrorPayload, k as ChatFormatRetryPayload, l as ChatMessagePayload, m as ChatMessageUpdatedPayload, n as ChatPathConfirmationPayload, o as ChatProgressPayload, p as ChatThinkingPayload, q as ChatTodoPayload, r as ChatToolCallPayload, s as ChatToolOutputPayload, t as ChatToolPreparingPayload, u as ChatToolResultPayload, v as ChatVisionFallbackPayload, w as ClientMessage, x as ClientMessageType, y as ContextCompactionEvent, z as ContextStatePayload, D as CriteriaUpdatedPayload, E as DevServerOutputPayload, F as DevServerStatePayload, G as ErrorPayload, H as GitDiffFile, I as GitStatusPayload, L as LogLine, J as LspDiagnosticsPayload, M as MetadataUpdatedPayload, K as ModeChangedPayload, P as PathConfirmPayload, N as PathConfirmationReason, O as PendingPathConfirmationPayload, Q as PendingQuestionPayload, R as PhaseChangedPayload, S as ProjectDeletedPayload, T as ProjectListPayload, U as ProjectStatePayload, V as ProviderChangedPayload, W as QueueAddedEvent, X as QueueCancelledEvent, Y as QueueDrainedEvent, Z as QueueEvent, _ as QueueEventType, $ as QueueStatePayload, a0 as QueuedMessage, a1 as ServerMessage, a2 as ServerMessageType, a3 as SessionListPayload, a4 as SessionLoadPayload, a5 as SessionNameGeneratedPayload, a6 as SessionRunningPayload, a7 as SessionStatePayload, a8 as TaskCompletedPayload, a9 as createClientMessage, aa as createServerMessage, ab as isClientMessage, ac as isServerMessage } from '../protocol-
|
|
1
|
+
import { M as Message, S as SessionStats } from '../types-BsfYpEai.js';
|
|
2
|
+
export { A as Attachment, C as CallStatsDataPoint, a as Config, b as ContextState, c as ContextWindow, d as Criterion, e as CriterionAttempt, f as CriterionStatus, g as CriterionValidation, D as DangerLevel, h as Diagnostic, E as EditContextEdit, i as EditContextLine, j as EditContextRegion, k as ElementData, l as ExecutionState, F as FileReadEntry, I as InjectedFile, L as LLMCallStats, m as LlmBackend, n as MessageRole, o as MessageSegment, p as MessageStats, q as MetadataEntry, r as ModelConfig, s as ModelSessionStats, P as PreparingToolCall, t as Project, u as Provider, v as ProviderBackend, R as RecentUserPrompt, w as Session, x as SessionMetadata, y as SessionMode, z as SessionPhase, B as SessionSummary, G as StatsDataPoint, H as StatsIdentity, T as Todo, J as ToolCall, K as ToolMode, N as ToolName, O as ToolResult, V as ValidationResult } from '../types-BsfYpEai.js';
|
|
3
|
+
export { A as AgentEvent, a as AskAnswerPayload, b as AskUserEvent, B as BackgroundProcess, c as BackgroundProcessExitedPayload, d as BackgroundProcessOutputPayload, e as BackgroundProcessRemovedPayload, f as BackgroundProcessStartedPayload, g as BackgroundProcessStatus, C as ChatAskUserPayload, h as ChatDeltaPayload, i as ChatDonePayload, j as ChatErrorPayload, k as ChatFormatRetryPayload, l as ChatMessagePayload, m as ChatMessageUpdatedPayload, n as ChatPathConfirmationPayload, o as ChatProgressPayload, p as ChatThinkingPayload, q as ChatTodoPayload, r as ChatToolCallPayload, s as ChatToolOutputPayload, t as ChatToolPreparingPayload, u as ChatToolResultPayload, v as ChatVisionFallbackPayload, w as ClientMessage, x as ClientMessageType, y as ContextCompactionEvent, z as ContextStatePayload, D as CriteriaUpdatedPayload, E as DevServerOutputPayload, F as DevServerStatePayload, G as ErrorPayload, H as GitDiffFile, I as GitStatusPayload, L as LogLine, J as LspDiagnosticsPayload, M as MetadataUpdatedPayload, K as ModeChangedPayload, P as PathConfirmPayload, N as PathConfirmationReason, O as PendingPathConfirmationPayload, Q as PendingQuestionPayload, R as PhaseChangedPayload, S as ProjectDeletedPayload, T as ProjectListPayload, U as ProjectStatePayload, V as ProviderChangedPayload, W as QueueAddedEvent, X as QueueCancelledEvent, Y as QueueDrainedEvent, Z as QueueEvent, _ as QueueEventType, $ as QueueStatePayload, a0 as QueuedMessage, a1 as ServerMessage, a2 as ServerMessageType, a3 as SessionListPayload, a4 as SessionLoadPayload, a5 as SessionNameGeneratedPayload, a6 as SessionRunningPayload, a7 as SessionStatePayload, a8 as TaskCompletedPayload, a9 as createClientMessage, aa as createServerMessage, ab as isClientMessage, ac as isServerMessage } from '../protocol-DIhV-tAc.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Session stats computation - aggregates response-level MessageStats from
|