Skip to content

Commit 8300f85

Browse files
authored
docs(ai-agents): document AI Router and update default agent references (#732)
* docs(ai-agents): document AI Router and update default agent references Add a dedicated AI Router page covering enabling the router, per-project routing instructions, the Auto option, what the router considers, the disambiguation picker, and Slack multi-agent routing. Add it to the nav and overview, and clarify how the default agent interacts with the router. * docs(ai-agents): trim AI Router page per review Make 'When the router runs' concise (drop the table and empty state), remove the 'Using Auto', 'What the router considers', and disambiguation picker sections (screenshots cover them), and simplify the default-agent FAQ to just link to the AI Router page. * docs(ai-agents): wire up router screenshots Use the Ask AI gif, add light/dark variants for the picker and settings toggle, and drop the routing-instructions image (the settings screenshot already shows it). * docs(ai-agents): add light/dark variants for the Auto option screenshot * docs(ai-agents): note that specialized agents pair well with the router
1 parent a122e31 commit 8300f85

12 files changed

Lines changed: 98 additions & 1 deletion

docs.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,7 @@
148148
"guides/ai-agents",
149149
"guides/ai-agents/getting-started",
150150
"guides/ai-agents/using-ai-agents",
151+
"guides/ai-agents/ai-router",
151152
"guides/ai-agents/agent-memory",
152153
"guides/ai-agents/verified-answers",
153154
"guides/ai-agents/evaluations",

guides/ai-agents.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ This guide covers everything you need to know about AI agents in Lightdash:
2424
</Card>
2525
<Card title="Using AI agents" icon="comment" horizontal href="/guides/ai-agents/using-ai-agents">
2626

27+
</Card>
28+
<Card title="AI Router" icon="route" horizontal href="/guides/ai-agents/ai-router">
29+
2730
</Card>
2831
<Card title="Agent memory" icon="brain" horizontal href="/guides/ai-agents/agent-memory">
2932

@@ -55,6 +58,7 @@ This guide covers everything you need to know about AI agents in Lightdash:
5558

5659
- **Natural language queries** - Ask questions in plain English and get instant answers
5760
- **Ask from a chart or dashboard** - Launch a conversation with the chart or dashboard you're viewing already pinned as context
61+
- **AI Router** - Automatically send each question to the best-fit agent, so users don't have to pick one first
5862
- **Automatic visualizations** - Get charts, tables, and dashboards generated based on your questions
5963
- **Slack integration** - Collaborate with your team directly in Slack channels
6064
- **Memory and learning** - Agents remember corrections and improve over time

guides/ai-agents/ai-router.mdx

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
---
2+
title: "AI Router"
3+
sidebarTitle: "AI Router"
4+
description: "Automatically route questions to the best-fit agent, so users don't have to pick one first."
5+
---
6+
7+
<Info>
8+
The AI Router is part of the AI agents add-on. [View pricing](https://www.lightdash.com/pricing)
9+
</Info>
10+
11+
When you have more than one AI agent in a project, users have to know which agent to ask. The **AI Router** removes that decision: type a question, and Lightdash picks the agent best suited to answer it.
12+
13+
The router compares each agent's description, instructions, data access, and verified questions to decide where a question should go.
14+
15+
<Note>
16+
The router only chooses **between agents the user can already access**. It never widens an agent's data access or bypasses permissions — it only changes *which* of the user's available agents answers a given question.
17+
</Note>
18+
19+
<Frame>
20+
<img src="/images/guides/ai-agents/ai-router-ask-ai.gif" alt="Ask AI router landing page" />
21+
</Frame>
22+
23+
## When the router runs
24+
25+
The router needs **at least two agents you can access** in a project. With a single accessible agent there's nothing to route between, so Lightdash opens that agent directly.
26+
27+
When the router is confident, it routes your question straight to the best agent and starts the conversation. When it isn't, it shows a short picker with the recommended agent highlighted so you can choose.
28+
29+
<Frame>
30+
<img className="block dark:hidden" src="/images/guides/ai-agents/ai-router-picker.png" alt="Picker showing candidate agents" />
31+
<img className="hidden dark:block" src="/images/guides/ai-agents/ai-router-picker-dark.png" alt="Picker showing candidate agents" />
32+
</Frame>
33+
34+
If you've set a [default agent](/guides/ai-agents/using-ai-agents#faqs), it opens first even when the router is enabled. Pick **Auto** from the agent dropdown to let the router decide instead.
35+
36+
<Frame>
37+
<img className="block dark:hidden" src="/images/guides/ai-agents/ai-router-auto-option.png" alt="Auto option in the agent selector" />
38+
<img className="hidden dark:block" src="/images/guides/ai-agents/ai-router-auto-option-dark.png" alt="Auto option in the agent selector" />
39+
</Frame>
40+
41+
## Enabling the router
42+
43+
The router is configured at the **organization level** and requires **Organization Admin** permissions.
44+
45+
<Steps>
46+
<Step title="Open AI settings">
47+
Go to **Settings → Organization Settings → Ask AI → General**.
48+
</Step>
49+
<Step title="Make sure AI features are on">
50+
The router can only be turned on when **Enable AI features for users** is already enabled. If AI features are off, the router toggle is disabled with the hint *"Enable AI features first to use the Router."*
51+
</Step>
52+
<Step title="Turn on the AI Router">
53+
Toggle on **AI Router***"Route user questions to the best agent automatically, instead of asking users to pick."*
54+
</Step>
55+
</Steps>
56+
57+
<Frame>
58+
<img className="block dark:hidden" src="/images/guides/ai-agents/ai-router-settings-toggle.png" alt="AI Router toggle in Ask AI general settings" />
59+
<img className="hidden dark:block" src="/images/guides/ai-agents/ai-router-settings-toggle-dark.png" alt="AI Router toggle in Ask AI general settings" />
60+
</Frame>
61+
62+
## Routing instructions
63+
64+
By default the router decides on its own, but you can give it **routing instructions** to steer specific kinds of questions toward specific agents — for example, *"send billing questions to the Finance agent."* Instructions are written per project and authored by admins.
65+
66+
<Steps>
67+
<Step title="Open routing instructions">
68+
With the router enabled, scroll down on the **Ask AI → General** page to the **Routing instructions** card.
69+
</Step>
70+
<Step title="Pick a project">
71+
Choose the project these instructions apply to. Routing instructions are scoped per project.
72+
</Step>
73+
<Step title="Write your rules">
74+
Describe how questions should be directed. Type **@** to tag a specific agent, then click **Save instructions**.
75+
</Step>
76+
</Steps>
77+
78+
A few things to keep in mind:
79+
80+
- **Rules are advisory.** They guide the router's choice but **never override an agent's access restrictions**. A rule can only point to agents the user can already access.
81+
- **Tagged agents must belong to the project.** You can only tag agents that exist in the selected project.
82+
- **Fewer than two agents?** You can still write and save instructions, but the router won't run in that project until at least two accessible agents exist. Lightdash shows a note when this is the case.
83+
84+
## Router and Slack
85+
86+
The same routing logic powers **multi-agent Slack channels**. In a multi-agent channel you mention the single Lightdash Slack app and Lightdash automatically picks the best agent for your question — no need to know which agent to address. See [Slack channels: single-agent vs. multi-agent](/guides/ai-agents/getting-started#slack-channels-single-agent-vs-multi-agent) for setup.

guides/ai-agents/best-practices.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ To get the most accurate and useful answers from your AI agents, follow these be
1010

1111
Think of AI agents as your specialized analysts - each one can be configured to focus on specific areas of your business. For example, you might create a "Marketing Assistant" that only has access to marketing data like campaign performance, lead generation, and customer acquisition metrics. This focused approach ensures more accurate, relevant responses and prevents sensitive data from being accessible to the wrong teams. To find out more about how to configure specific access, see [Limiting access to specific explores/fields](/guides/ai-agents/data-access#limiting-access-to-specific-explores-and-fields).
1212

13+
Specialized agents also work best with the [AI Router](/guides/ai-agents/ai-router) enabled: the more distinct each agent's focus, description, and data access, the more reliably the router can send each question to the right one — so users don't have to know which agent to ask.
14+
1315
## Document your data thoroughly
1416

1517
Good documentation is crucial for AI to understand your data models and provide meaningful insights. The quality of the results depend on the quality of your metadata and documentation.

guides/ai-agents/using-ai-agents.mdx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,11 @@ You can assign your default agent in Ask AI by clicking the star by your agent's
124124
alt="Set Default Agent"
125125
/>
126126
</Frame>
127-
The default agent setting is per-user, per-project. There's no project-wide default at the moment. If you haven't set a default, there's no predictable way to determine which agent appears first.
127+
The default agent setting is per-user, per-project. There's no project-wide default at the moment.
128+
129+
When you have a default agent set, Ask AI opens it directly — even if the [AI Router](/guides/ai-agents/ai-router) is enabled.
130+
131+
If you haven't set a default and the AI Router is enabled, Lightdash routes each question to the best-fit agent automatically. If the router is off and you have no default, there's no predictable way to determine which agent appears first.
128132

129133
## Known limitations
130134

5.37 MB
Loading
130 KB
Loading
137 KB
Loading
119 KB
Loading
135 KB
Loading

0 commit comments

Comments
 (0)