Inspiration

The journey from a business question to a real insight is broken. The marketer who needs data can't write SQL. The analyst who writes SQL can't create a visualization. The data scientist who creates the visualization can't design an experiment. Each handoff is a bottleneck, a process that stifles curiosity and kills agility.

This is the problem we solve with Rumi-Analytica. The project is inspired by my 6-year-old daughter, Rumi, who expertly orchestrates her team of unicorn toys. In the same way, our platform orchestrates a team of specialized AI agents to deliver insights in minutes, not weeks.

What it does

Rumi-Analytica is a self-deploying, multi-agent analytics platform that provides a unified, conversational solution to the fragmented analytics workflow. Built with the Google Agent Development Kit (ADK) and deployed on Cloud Run, it empowers a single user to navigate the entire analytics journey—from data retrieval to experimental design—through one intuitive chat interface.

The solution is built on a hierarchical agent architecture where a central orchestrator, "Rumi," intelligently routes tasks to a team of specialized agents:

  • Zoey (GA4 & BigQuery Agent): Converts natural language into precise SQL to query Google Analytics data in BigQuery.
  • Ginger (Data Science Agent): Takes data and uses the Vertex AI Code Executor to perform analysis and generate visualizations like charts and plots.
  • Persephone (Econometrics Agent): A causal inference expert that guides users through designing and interpreting statistically robust experiments (like A/B tests) to validate their hypotheses.

In a single conversation, a user can go from a high-level question ("How did we acquire users?"), to a visualization ("Plot this as a bar chart"), to a validated insight ("I believe Organic Search users are more engaged. Can you help me test this?").

How we built it

Rumi-Analytica is engineered from the ground up as a production-grade, cloud-native solution on Google Cloud.

  • Core Framework: The multi-agent system is built using the Google Agent Development Kit (ADK), with a strategic mix of Gemini 1.5 Flash for speed and Gemini 1.5 Pro for complex reasoning.
  • Deployment: The application consists of two decoupled services deployed on Google Cloud Run:
    1. A FastAPI (Python) backend that serves the agent logic.
    2. A React (TypeScript) frontend that provides the polished user interface.
  • GCP Integration: The system seamlessly integrates with the broader Google Cloud ecosystem:
    • Google BigQuery serves as the data warehouse for all analytics queries.
    • Vertex AI Code Executor provides a secure, stateful environment for the Data Science and Econometrics agents to run Python code.
    • Google Secret Manager securely stores all credentials and API keys.
  • CI/CD Pipeline: The entire project is automated with a GitOps workflow using Google Cloud Build and Google Artifact Registry. A push to the main branch automatically builds, tests, and deploys both the frontend and backend services.

Challenges we ran into

  1. Production-Ready Agent Integration: Moving beyond the simple adk web command to integrate the ADK as a library within a custom FastAPI backend was a key challenge. We had to architect a clean way to manage agent runners, user sessions, and API security (JWT) within a standard web framework.
  2. Reliable Agent Orchestration: Prompt engineering the root agent, Rumi, to consistently and accurately delegate tasks to the correct sub-agent was an iterative process. It required carefully defining each agent's role and providing clear routing instructions.
  3. Handling Image Artifacts: Creating a seamless flow where our Data Science agent (Ginger) could generate a plot, save it as a file within its Cloud Run instance, and have the FastAPI backend detect, encode, and transmit that image back to the React frontend required careful coordination between the agent logic and the API layer.

What we learned

This project was a deep dive into building practical, complex agentic systems. I learned the immense power of a multi-agent approach, where specialized agents outperform a single monolithic agent. We also learned that prompt engineering is not just about writing instructions, but about designing the architecture of conversation and delegation. Finally, we saw firsthand how the Google Cloud ecosystem (Cloud Run, BigQuery, Cloud Build) provides a powerful and seamless platform for bringing these sophisticated AI applications to life.

What's next for Rumi-Analytica

This is just the beginning. Our roadmap is focused on making this system truly enterprise-ready by closing the loop from insight to action. Future enhancements include:

  • Deeper Intelligence & Learning: Integrating long-term memory via services like Vertex AI Agent Engine Memory Bank, so agents can learn from every interaction and provide more personalized insights over time.
  • Enhanced Reliability & Security: Building an automated testing pipeline into our CI/CD process that validates not just the final answer but the agent's entire chain of thought (its trajectory). This will be paired with advanced security layers to safeguard against malicious prompts.
  • True Actionability: Empowering agents to act on their findings. This means:
    • Automated Audience Creation: Integrating with the Google Analytics Admin API so a user can discover a valuable segment and immediately command, "Create a GA4 audience from these users for retargeting."
    • Automated Campaign Launch: Connecting to the Google Ads API, allowing a user to validate a hypothesis and then follow up with, "Launch an A/B test in Google Ads based on this finding," turning analysis into execution in seconds.

Built With

Share this project:

Updates