Module 9: Model Context Protocol

MGMT 675: Generative AI for Finance

Kerry Back, Rice University

What is MCP?

The Model Context Protocol (MCP) is an open standard that lets AI applications connect to external tools through a uniform interface.

The Idea

  • A standard “plug-in” protocol for AI
  • Each server advertises tools (functions the AI can call)
  • Tools appear automatically — no custom code needed

Analogy

  • USB is a standard for peripherals
  • Plug in a keyboard, it just works
  • MCP is the USB standard for AI tools

You can connect multiple servers at once. The LLM sees all their tools and decides which to use.

MCP Server = Running Program

An MCP server is a small program that stands between the AI and an external tool.

  • The server advertises tools — functions the AI can call (e.g., “query stock prices”, “get income statement”)
  • When the AI decides to use a tool, the server makes the actual API call, queries the database, or controls the browser
  • The server returns structured results back to the AI

The AI never contacts the external service directly. It sends a request to the MCP server; the server does the work and reports back.

How MCP Works

%%{init: {'theme': 'base', 'themeVariables': {'fontSize': '20px'}, 'flowchart': {'nodeSpacing': 60, 'rankSpacing': 80, 'padding': 12, 'useMaxWidth': true}}}%%
flowchart LR
  C["<b>Claude Desktop<br>(MCP Client)</b>"] -->|"MCP protocol"| S1["<b>Browser Server</b>"]
  C -->|"MCP protocol"| S2["<b>Financial Data Server</b>"]
  C -->|"MCP protocol"| S3["<b>Terminal Server</b>"]

  style C fill:#eff6ff,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:20px,padding:12px
  style S1 fill:#eff6ff,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:20px,padding:12px
  style S2 fill:#eff6ff,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:20px,padding:12px
  style S3 fill:#eff6ff,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:20px,padding:12px

  • Claude Desktop is the client; each external service runs as a server
  • Servers expose tools (functions the AI can call); the LLM picks which to use

How an Agent Uses MCP

%%{init: {'theme': 'base', 'themeVariables': {'fontSize': '42px'}, 'flowchart': {'nodeSpacing': 100, 'rankSpacing': 140, 'padding': 28, 'useMaxWidth': true}}}%%
flowchart LR
  U["<b>👤 User</b>"] ---|"request & result"| A["<b>🤖 Agent</b>"]
  A ---|"API calls"| L["<b>🧠 LLM</b>"]
  A ---|"Protocol"| M["<b>🔌 MCP Server</b>"]
  M ---|"API Call"| T["<b>🔧 Tool</b>"]

  style U fill:#eff6ff,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:56px,padding:24px
  style A fill:#dbeafe,stroke:#3b82f6,stroke-width:2px,color:#0f172a,font-size:56px,padding:24px
  style L fill:#fef3c7,stroke:#f59e0b,stroke-width:2px,color:#0f172a,font-size:56px,padding:24px
  style M fill:#fed7aa,stroke:#ea580c,stroke-width:2px,color:#0f172a,font-size:56px,padding:24px
  style T fill:#f0fdf4,stroke:#22c55e,stroke-width:2px,color:#0f172a,font-size:56px,padding:24px

  linkStyle default stroke:#3b82f6,stroke-width:4px

  • The MCP server sits between the agent and the tool
  • Agent and server communicate via a standard protocol
  • The server makes the actual API call to the external tool

Why Not Just Call the API Directly?

An agent can access any API by writing code — Claude Code does this all the time. MCP servers are the alternative: a pre-built connector that standardizes the interface.

Direct API Access

  • Agent writes Python to call the API
  • Must handle auth, parsing, errors each time
  • Flexible but reinvents the wheel

MCP Server

  • Pre-built connector, tested and shared
  • Agent calls a tool; server handles the rest
  • Works with any MCP-compatible client

Like a USB driver: built once, works everywhere. The agent doesn’t need to know how the API works — just what tools are available.

