@parcha/agentrun 0.4.23 → 0.4.24
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/install.sh
CHANGED
|
@@ -690,12 +690,14 @@ vps_install_docker() {
|
|
|
690
690
|
say "Installed Docker Engine $engine"
|
|
691
691
|
}
|
|
692
692
|
|
|
693
|
-
# A server that has just booted may still be running cloud-init's or unattended-upgrades' apt. dpkg's lock
|
|
694
|
-
# (DPkg::Lock::Timeout)
|
|
693
|
+
# A server that has just booted may still be running cloud-init's, apt-daily's or unattended-upgrades' apt. dpkg's lock
|
|
694
|
+
# is waited for once (DPkg::Lock::Timeout): a dpkg still stuck after it stops the install. Every other lock apt-get could
|
|
695
|
+
# not get, which that option does not cover (the archives' an install takes, the lists' an update takes), by trying
|
|
696
|
+
# again, for 600 s as well. Under LC_ALL=C, so the words matched are apt's English ones on a server set to any language.
|
|
695
697
|
vps_apt() {
|
|
696
698
|
apt_waited=0
|
|
697
|
-
until DEBIAN_FRONTEND=noninteractive apt-get -y -qq -o Dpkg::Use-Pty=0 -o DPkg::Lock::Timeout=600 "$@" > "$work/apt.log" 2>&1; do
|
|
698
|
-
if [ "$apt_waited" -lt 600 ] && grep
|
|
699
|
+
until LC_ALL=C DEBIAN_FRONTEND=noninteractive apt-get -y -qq -o Dpkg::Use-Pty=0 -o DPkg::Lock::Timeout=600 "$@" > "$work/apt.log" 2>&1; do
|
|
700
|
+
if [ "$apt_waited" -lt 600 ] && grep 'Could not get lock' "$work/apt.log" | grep -qv '/var/lib/dpkg/'; then
|
|
699
701
|
[ "$apt_waited" -gt 0 ] || say "Waiting for the apt-get another process is running ..."
|
|
700
702
|
sleep 5
|
|
701
703
|
apt_waited=$((apt_waited + 5))
|
|
@@ -3766,7 +3766,7 @@ export const COMMANDS = [
|
|
|
3766
3766
|
"name": "limit",
|
|
3767
3767
|
"type": "integer",
|
|
3768
3768
|
"required": false,
|
|
3769
|
-
"description": "At most this many rows in a page (1 to 500, default 500); has_more says when another waits."
|
|
3769
|
+
"description": "At most this many rows in a page (1 to 500, default 500; with `calls=whole`, 1 to 100, default 100); has_more says when another waits."
|
|
3770
3770
|
},
|
|
3771
3771
|
{
|
|
3772
3772
|
"name": "calls",
|
|
@@ -3775,7 +3775,7 @@ export const COMMANDS = [
|
|
|
3775
3775
|
"whole"
|
|
3776
3776
|
],
|
|
3777
3777
|
"required": false,
|
|
3778
|
-
"description": "`whole`: each `tool_use` row carries its call's arguments (`tool_input`) and each `tool_result` row
|
|
3778
|
+
"description": "`whole`: each `tool_use` row carries its call's arguments (`tool_input`) and each `tool_result` row its output whole to 120000 characters (`tool_result_text`; a web call's every url, only its long texts cut), both through the run's redaction, for a reader that grades the run (a template eval). Its rows are another page sequence: a cursor (`after`, `Last-Event-ID`) from one read goes with the same `calls`."
|
|
3779
3779
|
}
|
|
3780
3780
|
],
|
|
3781
3781
|
"headers": [
|
|
@@ -4939,6 +4939,32 @@ export const COMMANDS = [
|
|
|
4939
4939
|
"secretBody": false,
|
|
4940
4940
|
"raw": false,
|
|
4941
4941
|
"summary": "Check a workflow definition without saving it"
|
|
4942
|
+
},
|
|
4943
|
+
{
|
|
4944
|
+
"command": [
|
|
4945
|
+
"wrapped"
|
|
4946
|
+
],
|
|
4947
|
+
"operationId": "getWrapped",
|
|
4948
|
+
"method": "GET",
|
|
4949
|
+
"path": "/wrapped",
|
|
4950
|
+
"pathParams": [],
|
|
4951
|
+
"multiSegment": [],
|
|
4952
|
+
"query": [
|
|
4953
|
+
{
|
|
4954
|
+
"name": "year",
|
|
4955
|
+
"type": "integer",
|
|
4956
|
+
"required": false,
|
|
4957
|
+
"description": "A four-digit year, in the server's local zone. Default the current year."
|
|
4958
|
+
}
|
|
4959
|
+
],
|
|
4960
|
+
"headers": [],
|
|
4961
|
+
"bodyFlags": [],
|
|
4962
|
+
"hasBody": false,
|
|
4963
|
+
"bodyRequired": false,
|
|
4964
|
+
"bodyTypes": [],
|
|
4965
|
+
"secretBody": false,
|
|
4966
|
+
"raw": false,
|
|
4967
|
+
"summary": "A year of the work under this machine's session files"
|
|
4942
4968
|
}
|
|
4943
4969
|
];
|
|
4944
4970
|
|
package/lib/start.mjs
CHANGED
|
@@ -290,13 +290,17 @@ function fieldsOf(line) {
|
|
|
290
290
|
|
|
291
291
|
/** A teller for one start: given a line of the server's output, what to say of it to the person, or undefined. A refused
|
|
292
292
|
* request (auth_failed) and a verified webhook delivery its trigger does not take (hook_ignored) are said in words, with
|
|
293
|
-
* their route and reason and never what was sent, each route and reason once, at most TOLD_MAX.
|
|
294
|
-
*
|
|
293
|
+
* their route and reason and never what was sent, each route and reason once, at most TOLD_MAX. A ChatGPT sign-in that
|
|
294
|
+
* did not finish (chatgpt=sign_in_failed: OpenAI's tab already said it completed) is said each time, with its reason,
|
|
295
|
+
* and so is one saved whose change the server failed to take (chatgpt=changed_failed).
|
|
296
|
+
* With AGENTRUN_LOG=quiet, as this command starts the server, those lines are all an operator would otherwise miss. */
|
|
295
297
|
export function tellerOf() {
|
|
296
298
|
const said = new Set();
|
|
297
299
|
let full = false;
|
|
298
300
|
return (line) => {
|
|
299
301
|
const fields = fieldsOf(line);
|
|
302
|
+
if (fields.event === "chatgpt" && fields.chatgpt === "sign_in_failed") return `AgentRun's ChatGPT sign-in did not finish (${fields.reason ?? "no reason given"}): Settings → API Keys says why; start it again there.`;
|
|
303
|
+
if (fields.event === "chatgpt" && fields.chatgpt === "changed_failed") return `AgentRun saved the ChatGPT sign-in but has not taken it into what it offers yet (${fields.reason ?? "no reason given"}): it tries again as Settings reads it; if codex and pi still ask for a key, restart AgentRun.`;
|
|
300
304
|
let words;
|
|
301
305
|
let key;
|
|
302
306
|
if (fields.event === "auth_failed" && fields.route) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parcha/agentrun",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.24",
|
|
4
4
|
"description": "AgentRun, the open-source platform that supercharges your agents (self-improvement, durable execution and a control plane on top of your favorite agent harness), on this machine with one command: npx @parcha/agentrun",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"NOTICE"
|
|
18
18
|
],
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@parcha/agentrun-serve": "0.1.0-beta.
|
|
20
|
+
"@parcha/agentrun-serve": "0.1.0-beta.56"
|
|
21
21
|
},
|
|
22
22
|
"scripts": {
|
|
23
23
|
"test": "node --test 'test/*.test.mjs'"
|
|
@@ -166,4 +166,5 @@ Two clients call the same API from code, with the same server and token. `@parch
|
|
|
166
166
|
- `agentrun usage`: Usage by meter over a period
|
|
167
167
|
- `agentrun webhook`: delete, deliveries, get, redeliver, save, test
|
|
168
168
|
- `agentrun workflows`: validate
|
|
169
|
+
- `agentrun wrapped`: A year of the work under this machine's session files
|
|
169
170
|
- `agentrun api METHOD PATH [--body JSON|@FILE|-]`: any route, PATH under the base URL
|
|
@@ -1181,8 +1181,8 @@ Route: `GET /runs/{run_id}/timeline`.
|
|
|
1181
1181
|
|
|
1182
1182
|
- `--after INTEGER` (integer): The change cursor last applied, from `next_after` or the last SSE `id`. 0 is the start.
|
|
1183
1183
|
- `--wait-ms INTEGER` (integer): JSON only. How long to hold the request for a change after `after`.
|
|
1184
|
-
- `--limit INTEGER` (integer): At most this many rows in a page (1 to 500, default 500); has_more says when another waits.
|
|
1185
|
-
- `--calls whole` (string, one of these): `whole`: each `tool_use` row carries its call's arguments (`tool_input`) and each `tool_result` row
|
|
1184
|
+
- `--limit INTEGER` (integer): At most this many rows in a page (1 to 500, default 500; with `calls=whole`, 1 to 100, default 100); has_more says when another waits.
|
|
1185
|
+
- `--calls whole` (string, one of these): `whole`: each `tool_use` row carries its call's arguments (`tool_input`) and each `tool_result` row its output whole to 120000 characters (`tool_result_text`; a web call's every url, only its long texts cut), both through the run's redaction, for a reader that grades the run (a template eval). Its rows are another page sequence: a cursor (`after`, `Last-Event-ID`) from one read goes with the same `calls`.
|
|
1186
1186
|
- `--last-event-id STRING` (string): SSE reconnect. Same meaning as `after`, and wins over it.
|
|
1187
1187
|
- `--follow` (boolean, this CLI's own): the timeline as it changes, one page per line (NDJSON), until the run ends; resumes a dropped connection
|
|
1188
1188
|
|
|
@@ -1639,3 +1639,13 @@ Route: `POST /workflows/validate`.
|
|
|
1639
1639
|
|
|
1640
1640
|
- `--body JSON|@FILE|-` (application/json, required): The whole body: inline, from a file or from stdin. The flags above win over a JSON body's fields.
|
|
1641
1641
|
- `--body-type TYPE` (string): The body's type, one of application/json; any other than JSON is sent as given.
|
|
1642
|
+
|
|
1643
|
+
## wrapped
|
|
1644
|
+
|
|
1645
|
+
### `agentrun wrapped`
|
|
1646
|
+
|
|
1647
|
+
A year of the work under this machine's session files.
|
|
1648
|
+
|
|
1649
|
+
Route: `GET /wrapped`.
|
|
1650
|
+
|
|
1651
|
+
- `--year INTEGER` (integer): A four-digit year, in the server's local zone. Default the current year.
|