stitchkit 0.119.0 → 0.121.0
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/CHANGELOG.md +68 -0
- package/README.md +10 -7
- package/dist/agent-runtime/coding-discovery.d.ts +25 -0
- package/dist/agent-runtime/coding-discovery.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-automaton.d.ts +37 -0
- package/dist/agent-runtime/coding-search-automaton.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-case-fold.d.ts +4 -0
- package/dist/agent-runtime/coding-search-case-fold.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-class-ranges.d.ts +10 -0
- package/dist/agent-runtime/coding-search-class-ranges.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-contract.d.ts +86 -0
- package/dist/agent-runtime/coding-search-contract.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-limits.d.ts +13 -0
- package/dist/agent-runtime/coding-search-limits.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-matcher.d.ts +33 -0
- package/dist/agent-runtime/coding-search-matcher.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-output.d.ts +5 -0
- package/dist/agent-runtime/coding-search-output.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-regex-syntax.d.ts +39 -0
- package/dist/agent-runtime/coding-search-regex-syntax.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-unit-classes.d.ts +31 -0
- package/dist/agent-runtime/coding-search-unit-classes.d.ts.map +1 -0
- package/dist/agent-runtime/coding-shell-process.d.ts +1 -0
- package/dist/agent-runtime/coding-shell-process.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-contract.d.ts +8 -3
- package/dist/agent-runtime/coding-tool-contract.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-files.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-listing.d.ts +1 -11
- package/dist/agent-runtime/coding-tool-listing.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-paths.d.ts +6 -2
- package/dist/agent-runtime/coding-tool-paths.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-refusals.d.ts +6 -0
- package/dist/agent-runtime/coding-tool-refusals.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-search-patch.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-search.d.ts +113 -0
- package/dist/agent-runtime/coding-tool-search.d.ts.map +1 -0
- package/dist/agent-runtime/coding-tool-shell.d.ts.map +1 -1
- package/dist/agent-runtime/contained-scan-budget.d.ts +32 -0
- package/dist/agent-runtime/contained-scan-budget.d.ts.map +1 -0
- package/dist/agent-runtime/contained-scan-contract.d.ts +52 -0
- package/dist/agent-runtime/contained-scan-contract.d.ts.map +1 -0
- package/dist/agent-runtime/contained-scan.d.ts +48 -13
- package/dist/agent-runtime/contained-scan.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox.d.ts +5 -1
- package/dist/agent-runtime/sandbox.d.ts.map +1 -1
- package/dist/agent-runtime/workspace-glob.d.ts +6 -0
- package/dist/agent-runtime/workspace-glob.d.ts.map +1 -0
- package/dist/entrypoints/agent-runtime/coding-tools.js +7 -7
- package/dist/entrypoints/agent-runtime/harness.js +5 -5
- package/dist/entrypoints/agent-runtime/realtime.js +3 -3
- package/dist/entrypoints/agent-runtime/sandbox.js +8 -8
- package/dist/entrypoints/agent-runtime/sqlite/bun.js +9 -9
- package/dist/entrypoints/agent-runtime/sqlite/node.js +9 -9
- package/dist/entrypoints/agent-runtime/testing.js +9 -9
- package/dist/entrypoints/agent-runtime.js +16 -14
- package/dist/entrypoints/application/diagnostic-journal.js +3 -3
- package/dist/entrypoints/application/directory-inbox.js +5 -5
- package/dist/entrypoints/application.js +6 -6
- package/dist/entrypoints/cli/publish.js +5 -5
- package/dist/entrypoints/cli.js +8 -8
- package/dist/entrypoints/contract.js +4 -4
- package/dist/entrypoints/files.js +4 -4
- package/dist/entrypoints/http.js +2 -2
- package/dist/entrypoints/index.js +2 -2
- package/dist/entrypoints/node.js +1 -1
- package/dist/entrypoints/process/owner-loss.js +2 -1
- package/dist/entrypoints/process.js +4 -4
- package/dist/entrypoints/remote.js +1 -1
- package/dist/entrypoints/server.js +12 -12
- package/dist/entrypoints/telegram/screens.js +5 -5
- package/dist/entrypoints/telegram.js +8 -8
- package/dist/entrypoints/testing.js +2 -2
- package/dist/entrypoints/tools/agent.d.ts +9 -0
- package/dist/entrypoints/tools/agent.d.ts.map +1 -0
- package/dist/entrypoints/tools/agent.js +16 -0
- package/dist/entrypoints/tools/connections.js +4 -4
- package/dist/entrypoints/tools/mcp.js +104 -4
- package/dist/entrypoints/tools/toolkit.d.ts +9 -0
- package/dist/entrypoints/tools/toolkit.d.ts.map +1 -0
- package/dist/entrypoints/tools/toolkit.js +40 -0
- package/dist/entrypoints/tools.d.ts +0 -10
- package/dist/entrypoints/tools.d.ts.map +1 -1
- package/dist/entrypoints/tools.js +25 -69
- package/dist/{index-s0qjs6ee.js → index-0fra8xvy.js} +9 -81
- package/dist/{index-rxcgp4b9.js → index-10rg78vf.js} +1 -1
- package/dist/index-1psbyyhj.js +21 -0
- package/dist/index-3prvb42w.js +30 -0
- package/dist/{index-ba7are04.js → index-4tyt1qya.js} +1 -1
- package/dist/index-568w258r.js +76 -0
- package/dist/{index-fqd4yqwd.js → index-6j15ktag.js} +1 -1
- package/dist/{index-zrdcmg6j.js → index-72xtvcvr.js} +40 -6
- package/dist/{index-6a69xzrx.js → index-7zwtbak8.js} +5 -46
- package/dist/{index-fcqj44mb.js → index-8ryydawp.js} +4 -4
- package/dist/{index-q968hy6y.js → index-aqmadanx.js} +2 -2
- package/dist/{index-s20s2mad.js → index-bgcwxhxh.js} +16 -14
- package/dist/index-bph35vpy.js +77 -0
- package/dist/{index-arjmb6de.js → index-eeahxwvg.js} +60 -76
- package/dist/{index-57gqaq8b.js → index-f6pw75e1.js} +1 -1
- package/dist/{index-f4njz9j0.js → index-gq3fnq3f.js} +1 -1
- package/dist/{index-ynrf908v.js → index-gtx3eknx.js} +1 -1
- package/dist/index-h1j71dr1.js +48 -0
- package/dist/{index-nn9qvkww.js → index-j95jp7ee.js} +45 -9
- package/dist/{index-mgb7r8b8.js → index-jswst0h3.js} +1 -1
- package/dist/{index-bbvc59gw.js → index-knmnj11j.js} +9 -180
- package/dist/{index-2kbysk9s.js → index-m5m9rmvt.js} +2 -0
- package/dist/{index-g444vfz2.js → index-nwm3ww60.js} +1 -1
- package/dist/{index-yk4g8805.js → index-pq7rkwkk.js} +1 -30
- package/dist/index-qaqxdbxf.js +2857 -0
- package/dist/{index-x8d9fdeg.js → index-qctbzmg9.js} +8 -4
- package/dist/index-s9a0fjh3.js +305 -0
- package/dist/index-sb9dr3tq.js +14 -0
- package/dist/{index-tvtacc9a.js → index-zyc64nbh.js} +1 -34
- package/dist/internal/contained-directory.d.ts +1 -1
- package/dist/internal/contained-directory.d.ts.map +1 -1
- package/dist/internal/contained-files.d.ts +18 -51
- package/dist/internal/contained-files.d.ts.map +1 -1
- package/dist/internal/contained-read.d.ts +17 -0
- package/dist/internal/contained-read.d.ts.map +1 -0
- package/dist/internal/darwin-binding.d.ts +3 -1
- package/dist/internal/darwin-binding.d.ts.map +1 -1
- package/dist/process/bun-child.d.ts.map +1 -1
- package/dist/process/command-owner.d.ts.map +1 -1
- package/dist/process/group.d.ts +2 -0
- package/dist/process/group.d.ts.map +1 -1
- package/dist/process/launch.d.ts +1 -0
- package/dist/process/launch.d.ts.map +1 -1
- package/dist/process/owned-child.d.ts.map +1 -1
- package/dist/process/owner-loss-guard.d.ts.map +1 -1
- package/dist/process/owner-loss-protocol.d.ts +1 -0
- package/dist/process/owner-loss-protocol.d.ts.map +1 -1
- package/llms/agent-runtime-coding-tools.txt +9 -9
- package/llms/agent-runtime-harness.txt +4 -3
- package/llms/agent-runtime-sandbox.txt +1 -1
- package/llms/agent-runtime.2.txt +20 -2
- package/llms/agent-runtime.3.txt +4 -46
- package/llms/agent-runtime.4.txt +113 -0
- package/llms/agent-runtime.txt +70 -37
- package/llms/application.3.txt +5 -2
- package/llms/cli.txt +1 -1
- package/llms/contract.txt +1 -1
- package/llms/process.txt +3 -1
- package/llms/server.5.txt +2 -0
- package/llms/stitchkit.txt +15 -9
- package/llms/testing.txt +4 -6
- package/llms/tools-agent.txt +24 -0
- package/llms/tools-mcp.txt +71 -6
- package/llms/tools-toolkit.txt +23 -0
- package/llms/tools.2.txt +6 -3
- package/llms/tools.3.txt +8 -77
- package/llms/tools.txt +8 -8
- package/llms/{upgrading-0.106.0-0.119.0.txt → upgrading-0.106.0-0.121.0.txt} +84 -3
- package/llms/upgrading.txt +1 -1
- package/llms-full.txt +360 -139
- package/llms.txt +11 -9
- package/native/darwin-arm64.node +0 -0
- package/native/darwin-x64.node +0 -0
- package/native-assets.json +4 -4
- package/package.json +10 -2
- package/dist/index-1k18qzqa.js +0 -1478
- package/dist/index-6f49krb5.js +0 -107
- package/dist/{index-2dfvv1jg.js → index-2fc1k9k2.js} +0 -0
- package/dist/{index-qndsr7f0.js → index-5efrpfmj.js} +3 -3
- /package/dist/{index-cyxp8rbf.js → index-mtwh9hyp.js} +0 -0
package/dist/index-6f49krb5.js
DELETED
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
openDirectoryAt,
|
|
3
|
-
openPinnedDirectory,
|
|
4
|
-
openFileAt,
|
|
5
|
-
listAt,
|
|
6
|
-
readContainedUtf8Handle
|
|
7
|
-
} from "./index-arjmb6de.js";
|
|
8
|
-
|
|
9
|
-
// src/agent-runtime/contained-scan.ts
|
|
10
|
-
import path from "node:path";
|
|
11
|
-
async function walkContainedFiles(input) {
|
|
12
|
-
const scan = await scanContainedFiles({ ...input, symlinks: "refuse" });
|
|
13
|
-
if (scan.truncated)
|
|
14
|
-
throw new Error("Contained file traversal exceeded its bounds");
|
|
15
|
-
return scan.files;
|
|
16
|
-
}
|
|
17
|
-
async function scanContainedFiles(input) {
|
|
18
|
-
const files = [];
|
|
19
|
-
let truncated = false;
|
|
20
|
-
let skippedDirectories = 0;
|
|
21
|
-
let skippedSymlinks = 0;
|
|
22
|
-
const denied = [];
|
|
23
|
-
let deniedTruncated = false;
|
|
24
|
-
const root = await openPinnedDirectory(input.root);
|
|
25
|
-
const visit = async (directory, relativeDirectory, depth) => {
|
|
26
|
-
if (truncated)
|
|
27
|
-
return;
|
|
28
|
-
if (depth > input.maxDepth) {
|
|
29
|
-
truncated = true;
|
|
30
|
-
return;
|
|
31
|
-
}
|
|
32
|
-
const entries = [...await listAt(directory)];
|
|
33
|
-
entries.sort((left, right) => left.name.localeCompare(right.name));
|
|
34
|
-
for (const entry of entries) {
|
|
35
|
-
const relative = relativeDirectory ? path.join(relativeDirectory, entry.name) : entry.name;
|
|
36
|
-
const kind = entry.isDirectory() ? "directory" : entry.isSymbolicLink() ? "symlink" : entry.isFile() ? "file" : "other";
|
|
37
|
-
if (kind === "file" && input.includeFile && !input.includeFile(relative))
|
|
38
|
-
continue;
|
|
39
|
-
if (input.authorizePath && !await input.authorizePath(relative, kind)) {
|
|
40
|
-
if (denied.length < input.maxFiles)
|
|
41
|
-
denied.push({ relative, kind });
|
|
42
|
-
else
|
|
43
|
-
deniedTruncated = true;
|
|
44
|
-
continue;
|
|
45
|
-
}
|
|
46
|
-
if (entry.isSymbolicLink()) {
|
|
47
|
-
if (input.symlinks === "refuse") {
|
|
48
|
-
throw new Error(`Contained file traversal refuses symlink: ${relative}`);
|
|
49
|
-
}
|
|
50
|
-
skippedSymlinks += 1;
|
|
51
|
-
continue;
|
|
52
|
-
}
|
|
53
|
-
if (entry.isDirectory()) {
|
|
54
|
-
if (input.excludeDirectory?.(relative)) {
|
|
55
|
-
skippedDirectories += 1;
|
|
56
|
-
continue;
|
|
57
|
-
}
|
|
58
|
-
let child;
|
|
59
|
-
try {
|
|
60
|
-
child = await openDirectoryAt(directory, entry.name);
|
|
61
|
-
} catch (error) {
|
|
62
|
-
if (input.symlinks === "skip") {
|
|
63
|
-
skippedSymlinks += 1;
|
|
64
|
-
continue;
|
|
65
|
-
}
|
|
66
|
-
throw error;
|
|
67
|
-
}
|
|
68
|
-
try {
|
|
69
|
-
await visit(child, relative, depth + 1);
|
|
70
|
-
} finally {
|
|
71
|
-
await child.close();
|
|
72
|
-
}
|
|
73
|
-
continue;
|
|
74
|
-
}
|
|
75
|
-
if (!entry.isFile())
|
|
76
|
-
continue;
|
|
77
|
-
if (files.length >= input.maxFiles) {
|
|
78
|
-
truncated = true;
|
|
79
|
-
return;
|
|
80
|
-
}
|
|
81
|
-
let content;
|
|
82
|
-
if (input.readMaxBytes !== undefined) {
|
|
83
|
-
try {
|
|
84
|
-
const handle = await openFileAt(directory, entry.name);
|
|
85
|
-
try {
|
|
86
|
-
content = await readContainedUtf8Handle(handle, input.readMaxBytes);
|
|
87
|
-
} finally {
|
|
88
|
-
await handle.close();
|
|
89
|
-
}
|
|
90
|
-
} catch (error) {
|
|
91
|
-
if (input.skipUnreadable)
|
|
92
|
-
continue;
|
|
93
|
-
throw error;
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
files.push({ absolute: relative, relative, ...content && { content } });
|
|
97
|
-
}
|
|
98
|
-
};
|
|
99
|
-
try {
|
|
100
|
-
await visit(root, "", 0);
|
|
101
|
-
} finally {
|
|
102
|
-
await root.close();
|
|
103
|
-
}
|
|
104
|
-
return { files, truncated, skippedDirectories, skippedSymlinks, denied, deniedTruncated };
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
export { walkContainedFiles, scanContainedFiles };
|
|
File without changes
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
chunksOf
|
|
3
3
|
} from "./index-cjbn98zt.js";
|
|
4
|
-
import {
|
|
5
|
-
abortReason
|
|
6
|
-
} from "./index-a5qr2rj6.js";
|
|
7
4
|
import {
|
|
8
5
|
assertPositiveSafeInteger
|
|
9
6
|
} from "./index-0s4xebbg.js";
|
|
7
|
+
import {
|
|
8
|
+
abortReason
|
|
9
|
+
} from "./index-a5qr2rj6.js";
|
|
10
10
|
|
|
11
11
|
// src/internal/bounded-body.ts
|
|
12
12
|
async function readBoundedChunks(source, options) {
|
|
File without changes
|