Migrate Ask AI to Agent Studio
Ask AI is now part of Agent Studio, where you build and manage AI agents. Migrate your existing Ask AI assistant, publish the new agent, then point DocSearch or your custom API client to Agent Studio.
Migrate your assistant
1. Start the migration in the dashboard
- Sign in to the Algolia dashboard.
- Open Ask AI.
- Select your assistant and click Migrate to Agent Studio.
The wizard creates a draft Agent Studio agent from your assistant configuration, including the prompt, model, indices, and related settings. After migration, the assistant and agent are independent and don't stay in sync.
2. Review and publish the agent
- Open Agents in Agent Studio.
- Review the migrated agent.
- Publish the agent when you're ready to go live.
Copy the agent ID. You use it in DocSearch and in custom API clients.
3. Update your integration
Choose the path that matches how you embed Ask AI today:
Your existing Ask AI assistant keeps serving traffic until Ask AI is fully retired. Switch your client to the Agent Studio agent when you're ready.
Update DocSearch
DocSearch v4
Set agentStudio to true inside the askAi object
and pass your Agent Studio agent ID as assistantId:
docsearch({
container: '#docsearch',
appId: 'YourApplicationID',
apiKey: 'YourSearchOnlyAPIKey',
indexName: 'YourIndexName',
askAi: {
assistantId: 'YOUR_AGENT_ID',
agentStudio: true,
},
});
<DocSearch
appId="YourApplicationID"
apiKey="YourSearchOnlyAPIKey"
indexName="YourIndexName"
askAi={{
assistantId: 'YOUR_AGENT_ID',
agentStudio: true,
}}
/>
Notes:
- Put
agentStudioinsideaskAi, not as a top-level DocSearch prop. - When
agentStudioistrue, DocSearch sends chat requests to Agent Studio for you. - When
agentStudio: true,searchParametersmust be keyed by index name. See Using Agent Studio with DocSearch andaskAi.agentStudio.
For the Sidepanel, set agentStudio={true} and pass the agent ID as assistantId. See the Sidepanel API reference.
DocSearch v5
In DocSearch v5, Agent Studio is the only chat backend.
Pass your Agent Studio agent ID as askAi.agentId, or as the askAi string shorthand.
Rename assistantId to agentId. You don't need an agentStudio flag:
docsearch({
container: '#docsearch',
appId: 'YourApplicationID',
apiKey: 'YourSearchOnlyAPIKey',
indices: ['YourIndexName'],
askAi: {
agentId: 'YOUR_AGENT_ID',
},
});
<DocSearchAI
appId="YourApplicationID"
apiKey="YourSearchOnlyAPIKey"
indices={['YourIndexName']}
askAi={{ agentId: 'YOUR_AGENT_ID' }}
/>
For more v5 detail, see the DocSearch v5 migration guide.
Custom Ask AI API integrations
If you call the Ask AI HTTP API yourself instead of using DocSearch,
configure your client to use Agent Studio instead of https://askai.algolia.com.
Don't build new integrations against the Ask AI chat API. Use the Agent Studio APIs:
- Integrate Agent Studio
- Agent Studio API
- Completions endpoint example:
https://{APPLICATION_ID}.algolia.net/agent-studio/1/agents/{AGENT_ID}/completions
Authenticate with your application ID and a search-only API key.
For DocSearch users, prefer the SDK configuration above—
DocSearch wires the Agent Studio transport when agentStudio is true.