feat: add reliable trigger and worker message blocks
Some checks failed
tamq-ci / test (push) Failing after 6s
Some checks failed
tamq-ci / test (push) Failing after 6s
Assistant: codex Assistant-Model: gpt-5.6-sol Assistant-Session: 01a03397-4d51-7fd1-8ff2-946eb22ea2bc
This commit is contained in:
parent
72f22a13f7
commit
17b6bd7ae7
25 changed files with 588 additions and 67 deletions
39
README.md
39
README.md
|
|
@ -7,6 +7,9 @@ The local alpha provides tmux endpoint lifecycle, local SQLite history and
|
|||
leases, readable `To:` routing, JSONL export/replay, and a Unix-socket protocol
|
||||
for a later coordination-engine adapter.
|
||||
|
||||
Agents and operators should start with the concise
|
||||
[TAMQ messaging introduction](TamqMessagingIntroduction.md).
|
||||
|
||||
## Install and start a local session
|
||||
|
||||
Prerequisites must be available on `PATH`: Python 3.11+, [uv](https://docs.astral.sh/uv/),
|
||||
|
|
@ -74,7 +77,7 @@ tamq --mode trigger --command codex flex-auth audit-core
|
|||
|
||||
All messaging-enabled windows use the same terminal-neutral PTY observer,
|
||||
whether they contain a shell, a tool, or an explicitly selected coding agent.
|
||||
An operator or a worker can emit the same readable line:
|
||||
An operator submits one addressed line:
|
||||
|
||||
```text
|
||||
To:audit-core: Please review the authentication change.
|
||||
|
|
@ -86,6 +89,16 @@ terminal programs, tamq also recognizes `To:` immediately after a conservative
|
|||
worker-output gutter such as the `•` used to frame assistant output; operator
|
||||
prompt gutters are not worker output.
|
||||
|
||||
A worker may extend its addressed first line with non-empty follow-up output.
|
||||
The first empty line terminates and sends the block:
|
||||
|
||||
```text
|
||||
To:audit-core: Please review the authentication change.
|
||||
Context: AUTH-WP-0004-T02.
|
||||
Expected reply: accepted or blocked.
|
||||
|
||||
```
|
||||
|
||||
Operator input is forwarded unchanged and is delivered with `/o`; a line
|
||||
originating in worker output has no suffix:
|
||||
|
||||
|
|
@ -94,12 +107,14 @@ From:flex-auth/o: Please review the authentication change.
|
|||
From:flex-auth: Worker-generated message.
|
||||
```
|
||||
|
||||
`From:` is never routable. The observer suppresses recent exact operator lines
|
||||
Every delivered physical line carries the same `From:` prefix and is never
|
||||
routable. The observer suppresses recent exact operator lines
|
||||
when a TUI echoes or redraws them, so the echo cannot become a second worker
|
||||
message. Ambiguous exact echoes fail closed. Pushy and trigger still cannot
|
||||
infer the foreground program or protect input already being edited, so both
|
||||
remain explicit experiments. Startup requires the readable-duplex, trigger,
|
||||
and line-limit capabilities and replaces an incompatible old broker.
|
||||
worker-block, and line-limit capabilities and replaces incompatible old broker
|
||||
or tap processes.
|
||||
|
||||
## Exchange messages manually
|
||||
|
||||
|
|
@ -110,9 +125,10 @@ Each managed window has its own repository identity. From operator input in the
|
|||
To:audit-core: please review the auth boundary
|
||||
```
|
||||
|
||||
The same line at the start of worker output queues a worker-originated message.
|
||||
The keyword may use any letter case, and a recognized full-screen output gutter
|
||||
may precede it.
|
||||
The same line at the start of worker output begins a worker-originated message
|
||||
block. Non-empty follow-up rows are included until an empty row, a new `To:`
|
||||
line, or worker exit. The keyword may use any letter case, and a recognized
|
||||
full-screen output gutter may precede it.
|
||||
The `@`, `#`, reply shorthand, and interactive recipient composer from earlier
|
||||
alphas have been removed.
|
||||
|
||||
|
|
@ -181,8 +197,10 @@ cannot be combined with `--all` or `--json`.
|
|||
Outside a managed window, use `tamq inbox --repo audit-core` and optionally
|
||||
`--json`. Output-displayed messages remain durable and pending until
|
||||
acknowledged. Neither `output` nor `inbox` mode injects terminal keystrokes.
|
||||
Pushy places input without Enter; trigger adds exactly one Enter. Both input
|
||||
modes record accepted delivery as `injected`.
|
||||
Pushy places input without Enter. Trigger waits for terminal paste detection to
|
||||
settle and then adds exactly one Enter. A short endpoint-startup grace protects
|
||||
the first input delivery while the foreground program initializes. Both input
|
||||
modes record accepted placement as `injected`, not recipient acknowledgement.
|
||||
|
||||
Every session window has independent, session-lifetime running counters for
|
||||
accepted outbound messages, operator input lines, and normalized worker output
|
||||
|
|
@ -281,8 +299,9 @@ observation and message identity.
|
|||
Normal endpoints use terminal-output delivery: each message is written once to
|
||||
the target pane's PTY output and stays pending in the durable inbox until
|
||||
acknowledged. `--mode inbox` selects inbox-only manual mode. Neither becomes
|
||||
pane input. Experimental `--mode pushy` places one sanitized `From:` line
|
||||
without Enter; `--mode trigger` performs the same placement and submits once.
|
||||
pane input. Experimental `--mode pushy` places a sanitized `From:` block
|
||||
without Enter; `--mode trigger` performs the same placement, lets paste
|
||||
detection settle, and submits once.
|
||||
The PTY observer records explicit operator/worker provenance and suppresses
|
||||
echoed operator lines before they can route again.
|
||||
The older pane-delivery experiment remains available only with the explicit
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue