Feature Request
Please extend the azd ai agent commands in the agent extension to deliver the agent inner-loop experience -- a browser-hosted Foundry Toolkit Agent Inspector auto-launched by azd ai agent run, plus a structured event stream on azd ai agent invoke -- following the design specifications in foundrysdk_specs PR #169. This work is part of the broader azd ai agent direct-commands surface for Foundry.
Design Highlights
azd ai agent run (modified): auto-launch the browser-hosted Agent Inspector and print its URL once at the top of run's output. New flags: --no-inspector, --inspector-port, --host, --inspector-token, and --attach <endpoint> (do not spawn a process; just attach the Inspector to an already-running agent server). Also honors AZD_AI_INSPECTOR=off env var. After the URL line, run's stdout shows only the agent process's own logs -- no event-record interleaving.
azd ai agent invoke (modified): three mutually-exclusive output modes -- (default) one-shot terminal invocation prints the final response (unchanged); --show-events adds an inline color-formatted event summary; --events-ndjson [--events-out <path>] emits the full structured event stream as line-delimited JSON (stderr by default) for coding-agent / CI consumers. New --web flag opens the Inspector against the target server instead of sending a one-shot message. New --url <endpoint> points --web (or any other mode) at an arbitrary local agent server.
azd ai agent show --local (modified): report the running local agent's status -- PID, port, endpoint URL, and Inspector URL -- so developers can re-find the Inspector after closing the browser tab without restarting run.
azd ai agent inspect (new, optional): dedicated brownfield convenience verb that opens the Agent Inspector against a local agent server. With no arguments, discovers the running azd-managed agent (same source of truth as show --local); with --url <endpoint> attaches to any local server that speaks the /agentdev/* + /v1/responses contract. Honors --no-browser.
- Brownfield parity: developers running their own agent server (
uvicorn, custom debugger, existing test-tool process) can open the Inspector via three equivalent entry points -- azd ai agent inspect, azd ai agent invoke --web --url, or azd ai agent run --attach -- all binding to the same local server contract (/agentdev/*, /v1/responses, /inspector/*).
monitor is unchanged. azd ai agent monitor continues to target hosted Foundry agents post-deployment; local inner-loop event observation lives on invoke and the Inspector UI.
Open design questions (from the spec, target 2026-05-15)
- Single SPA bundle vs. two builds (browser + VS Code webview) for the Inspector UI.
- Auto-launch the Inspector on
run vs. a strict run / invoke --web split.
- Brownfield entry point: ship one of
inspect / invoke --web / run --attach, or all three?
These need alignment with the Foundry Toolkit (Agent Inspector) team before implementation.
API dependencies
This feature does not require any new Foundry data plane routes. It relies on local agent server endpoints already served by the agentdev test-tool process, which this spec stabilizes:
GET /agentdev/entities -- list agents/workflows hosted by the local server.
POST /v1/responses -- OpenAI-compatible Responses API entry point; SSE stream of events.
GET /inspector -- serve the Inspector single-page web UI (new -- the same UI the VS Code webview loads).
GET /inspector/events -- WebSocket multiplex of all /v1/responses event streams across sessions, consumed by the Inspector UI and by azd ai agent invoke --events-ndjson.
The browser-hosted Inspector bundle ships from the Foundry Toolkit (current implementation: built from the same source as the VS Code webview via separate Vite build target; see Azure/azure-dev#8125 for the initial drop into assets/). A follow-up may publish the Inspector to a public feed / GitHub release and wire it as a dependency of azure.ai.agents.
Please refer to the full design spec (foundrysdk_specs PR #169) -- specifically the Requirements section, the Command Line Design table, and the Open Questions list -- for implementation guidance.
Additional Context
Feature Request
Please extend the
azd ai agentcommands in the agent extension to deliver the agent inner-loop experience -- a browser-hosted Foundry Toolkit Agent Inspector auto-launched byazd ai agent run, plus a structured event stream onazd ai agent invoke-- following the design specifications in foundrysdk_specs PR #169. This work is part of the broaderazd ai agentdirect-commands surface for Foundry.Design Highlights
azd ai agent run(modified): auto-launch the browser-hosted Agent Inspector and print its URL once at the top ofrun's output. New flags:--no-inspector,--inspector-port,--host,--inspector-token, and--attach <endpoint>(do not spawn a process; just attach the Inspector to an already-running agent server). Also honorsAZD_AI_INSPECTOR=offenv var. After the URL line,run's stdout shows only the agent process's own logs -- no event-record interleaving.azd ai agent invoke(modified): three mutually-exclusive output modes -- (default) one-shot terminal invocation prints the final response (unchanged);--show-eventsadds an inline color-formatted event summary;--events-ndjson [--events-out <path>]emits the full structured event stream as line-delimited JSON (stderr by default) for coding-agent / CI consumers. New--webflag opens the Inspector against the target server instead of sending a one-shot message. New--url <endpoint>points--web(or any other mode) at an arbitrary local agent server.azd ai agent show --local(modified): report the running local agent's status -- PID, port, endpoint URL, and Inspector URL -- so developers can re-find the Inspector after closing the browser tab without restartingrun.azd ai agent inspect(new, optional): dedicated brownfield convenience verb that opens the Agent Inspector against a local agent server. With no arguments, discovers the runningazd-managed agent (same source of truth asshow --local); with--url <endpoint>attaches to any local server that speaks the/agentdev/*+/v1/responsescontract. Honors--no-browser.uvicorn, custom debugger, existing test-tool process) can open the Inspector via three equivalent entry points --azd ai agent inspect,azd ai agent invoke --web --url, orazd ai agent run --attach-- all binding to the same local server contract (/agentdev/*,/v1/responses,/inspector/*).monitoris unchanged.azd ai agent monitorcontinues to target hosted Foundry agents post-deployment; local inner-loop event observation lives oninvokeand the Inspector UI.Open design questions (from the spec, target 2026-05-15)
runvs. a strictrun/invoke --websplit.inspect/invoke --web/run --attach, or all three?These need alignment with the Foundry Toolkit (Agent Inspector) team before implementation.
API dependencies
This feature does not require any new Foundry data plane routes. It relies on local agent server endpoints already served by the
agentdevtest-tool process, which this spec stabilizes:GET /agentdev/entities-- list agents/workflows hosted by the local server.POST /v1/responses-- OpenAI-compatible Responses API entry point; SSE stream of events.GET /inspector-- serve the Inspector single-page web UI (new -- the same UI the VS Code webview loads).GET /inspector/events-- WebSocket multiplex of all/v1/responsesevent streams across sessions, consumed by the Inspector UI and byazd ai agent invoke --events-ndjson.The browser-hosted Inspector bundle ships from the Foundry Toolkit (current implementation: built from the same source as the VS Code webview via separate Vite build target; see Azure/azure-dev#8125 for the initial drop into
assets/). A follow-up may publish the Inspector to a public feed / GitHub release and wire it as a dependency ofazure.ai.agents.Please refer to the full design spec (foundrysdk_specs PR #169) -- specifically the Requirements section, the Command Line Design table, and the Open Questions list -- for implementation guidance.
Additional Context
azd ai agentdirect-commands surface for Foundry.