What MCP Servers Handle for You

  • Authentication: API keys, OAuth tokens, and credential refresh — the LLM never sees secrets
  • Rate limiting: manages API quotas and retries failed requests automatically
  • Data transformation: cleans raw API responses into structured results the LLM can reason about
  • Security boundary: controls exactly which operations are exposed (e.g., read-only database access)
  • Tool discovery: advertises available tools with descriptions, so the LLM knows what it can do without being told in the prompt

Three Ways to Install a Connection to an MCP Server

Desktop Extensions

  1. Settings → Extensions
  2. Browse and find the server
  3. Click Install

One-click. Anthropic-reviewed.

Manual Config

  1. Install prerequisites (Node.js or uv)
  2. Edit JSON config file
  3. Restart Claude Desktop

More control. Any server.

Ask Claude Code

  1. Tell Claude Code which server you want
  2. It edits the config for you
  3. Restart Claude Desktop

Easiest for Code users.

You May Need to Install uv

Some MCP servers are distributed as Python packages and run via uvx. You may need to install uv first.

Manual install

  • Mac: brew install uv
  • Windows: winget install astral-sh.uv
  • Verify: uv --version

Used by: Browser-Use, Alpha Vantage, and others

If you use Claude Code to install a connection, it will ask permission to install uv automatically if needed.

Connecting to Financial Data

Enterprise Financial Data via MCP

Major financial data providers now offer official MCP servers, giving AI agents direct, governed access to institutional-grade data.

  • FactSet — fundamentals, M&A intelligence, real-time market data; first production-grade financial MCP server (800+ institutional users)
  • S&P Capital IQ — financial statements, earnings transcripts, company fundamentals (built by Kensho, S&P’s AI subsidiary)
  • LSEG / Refinitiv — financial data via LSEG Workspace APIs
  • Bloomberg — community-built blpapi-mcp server (requires a Bloomberg Terminal); Bloomberg is an MCP governance member but has no official server yet

Enterprise Financial Data via MCP (cont.)

  • Moody’s — credit ratings, fundamentals, entity linkages, market indicators
  • Morningstar — ratings, fair value, economic moat, fund data, editorial research
  • PitchBook — private market data (PE, VC, M&A)
  • Daloopa — financial metrics and KPIs for 5,000+ companies, every datapoint hyperlinked to its source

These are subscription services. Install the server, ask Claude to pull data — no code, no API documentation needed. The exercise uses free alternatives.

Browser Use

Browser-Use: Web Automation via MCP

Browser-Use is an MCP server that lets Claude autonomously control a web browser. Describe a task in plain English, and it handles the navigation.

Finance Applications

  • “Search for AAPL on Yahoo Finance and get the P/E ratio”
  • “Download all linked CSV files from this SEC page”
  • “Fill out this application form with my information”

Key Features

  • Plain-language task descriptions
  • Navigates pages and fills forms
  • Extracts data from web pages
  • Recommended: local (self-hosted) for full privacy

Terminal Control

DesktopCommander: Terminal Control via MCP

DesktopCommander gives Claude Desktop the ability to execute terminal commands, manage files, and control processes — without switching to Code mode.

What It Can Do

  • Run terminal commands (pip install, git, scripts)
  • Read, write, and search files
  • Manage running processes

When to Use It

  • You want to stay in Claude Desktop Chat
  • Quick terminal tasks
  • Always review commands before approving

Personal Productivity

Email and Calendar via MCP

MCP servers can connect Claude to your personal productivity tools, turning it into an assistant that can read, search, and act on your behalf.

Email (Gmail)

  • Search your inbox by sender, date, or keyword
  • Draft and send replies
  • Summarize unread messages
  • “Find all emails from our auditor about Q4 adjustments”

Calendar (Google Calendar)

  • Check availability and schedule meetings
  • List upcoming events
  • Create, update, or cancel events
  • “What’s on my calendar this week?”

Other Productivity Servers

The MCP ecosystem includes servers for many tools you already use:

  • Google Drive: search and read documents, spreadsheets, and slides
  • Slack: search channels, read messages, post updates
  • Notion: query databases, read and update pages
  • GitHub: manage repos, issues, and pull requests
  • Todoist / Linear: manage tasks and projects
  • Memory: give Claude persistent memory across conversations

