[Bug]: Async question replies display the agent’s question as user-authored text
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 23k
- Forks
- 5.9k
- Avg merge
- 11h 14m
- Merged PRs (30d)
- 357
Description
Before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
- In a Codex thread, have the agent ask a question using
request_user_input_async. - Enter a custom answer in the question panel and submit it.
- Read the resulting user message in the transcript.
A minimal example is a question of Which package manager? and an answer of pnpm. This concerns the async question tool, not the older blocking question flow.
Expected behavior
The transcript distinguishes the agent's question from the user's answer. Keeping the question as context is reasonable, but it should not appear to be text the user authored.
Actual behavior
The question and answer appear together in one user bubble, with no attribution or formatting that distinguishes them:
Which package manager?
pnpm
In the observed conversation, the agent asked about CPU power limits, fan/cooler settings, or RAM speed. The user entered only a reply about CPU cooler tuning presets. The resulting user bubble included the entire agent question before that reply.
A read-only inspection of that conversation's stored records confirmed:
- The
user-input.resolvedactivity contains only the user's reply inanswers. - The generated
async-answer:...user message contains the full question followed by that reply.
This is not only a renderer issue. The server constructs and persists the combined text, and the normal turn path sends that text to the provider.
Impact
Cosmetic issue
The transcript misattributes the question to the user. No failed delivery, duplicate submission, or change in the agent's reasoning was demonstrated.
Version or commit
Source verified at 061543e9e5b54ec0048725c37d52fef2962df173, which matched upstream main when checked. The exact installed version behind the original observation was not recorded.
Environment
Observed in the T3 chat UI with Codex async questions. The source path is shared by web, desktop, and mobile clients. Exact browser/desktop and Codex versions were not recorded; this was not independently reproduced on each client.
Supporting evidence
- The decider joins each question and answer and stores the result as a user message in the same command sequence.
- The provider turn path uses the stored message text.
- The existing engine test expects question-plus-answer text.
- Async question support was introduced in #9512.
The focused engine test was attempted but failed during imports with Schema.TaggedError is not a function, before any test ran. Installed Effect was 4.0.0-beta.103, while this checkout requires 4.0.0-rc.112. The evidence above is from the observed transcript, persisted records, and source inspection, not a successful new test run.
Workaround
No verified workaround. The report asks for clear attribution of question context, without requiring removal of that context from the provider message or a particular UI design.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in apps/server/src/orchestration/decider.ts around line 1282, then read ProviderCommandReactor.ts around line 1427 to trace how the combined question and answer are persisted and sent. Run the focused case in apps/server/src/orchestration/Layers/OrchestrationEngine.test.ts, after resolving the reported Effect version mismatch. Done means the transcript distinguishes the agent's question from the user's answer while preserving the intended question context.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend, testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100