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
92 lines
2.9 KiB
Markdown
92 lines
2.9 KiB
Markdown
---
|
|
id: TAMQ-WP-0008
|
|
type: workplan
|
|
title: "Counterparty reply shorthand and stable terminal output"
|
|
domain: communication
|
|
repo: tmux-amq
|
|
status: active
|
|
owner: codex
|
|
topic_slug: coulomb-social
|
|
planning_priority: P0
|
|
planning_order: 13
|
|
created: "2026-08-24"
|
|
updated: "2026-08-24"
|
|
---
|
|
|
|
# Counterparty reply shorthand and stable terminal output
|
|
|
|
Add a conversation-oriented reply convention and keep asynchronous message
|
|
output above the current input row instead of visually breaking the prompt.
|
|
|
|
## Required operator contract
|
|
|
|
If `audit-core` most recently received a message from `flex-auth`, this sends a
|
|
reply to `flex-auth`:
|
|
|
|
```bash
|
|
@ Thanks, I will take a look.
|
|
```
|
|
|
|
The generic `@` command resolves the latest durable inbound message for the
|
|
current `TAMQ_REPO`, regardless of acknowledgement state. It excludes
|
|
self-addressed messages. If there is no counterparty, it fails visibly and
|
|
queues nothing.
|
|
|
|
When a message arrives, tamq uses tmux's current pane cursor position and
|
|
VT100-compatible scroll margins to scroll only the rows above the input cursor,
|
|
write the comment immediately above it, restore the full scroll region, and
|
|
restore the cursor. The current input row and cursor position remain stable.
|
|
|
|
## Add durable latest-counterparty resolution
|
|
|
|
```task
|
|
id: TAMQ-WP-0008-T01
|
|
status: progress
|
|
priority: high
|
|
```
|
|
|
|
Query the latest inbound message by creation order for the current repository,
|
|
excluding self-addressed rows. Add `tamq reply MESSAGE...` and a tamq-owned
|
|
generic `@` executable alongside the repository-specific shims. Preserve
|
|
argument boundaries, require `TAMQ_REPO`, reuse target validation and send
|
|
transport, and refuse collision with an unrelated existing `@` command.
|
|
|
|
## Keep input position stable during output
|
|
|
|
```task
|
|
id: TAMQ-WP-0008-T02
|
|
status: todo
|
|
priority: high
|
|
```
|
|
|
|
Resolve `cursor_y`, `pane_height`, and the pane PTY atomically through tmux.
|
|
For a cursor with rows above it, generate a bounded DECSTBM scroll-region frame
|
|
that saves/restores the cursor and resets the full scrolling region. Sanitize
|
|
message content before framing and retain the simple output fallback when no
|
|
row exists above the cursor. Never emit input bytes.
|
|
|
|
## Prove conversation and screen behavior
|
|
|
|
```task
|
|
id: TAMQ-WP-0008-T03
|
|
status: todo
|
|
priority: high
|
|
```
|
|
|
|
Test latest inbound selection across pending/acknowledged and self-addressed
|
|
messages, missing identity/counterparty errors, generic shim arguments and
|
|
ownership collision, cursor-aware frames, and real tmux behavior with a partial
|
|
input line. Prove the input text and cursor coordinates are unchanged while the
|
|
message becomes visible immediately above them.
|
|
|
|
## Install and document the interaction convention
|
|
|
|
```task
|
|
id: TAMQ-WP-0008-T04
|
|
status: todo
|
|
priority: high
|
|
```
|
|
|
|
Update help, README, and SCOPE; run complete checks; install the build; exercise
|
|
`@ MESSAGE` in both directions in a live two-window session; and retain only
|
|
user messages pending after acknowledging controlled smoke records.
|