Inspiration
Africa generates vast amounts of data — on demographics, the economy, agriculture and health — but this data remains fragmented and inaccessible to most people. African policymakers, researchers and entrepreneurs spend hours searching for figures scattered across PDFs from international agencies. Kekeli was born out of this frustration: to make insights from African data accessible to everyone, through simple conversation and, above all, to avoid misinterpretations.
What it does
Kekeli is an AI agent specialising in African data. You ask a question in natural language — “What is the youth unemployment rate in Benin in 2023?”, "Compare the GDP of Senegal and Côte d'Ivoire over 10 years" — and Kekeli queries a BigQuery database of 13 tables covering 54 countries in real time: economic, demographic, agricultural, health and climate indicators. The answers are sourced, quantified and contextualised.
How we built it
- Agent: Google Agent Development Kit (ADK) + Gemini 3.5 Flash, 12 bespoke BigQuery tools
- Backend: Cloud Run (ADK agent + Next.js API), Firebase Auth, Firestore for conversation history
- Frontend: Next.js 15 with assistant-ui, word-by-word SSE streaming, bilingual interface (next-intl)
- Data: BigQuery on titan-ia-497117, 13 tables normalised from ISO sources (World Bank, FAO, WHO, AU and others)
- Resilience: min-instances=1 to keep ADK sessions in memory + Firestore history injection as a fallback if session expires
Challenges we ran into
- Cloud Run ingress internal was blocking all traffic between services — even within the same project. Solution:
switch to ingress=all with IAM as the sole safeguard.
- In-memory ADK sessions lost on every restart → silent 404 errors on the user side. Two-tier solution: minimum active instances + context reconstruction from Firestore.
- Cross-project IAM: the service account for titan-ia-497117 needed to have the roles/datastore.user permission in the Firebase project kekeli-fb324 — not clearly documented.
- Non-ISO indicators: some African countries use codes and conventions that deviate from international standards, requiring manual data standardisation.
- Hallucinations regarding African data: generalist LLMs invent plausible but false figures — GDP, mortality rates, populations — for countries under-represented in their training data. Solving this problem was central to Kekeli’s architecture.
Achievements we’re proud of
- Anti-hallucination by design: Kekeli never responds “from memory” on numerical data. Every numerical response goes through a BigQuery tool — if the data isn’t in the database, the agent states this explicitly rather than making it up. The model is used solely to understand the question and formulate the response, not to generate the figures.
- Source traceability: executed SQL queries are logged, and the returned data comes directly from referenced sources (World Bank, FAO, WHO) — the user can trace it back to the raw source.
- Honest fallback mode: when the ADK backend is unavailable, the Claude Opus fallback explicitly indicates explicitly states "fallback mode — real-time data unavailable" rather than silently substituting made-up figures.
- An agent that understands the African context: economic unions (ECOWAS, AU, SADC), local currencies, alternative country names
- Zero perceptible cold start thanks to min-instances + transparent Firestore fallback
- Smooth streaming with real-time tool indicators (“🔍 get_gdp_data…”)
What we learned
- Generalist LLMs actively hallucinate about Africa — not for lack of effort but due to a lack of quality training data. A confidently invented figure is worse than no response at all.
- The strict separation between reasoning (LLM) and data (BigQuery) is the only architecture that guarantees reliability across domains under-represented in the training corpora.
- Session persistence in a serverless environment is a problem in its own right, not a minor detail.
- Firestore rules and multi-project IAM are two orthogonal systems that can silently block each other.
Built With
- adk
- agent
- anthropic
- assistant-ui
- bigquery
- claude
- css
- firebase
- firestore
- gemini
- next-intl
- next.js
- opus
- run
- tailwind
- typescript
Log in or sign up for Devpost to join the conversation.