One prompt can span multiple tools: “Check my calendar for Friday, draft an email to the team with the agenda, and create a shared Google Doc for meeting notes.”

Combining Multiple Connections

Multi-Server MCP Configurations

You can connect multiple MCP servers at once. Claude sees all their tools and can use them together.

{
  "mcpServers": {
    "browser-use": {
      "command": "uvx",
      "args": ["--from", "browser-use[cli]", "browser-use", "--mcp"],
      "env": {"ANTHROPIC_API_KEY": "sk-ant-..."}
    },
    "desktop-commander": {
      "command": "npx",
      "args": ["-y", "desktop-commander-mcp"]
    },
    "alphavantage": {
      "command": "uvx",
      "args": ["av-mcp", "YOUR_AV_KEY"]
    }
  }
}

Built-In Alternatives to MCP

DesktopCommander and Browser-Use add capabilities to Claude’s Chat mode. But Code and Cowork modes have some of these built in.

  • Chat mode needs MCP servers for terminal, file access, and browser control — no internet access
  • Code tab has terminal and file access built in, plus full internet — browser control via Chrome extension
  • Cowork tab has terminal and file access built in, but no internet — browser control via Chrome extension

MCP servers for financial data (Alpha Vantage, FMP) and personal productivity (email, calendar, Google Drive) remain valuable in all modes.

Plugins and the SaaSpocalypse

What is a Plugin?

A plugin is a packaged collection of skills, agents, hooks, and MCP servers that can be shared across teams. (Hooks are shell commands that run automatically before or after specific events — e.g., running a linter every time Claude edits a file.)

A Plugin Can Include

  • Skills (SKILL.md files)
  • Agents (AGENT.md files)
  • MCP servers (external tools)

Why Use Plugins?

  • Share skills with your team
  • Namespace prevents conflicts
  • Install from marketplaces

Practical workflow: Start with a standalone skill for quick prototyping. When ready to share, wrap it in a plugin by adding a manifest file.

The “SaaSpocalypse”: Market Reaction to Plugins

On January 30, 2026, Anthropic released 11 open-source plugins for Claude. Within days, $285 billion in market cap evaporated from software, legal tech, and financial services stocks.

Hardest-Hit Stocks

  • LegalZoom: -20%
  • Thomson Reuters: -16%
  • RELX (LexisNexis): -14%
  • Intuit: >-10%; Salesforce: -7%

Why It Happened

  • Plugins showed AI could replicate core workflows of specialized enterprise software
  • No proprietary code — just markdown instructions + database connectors
  • Investors asked: “Why pay $50K/yr for software when a plugin does it?”

Exercises

Example: Install a Financial Data Server

Free MCP servers let you try this workflow without a subscription:

Alpha Vantage

"alphavantage": {
  "command": "uvx",
  "args": ["av-mcp", "YOUR_KEY"]
}

Financial Modeling Prep

"financial-modeling-prep": {
  "command": "npx",
  "args": ["-y", "@houtini/fmp-mcp"],
  "env": {"FMP_API_KEY": "YOUR_KEY"}
}
  1. Get a free API key and install the connection in Claude Desktop
  2. Ask Claude to retrieve financial data, analyze trends, and produce formatted Excel output

Exercise: Browser Automation

Use Browser-Use MCP to navigate a financial website:

  • Extract market cap, P/E ratio, and revenue for a company
  • Compile a summary comparison of 3 companies
  • Save results to a formatted document

Summary

MCP

  • Universal plug-in protocol
  • Financial data, browser, terminal
  • Works with Claude Desktop

Code Execution

  • Chat, Cowork, Code modes
  • Match the tool to the task
  • Code for APIs and files

AI in Apps

  • Excel, Google Sheets
  • Formulas, not hardcodes
  • Choose by ecosystem

AI becomes truly powerful when it can reach your data, your tools, and your files.