Skip to content

AI scenarios

Agent asks a question

Bit.BlazorUI.AI Scripted transport

A run that blocks mid-plan, offers suggested answers, and resumes from where it stopped.

Live demo

Start the migration: the agent inspects the schema, then asks when it may take the downtime. Pick an answer.

A run waiting for an answer

Start the migration
Ask a question to get started.

How it works

Blocked, not finished. The transport plans three steps, completes the first, starts the second, and sends BitAiAgentInputRequestedEvent(runId, prompt) with its Suggestions before ending the reply. The run moves to WaitingForInput and carries the question (PendingPrompt) and the one-tap answers (PendingSuggestions); the step it was on is Blocked until the answer comes, rather than drawn as running with a clock that keeps going.

Choosing an answer - or typing one into the run's own box - calls BitAiChatSession.RespondToAgentAsync(runId, answer), which resumes the run, appends the answer as a user message and starts the next turn. The transport finds the answer in the request and continues the same run from the step it stopped at, addressing it by the run id it used before. "Ask me again later" answers nothing: the agent skips the step and ends the run Cancelled instead of booking a window nobody chose.

This is the difference between an agent that asks and an agent that guesses. The state is explicit, so the UI can make waiting look deliberate rather than stuck.

Components used

Feedback

Found a mistake, a gap, or something that could be clearer? Every page and every component is one click from its source.