Plugin SDK adds agent.register and session.refreshAgents, plus a one-shot flag for whether the system prompt was delivered
The plugin system's internal dispatch table adds an agent.register action, which validates that a prompt is provided and that the description meets length rules, sitting alongside the existing agent.list action. The headless session's $ scripting surface also gains a refreshAgents() method next to the existing refreshCommands().
Separately, the turn-runner gains a takeSystemPromptDelivered option: a one-shot getter that reads and then clears an internal flag tracking whether the system prompt was delivered.
This lets plugins register new agents programmatically and refresh the list of available agents, and lets other code check exactly once whether the system prompt has already been sent for a turn.