Chat with your expense data in Telegram. Ask natural-language questions and receive a clean summary from Google Sheets.
This AI agent connects your Google Sheets expense log to an AI-powered query engine that understands natural language. It resolves ambiguous categories and person names, and returns a clean, formatted summary directly in Telegram. The end-to-end flow enables chat-based questions to yield accurate, on-demand insights without opening a spreadsheet.
Queries expenses from Google Sheets and returns a Telegram-ready summary.
Parse user intent from natural language queries using GPT-4.1-nano.
Resolve ambiguous categories and person names via mapping tables.
Query and filter Google Sheets expenses data by time range, category, and person.
Aggregate totals and provide breakdowns by category or person.
Format results into Telegram-ready messages with a clean layout.
Learn aliases over time to improve accuracy and reduce repeats.
This AI agent addresses real-world expense-reporting challenges by enabling natural-language access to financial data in a familiar chat interface. It processes ambiguous terms, resolves entities, and returns structured summaries. The system continuously learns by saving confirmed aliases, improving accuracy over time.
A simple 3-step flow that non-tech users can follow.
Parse the user’s natural-language query using GPT-4.1-nano to identify the time range, target category, and involved person(s).
Resolve ambiguous categories and person names using mapping tables, offering closest matches when needed.
Query Google Sheets with filters, aggregate results, format the summary for Telegram, and send it back; if needed, prompt for confirmation via inline buttons and save confirmed aliases for future accuracy.
A realistic chat scenario showing input, processing, and output.
Scenario: A user in Telegram asks, “Show groceries spending last month.” The AI agent parses the request, resolves the groceries category, and filters the Google Sheets expenses log for the prior month. It then aggregates the total and provides a category breakdown, returning a clean, formatted summary directly in Telegram.
Roles that gain fast, chat-based access to expense insights.
Needs quick visibility into monthly expenses for decision-making without digging through spreadsheets.
Wants project- or client-specific costs tracked across multiple clients via chat.
Needs consolidated expense views for teams or departments without complex dashboards.
Requires on-demand summaries to reconcile ledgers efficiently.
Keeps household spending in sight and under control through chat queries.
Tracks grant-related expenses and budgets quickly for reporting.
Key tools work together to power chat-based expense insights.
Delivers responses, uses inline buttons for disambiguation, and notifies users.
Reads the expenses log and mapping tables; applies filters for time, category, and person.
Interprets natural-language queries, resolves entities, and generates formatted summaries.
Executes filtered queries, aggregations, and data retrieval.
Concrete scenarios where this AI agent adds value.
Common questions about data, usage, and security.
The AI agent reads data from your approved Google Sheets: expenses, expense_categories, categories_mapping, and person_mapping. It processes queries in Telegram and uses inline buttons to confirm ambiguous results when needed. Access is restricted to the specified sheets and authorized users. Data handling follows standard security practices, and changes to mappings update the resolution logic for future queries. You control which users can send queries and when data is retrieved.
Yes. The system supports natural-language queries in English and German, and it will resolve categories and entities accordingly. It provides the same formatted summaries regardless of language, ensuring consistency in responses. If a term is ambiguous in either language, it will prompt for clarification via Telegram inline buttons. You can switch languages mid-conversation, and the AI will adapt the remaining interaction.
Unknown categories or names trigger aAI-suggested closest matches. The agent asks for confirmation via Telegram inline buttons before saving a new alias. Once confirmed, the alias is stored to improve subsequent results. If a match is rejected, the system can propose alternatives and continue querying without disruption. This keeps results accurate while expanding the mapping dataset over time.
Data security is prioritized through restricted access to the Google Sheets and controlled integration points. All data transfers occur over secure channels, and only the specified sheets are read for querying. Users authenticate via Telegram, and access can be managed with an allowlist. The agent logs are designed to avoid exposing sensitive fields in Telegram messages, focusing on concise, formatted results.
Yes. The system supports multiple users via a Chat ID allowlist. Each user’s queries are scoped to their permissions and mappings. Responses are delivered in their Telegram chat, and disambiguation prompts are shown only to the relevant user when needed. This enables collaborative expense analysis without sharing sensitive data beyond allowed channels.
Date ranges can be specified in natural language, such as 'this week', 'last month', or specific periods like '2025-04'. The agent translates these into exact filters against Google Sheets data. It also supports relative dates for quick, repeatable queries. For precise reporting, you can combine date ranges with category or person filters in a single query.
Responses typically come back within a few seconds, depending on the query complexity and dataset size. Simple queries return results faster, while multi-criteria requests may require deeper filtering. The system is optimized for Telegram delivery, so formatted summaries are provided promptly with clear breakdowns. If a query is ambiguous, the bot prompts for confirmation to avoid delays from incorrect results.
Chat with your expense data in Telegram. Ask natural-language questions and receive a clean summary from Google Sheets.