Contact us

AI-Powered Database Querying Assistant

Custom development of an MCP-enabled tool that integrates with AI models, allowing users to query relational databases using natural language requests.

ABOUT the project

Client:
Leobit's Internal Project
Location:
Country flag

USA

Company Size:
100+ Employees
Industry:

Information Technology

Technologies:

.NET

Angular

The Leobit team has developed an AI-powered database assistant that allows users without a corresponding technical expertise to query a PostgreSQL database using natural language questions in English.

We ran this project in two stages. Initially, we began implementation shortly after the release of MCP, but paused development due to its early limitations and shifting priorities. We later resumed the project once MCP had matured, gaining valuable experience in using it to integrate AI with database technologies and unlock powerful capabilities for database querying.

Yurii Shunkin

Yurii Shunkin

Head of R&D Department at Leobit

A man at a laptop with AI-Powered Database Querying Assistant on the screen

Customer

It was Leobit’s internal project aimed at exploring the capabilities of Model Context Protocol (MCP) for efficient and secure integration of AI models with relational databases.

Business Challenge

Many of our clients struggle with accessing unstructured data from databases. Such issues often require support from technical specialists. The Leobit team has decided to build a solution that would simplify database querying. We can reuse the approach to database schema organization and AI-powered database querying in our future projects.

Project
in detail

Our specialists started working on this PoC right after the introduction of MCP by Anthropic in 2024. As the technology still had some limitations, we put it on hold for some time and revived this idea in 2026.

Project in details

We had explored several iterations of the concept since the initial idea emerged. In 2026, our R&D specialists revisited the initiative and finalized the solution plan. For the PoC, we chose our proven technology approach with a .NET back end and a front end built with Angular and Tailwind CSS. Our specialists also designed the integration of AI models with relational databases using the now more mature MCP standard.

Our team used Anthropic SDK to use MCP for integrating Claude AI models with the PostgreSQL database. We also built basic yet very convenient PoC front ends with Angular and Tailwind CSS. .NET-based back end is responsible for connecting the interface with MCP delivering requests to the database. Our specialists also created a convenient schema within a PostgreSQL database storing sample data that can be queried.

At first, we faced issues with tool performance and excessive token optimization, as AI models had to spend time and capacity to explore the relational database. Therefore, we decided to build a convenient database schema that is analyzed by the model. Once Claude gets familiar with this schema, it can query data within the database much faster and without consuming so many tokens.

A woman with a laptop
Database Querying with Natural Language Requests

Database Querying with Natural Language Requests

The solution allows non-technical users to interact with a PostgreSQL database using plain English questions, without any SQL knowledge required. Under its hood, Claude processes that natural language input, interprets user intent, and generates database queries automatically. The assistant analyzes a pre-structured database schema to resolve queries faster and with lower token consumption. As a result, AI-powered querying is both practical and cost-effective.

Convenient UI

Convenient UI

The platform provides a simple and intuitive interface allowing users to explore its key functionality. Our developers used the combination of Angular and Tailwind CSS to keep the UI simple and user-friendly. A clean chat-style interface lets users type questions naturally and view results in a readable, well-organized format. Query results are presented in structured tables directly within the interface. In the future, the framework used in this project can be applied for integrating the solution with the UI of external tools, such as CRMs, corporate messengers, etc.

Model Context Protocol Integration

Model Context Protocol Integration

At the core of the solution, is a powerful integration layer built on Model Context Protocol. MCP ensures stability and security of the integration between Claude AI models and the PostgreSQL database. This approach provides AI models with read-only access to the database, ensuring that no sensitive credentials are exposed during the queries. The code written with .NET orchestrates the communication between the Angular front end and the MCP server to ensure fast and efficient work of the solution even under shifting loads.

Technology Solutions

  • Secure and reliable integration of AI models with databases through MCP.
  • Natural language processing and database querying capabilities powered by Claude AI.
  • Pre-structured database schema exposed to the assistant to ensure high operational speed and resource efficiency.
  • Minimalistic and intuitive front end built with Angular and Tailwind CSS.

Value Delivered

  • Ability to query databases with requests in natural language relevant to different industries, including financial services, healthcare, legal domain, manufacturing, etc.
  • Secure and reliable integration of AI models with the PostgreSQL database.
  • A framework that can be used in upcoming projects and integrated with varying solutions, such as CRMs, corporate messengers, etc.