neoctl 0.2.47 → 0.2.48
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/README.md +59 -59
- package/dist/agents/agent-activity.js +1 -1
- package/dist/agents/agent-activity.js.map +1 -1
- package/dist/context/prompts.js +3 -4
- package/dist/context/prompts.js.map +1 -1
- package/dist/context/system.md +16 -16
- package/dist/core/message-pipeline.js +2 -2
- package/dist/core/message-pipeline.js.map +1 -1
- package/dist/core/query-engine.d.ts +6 -0
- package/dist/core/query-engine.js +60 -3
- package/dist/core/query-engine.js.map +1 -1
- package/dist/execution/filesystem.js +22 -22
- package/dist/execution/process.js +44 -44
- package/dist/model/model-metadata.json +137 -137
- package/dist/repl/index.js +30 -30
- package/dist/repl/index.js.map +1 -1
- package/dist/session/tool-result-memory.js +2 -2
- package/dist/session/tool-result-memory.js.map +1 -1
- package/dist/tools/builtins/image-capabilities.d.ts +2 -2
- package/dist/tools/builtins/image-capabilities.js +3 -3
- package/dist/tools/builtins/image-capabilities.js.map +1 -1
- package/dist/tools/builtins/image-generation-tool.js +1 -1
- package/dist/tools/builtins/image-generation-tool.js.map +1 -1
- package/dist/tools/builtins/image-loader-tool.js +2 -1
- package/dist/tools/builtins/image-loader-tool.js.map +1 -1
- package/dist/web/demo-tools.js +1 -1
- package/dist/web/demo-tools.js.map +1 -1
- package/dist/web/html.js +5 -5
- package/dist/web/index.d.ts +1 -0
- package/dist/web/index.js +15 -5
- package/dist/web/index.js.map +1 -1
- package/dist/web/terminal-presentation.js +1 -1
- package/dist/web/terminal-presentation.js.map +1 -1
- package/docs/prompt-config.md +86 -86
- package/package.json +1 -1
- package/scripts/copy-prompt-resources.mjs +5 -5
package/dist/web/index.js
CHANGED
|
@@ -227,6 +227,7 @@ export async function createWebRuntime(options = {}) {
|
|
|
227
227
|
taskNotificationSource: createTaskNotificationSource(taskStore),
|
|
228
228
|
commands: replCommandDefinitions.map((command) => command.usage),
|
|
229
229
|
plugins: [...(options.plugins ?? []), ...activePlugins.map((plugin) => plugin.id)],
|
|
230
|
+
workspacePaths: options.workspacePaths,
|
|
230
231
|
cwdTransitionPaths: options.cwdTransitionPaths,
|
|
231
232
|
onCwdTransitionConsumed: options.onCwdTransitionConsumed,
|
|
232
233
|
session: {
|
|
@@ -2560,6 +2561,15 @@ export async function handleWebRequest(req, res, router) {
|
|
|
2560
2561
|
if (req.method === "GET" && url.pathname === "/api/runtime-context")
|
|
2561
2562
|
return sendJson(res, await repl.runtimeContext());
|
|
2562
2563
|
const workspaceRepl = repl;
|
|
2564
|
+
if (req.method === "GET" && url.pathname === "/api/cwd/scope") {
|
|
2565
|
+
return sendJson(res, workspaceRepl.workspaceScope?.() ?? actionFailure("CWD_NOT_CONFIGURED", "Workspace scope is not configured"));
|
|
2566
|
+
}
|
|
2567
|
+
if (req.method === "POST" && ["/api/cwd/add", "/api/cwd/remove"].includes(url.pathname)) {
|
|
2568
|
+
const body = await readJsonBody(req);
|
|
2569
|
+
return sendJson(res, workspaceRepl.updateWorkspaceScope
|
|
2570
|
+
? await workspaceRepl.updateWorkspaceScope(body.path, url.pathname.endsWith("/remove"))
|
|
2571
|
+
: actionFailure("CWD_NOT_CONFIGURED", "Workspace scope is not configured"));
|
|
2572
|
+
}
|
|
2563
2573
|
if (req.method === "GET" && url.pathname === "/api/cwd") {
|
|
2564
2574
|
return sendJson(res, workspaceRepl.browseWorkspace
|
|
2565
2575
|
? await workspaceRepl.browseWorkspace(url.searchParams.get("path") ?? undefined)
|
|
@@ -4086,13 +4096,13 @@ function formatImageGenerationToolResult(output, ok) {
|
|
|
4086
4096
|
const lines = [`${mode === "edit" ? "edited" : "generated"} ${returnedImages ?? 0} image${returnedImages === 1 ? "" : "s"}`];
|
|
4087
4097
|
const details = [provider, model, size, quality && quality !== "auto" ? quality : undefined, format].filter((value) => Boolean(value));
|
|
4088
4098
|
if (details.length > 0)
|
|
4089
|
-
lines.push(`${output.requested ? "requested: " : ""}${details.join("
|
|
4099
|
+
lines.push(`${output.requested ? "requested: " : ""}${details.join(" ")}`);
|
|
4090
4100
|
if (isRecord(output.actual)) {
|
|
4091
4101
|
lines.push(`upstream-reported quality: ${String(output.actual.quality ?? "unreported")}`);
|
|
4092
4102
|
if (Array.isArray(output.images))
|
|
4093
4103
|
for (const image of output.images.filter(isRecord)) {
|
|
4094
4104
|
if (typeof image.width === "number" && typeof image.height === "number")
|
|
4095
|
-
lines.push(`actual image: ${image.width}x${image.height}
|
|
4105
|
+
lines.push(`actual image: ${image.width}x${image.height} ${String(image.mimeType ?? "")}`);
|
|
4096
4106
|
}
|
|
4097
4107
|
}
|
|
4098
4108
|
if (Array.isArray(output.warnings))
|
|
@@ -4137,7 +4147,7 @@ function formatListToolResult(output, ok) {
|
|
|
4137
4147
|
lines.push(`type: ${typeValue}`);
|
|
4138
4148
|
const counts = [returnedEntries !== undefined ? `${returnedEntries} shown` : undefined, totalFiles !== undefined ? `${totalFiles} files` : undefined, totalDirectories !== undefined ? `${totalDirectories} dirs` : undefined].filter((value) => Boolean(value));
|
|
4139
4149
|
if (counts.length > 0)
|
|
4140
|
-
lines.push(`entries: ${counts.join("
|
|
4150
|
+
lines.push(`entries: ${counts.join(" ")}`);
|
|
4141
4151
|
if (names.length > 0)
|
|
4142
4152
|
lines.push("sample:", ...names.map((name) => ` ${name}`));
|
|
4143
4153
|
return lines.join("\n");
|
|
@@ -4183,7 +4193,7 @@ function formatWebSearchToolResult(output, ok) {
|
|
|
4183
4193
|
return;
|
|
4184
4194
|
const title = typeof item.title === "string" && item.title.trim() ? item.title.trim() : "Untitled";
|
|
4185
4195
|
const url = typeof item.url === "string" ? item.url : "";
|
|
4186
|
-
const published = typeof item.published === "string" ? `
|
|
4196
|
+
const published = typeof item.published === "string" ? ` ${item.published}` : "";
|
|
4187
4197
|
lines.push(`[${index + 1}] ${title}${published}`);
|
|
4188
4198
|
if (url)
|
|
4189
4199
|
lines.push(url);
|
|
@@ -4210,7 +4220,7 @@ function formatGrepToolResult(output, ok) {
|
|
|
4210
4220
|
if (grepPath !== undefined)
|
|
4211
4221
|
lines.push(`path: ${grepPath}`);
|
|
4212
4222
|
const countParts = [`${returnedMatches ?? matches.length} shown`, totalMatchesKnown !== undefined ? `${totalMatchesKnown} known` : undefined, truncated ? "truncated" : undefined].filter((value) => Boolean(value));
|
|
4213
|
-
lines.push(`matches: ${countParts.join("
|
|
4223
|
+
lines.push(`matches: ${countParts.join(" ")}`);
|
|
4214
4224
|
if (matches.length === 0)
|
|
4215
4225
|
return [...lines, "no matches"].join("\n");
|
|
4216
4226
|
lines.push("results:");
|