02 / Analytics copilot · Moglix

Ramanujan

Project study

Ask business questions in plain English inside Microsoft Teams and get answers from company data in seconds.

Ramanujan / Analytics copilot · Moglix / 2026

Role
Backend & GenAI · AI & Analytics team
Status
Internal tool
Year
2026
Stack
Python / FastAPI / Gemini / Vertex AI / BigQuery / Qdrant / Sentence-Transformers / Microsoft Graph API / Docker

02 / Overview

A question in Teams. An answer from the warehouse.

Ramanujan is an analytics copilot that lives where business teams already talk: Microsoft Teams. Someone asks a question in plain English, and a Gemini agent turns it into governed BigQuery SQL, runs it and replies with the answer, without the person writing SQL or opening a dashboard.

  1. Ask
  2. Ground
  3. Generate
  4. Guard
  5. Answer

Ramanujan / how the parts connect

03 / The problem

Every simple question waited on someone who could write the query.

Business teams had questions about their numbers every day, but the answers sat in a data warehouse behind SQL and dashboards. Each question became a request to the data team, and the same metric could be calculated differently depending on who wrote the query.

  1. 01

    Answers locked behind SQL and dashboards

  2. 02

    Metrics defined differently by different people

  3. 03

    Data access that has to respect who is asking

04 / How it works

Five steps from a sentence to a governed answer.

  1. 01

    Ask

    A question arrives from Microsoft Teams through the Microsoft Graph API.

  2. 02

    Ground

    RAG over a KPI glossary in Qdrant finds the business definition of each metric.

  3. 03

    Generate

    A Gemini ReAct agent writes BigQuery SQL that follows those definitions.

  4. 04

    Guard

    A SQL policy engine checks the query and applies row-level access control.

  5. 05

    Answer

    The result comes back to Teams, grounded in the data, not guessed.

05 / Key decisions

Where the important calls were made.

Decision 01

Should the model be free to query anything?

  1. →

    The choice

    Every query passes a SQL policy engine with row-level access control.

  2. →

    What it gave

    People only ever see the data they are allowed to see.

Decision 02

How do answers match what the business means by a metric?

  1. →

    The choice

    RAG over a KPI glossary with sentence-transformer embeddings.

  2. →

    What it gave

    GMV, margin or fill rate mean the same thing in every answer.

Decision 03

How should the service be structured?

  1. →

    The choice

    A FastAPI service on Vertex AI built with hexagonal architecture.

  2. →

    What it gave

    Models, data sources and chat channels can be swapped without touching the core.

06 / The flow

From the first step to the result.

What it looks like from the side of the person using it — the path through Ramanujan in 4 steps.

  1. 01Ask a question in Teams
  2. 02The agent writes a governed query
  3. 03Guardrails check the query and access
  4. 04Read the answer in the chat

Ramanujan / user flow

07 / Outcome

Data questions answered where the conversation already happens.

From question to answer
Seconds
Needed from the person asking
0 SQL
Access control on every query
Row-level
03 / Next project Distiller Change one line, and repeated LLM calls slowly move to a small model you own.