prompt + query verbs (Ephemeral Sessions) #58

Closed
opened 2026-07-08 02:12:14 +08:00 by weiwen · 1 comment
Owner

Parent

#55

What to build

Add the two pi-backed Verbs on top of the dispatch core, both running in Ephemeral Sessions — throwaway pi sessions spawned for a single turn and discarded, isolated from the chat's live conversation Session so they never abort, block, or pollute an in-flight turn:

  • prompt — run text through pi and deliver the response to the resolved chat.
  • query — run text through pi and return the response to the caller (stdout), delivering nothing to the chat.

This requires ephemeral-session support in the Session manager: spawn a fresh pi process for the turn without registering it as (or evicting) the chat's live Slot.

Demoable: evie prompt "summarize today's notes" posts the answer to Telegram; evie query "..." prints the answer to stdout while any live conversation session is left intact.

Acceptance criteria

  • evie prompt "text" runs pi in an Ephemeral Session and delivers the response to the resolved chat.
  • evie query "text" runs pi in an Ephemeral Session and returns the response to the caller; nothing is delivered to the chat.
  • A live conversation Slot for the target chat is neither aborted, blocked, nor replaced by a prompt/query (verified via an inserted live slot).
  • query is immediate-only (no deferral path).
  • Tests at the dispatch-core seam use PiProcess::fake_responder: assert prompt delivers, query returns, and Ephemeral-Session isolation against an insert_slot_for_test live slot.
  • Uses CONTEXT.md vocabulary (Ephemeral Session, Prompt, Query); respects ADR 0006.

Blocked by

## Parent #55 ## What to build Add the two `pi`-backed **Verbs** on top of the dispatch core, both running in **Ephemeral Sessions** — throwaway `pi` sessions spawned for a single turn and discarded, isolated from the chat's live conversation Session so they never abort, block, or pollute an in-flight turn: - **`prompt`** — run text through `pi` and deliver the response to the resolved chat. - **`query`** — run text through `pi` and return the response to the caller (stdout), delivering nothing to the chat. This requires ephemeral-session support in the Session manager: spawn a fresh `pi` process for the turn without registering it as (or evicting) the chat's live Slot. Demoable: `evie prompt "summarize today's notes"` posts the answer to Telegram; `evie query "..."` prints the answer to stdout while any live conversation session is left intact. ## Acceptance criteria - [ ] `evie prompt "text"` runs `pi` in an Ephemeral Session and delivers the response to the resolved chat. - [ ] `evie query "text"` runs `pi` in an Ephemeral Session and returns the response to the caller; nothing is delivered to the chat. - [ ] A live conversation Slot for the target chat is neither aborted, blocked, nor replaced by a `prompt`/`query` (verified via an inserted live slot). - [ ] `query` is immediate-only (no deferral path). - [ ] Tests at the dispatch-core seam use `PiProcess::fake_responder`: assert `prompt` delivers, `query` returns, and Ephemeral-Session isolation against an `insert_slot_for_test` live slot. - [ ] Uses CONTEXT.md vocabulary (Ephemeral Session, Prompt, Query); respects ADR 0006. ## Blocked by - #57
Author
Owner

Automated PR created: # #64 fix: prompt + query verbs (Ephemeral Sessions) (open)

@weiwen created 2026-07-11 23:35 main <- issue-58

Closes #58

Automated implementation by implement-issue workflow.


• No Conflicts

#64

Automated PR created: # #64 fix: prompt + query verbs (Ephemeral Sessions) (open) @weiwen created 2026-07-11 23:35 **main** <- **issue-58** Closes #58 Automated implementation by implement-issue workflow. -------- • No Conflicts https://forge.weiwen.dev/weiwen/evie/pulls/64
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
weiwen/evie#58
No description provided.