Guokao MCP

Guokao MCP

Enables intelligent querying and matching of 2025 Chinese civil service examination positions based on personal qualifications, including education, major, political status, work experience, and location preferences.

Category
Visit Server

README

2025年国考小助手 MCP 服务器

这是一个基于 FastMCP 的国考岗位查询与匹配服务器,提供智能化的国考岗位筛选、专业匹配和个人条件一键匹配功能。

功能特性

本 MCP 服务器提供以下六个工具:

1. filter_positions - 多条件智能筛选

根据多个条件筛选符合要求的国考岗位。

参数:

  • organ_type: 机关类别(精确匹配)
    • "中央党群机关"
    • "中央国家行政机关(本级)"
    • "中央国家行政机关省级以下直属机构"
    • "中央国家行政机关参照公务员法管理事业单位"
  • department: 部门名称关键词(模糊匹配),如"税务"、"海关"
  • location: 工作地点(模糊匹配),如"北京"、"广东"
  • education: 学历要求(模糊匹配),如"本科"、"硕士研究生"
  • political_status: 政治面貌,如"不限"、"中共党员"
  • work_years: 基层工作最低年限,如"无限制"、"二年"
  • major: 专业关键词(模糊匹配),如"计算机"、"法学"
  • exam_type: 考试类别(模糊匹配)
  • position_type: 职位属性(模糊匹配)
  • min_recruitment: 最小招考人数
  • max_recruitment: 最大招考人数
  • max_results: 最大返回结果数,默认30

2. match_by_major - 专业匹配查询

根据专业关键词查询可报考的岗位。

参数:

  • major_keyword: 专业关键词,如"计算机"、"软件工程"、"法学"、"会计"
  • max_results: 最大返回结果数,默认30

3. personal_match - 个人条件一键匹配

根据个人条件智能匹配可报考的岗位。

参数:

  • education: 学历,可选值:"大专"、"本科"、"硕士研究生"、"博士研究生"
  • major: 专业关键词
  • political_status: 政治面貌,可选值:"中共党员"、"共青团员"、"群众"
  • work_years: 基层工作年限(数字),如 0、1、2、3、5
  • location: 期望工作地点
  • has_base_project: 是否有服务基层项目经历,True/False
  • max_results: 最大返回结果数,默认30

4. get_position_detail - 获取岗位详情

获取指定岗位的详细信息。

参数:

  • department: 部门名称
  • position_name: 招考职位名称

5. get_statistics - 获取统计信息

获取国考岗位的统计信息。

参数:

  • group_by: 分组统计字段,可选值:"机关类别"、"学历"、"政治面貌"、"基层工作最低年限"

6. compare_positions - 岗位对比

对比多个岗位的信息。

参数:

  • positions: 岗位列表,每个岗位包含 departmentposition_name

环境配置

1. 安装依赖

pip install -r requirements.txt

2. 配置数据文件

2025年国考岗位表.xls 文件放置在项目目录下,或设置环境变量:

export GUOKAO_EXCEL_PATH=/path/to/2025年国考岗位表.xls

使用方法

本地运行

python mcp_server.py

服务器将在 http://localhost:9000/sse 启动。

配置到 Claude Desktop

Stdio 模式(推荐日常使用)

编辑 Claude Desktop 配置文件 (%APPDATA%\Claude\claude_desktop_config.json):

{
  "mcpServers": {
    "guokao-helper": {
      "command": "python",
      "args": ["G:\\Desktop\\mcp_guokao\\guokao_mcp\\mcp_server.py"],
      "env": {
        "GUOKAO_EXCEL_PATH": "G:\\Desktop\\mcp_guokao\\guokao_mcp\\2025年国考岗位表.xls"
      }
    }
  }
}

SSE 模式(推荐开发测试)

  1. 启动 SSE 服务器:
python mcp_server.py
  1. 配置 Claude Desktop:
{
  "mcpServers": {
    "guokao-helper": {
      "url": "http://localhost:9000/sse"
    }
  }
}

阿里云函数计算部署

  1. 运行构建脚本安装依赖:
./build.sh
  1. 将以下文件上传到阿里云函数计算:

    • mcp_server.py
    • run.sh
    • 2025年国考岗位表.xls
    • python/ 目录(依赖包)
  2. 配置函数:

    • 运行时:自定义运行时
    • 启动命令:./run.sh
    • 监听端口:9000

使用示例

示例 1: 查找计算机专业可报考的岗位

帮我查找计算机专业可以报考的国考岗位

示例 2: 根据个人条件匹配岗位

我是本科学历,计算机专业,共青团员,没有基层工作经验,想在北京工作,帮我匹配可以报考的岗位

示例 3: 多条件筛选

帮我筛选税务系统的岗位,要求本科学历,工作地点在广东

示例 4: 查看统计信息

帮我统计一下各个机关类别的岗位数量

示例 5: 对比岗位

帮我对比以下两个岗位的条件:税务局的科员和海关的科员

项目结构

guokao_mcp/
├── mcp_server.py              # FastMCP 服务器实现
├── guokao_helper.py           # 原始命令行工具(保留)
├── build.sh                   # 构建脚本
├── run.sh                     # 启动脚本
├── requirements.txt           # Python 依赖
├── 2025年国考岗位表.xls       # 数据文件(需自行准备)
└── README.md                  # 本文件

技术栈

  • FastMCP: MCP 服务器框架
  • Pandas: 数据处理和分析
  • Python 3.11+: 运行环境

注意事项

  1. 确保数据文件 2025年国考岗位表.xls 已正确配置
  2. 数据文件应包含以下字段:部门名称、招考职位、工作地点、学历、政治面貌、基层工作最低年限、专业、招考人数等
  3. 返回结果默认限制为30条,可通过 max_results 参数调整

许可证

MIT License

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured