Review Analysis MCP Server
A local, privacy-friendly pipeline for analyzing customer reviews using Ollama for sentiment analysis and issue clustering.
README
Review Analysis MCP Server
A local, privacy-friendly pipeline for analyzing customer reviews. An MCP client (VS Code, Claude Desktop, …) drives a FastMCP server whose tools call a local Ollama model (Llama 3.1) to classify sentiment, surface recurring issues, and generate reports. A Streamlit dashboard visualizes the results.
MCP client ──MCP──▶ FastMCP server ──▶ Ollama (Llama 3.1)
│
▼
data/store.json ◀──reads── Streamlit dashboard
Tools
| Tool | Description |
|---|---|
upload_reviews(csv_text | reviews, replace) |
Ingest reviews from CSV text or a list of dicts. |
analyze_sentiment() |
Classify each review positive / neutral / negative. |
get_top_issues(limit) |
Cluster complaints into the top recurring issues. |
generate_report() |
Render a markdown report from the analysis. |
Setup
# 1. Python deps
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
# 2. Local LLM
# Install Ollama from https://ollama.com, then:
ollama pull llama3.1
ollama serve # if not already running as a service
Run
MCP server (stdio transport):
python server.py
Register it with your client. Example Claude Desktop / VS Code MCP config:
{
"mcpServers": {
"review-analyzer": {
"command": "/Users/chandangowda/Desktop/mcp/.venv/bin/python",
"args": ["/Users/chandangowda/Desktop/mcp/server.py"]
}
}
}
Point
commandat the Python inside your virtualenv (as above) so the server starts withmcp,ollama, etc. already installed.
Run with the MCP Inspector
The MCP Inspector is a browser UI for calling the server's tools by hand — the fastest way to try the pipeline without wiring up a full client.
# From the project root, with the virtualenv active:
source .venv/bin/activate
mcp dev server.py
This launches the Inspector and prints a local URL (default http://localhost:6274). Open it in your browser, then:
- Connect — the transport is already set to stdio with the command
pre-filled from
server.py. Click Connect. - Open the Tools tab and click List Tools to see the four tools:
upload_reviews,analyze_sentiment,get_top_issues,generate_report. - Run them in order:
upload_reviews— paste the contents ofdata/sample_reviews.csvinto thecsv_textfield (leavereplaceastrue), then Run Tool. You should see{"uploaded": 15, "total_reviews": 15}.analyze_sentiment— no arguments; Run Tool. Returns the sentiment distribution. (Requiresollama serverunning.)get_top_issues— optionally setlimit(default 5); Run Tool.generate_report— no arguments; Run Tool. Returns the final markdown report.
Prerequisites: ollama serve must be running and llama3.1 pulled (see
Setup), otherwise the analysis tools return an LLMError. If the
mcp command isn't found, install the CLI extra with
pip install "mcp[cli]".
Dashboard:
streamlit run dashboard/app.py
Try it end to end
- Start
ollama serveand the dashboard. - In the dashboard sidebar, upload
data/sample_reviews.csv→ Ingest CSV. - Click Run sentiment analysis, Find top issues, Generate report.
- Or drive the same flow from your MCP client by calling the tools.
Configuration
| Env var | Default | Purpose |
|---|---|---|
OLLAMA_MODEL |
llama3.1 |
Which Ollama model to use. |
OLLAMA_HOST |
(library default) | Ollama server URL, e.g. http://localhost:11434. |
REVIEW_STORE_PATH |
data/store.json |
Where shared state is persisted. |
Notes
- The server and dashboard are separate processes; they communicate only
through
data/store.json(atomic writes, so readers never see partial data). - Uploading new reviews clears any prior analysis for that dataset.
- Swapping to OpenAI/GPT-4o later means implementing the same
chat_jsoncontract insrc/llm.py— nothing else changes.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。