Perplexity MCP Server

Perplexity MCP Server

site icon
2025.03.05 2
TypeScript网络搜索Perplexity AI搜索工具
Perplexity MCP Server 是一个简单的 MCP 服务器,允许用户使用 Perplexity AI 进行网络搜索。它提供了一个名为 `perplexity_search` 的工具,用于执行网络搜索查询。
View on GitHub

Overview

基本能力

产品定位

Perplexity MCP Server 是一个基于 Perplexity AI 的网络搜索服务,旨在为用户提供高效的网络搜索能力。

核心功能

  1. 提供 perplexity_search 工具,用于执行网络搜索查询。
  2. 支持开发和生产模式运行。
  3. 提供 Windows 批处理文件简化运行流程。

适用场景

  1. 需要集成网络搜索功能的应用程序。
  2. 开发者在开发过程中需要快速获取网络信息。
  3. 生产环境中需要稳定的网络搜索服务。

工具列表

  1. perplexity_search:用于执行网络搜索查询,参数为 query

常见问题解答

  1. 权限错误:以管理员身份运行命令提示符或 PowerShell。
  2. 环境变量问题:确保 .env 文件位于根目录,且格式正确。
  3. Node.js 问题:验证 Node.js 和 npm 的安装。

使用教程

使用依赖

  1. Node.js 18+:从 nodejs.org 下载。
  2. Git:从 git-scm.com 下载。
  3. Perplexity AI API 密钥。

安装教程

  1. 克隆仓库:
git clone [repository-url]
cd perplexity-mcp-server
  1. 安装依赖:
npm install
  1. 创建环境文件 .env 并添加 API 密钥:
PERPLEXITY_API_KEY=your_api_key_here

调试方式

  1. 开发模式:
npm run dev
  1. 生产模式:
npm run build
npm start
  1. 使用批处理文件:
.\run-perplexity-server.bat

许可证

该项目遵循 MIT 开源许可条款。