SQL Assistant
- Customer
- Halyk Bank
- Project manager on the customer side
- Year of project completion
- 2026
- Project timeline
- september, 2025 — september, 2026
- Project scope
- 100 automated workstations
- Goals
-
AI assitant for Banks DWH based on data catalog and business glossary.
To grant bank employees direct access to corporate data warehouse information, eliminating the need to consult with analysts or IT staff. The objectives are: (1) to develop an AI assistant capable of interpreting natural-language queries to locate relevant data, explain its meaning, generate the corresponding SQL query, and execute it within the data warehouse; (2) to ensure the accuracy of responses by relying on a defined data model and business glossary, rather than the AI model’s internal "knowledge"; (3) to adhere to banking security requirements by ensuring the model operates within the bank’s secure environment, respects user access permissions, and is restricted to read-only operations; (4) to accelerate the migration of the data warehouse to a new platform by automating the rewriting of report queries; and (5) to engage business stakeholders in defining their own metrics and terminology.
- Project Results
-
The assistant proved valuable beyond just the business side: during the migration of the storage layer to a new platform, it enabled a team of two people to re-map over 4,000 reports in just three months—a task that otherwise would have required six people working for an entire year.
The uniqueness of the project
The assistant doesn’t guess—it relies on data descriptions. Every response is built from three sources: the data warehouse model, the technical catalog, and the business glossary. This drastically reduces the risk of hallucinations: the model doesn’t invent tables or metrics; instead, it locates them within these descriptions. The technical documentation was prepared by data specialists, while business terms and metrics were defined by the individual departments—essentially, the entire bank.Catalog has become a practical working tool rather than just a formality; the quality of the assistant’s responses depends directly on the quality of the catalog itself. The solution operates entirely within the bank’s internal environment using an open model; it is integrated with the directory service and access control system, functions in read-only mode, and includes a request-validation checkpoint before any action is executed.
- Used software
-
Qwen (on-premise, within the bank’s secure perimeter); Open WebUI (chat interface); Ataccama DGC (data catalog and business glossary); Greenplum (enterprise data warehouse); Oracle (source platform for the DDS layer); Active Directory and an access rights management system.
- Difficulty of implementation
-
The main challenge wasn’t the model itself, but the data about the data. To ensure the assistant provided accurate answers, we had to document the entire data repository and all data marts—including both technical specifications and a business glossary. The business terms were defined by the individual departments themselves, a process that required organizational coordination across virtually the entire bank. Security requirements precluded the use of external cloud services; the open-source model is deployed within the bank’s own infrastructure, which limits both the available computing resources and the model’s performance compared to cloud-based alternatives. This is compensated for by providing precise context from the directory. Integration with the directory service and the access control system ensures that the assistant does not reveal unauthorized information to the user. To reduce errors, a request-validation checkpoint has been incorporated into the processing pipeline.
- Project Description
-
The bank employs a self-service BI system, granting all employees access to data. However, access does not equate to the ability to use it: retrieving data requires knowing where it is stored, understanding the meaning of each field, and knowing how to write SQL queries. Some employees were unable to do this on their own and had to rely on analysts.
SQL_assistant is an AI-powered chat tool that acts as a guide to the data warehouse. An employee asks a question in natural language, and the assistant identifies the relevant tables and fields in the data catalog, verifies their definitions against the business glossary, constructs an SQL query, validates it, and executes it within the warehouse. The assistant covers the entire data warehouse and all data marts.
The foundation of accuracy lies in data description. Data models and technical catalogs were defined by data specialists, while business metrics and terminology were documented by the bank’s various departments—with nearly everyone taking part. The assistant draws its context from the catalog rather than from the model’s own internal memory, ensuring that its responses are based on verified descriptions.
Security is built into the architecture. The open-source language model is deployed within the bank’s internal environment, ensuring that data never leaves its perimeter. The assistant is integrated with the directory service and access control system, so users can only see data they are authorized to access. The assistant operates in read-only mode. Furthermore, the processing pipeline includes a validation step: any generated query is verified by the model before it is executed.
Currently, the assistant is used by 100 employees across 20 departments. Staff members who previously could not access data on their own are now able to retrieve it independently.
A second effect emerged during the migration of the data warehouse’s DDS layer from one DBMS to another. Over 4,000 reports had to be remapped to the new platform. By our estimates, this would have required 6 people working for a year; with the help of the assistant, 2 employees completed the task in 3 months—resulting in a saving of 5.5 person-years.
- Project geography
-
Kazakhstan