Web and local search via Brave combined with Gemini academic paper analysis.
Brave-Gemini Research MCP Server
A modern MCP (Model Context Protocol) server implementation that provides AI assistants with web search capabilities via the Brave Search API and advanced research paper analysis with Google's Gemini model.
Overview
This project enables AI assistants like Claude to perform web searches and analyze research papers directly through a standardized API interface. The MCP server exposes three main tools:
- Web Search - For general internet searches and information retrieval
- Local Search - For finding businesses, locations, and places of interest
- Research Paper Analysis - For in-depth analysis of academic papers using Google's Gemini model
Features
- 🔍 Web Search API - Find information across the web
- 🏢 Local Search API - Discover businesses and places
- 📑 Research Paper Analysis - Analyze academic papers with Gemini AI
- 🤖 Claude Integration - Seamless connection with Claude Desktop
- 🛠️ Extensible Design - Easy to add new tools and capabilities
Setup and Installation
Prerequisites
- Node.js v18+ recommended
- Brave Search API key (Get one here)
- Google API key for Gemini integration (required for research paper analysis)
- Claude Desktop for AI assistant integration (optional)
Installation
Clone the repository:
git clone https://github.com/falahgs/brave-gemini-research-mcp.git cd brave-gemini-research-mcpInstall dependencies:
npm installCreate a
.envfile with your API keys:BRAVE_API_KEY=your_brave_api_key GOOGLE_API_KEY=your_google_api_key
Building
Compile the TypeScript code to JavaScript:
npm run build
# or manually
npx tsc
Running the Server
Set environment variables and start the server:
PowerShell:
$env:BRAVE_API_KEY="your_brave_api_key"
$env:GOOGLE_API_KEY="your_google_api_key"
node dist/index.js
Command Prompt:
SET BRAVE_API_KEY=your_brave_api_key
SET GOOGLE_API_KEY=your_google_api_key
node dist/index.js
Bash/Linux/macOS:
BRAVE_API_KEY=your_brave_api_key GOOGLE_API_KEY=your_google_api_key node dist/index.js
Claude Desktop Integration
Follow these steps to integrate the MCP server with Claude Desktop:
Ensure you have Claude Desktop installed (Download here)
Locate your Claude Desktop configuration file:
- Windows:
C:\Users\<username>\AppData\Roaming\Claude\claude_desktop_config.json - macOS:
~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:
Add the Brave-Gemini Research MCP configuration:
{
"mcpServers": {
"Brave-Gemini Research": {
"command": "node",
"args": ["G:\\path\\to\\your\\brave-gemini-research-mcp\\dist\\index.js"],
"cwd": "G:\\path\\to\\your\\brave-gemini-research-mcp",
"timeoutMs": 120000,
"env": {
"BRAVE_API_KEY": "your_brave_api_key",
"GOOGLE_API_KEY": "your_google_api_key",
"NODE_ENV": "production",
"DEBUG": "mcp:*"
}
}
}
}
Important notes:
- Use absolute paths with double backslashes (Windows) in the
argsandcwdfields - Replace
G:\\path\\to\\your\\brave-gemini-research-mcpwith the actual path to your project - Replace
your_brave_api_keyandyour_google_api_keywith your actual API keys - The
timeoutMssetting helps prevent timeout issues during initialization
- Use absolute paths with double backslashes (Windows) in the
Save the file and restart Claude Desktop
Using with Claude
After configuration, you can ask Claude to search the web or analyze research papers with prompts like:
- "Search the web for the latest AI research papers"
- "Find coffee shops in San Francisco"
- "Analyze this research paper on quantum computing: [paper content]"
Claude will use the MCP server to perform these searches and analyses, returning the results directly in your conversation.
Tool Capabilities
Web Search Tool
The web search tool enables general internet searches:
- Function:
brave_web_search - Parameters:
query(required): Search query (max 400 chars)count(optional): Number of results (1-20, default 10)offset(optional): Pagination offset (max 9, default 0)
Local Search Tool
The local search tool finds businesses and locations:
- Function:
brave_local_search - Parameters:
query(required): Local search query (e.g., "pizza near Central Park")count(optional): Number of results (1-20, default 5)
Research Paper Analysis Tool
The research paper analysis tool provides in-depth analysis of academic papers using Google's Gemini model:
- Function:
gemini_research_paper_analysis - Parameters:
paperContent(required): The full
Tools (3)
brave_web_searchFor general internet searches and information retrievalbrave_local_searchFor finding businesses, locations, and places of interestgemini_research_paper_analysisIn-depth analysis of academic papers using Google's Gemini modelEnvironment Variables
BRAVE_API_KEYrequiredAPI key for Brave SearchGOOGLE_API_KEYrequiredAPI key for Gemini integrationConfiguration
{
"mcpServers": {
"Brave-Gemini Research": {
"command": "node",
"args": ["G:\\path\\to\\your\\brave-gemini-research-mcp\\dist\\index.js"],
"cwd": "G:\\path\\to\\your\\brave-gemini-research-mcp",
"timeoutMs": 120000,
"env": {
"BRAVE_API_KEY": "your_brave_api_key",
"GOOGLE_API_KEY": "your_google_api_key",
"NODE_ENV": "production",
"DEBUG": "mcp:*"
}
}
}
}