do_steps — Claude Code prompt: screen actions
The do_steps Claude Code prompt batches known actions on one screen into a single call. It stops when a step fails or the next result needs visual inspection.
Apache-2.0 ★ 9,488 updated 2026-11-16
.claude/commands/do_steps.mdWhat do_steps does
The prompt groups actions on a screen when their targets are already known, such as entering text in one field and then tapping another. It checks each action before moving on. A failure, app switch, or need to inspect the interface ends the batch.
For actions that start loading, the next step can wait for a condition: new text (expect), a loading label to disappear (expect_gone), a specific app or page address (expect_app), or a stable screen (wait_stable). The wait is capped by a timeout, which defaults to 8 seconds. A popup, system dialog, or switch to another app stops it early.
The prompt ends the batch before an action whose outcome needs a visual judgment. Every step must stay on the same screen, and targets must use references that were visible before the batch began. After sending, posting, ordering, deleting, or paying, inspect the resulting state before reporting success.
What it helps with
- Fill several known fields on one screen in a single call
- Wait for search results or a form submission to finish
- Stop a sequence before a visual decision is needed
- Check the resulting state after a payment or deletion
Example prompts for the agent
- Fill the visible name and address fields, then inspect the screen.
- Run the search and wait for its results before taking the next step.
- Submit the form, stop if the app changes, and check the result.
How to install do_steps
Manually: put the files in place
.claude/commands/do_steps.mdHow to use
Paste the text at the start of a chat or into project instructions
Questions about do_steps
How do I install do_steps in Claude Code?
Place the prompt file at .claude/commands/do_steps.md.
What does do_steps do?
It batches consecutive actions on one screen and checks each step. The batch stops if an action fails or the interface needs visual review.
How does do_steps wait for loading to finish?
A step can wait for expect, expect_gone, expect_app, or wait_stable. The wait has a timeout that defaults to 8 seconds.
Source text
do_steps.md · Apache-2.0
Run consecutive actions on one screen in one call when the element list already identifies the next targets (for example: tap a named field, type the whole value, tap another named field, type its whole value). Choose the number of steps from the task and known interface, up to the per-call resource limit. Each step is checked locally before the next; the batch stops when an action fails, the interface needs visual review, the app switches, or a step's wait condition is not met. When a step starts loading (search, submit, open a page) and the next step needs the result, give that step a condition instead of ending the batch to wait: expect (text it brings up), expect_gone (a loading label), expect_app (app package or page address) or wait_stable. The step then waits up to timeout_s (default 8) and stops early on a popup, a system dialog or another app; the result says how long it waited and why it stopped. Do not batch past a step whose outcome you must judge by looking (which item to pick, whether it worked); end the batch there. An unchanged screen alone does not mean the task is stuck. Inspect the final screen before deciding what to do next. All steps must act on the same screen (mixed_surface otherwise). Requested send, post, order, delete and pay actions can be included in a batch; read the resulting state before claiming success. Use only refs that were visible before the batch and still identify the same element; if the next target appears only after an action, stop and inspect the new screen.
© wangzan101 · Apache-2.0 · wangzan101/Mika