papermate
This MCP server enables AI models to format academic papers into Word documents conforming to the China University of Political Science and Law thesis standards.
README
PaperMate AI Skill
让 AI 模型具备论文排版能力,直接输出符合中国政法大学硕博论文规范的 Word 文档。
两种使用方式
方式一:MCP Server(Claude Desktop / Claude Code)
安装
pip install -r requirements.txt
配置 Claude Desktop
在 claude_desktop_config.json 中添加:
{
"mcpServers": {
"papermate": {
"command": "python",
"args": ["C:/你的路径/paper-mate-ai-skill/mcp_server.py"]
}
}
}
配置 Claude Code
在项目 .claude/settings.json 中添加:
{
"mcpServers": {
"papermate": {
"command": "python",
"args": ["mcp_server.py"]
}
}
}
配置后重启,Claude 即可调用:
format_paper— 排版论文get_format_spec— 查看格式规范
使用示例
"帮我把这篇论文按法大规范排版,输出为 thesis.docx"
Claude 会自动调用 format_paper 工具完成排版。
方式二:CLI 命令行(Codex / Cursor / 任意 AI)
所有支持 Shell 执行的 AI 均可通过命令行调用:
# 从文件读取
python cli_format.py -i my_paper.md -o output.docx
# 直接传入内容
python cli_format.py --body "# 一级标题\n正文内容" -o output.docx
# 带摘要和参考文献
python cli_format.py -i body.md -o paper.docx \
--abstract "本文研究了..." \
--keywords "关键词1;关键词2" \
--references "refs.txt"
Codex 中使用:
执行 python cli_format.py -i paper.md -o output.docx 把论文排成法大格式
Markdown 写作规范
| Markdown | 对应 Word 格式 |
|---|---|
# 标题 |
一级标题(黑体 16pt 居中加粗) |
## 标题 |
二级标题(黑体 14pt 左对齐加粗) |
### 标题 |
三级标题(黑体 13pt 左对齐不加粗) |
#### 标题 |
四级标题(黑体 12pt 左对齐不加粗) |
| 普通段落 | 正文(宋体 12pt 首行缩进2字符) |
[脚注文字] |
Word 脚注(页脚区域 9pt) |
**文字** |
加粗 |
格式规范
严格遵循中国政法大学硕士、博士学位论文写作规范: 页边距 2.54cm · 正文宋体/Times New Roman 12pt · 20pt固定行距 · 首行缩进2字符 · 标题黑体 · 脚注正常编号 · 参考文献悬挂缩进
依赖
- Python 3.10+
- python-docx
- lxml
- mcp(仅 MCP 方式需要)
Recommended Servers
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.
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.
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.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
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.
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.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
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.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.