Repository navigation
fix(chat): show the fields of omp's ask form instead of cancelling them - #42
Merged
Merged
Conversation
omp 18.19 changed the ask tool's argument to an HTML form. omp's RPC host
has no form dialog, so it asks the form one field at a time through plain
`select`, `input` and `editor` dialogs instead of the `ask` request.
ompwire cancelled every dialog that was not an approval or an `ask`, and
omp fails the whole ask on any cancelled field, so the agent saw "Ask tool
was cancelled by the user" and the turn ended before the chat saw the
question.
Each field now gets the options card. omp's own "Other (type your own)"
entry is left off because the card has an Other button. Text that names
an option picks it. Any other text on a group answers omp's Other entry
and then fills the input omp opens for it. Skip answers
{cancelled, timedOut} so the field keeps its default. An editor has no
timeout path, so Skip there answers with the prefill.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
omp 18.19 made the ask tool take an HTML form. Over RPC, omp asks that form one field at a time with plain
select/input/editordialogs. ompwire cancelled those dialogs because they were neither an approval nor anask, and a single cancelled field fails the whole ask. The chat never saw the question, and the turn ended with "Ask tool was cancelled by the user".Seen live on vidura-demon:
Change
select(not an approval),inputandeditordialogs now open the same question card thataskuses.Other (type your own)option because it already has an Other button. Typed text that matches an option picks that option. Other text answers omp's Other option, then fills theinputomp opens next.{cancelled, timedOut}, so the field keeps its default and the form continues.editorhas no timeout path, so Skip sends its prefill.Tests
tests/test_ask_flow.py. The 6 form-field tests fail onmainand pass here.ruff checkis clean.