preview

A command for opening a web address or workspace file in the session’s desktop browser panel, or starting a development server defined in .ao/launch.json. A development server is a local program that serves an application while you work on it.

In plain words
What is it for?
Previewing HTML, Markdown, URLs, and workspace files, and launching a session-owned local server for applications with an existing launch configuration.
Why use it?
It lets you inspect local files and running applications in a browser without creating project files or installing packages just to display static content.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/untrivial-ai/agent-orchestrator/preview
Clone the repo
git clone --depth 1 https://github.com/Untrivial-ai/agent-orchestrator
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,194 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01194
Opus 5 $0.00000 $0.00597
Sonnet 5 $0.00000 $0.00239
Haiku 4.5 $0.00000 $0.00119

Measured yesterday against content hash b62cfb5f6be8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

preview scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

backend/internal/skillassets/using-ao/commands/preview.md · 179 lines

How it starts

The opening of the file, as written. The whole thing — 179 lines — stays where its author put it; the contents beside it link to each section on GitHub.

ao preview

Open a URL or workspace file in the desktop browser panel for the current session, or start a deterministic session-owned dev server from an existing .ao/launch.json.

Static HTML and Markdown do not need a development server. Open them directly with ao preview <workspace-path>. Never create or modify package.json, install dependencies, or introduce npm or another server solely to display static files.

Workspace file paths

Treat every relative file target as relative to the session workspace root, not the shell's current directory. The same command works from the workspace root or any subdirectory:

ao preview README.md
ao preview docs/guide.md

Do not compensate for the current directory with ../README.md. Relative targets already start at the workspace root, so parent traversal instead tries to leave the workspace and is rejected with PREVIEW_FILE_OUTSIDE_WORKSPACE. An absolute path is also accepted when it resolves inside the session workspace, but a workspace-root-relative path is clearer and more portable.

AO serves workspace files through the daemon's existing confined loopback preview origin. This is a local preview, not a deployment or a new development server. Do not open workspace files with file://; direct file URLs are not the AO Browser panel's static-file workflow.

Use a managed server only when the project genuinely has a runtime. Start an existing .ao/launch.json configuration when present. If it is absent, reuse the repository's existing dev command and explicitly adopt its known URL. Do not create .ao/launch.json unless the user asks for reusable launch configuration.

Automatic artifact handoff

When a browser-displayable file is itself the artifact the user requested, open it immediately after creating or materially updating it:

ao preview docs/plan.md
ao preview report.html
ao preview output.pdf
ao preview diagram.svg
ao preview mockup.png

Do this without waiting for a separate "open it" request. Browser-displayable artifacts include Markdown, HTML, PDF, SVG, and common image formats such as PNG, JPEG, GIF, WebP, and AVIF. If the task produces several files, open the primary requested artifact rather than cycling through every output.

Read the full file on GitHub · 179 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 179 lines · 0 tokens per session scan A b62cfb5f6be8

Subscribe to this mod's changes

preview is a command published in the GitHub repository Untrivial-ai/agent-orchestrator (10,763 stars, last pushed today), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,194 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.