Situation
The delivery-analytics and scorecard system I ran lived in Google Sheets and Apps Script with a homemade CSV and Drive persistence layer. It worked, but it made me the human query engine for every ad-hoc data request, and it was not going to scale.
Objective
Cut the ad-hoc request load, let non-analysts answer their own data questions, and deprecate the Sheets system with a web app that stored data in Google BigQuery and could build charts, tables and summaries on demand. I built it on SentinelOne’s standard design language, technologies and tooling so it would feel native to the company.
Approach
Data and AI backbone
- Integrated with SentinelOne’s self-developed AI gateway, the same gateway the company used inside its own products, rather than standing up separate model access.
- Pluggable data stores such as Postgres or BigQuery, with either a service credential or the user’s own auth.
- A Redis caching layer.
- A vector store holding the table and column structure of each registered store. Where the source was thin, I investigated and injected table and column descriptions so the schema carried meaning for the model.
Chat to read-only query, one shot
Wiring the schema-aware vector store into chat, with enforced read-only query generation, let the chat one-shot ad-hoc queries that retrieved data far more efficiently than a naive query system. I built it in LangGraph with a ReAct agent and custom tooling, including a BigQuery provider I wrote myself, since the default DB-provider system did not ship one. The LLM emitted structured JSON that the front end rendered as live charts and tables in the chat window.
A SQL and KPI workbench
For structured, formal KPIs I built a SQL IDE with an AI co-pilot:
- Full SQL recognition with syntax highlighting, a table explorer that detects newly added tables, and enriched autocompletion.
- An AI chat beside the editor that could create, optimize, fix and run SQL against the gateway’s models.
- Dynamic variables such as
@current_user, tied to the user’s profile loaded on login from BigQuery-hosted employee records, and@current_sprint. - Save as KPI: a validated query and its variables persisted to Postgres, with a description and use cases written into the knowledge base. The chat checked that KB first and favored an existing KPI over fresh SQL when one fit.
Business context in the knowledge base
I built a harvester that, given a URL with pass-through auth, collected information about SentinelOne from the marketing site, the support-portal documentation and Confluence. That made cross-domain questions answerable. Asked “how many bugs past SLA are open in a given product?”, the chat would pull SentinelOne’s SLA definitions from the KB, find the right data source, create and validate a query, run it, present the data and a summary, and offer to save it as a KPI.
Dashboard builder
- A GUI editor for pages with controls bound to the variable system, including hierarchical ones: pick a department, get its engineering managers, pass one into a KPI.
- Tables, charts and AI insights, each bound to a KPI from the library.
- Personal or system-level reports, shareable to a person or org.
- A per-report button that opened the chat scoped to that report’s content.
Net results
- One platform replaced the Sheets delivery and scorecard pipeline, collapsed my ad-hoc request load, and let non-analysts self-serve data questions in plain English. Internally it served as SentinelOne’s SEI, or Software Engineering Intelligence, platform pending selection of a commercial SEI vendor.
- Through the GUI I reproduced and retired the scorecard and DevOps reporting system that had run in Apps Script and Sheets.
- A substantial TypeScript and Next.js application, well into six figures of lines, with validated query generation, markedly faster query resolution than a naive approach, and high automated-test coverage across a large unit and end-to-end suite. Built from scratch, essentially solo, in weeks.
Takeaway: prefer a vetted KPI over fresh generation. Letting the agent reach for a human-validated KPI first is what makes agentic analytics trustworthy.
Scope and technologies
Windsurf; TypeScript and Next.js; Google BigQuery as the primary store, with a custom provider; Postgres and pgvector for KPI and variable persistence and vector search; Redis; LangGraph with a ReAct agent and custom tooling; unit and Playwright end-to-end tests; SentinelOne’s internal AI gateway with hosted models; enforced read-only query generation; structured-JSON chart and table rendering; a SQL IDE with table explorer, autocomplete and AI create, optimize, fix and run; a dynamic variable library; a pass-through-auth KB harvester for the marketing site, support docs and Confluence; a GUI dashboard and report builder with KPI-bound hierarchical controls, sharing and report-scoped AI.