aicodeman 1.44.0 → 1.45.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/README.md +6 -2
- package/dist/case-rename.d.ts +65 -0
- package/dist/case-rename.d.ts.map +1 -0
- package/dist/case-rename.js +198 -0
- package/dist/case-rename.js.map +1 -0
- package/dist/cli-agent.d.ts +60 -1
- package/dist/cli-agent.d.ts.map +1 -1
- package/dist/cli-agent.js +225 -13
- package/dist/cli-agent.js.map +1 -1
- package/dist/config/auth-config.d.ts +16 -1
- package/dist/config/auth-config.d.ts.map +1 -1
- package/dist/config/auth-config.js +16 -1
- package/dist/config/auth-config.js.map +1 -1
- package/dist/host-sensors.d.ts +115 -0
- package/dist/host-sensors.d.ts.map +1 -0
- package/dist/host-sensors.js +457 -0
- package/dist/host-sensors.js.map +1 -0
- package/dist/remote-hosts.d.ts +7 -0
- package/dist/remote-hosts.d.ts.map +1 -1
- package/dist/remote-hosts.js +17 -3
- package/dist/remote-hosts.js.map +1 -1
- package/dist/remote-pane-history.d.ts.map +1 -1
- package/dist/remote-pane-history.js +2 -2
- package/dist/remote-pane-history.js.map +1 -1
- package/dist/session.d.ts.map +1 -1
- package/dist/session.js +13 -0
- package/dist/session.js.map +1 -1
- package/dist/tmux-manager.d.ts +7 -3
- package/dist/tmux-manager.d.ts.map +1 -1
- package/dist/tmux-manager.js +47 -15
- package/dist/tmux-manager.js.map +1 -1
- package/dist/tmux-prefix-table.d.ts +37 -5
- package/dist/tmux-prefix-table.d.ts.map +1 -1
- package/dist/tmux-prefix-table.js +40 -5
- package/dist/tmux-prefix-table.js.map +1 -1
- package/dist/tui/tui-app.d.ts +8 -1
- package/dist/tui/tui-app.d.ts.map +1 -1
- package/dist/tui/tui-app.js +49 -12
- package/dist/tui/tui-app.js.map +1 -1
- package/dist/tui/tui-client.d.ts +90 -3
- package/dist/tui/tui-client.d.ts.map +1 -1
- package/dist/tui/tui-client.js +195 -26
- package/dist/tui/tui-client.js.map +1 -1
- package/dist/web/agent-inbox-persistence.d.ts +52 -0
- package/dist/web/agent-inbox-persistence.d.ts.map +1 -0
- package/dist/web/agent-inbox-persistence.js +139 -0
- package/dist/web/agent-inbox-persistence.js.map +1 -0
- package/dist/web/agent-inbox.d.ts +140 -0
- package/dist/web/agent-inbox.d.ts.map +1 -0
- package/dist/web/agent-inbox.js +258 -0
- package/dist/web/agent-inbox.js.map +1 -0
- package/dist/web/middleware/auth.d.ts +2 -0
- package/dist/web/middleware/auth.d.ts.map +1 -1
- package/dist/web/middleware/auth.js +145 -52
- package/dist/web/middleware/auth.js.map +1 -1
- package/dist/web/public/admin-ui.js.gz +0 -0
- package/dist/web/public/api-client.c9b1cddc.js.gz +0 -0
- package/dist/web/public/app.42d0abae.js +43 -0
- package/dist/web/public/app.42d0abae.js.br +0 -0
- package/dist/web/public/app.42d0abae.js.gz +0 -0
- package/dist/web/public/approvals-ui.js.gz +0 -0
- package/dist/web/public/{constants.4866ecc3.js → constants.0b3cdde9.js} +11 -0
- package/dist/web/public/constants.0b3cdde9.js.br +0 -0
- package/dist/web/public/constants.0b3cdde9.js.gz +0 -0
- package/dist/web/public/cron-ui.js.gz +0 -0
- package/dist/web/public/entrance-animations.js.gz +0 -0
- package/dist/web/public/git-status-ui.js.gz +0 -0
- package/dist/web/public/header-divider.eb2d2463.js +1 -0
- package/dist/web/public/header-divider.eb2d2463.js.br +0 -0
- package/dist/web/public/header-divider.eb2d2463.js.gz +0 -0
- package/dist/web/public/home-sessions.js.gz +0 -0
- package/dist/web/public/host-wake-ui.js.gz +0 -0
- package/dist/web/public/i18n.1e68220d.js +2 -0
- package/dist/web/public/i18n.1e68220d.js.br +0 -0
- package/dist/web/public/i18n.1e68220d.js.gz +0 -0
- package/dist/web/public/image-input.941386e7.js.gz +0 -0
- package/dist/web/public/index.html +74 -11
- package/dist/web/public/index.html.br +0 -0
- package/dist/web/public/index.html.gz +0 -0
- package/dist/web/public/input-cjk.8bc46081.js.gz +0 -0
- package/dist/web/public/keyboard-accessory.4e8b20ac.js.gz +0 -0
- package/dist/web/public/{mobile-handlers.44adaa07.js → mobile-handlers.1c0cbcd8.js} +4 -2
- package/dist/web/public/mobile-handlers.1c0cbcd8.js.br +0 -0
- package/dist/web/public/mobile-handlers.1c0cbcd8.js.gz +0 -0
- package/dist/web/public/mobile-ime-preview.2dbaf262.js.gz +0 -0
- package/dist/web/public/mobile-overview.js.gz +0 -0
- package/dist/web/public/mobile.12fb18de.css.gz +0 -0
- package/dist/web/public/notification-manager.feb82c04.js.gz +0 -0
- package/dist/web/public/orchestrator-panel.js.gz +0 -0
- package/dist/web/public/{panels-ui.cbb24ba1.js → panels-ui.78c3defb.js} +76 -70
- package/dist/web/public/panels-ui.78c3defb.js.br +0 -0
- package/dist/web/public/panels-ui.78c3defb.js.gz +0 -0
- package/dist/web/public/ralph-panel.b350e2ef.js.gz +0 -0
- package/dist/web/public/ralph-wizard.b6c0dd19.js.gz +0 -0
- package/dist/web/public/readmymind-ui.js.gz +0 -0
- package/dist/web/public/reboot-restore-ui.js.gz +0 -0
- package/dist/web/public/respawn-ui.d7adcf6a.js.gz +0 -0
- package/dist/web/public/sanitize-html.e7147e76.js.gz +0 -0
- package/dist/web/public/session-lineage.js.gz +0 -0
- package/dist/web/public/{session-ui.9c1f009b.js → session-ui.ea6b1994.js} +28 -26
- package/dist/web/public/session-ui.ea6b1994.js.br +0 -0
- package/dist/web/public/session-ui.ea6b1994.js.gz +0 -0
- package/dist/web/public/{settings-ui.fea9ddae.js → settings-ui.085dd202.js} +3 -3
- package/dist/web/public/settings-ui.085dd202.js.br +0 -0
- package/dist/web/public/settings-ui.085dd202.js.gz +0 -0
- package/dist/web/public/spreadsheet-preview-worker.js.gz +0 -0
- package/dist/web/public/spreadsheet-preview.75c751de.js.gz +0 -0
- package/dist/web/public/spreadsheet-xlsx-core.js.gz +0 -0
- package/dist/web/public/styles.3b59b41d.css +1 -0
- package/dist/web/public/styles.3b59b41d.css.br +0 -0
- package/dist/web/public/styles.3b59b41d.css.gz +0 -0
- package/dist/web/public/subagent-windows.07277a58.js.gz +0 -0
- package/dist/web/public/sw.js +2 -2
- package/dist/web/public/sw.js.br +0 -0
- package/dist/web/public/sw.js.gz +0 -0
- package/dist/web/public/tab-layout-browser.2d6189f7.js.gz +0 -0
- package/dist/web/public/tab-rail-resize.7157e0bd.js.gz +0 -0
- package/dist/web/public/terminal-keycode229-recovery.af09f99a.js.gz +0 -0
- package/dist/web/public/terminal-split.js.gz +0 -0
- package/dist/web/public/terminal-tile.js +8 -1
- package/dist/web/public/terminal-tile.js.br +0 -0
- package/dist/web/public/terminal-tile.js.gz +0 -0
- package/dist/web/public/terminal-ui.fb2a27f5.js +2 -0
- package/dist/web/public/terminal-ui.fb2a27f5.js.br +0 -0
- package/dist/web/public/terminal-ui.fb2a27f5.js.gz +0 -0
- package/dist/web/public/tile-grid.js.gz +0 -0
- package/dist/web/public/ultracode-panel.js.gz +0 -0
- package/dist/web/public/ultracode-windows.js.gz +0 -0
- package/dist/web/public/vendor/dompurify.min.js.gz +0 -0
- package/dist/web/public/vendor/exceljs.min.js.gz +0 -0
- package/dist/web/public/vendor/fflate.min.js.gz +0 -0
- package/dist/web/public/vendor/marked.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-fit.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-serialize.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-unicode11.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-webgl.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-predictive-echo.ae5e3d5d.js.gz +0 -0
- package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js.gz +0 -0
- package/dist/web/public/vendor/xterm.css.gz +0 -0
- package/dist/web/public/vendor/xterm.min.js.gz +0 -0
- package/dist/web/public/voice-input.2342c37b.js.gz +0 -0
- package/dist/web/public/voice-pcm-worklet.js.gz +0 -0
- package/dist/web/public/webview-tabs.js.gz +0 -0
- package/dist/web/public/whats-new.json +9 -9
- package/dist/web/route-helpers.d.ts +57 -6
- package/dist/web/route-helpers.d.ts.map +1 -1
- package/dist/web/route-helpers.js +72 -4
- package/dist/web/route-helpers.js.map +1 -1
- package/dist/web/routes/case-routes.d.ts.map +1 -1
- package/dist/web/routes/case-routes.js +183 -2
- package/dist/web/routes/case-routes.js.map +1 -1
- package/dist/web/routes/inbox-routes.d.ts +43 -0
- package/dist/web/routes/inbox-routes.d.ts.map +1 -0
- package/dist/web/routes/inbox-routes.js +148 -0
- package/dist/web/routes/inbox-routes.js.map +1 -0
- package/dist/web/routes/index.d.ts +1 -0
- package/dist/web/routes/index.d.ts.map +1 -1
- package/dist/web/routes/index.js +1 -0
- package/dist/web/routes/index.js.map +1 -1
- package/dist/web/routes/session-routes.d.ts.map +1 -1
- package/dist/web/routes/session-routes.js +25 -47
- package/dist/web/routes/session-routes.js.map +1 -1
- package/dist/web/routes/system-routes.d.ts.map +1 -1
- package/dist/web/routes/system-routes.js +23 -2
- package/dist/web/routes/system-routes.js.map +1 -1
- package/dist/web/schemas.d.ts +26 -0
- package/dist/web/schemas.d.ts.map +1 -1
- package/dist/web/schemas.js +48 -0
- package/dist/web/schemas.js.map +1 -1
- package/dist/web/sensitive-path.d.ts.map +1 -1
- package/dist/web/sensitive-path.js +2 -0
- package/dist/web/sensitive-path.js.map +1 -1
- package/dist/web/server.d.ts +2 -0
- package/dist/web/server.d.ts.map +1 -1
- package/dist/web/server.js +61 -3
- package/dist/web/server.js.map +1 -1
- package/dist/web/session-wait-registry.d.ts +48 -4
- package/dist/web/session-wait-registry.d.ts.map +1 -1
- package/dist/web/session-wait-registry.js +144 -6
- package/dist/web/session-wait-registry.js.map +1 -1
- package/dist/web/sse-events.d.ts +4 -1
- package/dist/web/sse-events.d.ts.map +1 -1
- package/dist/web/sse-events.js +4 -1
- package/dist/web/sse-events.js.map +1 -1
- package/package.json +1 -1
- package/skills/codeman/SKILL.md +7 -4
- package/skills/codeman/preamble.sh +3 -3
- package/skills/codeman/reference/endpoints.md +24 -3
- package/skills/codeman/reference/verbs.md +47 -0
- package/dist/web/public/app.9314ee60.js +0 -43
- package/dist/web/public/app.9314ee60.js.br +0 -0
- package/dist/web/public/app.9314ee60.js.gz +0 -0
- package/dist/web/public/constants.4866ecc3.js.br +0 -0
- package/dist/web/public/constants.4866ecc3.js.gz +0 -0
- package/dist/web/public/i18n.22ca902b.js +0 -2
- package/dist/web/public/i18n.22ca902b.js.br +0 -0
- package/dist/web/public/i18n.22ca902b.js.gz +0 -0
- package/dist/web/public/mobile-handlers.44adaa07.js.br +0 -0
- package/dist/web/public/mobile-handlers.44adaa07.js.gz +0 -0
- package/dist/web/public/panels-ui.cbb24ba1.js.br +0 -0
- package/dist/web/public/panels-ui.cbb24ba1.js.gz +0 -0
- package/dist/web/public/session-ui.9c1f009b.js.br +0 -0
- package/dist/web/public/session-ui.9c1f009b.js.gz +0 -0
- package/dist/web/public/settings-ui.fea9ddae.js.br +0 -0
- package/dist/web/public/settings-ui.fea9ddae.js.gz +0 -0
- package/dist/web/public/styles.e096fcd6.css +0 -1
- package/dist/web/public/styles.e096fcd6.css.br +0 -0
- package/dist/web/public/styles.e096fcd6.css.gz +0 -0
- package/dist/web/public/terminal-ui.68dbd352.js +0 -2
- package/dist/web/public/terminal-ui.68dbd352.js.br +0 -0
- package/dist/web/public/terminal-ui.68dbd352.js.gz +0 -0
|
@@ -18,9 +18,9 @@ fi
|
|
|
18
18
|
AUTH=(); [ -n "${CODEMAN_PASSWORD:-}" ] && AUTH=(-u "${CODEMAN_USERNAME:-admin}:$CODEMAN_PASSWORD")
|
|
19
19
|
# -k: harmless on http, required on https (self-signed cert).
|
|
20
20
|
# X-Codeman-Parent-Session: tags workers YOU spawn as your children, so the web UI can
|
|
21
|
-
# draw the lineage. Set once here and every present and future create call carries it
|
|
22
|
-
#
|
|
23
|
-
# fail a spawn, so there is no case where you would want to leave it off.
|
|
21
|
+
# draw the lineage. Set once here and every present and future create call carries it.
|
|
22
|
+
# The agent inbox reads it too, as "who is calling" (§5.15); every other endpoint ignores
|
|
23
|
+
# it. It can never fail a spawn, so there is no case where you would want to leave it off.
|
|
24
24
|
# X-Codeman-Agent-Origin: marks a case directory a spawn CREATES as agent scratch, so the
|
|
25
25
|
# user can find and delete it long after your workers are gone (§5.14). Same deal: set
|
|
26
26
|
# once, cosmetic, never fails a spawn, and it labels only directories Codeman creates.
|
|
@@ -35,8 +35,13 @@ only and can never drive a session.
|
|
|
35
35
|
with a parse error and `.errorCode` is simply absent (see
|
|
36
36
|
[symptom 6](#6-jq-parse-error-instead-of-an-errorcode)). Ten failed attempts from one
|
|
37
37
|
IP then get a plain-text `429 Too Many Requests` with `Retry-After`, decaying over 15
|
|
38
|
-
minutes (`AUTH_FAILURE_MAX` = 10, `AUTH_FAILURE_WINDOW_MS` = 15 min).
|
|
39
|
-
|
|
38
|
+
minutes (`AUTH_FAILURE_MAX` = 10, `AUTH_FAILURE_WINDOW_MS` = 15 min). In multi-user
|
|
39
|
+
mode the per-IP cap is 50 (`AUTH_IP_FAILURE_MAX`) and each account allows 10 failed
|
|
40
|
+
guesses per IP; both are checked before the password, so past either even a correct
|
|
41
|
+
password from that address gets the 429 (for the per-account one, only for that
|
|
42
|
+
account). From the 10th failed guess on, an account's wrong guesses also get the 429
|
|
43
|
+
from every address, but a correct password still logs in. **Never retry a failing
|
|
44
|
+
credential in a loop**: you will lock the address out of the login path for
|
|
40
45
|
everything, including the user's browser through a tunnel (tunneled traffic arrives as
|
|
41
46
|
127.0.0.1, so one bucket covers it all).
|
|
42
47
|
|
|
@@ -608,6 +613,22 @@ Approving a permission dialog on your own is exactly the laundering this skill f
|
|
|
608
613
|
can access, which includes the user's own working sessions. An approval belonging to one
|
|
609
614
|
of those is something you **report**, never something you answer.
|
|
610
615
|
|
|
616
|
+
### Agent inbox: hand a worker text without typing into its pane
|
|
617
|
+
|
|
618
|
+
Stored, not typed: the receiver reads it when it asks. Semantics, CLI form and the
|
|
619
|
+
receiver loop: `verbs.md` §5.15.
|
|
620
|
+
|
|
621
|
+
| Task | Call |
|
|
622
|
+
|------|------|
|
|
623
|
+
| post to a session's inbox | `POST /api/v1/sessions/:id/inbox` body `{"text":"…"}` → `.data.message.{id,from}`; 409 = inbox full, nothing stored |
|
|
624
|
+
| read (yours marks seen, anyone else's is a peek) | `GET /api/v1/sessions/:id/inbox` → `.data.{receiver,pending,unseen,messages[]}` |
|
|
625
|
+
| block until something unseen arrives | `GET /api/v1/sessions/:id/inbox?wait=60000` → `.data.wait.{posted,timedOut,ended}` |
|
|
626
|
+
| remove what you handled (receiver only, idempotent) | `POST /api/v1/sessions/:id/inbox/ack` body `{"ids":["…"]}`; 403 from anyone else |
|
|
627
|
+
| counts per session, never text | `GET /api/v1/agent-inbox/summary` → `.data.sessions[id].{pending,unseen,oldestUnseenAt,parked}` |
|
|
628
|
+
|
|
629
|
+
`from` and "who is the receiver" both come from the `X-Codeman-Parent-Session` header the
|
|
630
|
+
preamble's `CURL` sends, never from the body.
|
|
631
|
+
|
|
611
632
|
### The wait primitives
|
|
612
633
|
|
|
613
634
|
Three bounded long-polls. Shared semantics:
|
|
@@ -801,7 +822,7 @@ response echoes.
|
|
|
801
822
|
| sessions, per user | half the global cap (25 by default) in multi-user mode | the same 409, with a different message |
|
|
802
823
|
| SSE clients, process-wide | 100 (`MAX_SSE_CLIENTS`) | plain-text `503 Too many SSE connections`; shared with every browser tab |
|
|
803
824
|
| active bash tools tracked | 20 per session | oldest entries drop off `active-tools` |
|
|
804
|
-
| auth failures per IP | 10, decaying over 15 min | plain-text 429 with `Retry-After`; locks out the login path, so never loop a bad credential |
|
|
825
|
+
| auth failures per IP | 10, decaying over 15 min (multi-user: 50 per IP, plus 10 per account per IP) | plain-text 429 with `Retry-After`; locks out the login path, so never loop a bad credential |
|
|
805
826
|
|
|
806
827
|
Case creation is **uncapped**, which is the one place restraint has to come from you:
|
|
807
828
|
every `quick-start` with a new `caseName` creates a real directory on the user's disk.
|
|
@@ -764,3 +764,50 @@ Confirm cleanup with `GET /api/v1/sessions`, never with `/api/v1/sessions/unifie
|
|
|
764
764
|
(that one folds in transcript history from the whole machine and will keep showing
|
|
765
765
|
your worker forever).
|
|
766
766
|
|
|
767
|
+
### 5.15 Agent inbox
|
|
768
|
+
|
|
769
|
+
Every session has an inbox. A message posted there is stored, not typed: the receiver's
|
|
770
|
+
pane is untouched, no turn starts, and the text may span several lines. The receiver
|
|
771
|
+
reads when it is ready. Use it for results a worker hands back, for a follow-up task a
|
|
772
|
+
busy worker should pick up after its current one, and for anything longer than one
|
|
773
|
+
composer line. Use `send` when you want a turn to start now.
|
|
774
|
+
|
|
775
|
+
```bash
|
|
776
|
+
codeman agent post "$WORKER" "$(cat task.md)" # ONE quoted argument; prints pending/unseen
|
|
777
|
+
codeman agent inbox --wait --timeout 300000 # your own inbox; blocks while nothing is new
|
|
778
|
+
codeman agent ack <id> [<id>…] # remove what you handled, by the full id inbox printed
|
|
779
|
+
codeman agent inbox "$WORKER" # peek at someone else's: marks nothing
|
|
780
|
+
codeman agent ls # INBOX column: pending (new), parked
|
|
781
|
+
```
|
|
782
|
+
|
|
783
|
+
The same over HTTP: `POST /api/v1/sessions/:id/inbox {"text":…}`, `GET
|
|
784
|
+
/api/v1/sessions/:id/inbox?wait=<ms>`, `POST /api/v1/sessions/:id/inbox/ack {"ids":[…]}`,
|
|
785
|
+
`GET /api/v1/agent-inbox/summary`. The preamble's `CURL` already sends
|
|
786
|
+
`X-Codeman-Parent-Session`, which is how the server knows who you are.
|
|
787
|
+
|
|
788
|
+
Rules that matter:
|
|
789
|
+
|
|
790
|
+
- **Reading removes nothing.** Every read returns every pending message until you ack
|
|
791
|
+
it, so a crash between reading and doing loses nothing. Ack once the work is done,
|
|
792
|
+
not when you have read it: a sender looking at `ls` sees unacked mail as not done.
|
|
793
|
+
- **Only the receiver's own read counts.** Your read of your own inbox marks messages
|
|
794
|
+
seen (`seen: true` on the next read); reading another session's inbox is a peek and
|
|
795
|
+
changes nothing for it. Only the receiver can ack (403 otherwise).
|
|
796
|
+
- **`--wait` waits for something new.** It returns at once when there is unseen mail
|
|
797
|
+
and otherwise blocks until a post arrives; seen but unacked messages come back with it
|
|
798
|
+
and do not end the wait. Timeout is exit 2, and so is a wait the server cut short
|
|
799
|
+
(a restart): loop again. Exit 3 means the session list no longer has the session.
|
|
800
|
+
`--wait` on someone else's inbox returns at once while they have unseen mail (only
|
|
801
|
+
their read clears it); check `ls` instead.
|
|
802
|
+
- **The sender is resolved, not claimed.** `from` is the session the header resolves to,
|
|
803
|
+
or `null` (the user). In single-user mode that is a hint, since every local process
|
|
804
|
+
holds the same credentials. In multi-user mode it is checked against the owner;
|
|
805
|
+
an admin can still act as any session of the receiver's owner.
|
|
806
|
+
- **Full means refused.** 200 messages or 512 KiB per inbox, 16 KiB per message. A full
|
|
807
|
+
inbox answers 409 and stores nothing; the oldest is never dropped. Messages expire 12
|
|
808
|
+
hours after they were posted.
|
|
809
|
+
- **Nobody is woken.** An idle receiver does not look at its inbox by itself, and the
|
|
810
|
+
server never types into its pane. When `ls` shows a worker idle with unread mail and
|
|
811
|
+
not parked, `send` it one line ("read your inbox: `codeman agent inbox`").
|
|
812
|
+
- **Lifetime.** An inbox goes with its session on delete. A server restart empties all
|
|
813
|
+
inboxes unless the user turned on *Keep agent inbox across restarts* in Settings.
|