Utilizes Google Gemini 2.0 Flash to provide AI-powered analysis of company data, enabling natural language queries about spending trends and departmental performance.
Provides tools for complete CRUD operations on a structured database containing department, employee, expense, and performance records.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Enterprise Expense Automation SystemShow me a summary of the Tech department's expenses and performance"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
π’Enterprise Expense Automation System using MCP & NLP
A professional Model Context Protocol (MCP) server for tracking company expenses, employees, departments, and performance through natural language conversations with Claude Desktop.
β¨ Features
12 MCP Tools for complete CRUD operations
Natural Language Interface through Claude Desktop chatbot
Employee Management with unique employee numbers (EMP0001, EMP0002, etc.)
Expense Tracking with categorization and department assignment
Performance Management with ratings and comments
AI-Powered Analysis using Google Gemini 2.0 Flash (Latest 2025 Model)
Duplicate Detection and automatic cleanup
Safe Delete Operations with cascade support
ποΈ System Architecture

The architecture shows the complete flow from Claude Desktop through the MCP Server to the SQLite database, with AI-powered analysis via Google Gemini.
π Database Schema
Current Data:
4 Departments (Admin, HR, Tech, BPO)
18 Employees with unique employee numbers
34 Expense records
20 Performance ratings
π Quick Start
Prerequisites
Python 3.11 or higher
UV package manager or pip
Claude Desktop application
Google Gemini API key
Installation
Create virtual environment
Install dependencies
Set up environment variables
Create .env file:
Initialize database with sample data
Configure Claude Desktop
Add to %APPDATA%\Claude\claude_desktop_config.json:
Restart Claude Desktop
π οΈ MCP Tools (12 Total)
β Create Operations (4)
Tool | Description | Example |
| Create new departments | "Create Marketing department" |
| Add employees with auto employee numbers | "Hire John as Developer in Tech at $100k" |
| Track expenses by department | "Add $500 AWS expense to Tech" |
| Add performance ratings | "Give Alice 5 stars this month" |
ποΈ Delete Operations (4)
Tool | Description | Example |
| Remove employees by number/name | "Delete employee EMP0015" |
| Delete expense records | "Delete expense ID 45" |
| Remove departments (force mode available) | "Force delete Marketing with all data" |
| Auto-detect and remove duplicates | "Remove all duplicate employees" |
π Query Operations (3)
Tool | Description | Example |
| View employees (all or by department) | "Show all HR employees" |
| List expenses with filters | "Show Tech expenses last 30 days" |
| Comprehensive department stats | "Give me HR summary" |
π€ AI Analysis (1)
Tool | Description | Example |
| AI-powered insights via Gemini | "Which department spends most?" |
π¬ Usage Examples
Employee Management
Expense Tracking
Performance & Analysis
π Project Structure
π§ͺ Testing
Run tests:
Interactive database viewer:
π§ Configuration
Expense Categories
Infrastructure, Software Licenses, Training
Office Supplies, Utilities, Salaries
Recruitment, Events, Equipment, Maintenance
Employee Number Format
Auto-generated:
EMP0001,EMP0002, etc.Unique identifier for each employee
Used for quick lookups and operations
π Security Features
β API keys in environment variables
β Foreign key constraints in database
β Input validation on all operations
β Safe delete mode (force flag required for cascade)
β Duplicate detection and prevention
π Troubleshooting
Claude Desktop not showing tools
Restart Claude Desktop (right-click tray icon β Quit)
Check config path in
claude_desktop_config.jsonVerify database exists at
data/company.db
Database errors
Import errors
π Documentation
Quick Reference:
docs/QUICK_REFERENCE.mdComplete Summary:
docs/COMPLETE_SUMMARY.mdDelete Tools Guide:
docs/DELETE_TOOLS.mdGetting Started:
docs/GETTING_STARTED.md
π― Roadmap
Update/edit operations for employees and expenses
Bulk import/export functionality
Monthly and yearly report generation
Budget tracking with alerts
Employee search by skills/role
Expense approval workflow
Department budget management
API endpoint version
π Statistics
π€ Development
Adding New Tools
Define function in appropriate module
Add MCP tool wrapper in
main.pyTest with
tests/test_*.pyUpdate documentation
Code Style
Follow PEP 8 guidelines
Use type hints
Add docstrings to all functions
Include error handling
π License
Internal use only - Company Expense Tracker
Version: 1.0.0
Last Updated: October 15, 2025
Status: β
Production Ready
Maintained by: Company Development Team
For support or questions, see docs/COMPLETE_SUMMARY.md