batch-graduation-archive-filler
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "batch-graduation-archive-filler" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-05eef2202f8993cb5326a9a1110c91b30c93be4dd44afebbd74c8ea14c82f436. Verify the upstream source and version against https://skillhub.cn/skills/user_3c78e0c8/batch-graduation-archive-fille before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
skillhub.cn
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Bulk-identify thesis archive template structures, extract content from text, images, or PDFs, and automatically populate docx tables to produce archive documents.
Introduction source: third_party · user_3c78e0c8 · 1.0.0 Reference
SkillPi interpretation
- Tasks
- Translation pending; see source documentation.
- Audience
- Translation pending; see source documentation.
- Inputs and outputs
- Translation pending; see source documentation.
- Software, accounts and paid services
- Translation pending; see source documentation.
- Limits and differences
- Translation pending; see source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: batch-graduation-archive-filler
description: "批量识别毕设归档模板结构,从文本/图片/PDF提取内容,自动填入docx表格并输出。"
metadata:
author: "ph629"
version: 1.0.0
license: MIT
tags:
- graduation
- docx
- archive
- template-filling
- ocr
homepage: "https://github.com/openclaw/workspace/tree/main/skills/batch-graduation-archive-filler"毕业设计归档材料批量填写工作流
适用场景
需要将已完成的毕业设计材料(PDF论文、纸质扫描件、答辩记录等)批量填入学校模板化的 docx 归档表格。
输入
- N 个 docx 模板文件 — 学校提供的标准归档表格
- 内容源(三种类型,可混合):
- 文本数据 — 用户直接提供的文字(如答辩陈述、问答记录)
- 图片/扫描件 — 已签章填写的纸质表格照片(需 OCR)
- PDF 文档 — 已完成的毕业设计正文、任务书、文献综述等
工作流步骤
Step 1:模板结构分析
对每个 docx 模板执行结构探测:
遍历 paragraph → 记录 style、text、run 格式(bold/size)
遍历 table → 记录 rows×cols、gridSpan(合并单元格)、cell text
关键要点:
- gridSpan 决定哪些单元格是合并的(写入合并区的第一个 cell 即可)
- 段落中的占位文本(如
××××××、评语内容、年 月 日)标记为待替换位置 - 区分表格外段落(如签名区、日期行)和表格内单元格
Step 2:内容源解析
根据内容源类型执行不同的解析策略:
A. 文本数据
- 直接接收用户提供的结构化文本
- 按字段名称(如"答辩陈述""评语内容""评分")匹配到模板对应位置
B. 图片/扫描件
- OCR 处理:
api.ocr.space(免费 key:helloworld或K86835413788957,语言chs,引擎 2) - 对复杂表格/手写体:先 Pillow 增强对比度 + 二值化再 OCR
- 提取关键字段(学号、姓名、评分、评语、签名、日期)
- 注意:手写体 OCR 准确率有限,需标记"建议人工核对"
C. PDF 文档
- 使用
PyMuPDF/pdfplumber提取文本 - 按章节结构分割(前言、正文、总结、参考文献等)
- 匹配到模板对应段落位置
Step 3:内容-模板映射
建立映射表:
模板位置 → 内容字段
[学号 cell] → student_id
[姓名 cell] → student_name
[专业班级 cell] → class_name
[题目 cell] → title
[评语内容 cell] → evaluation_text + score + signature + date
[总分 cell] → total_score
[P{序号}] → paragraph_content
处理合并单元格: 找到 gridSpan 起始 cell,只写该 cell 的内容,合并区自然显示。
Step 4:填入并输出
原始模板 → copy → 按映射逐字段填入 → 保存为 "原名_已填写.docx"
写入规则:
cell.text = ''清空 →cell.paragraphs[0].clear()→ 用add_run()写入- 保持原有字号(通常
177800EMU = 14pt) - 对签名区/日期区保留框架,只替换具体内容
Step 5:验证
- 读取输出文件,逐段落/逐格检查内容是否正确填入
- 标记所有"待人工确认"项(手写 OCR 模糊处、需签名处)
输出
与输入模板文件同目录下,生成 {序号}-{原名}_已填写.docx 文件集合。
模板结构速查(南昌职业大学模板规格)
| 形式 | 表格规格 | 关键特征 |
|---|---|---|
| 纯表格型 | 多行列,gridSpan 合并 | 评语表、评分表 |
| 纯段落型 | 无 table,仅 paragraphs | 文献综述 |
| 混合型 | header 段落 + 主体表格 | 任务书、开题报告 |
已知限制
- 手写体 OCR 准确率有限 — 建议标记"需人工核对"而非盲目信任
- 评分表的细分项分值 — 如果源图片只显示总分不显示子项分,只能填入总分
- 签名字段 — 自动化填入文本化签名(如"刘薇薇"),不影响打印后手签
依赖
python-docx— 读写 docxrequests— 调用 OCR APIPillow— 图片预处理pdfplumber或PyMuPDF— PDF 文本提取(可选)
Current listing version
1.0.0
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 解决毕业设计归档这一明确刚需场景,显著提升从多源内容自动填入 docx 模板的效率
- 覆盖文本、图片、PDF 三种内容源,实用性强
Highlights
- 触发词精准完整,覆盖批量识别、模板结构、多源提取、自动填入等核心功能
- 边界清晰,不易与其他 Skill 重叠
Areas to improve
-
description 写错位置 Reported severity: Minor
顶层 frontmatter 与 skill_body 内部均包含 description,内容重复
Recommendation: 建议仅保留一处 description,避免冗余
-
缺少 When to Use 显式章节 Reported severity: Minor
文档有适用场景但未使用标准 When to Use 标题
Recommendation: 建议增加 When to Use 章节以提升规范性
-
文档略长 Reported severity: Minor
文档约 450 行,接近 500 行上限
Recommendation: 建议适当精简或拆分内容,保持可读性
Highlights
- 工作流步骤清晰(Step 1~5),含端到端示例和验证机制
- frontmatter 完整,含作者、版本、标签、homepage 等元信息
Highlights
- 工具来源明确(python-docx、requests、Pillow、pdfplumber/PyMuPDF),参数说明具体
- 覆盖主要异常(手写体 OCR 准确率有限、需人工核对),不可逆操作有验证机制
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- github.com
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Translation pending; see source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.