As an agent user, I want to create an agent with a name, a provider, a model and a standing instruction, so that I have an assistant of my own to talk to from my phone.
Situation
I have an identity, my agent server is "Online" and at least one model provider is configured. I am on the Agents list.
What I do
Tap the add button in the bar, or "Create an agent" when the list is empty.
Type a name.
Check the provider that is ticked, or tap another.
Check the model that is ticked, or tap another.
Read the system prompt and change it if I want.
Tap "Create".
What I should see
The New agent sheet rises with "Cancel", the title "New agent" and "Create".
Sections in this order: "Name", "Provider", "Model", "System prompt".
The name field is empty with the hint "Agent name".
"Provider" lists my configured providers. The first one is already ticked with a check mark in the brand colour.
"Model" lists the recommended chat models of the chosen provider. Once they arrive, a default is already ticked.
Tapping another provider moves the tick, clears the model and loads that provider's models.
The system prompt starts as "You are a helpful assistant working inside Seed Hypermedia." with the note "The standing instruction for every conversation." under it.
"Create" is dimmed until there is a name, a provider and a model, and while the agent is being created.
After "Create" the sheet is replaced by the new agent's detail screen, titled with the name I typed, with "New conversation" ready to tap.
The new agent is in "Your agents" when I go back.
"Cancel" closes the sheet and creates nothing.
The next time I open the sheet the name is empty again. A prompt I edited is still there.
When something goes wrong
With no provider configured the sheet says a model provider must be configured first and offers a row "Model providers". "Create" stays dimmed. I tap the row, add a provider and come back.
If the provider's models cannot be listed, the reason is shown in red under "Model" and nothing can be ticked. I check the provider's key or pick another provider.
If the server refuses to create the agent, the sheet stays open with the reason in red at the bottom and everything I entered is kept. I tap "Create" again.
Not included
I cannot choose the agent's tools. Every agent made on the phone gets the same fixed set (current limits).
An agent cannot be edited, renamed or deleted on the phone after it is created.
Only the recommended models are listed, not every model the provider has.
Trace
Story US-AGENT-04, status Shipped. These links are kept in step with the traceability matrix and with the "User stories" section of every page listed here.
Design
Page | Part it plays |
|---|---|
The sheet: name, provider, model, system prompt | |
Provider and model radio rows with the check mark | |
The add button and Create an agent row that open the sheet | |
Where Create lands | |
Where the no provider notice sends the person | |
Sheet with Cancel and a confirming action, defaults chosen | |
This form among all forms | |
Cancel and Create in the bar | |
Why this is a sheet and why it is replaced by the agent | |
Radio role on the choice rows | |
The blocker names its fix | |
The notice, footer and error wording |
Implementation
Page | Part it plays |
|---|---|
AgentCreateScreen | |
Model curation, the default model and model labels | |
agentsModels and the create-agent command with its fixed tool list | |
The signed CreateAgent action | |
Package overview and known limits | |
ListProviderModels and CreateAgent | |
agentsName, agentsPrompt, agentsProvider, agentsModel, agentsModelData and the form tasks | |
The new-agent route and the replace to the agent | |
Mutation then refresh of the list | |
The UI test of validated creation | |
The mock's CreateAgent and model list | |
Unit test of model choices | |
A new agent is created with a fixed tool list |
Code
File | What |
|---|---|
AgentCreateScreen | |
AgentModel and AgentModels shapes | |
new-agent route | |
agentsName, agentsPrompt, agentsProvider, agentsModel | |
agentsModelData resource | |
agentsNewForm and agentsDefaultModel tasks | |
agentsInitCreate to agentsCreate | |
agentsAfterChange: replace the sheet with the new agent | |
AgentCreateScreen wiring | |
agentsModels | |
create-agent command with the fixed tool list | |
curateProviderModels, pickDefaultProviderModel, modelLabel |
Tests
File | What it checks |
|---|---|
agents list, configuration, providers and validated creation | |
model choices retain chat aliases and the RN preferred defaults | |
the merged identity store signs agent commands through the production signer path |
Delivery
Delivered by #1470.
Do you like what you are reading? Subscribe to receive updates.
Unsubscribe anytime