@parcha/agentrun-serve 0.1.0-beta.50 → 0.1.0-beta.52
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 +185 -0
- package/README.md +236 -30
- package/dist/adapters.js +1 -1
- package/dist/agent-delete.d.ts +13 -2
- package/dist/agent-delete.js +14 -5
- package/dist/agents-store.d.ts +5 -1
- package/dist/agents-store.js +17 -7
- package/dist/api-only.d.ts +6 -3
- package/dist/api-only.js +8 -5
- package/dist/archil-routes.d.ts +1 -0
- package/dist/archil-routes.js +28 -2
- package/dist/capacity.d.ts +50 -0
- package/dist/capacity.js +49 -0
- package/dist/cli-learning/claude-wire.d.ts +41 -0
- package/dist/cli-learning/claude-wire.js +258 -0
- package/dist/cli-learning/cli.d.ts +11 -0
- package/dist/cli-learning/cli.js +241 -0
- package/dist/cli-learning/codex-worktree.d.ts +10 -0
- package/dist/cli-learning/codex-worktree.js +119 -0
- package/dist/cli-learning/connections.d.ts +62 -0
- package/dist/cli-learning/connections.js +87 -0
- package/dist/cli-learning/entry.d.ts +1 -0
- package/dist/cli-learning/entry.js +4 -0
- package/dist/cli-learning/evidence.d.ts +78 -0
- package/dist/cli-learning/evidence.js +492 -0
- package/dist/cli-learning/hook.d.ts +33 -0
- package/dist/cli-learning/hook.js +544 -0
- package/dist/cli-learning/install.d.ts +33 -0
- package/dist/cli-learning/install.js +335 -0
- package/dist/cli-learning/observation-proof.d.ts +14 -0
- package/dist/cli-learning/observation-proof.js +10 -0
- package/dist/cli-learning/policy.d.ts +48 -0
- package/dist/cli-learning/policy.js +363 -0
- package/dist/cli-learning/schema.d.ts +16 -0
- package/dist/cli-learning/schema.js +27 -0
- package/dist/cli-learning/state.d.ts +23 -0
- package/dist/cli-learning/state.js +61 -0
- package/dist/cli.js +24 -2
- package/dist/computer-setting.d.ts +8 -0
- package/dist/computer-setting.js +11 -0
- package/dist/computers.d.ts +6 -2
- package/dist/computers.js +2 -2
- package/dist/console/assets/index-B-D0EM3j.js +733 -0
- package/dist/console/assets/{index-D0mr9wfZ.css → index-DlQepP2J.css} +1 -1
- package/dist/console/index.html +2 -2
- package/dist/email/email-faux.d.ts +3 -1
- package/dist/email/email-faux.js +3 -2
- package/dist/email/routes.js +22 -12
- package/dist/fal-price.d.ts +76 -0
- package/dist/fal-price.js +368 -0
- package/dist/harness-install.d.ts +6 -2
- package/dist/harness-install.js +40 -8
- package/dist/harness.d.ts +1 -1
- package/dist/harness.js +2 -2
- package/dist/learn/commit.d.ts +5 -0
- package/dist/learn/commit.js +4 -1
- package/dist/learn/compile.d.ts +13 -5
- package/dist/learn/compile.js +24 -7
- package/dist/learn/delete.d.ts +12 -6
- package/dist/learn/delete.js +17 -11
- package/dist/learn/folder.d.ts +11 -0
- package/dist/learn/folder.js +20 -3
- package/dist/learn/learning-of.d.ts +8 -0
- package/dist/learn/learning-of.js +8 -0
- package/dist/learn/learning.sh +14 -1
- package/dist/learn/promote.d.ts +51 -7
- package/dist/learn/promote.js +51 -8
- package/dist/learn/secrets.js +14 -3
- package/dist/learning-reset.d.ts +18 -0
- package/dist/learning-reset.js +115 -0
- package/dist/learning-routes.d.ts +1 -1
- package/dist/learning-words.d.ts +6 -1
- package/dist/learning-words.js +6 -1
- package/dist/learning.d.ts +8 -6
- package/dist/learning.js +5 -4
- package/dist/llms.txt +1 -0
- package/dist/mcp-gateway.d.ts +39 -2
- package/dist/mcp-gateway.js +41 -10
- package/dist/mcp-pin-first.js +3 -2
- package/dist/mcp-private-hosts.d.ts +24 -3
- package/dist/mcp-private-hosts.js +53 -3
- package/dist/mcp-servers-store.d.ts +1 -0
- package/dist/mcp-servers-store.js +2 -1
- package/dist/media-duration.d.ts +2 -0
- package/dist/media-duration.js +136 -0
- package/dist/model-gateway.d.ts +2 -0
- package/dist/model-gateway.js +3 -1
- package/dist/native/runtimes.d.ts +2 -0
- package/dist/native/runtimes.js +2 -0
- package/dist/observation/learning.d.ts +32 -0
- package/dist/observation/learning.js +66 -0
- package/dist/observation/observer.d.ts +8 -1
- package/dist/observation/observer.js +89 -9
- package/dist/observation/schema.js +12 -4
- package/dist/observation/usage-identity.d.ts +9 -0
- package/dist/observation/usage-identity.js +11 -0
- package/dist/openapi.js +133 -24
- package/dist/provider.d.ts +8 -0
- package/dist/provider.js +14 -2
- package/dist/refusal-words.d.ts +0 -3
- package/dist/refusal-words.js +0 -3
- package/dist/request-metadata.d.ts +20 -0
- package/dist/request-metadata.js +24 -0
- package/dist/run-launch.d.ts +27 -4
- package/dist/run-launch.js +18 -3
- package/dist/run-learning-served.d.ts +2 -2
- package/dist/run-usage.d.ts +48 -4
- package/dist/run-usage.js +156 -39
- package/dist/run-view.d.ts +2 -0
- package/dist/run-view.js +8 -7
- package/dist/runner/adapter-loop.d.ts +3 -1
- package/dist/runner/adapter-loop.js +41 -35
- package/dist/runner/adapter-run-spec.d.ts +1 -1
- package/dist/runner/adapter-run-spec.js +15 -15
- package/dist/runner/audit.d.ts +8 -3
- package/dist/runner/audit.js +21 -6
- package/dist/runner/beside.d.ts +13 -0
- package/dist/runner/beside.js +27 -8
- package/dist/runner/claim-secrets.d.ts +2 -1
- package/dist/runner/claim-secrets.js +5 -3
- package/dist/runner/cli-run-spec.d.ts +1 -1
- package/dist/runner/cli-run-spec.js +14 -13
- package/dist/runner/conformance/harness.js +4 -2
- package/dist/runner/disk-free.d.ts +44 -0
- package/dist/runner/disk-free.js +96 -0
- package/dist/runner/dispatch.js +4 -2
- package/dist/runner/feedback-round.d.ts +12 -8
- package/dist/runner/feedback-round.js +16 -30
- package/dist/runner/harness-loops.js +8 -3
- package/dist/runner/journal-kinds.d.ts +4 -1
- package/dist/runner/learning-end.d.ts +2 -1
- package/dist/runner/learning-end.js +51 -22
- package/dist/runner/main.d.ts +17 -6
- package/dist/runner/main.js +187 -45
- package/dist/runner/mcp-claim.js +1 -1
- package/dist/runner/mcp-run.d.ts +9 -0
- package/dist/runner/mcp-run.js +16 -1
- package/dist/runner/model-route.js +7 -4
- package/dist/runner/presence.d.ts +11 -2
- package/dist/runner/presence.js +31 -3
- package/dist/runner/promotion.d.ts +40 -21
- package/dist/runner/promotion.js +130 -59
- package/dist/runner/run-child-host.d.ts +12 -15
- package/dist/runner/run-child-host.js +52 -112
- package/dist/runner/run-errors.js +2 -0
- package/dist/runner/runner-check.d.ts +51 -0
- package/dist/runner/runner-check.js +206 -0
- package/dist/runner/runner-metrics.d.ts +19 -0
- package/dist/runner/runner-metrics.js +49 -0
- package/dist/runner/runner.d.ts +37 -0
- package/dist/runner/runner.js +58 -6
- package/dist/runner/sdk-loop.d.ts +2 -2
- package/dist/runner/sdk-loop.js +37 -25
- package/dist/runner/store-port.d.ts +3 -0
- package/dist/runner/workflow-spec.js +3 -3
- package/dist/runs-over-store.d.ts +13 -3
- package/dist/runs-over-store.js +71 -16
- package/dist/sdk/check.d.ts +6 -5
- package/dist/sdk/check.js +17 -16
- package/dist/sdk/runs.d.ts +22 -2
- package/dist/sdk/runs.js +167 -82
- package/dist/server.d.ts +3 -0
- package/dist/server.js +230 -43
- package/dist/skills/agentrun-serve/SKILL.md +52 -7
- package/dist/start-switches.js +2 -0
- package/dist/stats.d.ts +4 -0
- package/dist/stats.js +1 -1
- package/dist/store/agent-body.d.ts +16 -0
- package/dist/store/agent-body.js +20 -3
- package/dist/store/dialect.d.ts +2 -0
- package/dist/store/dialect.js +1 -0
- package/dist/store/index.d.ts +3 -3
- package/dist/store/index.js +2 -2
- package/dist/store/journal/storage.d.ts +2 -0
- package/dist/store/journal/storage.js +2 -1
- package/dist/store/postgres/connection.d.ts +5 -2
- package/dist/store/postgres/connection.js +19 -7
- package/dist/store/postgres/dialect.js +1 -0
- package/dist/store/postgres/migrate.d.ts +30 -0
- package/dist/store/postgres/migrate.js +72 -5
- package/dist/store/postgres/migration-lint.d.ts +8 -0
- package/dist/store/postgres/migration-lint.js +119 -0
- package/dist/store/postgres/migrations/0024_runner_capacity.sql +28 -0
- package/dist/store/postgres/migrations/0025_run_attempts.sql +27 -0
- package/dist/store/postgres/migrations/0026_run_disk.sql +23 -0
- package/dist/store/postgres/store.d.ts +8 -3
- package/dist/store/postgres/store.js +31 -11
- package/dist/store/schema.d.ts +32 -2
- package/dist/store/schema.js +74 -5
- package/dist/store/sqlite/run-launch.d.ts +31 -1
- package/dist/store/sqlite/run-launch.js +111 -2
- package/dist/store/sqlite/run-patch.d.ts +2 -1
- package/dist/store/sqlite/run-patch.js +4 -3
- package/dist/store/sqlite/store.d.ts +17 -0
- package/dist/store/sqlite/store.js +226 -37
- package/dist/store/store-schema.d.ts +34 -0
- package/dist/store/store-schema.js +125 -0
- package/dist/store/store.d.ts +120 -5
- package/dist/store/store.js +13 -0
- package/dist/store-reads/analytics.d.ts +3 -2
- package/dist/store-reads/analytics.js +20 -8
- package/dist/store-reads/learning.d.ts +12 -8
- package/dist/store-reads/learning.js +33 -24
- package/dist/store-reads/loop.d.ts +4 -3
- package/dist/store-reads/loop.js +7 -5
- package/dist/store-view.d.ts +4 -3
- package/dist/store-view.js +11 -7
- package/dist/template-eval.js +4 -4
- package/dist/templates.d.ts +6 -2
- package/dist/templates.js +7 -5
- package/dist/timeline/labels.js +1 -1
- package/dist/tool-gate.d.ts +4 -2
- package/dist/tools.js +1 -1
- package/dist/unified-usage.d.ts +24 -0
- package/dist/unified-usage.js +400 -0
- package/dist/uploads-archil.d.ts +100 -0
- package/dist/uploads-archil.js +431 -0
- package/dist/uploads.d.ts +52 -1
- package/dist/uploads.js +186 -108
- package/dist/validate.js +5 -1
- package/dist/web-save.d.ts +3 -0
- package/dist/web-save.js +17 -2
- package/dist/workspace/archil-disk.d.ts +6 -5
- package/dist/workspace/archil-disk.js +27 -12
- package/dist/workspace/archil-exec.js +1 -1
- package/dist/workspace/archil.js +4 -3
- package/dist/workspace/revision-skills.js +24 -11
- package/dist/workspace/synced-folder.d.ts +3 -3
- package/dist/workspace/synced-folder.js +7 -6
- package/package.json +10 -10
- package/skills/agentrun-serve/SKILL.md +52 -7
- package/dist/console/assets/index-D7G6o-1E.js +0 -720
|
@@ -33,16 +33,29 @@ export async function layOwnSkills(work, skills, options = {}) {
|
|
|
33
33
|
files.push([brought[0], kind.text]);
|
|
34
34
|
if (!files.length)
|
|
35
35
|
return brought;
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
36
|
+
try {
|
|
37
|
+
// What is there is asked with stat, which answers a fresh folder's missing .agents/skills/ with undefined: no error
|
|
38
|
+
// is read as "not there", so no check of an error's class decides it (a run's own process gets its errors over its
|
|
39
|
+
// channel, where beta.50 lost WorkspaceError's class and failed every new run that had a skill).
|
|
40
|
+
const there = (await work.stat(RUN_SKILLS_DIR)) === undefined ? new Set() : new Set((await work.list(RUN_SKILLS_DIR)).map((entry) => entry.name));
|
|
41
|
+
const missing = files.filter(([path]) => !there.has(relativeSegments(path)[0]));
|
|
42
|
+
if (!missing.length)
|
|
43
|
+
return brought;
|
|
44
|
+
await work.mkdir(RUN_SKILLS_DIR);
|
|
45
|
+
for (const [path, text] of missing)
|
|
46
|
+
await work.write(`${RUN_SKILLS_DIR}/${path}`, text);
|
|
47
|
+
}
|
|
48
|
+
catch (error) {
|
|
49
|
+
throw laidFailed(error);
|
|
50
|
+
}
|
|
47
51
|
return brought;
|
|
48
52
|
}
|
|
53
|
+
/** A lay's failure, saying it was the lay of the run's skills: a WorkspaceError keeps its code, its path and its words
|
|
54
|
+
* (the backend's, an Archil key and Archil's own included) after that. */
|
|
55
|
+
function laidFailed(error) {
|
|
56
|
+
const code = error?.code;
|
|
57
|
+
if (!(error instanceof Error) || error.name !== "WorkspaceError" || typeof code !== "string")
|
|
58
|
+
return error;
|
|
59
|
+
const path = error.path;
|
|
60
|
+
return new WorkspaceError(code, `laying the run's skills in ${RUN_SKILLS_DIR}/: ${error.message}`, { ...(typeof path === "string" ? { path } : {}), cause: error });
|
|
61
|
+
}
|
|
@@ -38,9 +38,9 @@ export type HeldFolder = {
|
|
|
38
38
|
};
|
|
39
39
|
/**
|
|
40
40
|
* The stored folder pushed into the computer's empty /workspace through `client` (the computer's own, under no sync),
|
|
41
|
-
* one streaming tar, then the computer's listing read as the manifest: the sync the claim
|
|
42
|
-
* caller sets HeldFolder.folder to it), at the claim's start and for a new sandbox in place of a
|
|
43
|
-
*
|
|
41
|
+
* one streaming tar, each file at PUSHED_MTIME, then the computer's listing read as the manifest: the sync the claim
|
|
42
|
+
* holds from then on (the caller sets HeldFolder.folder to it), at the claim's start and for a new sandbox in place of a
|
|
43
|
+
* lost one, whose files the old manifest does not describe. The links an exec made on the disk (linkObjects), now links
|
|
44
44
|
* in the computer, are then removed from the disk. Throws in words where the push, the listing or a remove fails.
|
|
45
45
|
*/
|
|
46
46
|
export declare function holdSynced(store: FolderStore, client: ComputerClient, stored: StoredFolder, signal?: AbortSignal): Promise<FolderSync>;
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
// the disk (storedFolder, holdSynced).
|
|
24
24
|
// - Every write of a claim's goes through fencedStore: once a later claim has taken the run (the run's epoch and runner
|
|
25
25
|
// say so, held or not), it is refused, never sent.
|
|
26
|
-
import { fail, folderPathProblem, FolderSync, ok, pushTar, SYNC_MAX_BYTES, SYNC_MAX_ENTRIES, tarStream, WORKSPACE } from "@parcha/agentrun-computer";
|
|
26
|
+
import { fail, folderPathProblem, FolderSync, ok, PUSHED_MTIME, pushTar, SYNC_MAX_BYTES, SYNC_MAX_ENTRIES, tarStream, WORKSPACE } from "@parcha/agentrun-computer";
|
|
27
27
|
/** How many files a push reads ahead of the one the tar is writing. */
|
|
28
28
|
const AHEAD = 4;
|
|
29
29
|
const FILE_MODE = 0o644;
|
|
@@ -66,7 +66,8 @@ const quiet = (promise) => {
|
|
|
66
66
|
return promise;
|
|
67
67
|
};
|
|
68
68
|
/** The folder's entries as tar entries, by path (a directory before what is in it), then its links: each file read
|
|
69
|
-
* AHEAD ahead of the one written, so what is held is those few, never the folder
|
|
69
|
+
* AHEAD ahead of the one written, so what is held is those few, never the folder; each file at PUSHED_MTIME, which
|
|
70
|
+
* the baseline after the push needs. */
|
|
70
71
|
async function* tarEntries(store, { entries, meta }) {
|
|
71
72
|
const modeOf = (path, fallback) => (Object.hasOwn(meta.modes, path) ? meta.modes[path] : fallback);
|
|
72
73
|
const sorted = [...entries].sort(byPath);
|
|
@@ -85,16 +86,16 @@ async function* tarEntries(store, { entries, meta }) {
|
|
|
85
86
|
}
|
|
86
87
|
const body = await reads.shift();
|
|
87
88
|
ahead();
|
|
88
|
-
yield { name: entry.path, type: "file", mode: modeOf(entry.path, FILE_MODE), body };
|
|
89
|
+
yield { name: entry.path, type: "file", mode: modeOf(entry.path, FILE_MODE), body, mtime: PUSHED_MTIME };
|
|
89
90
|
}
|
|
90
91
|
for (const [path, target] of Object.entries(meta.links))
|
|
91
92
|
yield { name: path, type: "symlink", mode: 0o777, link: target };
|
|
92
93
|
}
|
|
93
94
|
/**
|
|
94
95
|
* The stored folder pushed into the computer's empty /workspace through `client` (the computer's own, under no sync),
|
|
95
|
-
* one streaming tar, then the computer's listing read as the manifest: the sync the claim
|
|
96
|
-
* caller sets HeldFolder.folder to it), at the claim's start and for a new sandbox in place of a
|
|
97
|
-
*
|
|
96
|
+
* one streaming tar, each file at PUSHED_MTIME, then the computer's listing read as the manifest: the sync the claim
|
|
97
|
+
* holds from then on (the caller sets HeldFolder.folder to it), at the claim's start and for a new sandbox in place of a
|
|
98
|
+
* lost one, whose files the old manifest does not describe. The links an exec made on the disk (linkObjects), now links
|
|
98
99
|
* in the computer, are then removed from the disk. Throws in words where the push, the listing or a remove fails.
|
|
99
100
|
*/
|
|
100
101
|
export async function holdSynced(store, client, stored, signal) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parcha/agentrun-serve",
|
|
3
|
-
"version": "0.1.0-beta.
|
|
3
|
+
"version": "0.1.0-beta.52",
|
|
4
4
|
"description": "The AgentRun server: the /v2 API and console over one store, with runners that run your agents; the deployable process of the AgentRun platform.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"agentrun",
|
|
@@ -62,15 +62,15 @@
|
|
|
62
62
|
"@earendil-works/pi-coding-agent": "1.5.2",
|
|
63
63
|
"@modelcontextprotocol/client": "2.4.0",
|
|
64
64
|
"@modelcontextprotocol/server": "2.4.0",
|
|
65
|
-
"@parcha/agentrun-computer": "0.1.0-beta.
|
|
66
|
-
"@parcha/agentrun-decisions": "0.1.0-beta.
|
|
67
|
-
"@parcha/agentrun-dsl": "0.1.0-beta.
|
|
68
|
-
"@parcha/agentrun-harness-acp": "0.1.0-beta.
|
|
69
|
-
"@parcha/agentrun-harness-claude": "0.1.0-beta.
|
|
70
|
-
"@parcha/agentrun-harness-codex": "0.1.0-beta.
|
|
71
|
-
"@parcha/agentrun-jev": "0.1.0-beta.
|
|
72
|
-
"@parcha/agentrun-kernel": "0.1.0-beta.
|
|
73
|
-
"@parcha/pi-browser": "0.1.0-beta.
|
|
65
|
+
"@parcha/agentrun-computer": "0.1.0-beta.52",
|
|
66
|
+
"@parcha/agentrun-decisions": "0.1.0-beta.52",
|
|
67
|
+
"@parcha/agentrun-dsl": "0.1.0-beta.52",
|
|
68
|
+
"@parcha/agentrun-harness-acp": "0.1.0-beta.52",
|
|
69
|
+
"@parcha/agentrun-harness-claude": "0.1.0-beta.52",
|
|
70
|
+
"@parcha/agentrun-harness-codex": "0.1.0-beta.52",
|
|
71
|
+
"@parcha/agentrun-jev": "0.1.0-beta.52",
|
|
72
|
+
"@parcha/agentrun-kernel": "0.1.0-beta.52",
|
|
73
|
+
"@parcha/pi-browser": "0.1.0-beta.52",
|
|
74
74
|
"@secretlint/core": "13.1.0",
|
|
75
75
|
"@secretlint/profiler": "13.1.0",
|
|
76
76
|
"@secretlint/secretlint-rule-preset-recommend": "13.1.0",
|
|
@@ -30,7 +30,7 @@ Inspect configured models before asking for a key. For an existing setup, follow
|
|
|
30
30
|
and history import need no destination model key. Live jobs use the source runtime's existing sign-in.
|
|
31
31
|
|
|
32
32
|
Finish with the first requested run's result and console link, or imported history and counts. Offer optional
|
|
33
|
-
self-improvement separately, and verify
|
|
33
|
+
self-improvement separately, and verify owner corrections in a fresh later run when requested.
|
|
34
34
|
|
|
35
35
|
## Connect agent
|
|
36
36
|
|
|
@@ -108,11 +108,56 @@ reported model/harness and activity/usage. CLI `configured` or `delivery_state:
|
|
|
108
108
|
delivery. Observed sessions are read-only: idle is not proof of completion, and missing telemetry is not proof of
|
|
109
109
|
an agent failure. No prompts, transcripts or tool contents are uploaded through this metadata path.
|
|
110
110
|
|
|
111
|
-
|
|
111
|
+
For independently started **Codex CLI or Claude Code** sessions, use the existing CLI learning path below.
|
|
112
|
+
For SDK application-owned jobs, follow the supported backend SDK learning
|
|
112
113
|
integration and verify accepted-revision delivery in a fresh run. Observation alone cannot enable it. The current
|
|
113
114
|
Claude Agent SDK and Codex SDK wrappers are TypeScript integrations; do not claim a Python SDK backend is wrapped
|
|
114
115
|
by setting OTEL variables. Do not fabricate a runnable native agent or use a copied prompt as proof.
|
|
115
116
|
|
|
117
|
+
### Learning in existing CLI sessions
|
|
118
|
+
|
|
119
|
+
For a connected-session card handoff, read its exact `GET /v2/observations?session_id=...` record.
|
|
120
|
+
On the source machine, resolve `external_session_id` through the collector's private identity map to the
|
|
121
|
+
native session, then inspect that session's actual project through its harness. Never print the identity
|
|
122
|
+
map or credentials, and never select a project from a display name or basename. A verified
|
|
123
|
+
`learning.agent_id` links to the existing shared project/runtime learning profile; reuse it. If the
|
|
124
|
+
source is unavailable, ask the user to open the original session. Run and Edit continue or change that
|
|
125
|
+
original setup, not a managed run or a replacement definition. Delegated children cannot enable independent
|
|
126
|
+
hook learning. Only offer enrollment for the selected root session's project, with its shared scope clear.
|
|
127
|
+
|
|
128
|
+
When requested, use the matching build's `learning connect` on the source machine. This path keeps the
|
|
129
|
+
original CLI in control of task execution and does not require an SDK wrapper. The initial integration
|
|
130
|
+
requires AgentRun on that same machine; identify its loopback port and actual data directory. Do not
|
|
131
|
+
silently replace a remote destination with a new local server. Enrollment uses the local owner credential
|
|
132
|
+
privately and leaves a scoped connection credential for hooks, never an owner key in project files.
|
|
133
|
+
|
|
134
|
+
```sh
|
|
135
|
+
agentrun-serve learning connect --project /absolute/project --runtime codex \
|
|
136
|
+
--url http://127.0.0.1:7340 --data /absolute/server-data
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
Use `claude-code` for Claude Code. Scope enrollment to the selected project/runtime. Installation merges
|
|
140
|
+
source hooks without replacing other hooks or changing tools, permissions, instructions or sign-in.
|
|
141
|
+
Codex linked worktrees append exact project-scoped hooks to the corresponding main-checkout
|
|
142
|
+
`.codex/hooks.json`, following native discovery. They keep separate local receipts and a local `.codex`
|
|
143
|
+
directory; disconnect preserves surviving native hook positions. If `learning status` reports `migration-required`,
|
|
144
|
+
rerun the same connect command to migrate unchanged owned hooks without replacing the connection.
|
|
145
|
+
Verify `/hooks`; Codex must trust the current declaration. Project configuration does not hot reload:
|
|
146
|
+
open a new session or close and resume it after the current task finishes. Reloading user settings alone
|
|
147
|
+
does not reload these project hooks. Do not interrupt the user's running task to activate them.
|
|
148
|
+
Do not claim merely writing a configuration file activated a running session. Begin on the next complete
|
|
149
|
+
prompt after activation, without importing earlier conversations or learning from an in-flight turn.
|
|
150
|
+
|
|
151
|
+
The prompt hook supplies pinned owner corrections; completion hooks record bounded role-preserving evidence
|
|
152
|
+
and reported usage. Source dialogue never becomes a standing correction automatically. Source hooks do not
|
|
153
|
+
provide a workflow execution bridge or make extra native reflection calls. Missing policy, truncated evidence
|
|
154
|
+
and cancellation stay explicit. This is not metadata-only observation.
|
|
155
|
+
|
|
156
|
+
Use `learning status` with the same project/runtime/data arguments and open the returned agent's Learning
|
|
157
|
+
tab. Save a correction explicitly, then verify an actual completed source run and its delivery and use
|
|
158
|
+
on a later prompt. Report incomplete evidence accurately. Learning Off controls guidance for future prompts;
|
|
159
|
+
`learning disconnect` revokes enrollment and removes only its installed hooks, retaining prior history.
|
|
160
|
+
|
|
116
161
|
### Live connection on this server
|
|
117
162
|
|
|
118
163
|
Verify that the coding agent, source project and AgentRun server are on the same machine. A browser's loopback
|
|
@@ -210,11 +255,11 @@ target; duplicates are skipped. The worker does not continuously upload historic
|
|
|
210
255
|
|
|
211
256
|
### Optional self-improvement
|
|
212
257
|
|
|
213
|
-
When requested, verify the imported agent and enable its existing **Self-improving** control.
|
|
214
|
-
additive, pinned to a learning revision for each run.
|
|
215
|
-
the
|
|
216
|
-
|
|
217
|
-
|
|
258
|
+
When requested, verify the imported agent and enable its existing **Self-improving** control. Owner corrections
|
|
259
|
+
are additive, pinned to a learning revision for each run. Eligible jobs compile into workflow drafts by resuming
|
|
260
|
+
the exact task session with tools disabled; checks and a dry run decide whether to keep a draft. Compilation
|
|
261
|
+
adds model usage. Learned workflows do not serve native runs in this release. Off means later runs receive
|
|
262
|
+
and create no AgentRun learning. Do not start a paid run unless authorized, and do not promise enforcement
|
|
218
263
|
of native dollar caps, interactive approvals, learned workflows or unsupported desktop tools.
|
|
219
264
|
|
|
220
265
|
### Historical import into a local store
|