rental-data

rental-data

Exposes multifamily rental data including average rent by market, occupancy anomalies, and property summaries to LLM tools via MCP.

Category
访问服务器

README

rental-data MCP server

An MCP (Model Context Protocol) server that exposes a multifamily rental dataset (markets, properties, rent, occupancy) to LLM tools like Claude Desktop or Claude Code — you ask questions in plain English, the model calls these tools to get real numbers back.

Built as a portfolio project mapped to: "Build and maintain MCP server integrations that expose data to LLM-powered tools."

What's here

  • data/make_data.py — generates a synthetic-but-realistic rental dataset (8 markets, 4 properties each, 12 months, 4 unit types = ~1,500 rows), with two deliberate anomalies baked in so the anomaly tool has something to find.
  • server.py — the MCP server itself. Three tools:
    • average_rent_by_market(unit_type) — average rent per market, latest month
    • occupancy_anomalies(threshold_pct) — flags month-over-month occupancy drops
    • property_summary(property_name) — rent trend + current occupancy for one property
  • requirements.txt — one dependency, pinned.

1. Setup (5 minutes)

cd mcp-rental-server
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
python3 data/make_data.py     # generates data/rentals.csv

2. Test it standalone (no Claude needed yet)

python3 -c "
from server import average_rent_by_market, occupancy_anomalies, property_summary
print(average_rent_by_market('2BR'))
print(occupancy_anomalies())
print(property_summary('AtlantaRidge1'))
"

You should see rent numbers by market, a flagged anomaly at AtlantaRidge2, and a rent trend summary. If that prints cleanly, the server logic works — the rest is just wiring it into a chat client.

3. Connect it to Claude Desktop

Find (or create) Claude Desktop's config file:

  • Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Add this (use the absolute path to your project + venv python):

{
  "mcpServers": {
    "rental-data": {
      "command": "/absolute/path/to/mcp-rental-server/venv/bin/python3",
      "args": ["/absolute/path/to/mcp-rental-server/server.py"]
    }
  }
}

On Mac, get the absolute path with pwd while inside the project folder. Fully quit and reopen Claude Desktop. You should see a small tools/plug icon in the chat box — click it to confirm rental-data is connected with 3 tools.

4. Demo prompts (use these in your screen recording)

  • "What's the average 2BR rent across all markets?"
  • "Are there any properties with anomalous occupancy drops?"
  • "Give me a summary of AtlantaRidge2 — what's going on with it?"
  • "Which market has the highest 3BR rent, and how does that compare to Charlotte?"

Watch Claude call the tool (it'll show up as a tool-use step) and answer using the real numbers, not a hallucinated guess. That contrast — grounded vs. ungrounded answers — is worth narrating out loud in the video.

5. Upgrade path: swap SQLite for real Databricks/Delta

This is the part worth mentioning verbally in your interview even if you don't demo it live: server.py loads data/rentals.csv into SQLite purely so the project runs with zero external accounts. The tool signatures (average_rent_by_market, etc.) don't change if you point them at a real warehouse — only load_data() and the query strings do.

To do the real version:

  1. Spin up Databricks Community Edition (free) at databricks.com/try-databricks
  2. Create a Unity Catalog table from the same CSV (or a public Kaggle rental dataset) as a Delta table
  3. Replace the SQLite connection with the databricks-sql-connector package:
    from databricks import sql
    conn = sql.connect(
        server_hostname="<your-workspace>.cloud.databricks.com",
        http_path="<your-warehouse-http-path>",
        access_token="<personal-access-token>",
    )
    
  4. Swap _conn.execute(...) calls to use this connection instead — same SQL, different backend.

Doing this swap for real (even against a tiny Databricks Community Edition table) is the single highest-leverage next step if you have extra time, since it's the literal technology named in the JD.

Repo structure

mcp-rental-server/
├── README.md
├── requirements.txt
├── server.py
└── data/
    ├── make_data.py
    └── rentals.csv   (generated, gitignored — see below)

Suggested .gitignore:

venv/
__pycache__/
*.pyc
data/rentals.csv

(Keep make_data.py in the repo so anyone cloning it can regenerate the dataset — cleaner than committing generated data.)

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选