Skip to main content
Glama
VladimirBigunenko

Portfolio Data Analytics MCP Server

Python Portfolio — Data Analytics MCP Server

A self-contained demo portfolio project built to showcase Python skills relevant to a data-analytics / AI-assisted development role.

It is a working MCP (Model Context Protocol) server that exposes data analytics tools — load a CSV, compute summary statistics, filter rows, rank columns, compute correlations. An AI assistant (or any MCP client) can drive it over the standard protocol.

Why an MCP server? This is a real, production-shaped type of software: it connects AI agents to tools and data. I build MCP servers and AI agents as part of my daily work, and this project demonstrates those exact skills in a clean, self-contained way.

Features

  • load_csv — ingest a CSV dataset, get back its inferred schema

  • list_datasets — show all registered datasets

  • summary — pandas describe() statistics

  • filter_rows — filter on a numeric column (>, <, >=, …)

  • top_rows — top-N rows by a numeric column

  • correlation — Pearson correlation between two columns

A built-in demo dataset (campaigns) lets it run immediately with no setup.

Quickstart

# install deps + dev tools
uv sync --dev

# run tests (13 tests covering all tools)
uv run pytest -q

# run as an MCP server over stdio (used by MCP clients)
uv run portfolio_data_mcp.py

# run over SSE for local HTTP testing
uv run portfolio_data_mcp.py --transport sse --port 8765

Test with the mcp CLI

# register the server so an MCP client can connect
uv run mcp install portfolio_data_mcp.py --name "portfolio-data"

Example

echo 'channel,spend,conversions
social,3500,210
search,4200,330
display,3800,95
email,1100,180' | uv run python -c "
import asyncio, portfolio_data_mcp as m
asyncio.run(m.main())  # starts stdio server
"

Then from an MCP client:

tools: load_csv(name="x", csv_text=...)   -> schema
       summary(name="x")                  -> statistics
       top_rows(name="x", column="spend", n=3)

Project layout

python-portfolio/
├── portfolio_data_mcp.py   # the MCP server (tools + logic)
├── tests/
│   └── test_portfolio_mcp.py   # 13 passing tests
├── pyproject.toml
└── README.md

Tech

Python · MCP SDK (mcp) · pandas · pytest · type hints · uv


© Volodymyr — Vienna, Austria. Part of my job-search portfolio.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/VladimirBigunenko/python-portfolio'

If you have feedback or need assistance with the MCP directory API, please join our Discord server