Financial-MCP-Server

Financial-MCP-Server

Provides financial data extraction, calculation, and analysis from XML files via a FastMCP server, integrated with a Streamlit frontend and local LLM for secure corporate data handling.

Category
Visit Server

README

Financial-MCP-Server- Assistant IA & Serveur MCP

Description du Projet

Ce projet a été réalisé dans le cadre d'un stage de 2ème année de licence. Il s'agit d'une application IA complète intégrant un serveur MCP (Model Context Protocol) en Python. Ce projet implémente un serveur FastMCP pour l'extraction, le calcul et l'analyse de données financières d'entreprises à partir de fichiers XML (bilans standards et bilans détaillés étendus). Il inclut un client frontend interactif développé avec Streamlit, connecté à un modèle de langage local via Ollama pour garantir la sécurité et la confidentialité totale des données corporate.

Auteur : Malek Ghozzi

Prérequis

  • Python 3.10+
  • Ollama installé en local avec le modèle qwen2.5-coder:7b
  • Fichiers sources :
    • Fichiers XML placés dans le répertoire ./data/xml/
    • Fichier d'indexation placé dans ./data/xmls.csv
    • Dictionnaire de données data_dictionary.md à la racine

Installation

  1. Clonez ce dépôt ou copiez les fichiers du projet.
  2. Installez les dépendances requises :
    pip install mcp streamlit openai
    pip install -r requirements.txt ```
    
    

Démarrage et Utilisation

  1. Lancez le modèle local Ollama en arrière-plan : 'ollama run qwen2.5-coder:7b'
  2. Dans un nouveau terminal, lancez l'interface Streamlit : 'streamlit run app.py'

Outils Implémentés

Le serveur FastMCP met à disposition du LLM 5 outils d'analyse :

- find_company_xml : Recherche l'entreprise dans l'index CSV via son nom ou SIREN.

- extract_xml_by_keyword : Explore les bilans détaillés pour extraire les valeurs historiques d'un      mot-clé spécifique (gère la déduplication et les valeurs absentes).

- get_company_indicator : Extrait la valeur d'un code indicateur précis (ex: CA00, RN00).

- calculate_profit_margin : Calcule la marge bénéficiaire (Résultat Net / Chiffre d'Affaires).

- lookup_financial_term : Traduit les acronymes financiers via le dictionnaire de données.

Exemples d'Utilisation

L'agent est configuré pour interroger chaque entité séparément et éviter les hallucinations. Testez avec ces requêtes :

- "Quelle est la marge bénéficiaire de TISSOT ETANCHEITE ?"

- "Peux-tu me donner l'indicateur CA00 pour KA BATIMENT ainsi que pour TISSOT ETANCHEITE ?"

- "Recherche le mot-clé 'provisions' dans le fichier de KA BATIMENT."

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured