Skip to content

Demo agent: in view, legible, and quicker - #103

Open
jpcamara wants to merge 3 commits into
feat/markdown-editorfrom
feat/agent-in-view
Open

Demo agent: in view, legible, and quicker#103
jpcamara wants to merge 3 commits into
feat/markdown-editorfrom
feat/agent-in-view

Conversation

@jpcamara

Copy link
Copy Markdown
Owner

Stacked on #102.

Three complaints from using it: the agent was often off screen, it was unclear how to interact with it or what it would do next, and too much time was spent waiting.

In view

  • A bar pinned under the page header always shows the current status and detail, with a "jump to it" link that scrolls the editor to the agent's cursor and a follow switch (on by default) that keeps the cursor in view as it moves, held for four seconds after you type. Lexical: the cursor element is scrolled into view once drawn. CodeMirror: the awareness position is resolved to an index and EditorView.scrollIntoView does the rest.

Legible

  • The agent introduces itself as its first ledger entry: what it will do first, that it works through the list under a heading that names it at the same time, and how to talk to it.
  • "up next: …" before each task, with a moment to say @agent pause.
  • Buttons under the bar for what you can say: ask, hand it a task, draft this section, pause, resume. Each puts the line on a new paragraph (Lexxy, through the editor's own API) or line (CodeMirror) at your caret and leaves the caret at its end.

Quicker

  • StreamJob: a model stream with its own pacer, stepped by the watch loop, so several run at once and the loop keeps reacting. The review and the first task from the list start together at the invite; draft text appears two to three seconds after the invite. While both run, one combined status ("writing a review and drafting Rollout") keeps the ledger and the bar from flickering, and the caret stays with the draft.
  • Quick calls, the decision after a change and answers, go to a model without a reasoning phase: AGENT_FAST_MODEL, default accounts/fireworks/models/minimax-m3 (2.4s to first token on the decision prompt, clean JSON; gpt-oss-120b also works). Reviews and drafts keep the reasoning model. Measured with the real models: a decision landed 3s after a sentence ended, against 20s before.
  • A change is only weighed once it reads finished: the block ends with punctuation, or the person's caret has left it.

Verified

  • Chrome, stub, both pages: draft started 3s after invite with the review still writing; ledger reads hello, reading, writing a review, up next, drafting, writing a review and drafting, wrote a review, drafted; the bar follows; jump scrolls to the agent; the Ask button makes a new paragraph with @agent at the caret and the answer arrives.
  • Chrome, real models, markdown page: first text 2s after invite; review and draft interleaved; decision 3s after the sentence ended with a sensible reason.

jpcamara and others added 3 commits September 11, 2026 16:38
A bar pinned under the page header shows what the agent is doing, with a
"jump to it" link and a follow switch that keeps its cursor in view as it
moves, held for a few seconds after you type. Buttons put the things you
can say on a new line at your caret. The agent introduces itself when it
arrives and says "up next" before each task.

The review and the first task now run at the same time: each is a
StreamJob, a model stream paced and stepped by the watch loop, so text
appears seconds after the invite rather than after the review. One status
names everything in flight so the ledger does not flicker.

Quick calls, the decision after a change and answers, go to a model without
a reasoning phase (AGENT_FAST_MODEL, default MiniMax M3 on Fireworks, about
two seconds); reviews and drafts keep the reasoning model. A change is only
weighed once the sentence reads finished or the person has left it.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017TeaovH2jyHARHJSyQ8Afo
…y under headings

The pacer accrued credit while the model was silent, so the first chunk
after a think paid out the whole wait at once. Credit now starts when text
arrives; the first writes after a pause are a few characters.

Follow holds for fifteen seconds after any typing, key, click or scroll,
not four seconds after typing only, and selection changes do not count,
since remote edits move the selection too. On the markdown page it
compares the agent's resolved index, since the relative position it sends
stays on the same character while it writes.

On the Lexxy page only a heading names the agent's task list, and its own
review section never does: a paragraph mentioning the agent had turned the
review's suggestions into tasks and a mark landed inside one of them.

Answers are brief (two or three sentences), go out at a brisker pace than
drafts, and never become headings. A task handed over while it is busy says
what it will start after. The instructions tell the model that a "[~]"
task's section may end mid-sentence because it is being written. And a
draft-this-section request with the caret still in the heading no longer
crashes the work loop.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017TeaovH2jyHARHJSyQ8Afo
…are brief

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017TeaovH2jyHARHJSyQ8Afo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant