Add fetch_glql_schema to Data Analyst agent tools
What does this MR do and why?
Adds fetch_glql_schema to the analytics_agent catalog entry so the AI Catalog detail page reports the agent's tools accurately. The agent already has this tool in the AI gateway flow config, which is the runtime source of truth. The Rails list is display-only, so it was under-reporting the agent's capabilities.
orbit_list_commands and orbit_invoke_command are deliberately excluded. BuiltInToolDefinitions has no orbit entries, so Ai::FoundationalChatAgent#built_in_tools would silently drop them and they would not render. This is consistent with the orbit_agent entry, which has no tools entry at all. Making orbit tools catalog-visible is a separate follow-up.
References
Closes #624155
Gateway flow config (runtime source of truth): https://gitlab.com/gitlab-org/modelops/applied-ml/code-suggestions/ai-assist/-/blob/main/duo_workflow_service/agent_platform/v1/flows/configs/analytics_agent/2.0.0.yml
Screenshots or screen recordings
Not applicable. This changes catalog metadata only, and there is no visual change beyond one additional tool row on the agent detail page.
How to set up and validate locally
-
Run the specs:
bin/rspec ee/spec/lib/ai/foundational_chat_agents_definitions_spec.rb ee/spec/models/ai/foundational_chat_agent_spec.rbResult: 64 examples, 0 failures.
-
Query the agent through GraphQL:
{ aiFoundationalChatAgent(reference: "analytics_agent") { tools { title } } }It returns five tools, including
Fetch GLQL Schema.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist.
- Tests: no new test needed. Existing specs cover definition validity and model behavior, and this is a one-symbol metadata correction with no new branching.
- Documentation: no impact.
- Feature flag: not needed. The change only corrects a display list.
- Security, database, translation: no impact.