Markitdown
ImCa0/just-laws
Convert files and office documents to Markdown. An agent skill from ImCa0/just-laws.
课程目标达成情况分析表生成工具。根据Excel学生数据替换Word模板中的课程目标达成情况,生成新的分析表. An agent skill from LeoYeAI/openclaw-master-skills.
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztc --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/achievement-qztc .claude/skills/achievement-qztc && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .claude/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztcType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztc --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/achievement-qztc .agents/skills/achievement-qztc && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .agents/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztc --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/achievement-qztc .cursor/skills/achievement-qztc && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .cursor/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/LeoYeAI/openclaw-master-skills.git --path skills/achievement-qztc--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztc --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/achievement-qztc .gemini/skills/achievement-qztc && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .gemini/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztcInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/achievement-qztc .github/skills/achievement-qztc && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .github/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install LeoYeAI/openclaw-master-skills achievement-qztc --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/achievement-qztc .opencode/skills/achievement-qztc && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "achievement-qztc" agent skill from https://github.com/LeoYeAI/openclaw-master-skills/tree/main/skills/achievement-qztc into .opencode/skills/achievement-qztc/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "achievement-qztc", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
achievement-qztc课程目标达成情况分析表生成工具。根据Excel学生数据替换Word模板中的课程目标达成情况,生成新的分析表. An agent skill from LeoYeAI/openclaw-master-skills.
Achievement Qztc is an agent skill from LeoYeAI/openclaw-master-skills. 课程目标达成情况分析表生成工具。根据Excel学生数据替换Word模板中的课程目标达成情况,生成新的分析表。
Its SKILL.md is about 4.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 1 other file (for example `_meta.json`).
It sits in Documents & Office, covering Excel spreadsheets. It works with Microsoft Excel. The repository describes itself as: 🧠 Curated collection of 1209+ best OpenClaw skills — weekly updated by MyClaw.ai. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit e5199b5. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are python).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Achievement Qztc loads about 4.4k tokens when it runs. Until then it costs about 18 tokens; SKILL.md has 136 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from LeoYeAI/openclaw-master-skills at commit e5199b5, republished under its MIT licence (© LeoYeAI). 136 words, ~4,356 tokens.
.claude/skills/achievement-qztc/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.根据Excel学生数据替换Word模板中的课程目标达成情况,生成新的分析表。
/Volumes/qztcm09/Desktop/temp/课程目标达成情况分析表-数据可视化-模版.docx/Volumes/qztcm09/Desktop/temp/数据可视化技术23级计算机.xlsimport pandas as pd
import shutil
import random
from docx import Document
from datetime import datetime
# 读取Excel
df = pd.read_excel('/Users/qztcm09/Desktop/temp/数据可视化技术23级计算机.xls')
# 排除旷考学生
df = df[df['备注'] != '旷考'].reset_index(drop=True)
# 自动判断当前学年和学期
now = datetime.now()
year = now.year
month = now.month
day= now.day
if 1 <= month <= 6:
# 1-6月:第一学期(上学年)
academic_year = f"{year-1} - {year}"
semester = "一"
else:
# 7-12月:第二学期(上学年)
academic_year = f"{year-1} - {year}"
semester = "二"
print(f"当前学年: {academic_year}, 学期: {semester}学期")
# 从"班级"字段提取年级、班级、专业信息
# 专业名称提取支持两种情况:
# 情况1: "23级计算机" → 年级=23, 专业=计算机
# 情况2: "23级软工2班" → 年级=23, 专业=软工
import re
class_name = df['班级'].iloc[0] if '班级' in df.columns else ''
match = re.search(r'(\d+)级', str(class_name))
grade = match.group(1) if match else '' # 如 "23"
# 提取专业:匹配 "XX级" 后面到 "XX班" 或结尾的部分
match = re.search(r'\d+级(.+?)(?:\d+班)?$', str(class_name))
major = match.group(1).strip() if match else '' # 如 "计算机" 或 "软工"
# 获取学生信息
students = df[['学号', '姓名']].copy()
print(f"学生人数: {len(students)}")template_path = '/Users/qztcm09/Desktop/temp/课程目标达成情况分析表-数据可视化-模版.docx'
output_path = '/Users/qztcm09/Desktop/temp/课程目标达成情况分析表-数据可视化-23级计算机.docx'
shutil.copy(template_path, output_path)
doc = Document(output_path)⚠️ 重要:Word占位符可能被拆分成多个run,且表格单元格中可能有换行,需要特殊处理,保留原格式
def replace_text_preserve_format(para, replacements):
"""替换段落文本但保留格式"""
# 先收集所有run的文本
full_text = ''.join(run.text for run in para.runs if run.text)
# 检查是否有占位符
has_placeholder = any(old in full_text for old, _ in replacements)
if not has_placeholder:
return
# 执行替换
for old, new in replacements:
full_text = full_text.replace(old, new)
# 获取第一个run的格式作为基准
if para.runs:
first_run = para.runs[0]
font_name = first_run.font.name
font_size = first_run.font.size
font_bold = first_run.font.bold
font_italic = first_run.font.italic
else:
font_name, font_size, font_bold, font_italic = None, None, None, None
# 清空并用新文本创建单一run,保留格式
para.clear()
run = para.add_run(full_text)
if font_name:
run.font.name = font_name
if font_size:
run.font.size = font_size
if font_bold is not None:
run.font.bold = font_bold
if font_italic is not None:
run.font.italic = font_italic
return para
def replace_text_in_table_cell(cell, replacements):
"""替换表格单元格中的文本(处理单元格内换行的情况)"""
# 遍历单元格中的所有段落
for para in cell.paragraphs:
full_text = ''.join(run.text for run in para.runs if run.text)
has_placeholder = any(old in full_text for old, _ in replacements)
if has_placeholder:
# 获取格式
if para.runs:
first_run = para.runs[0]
font_name = first_run.font.name
font_size = first_run.font.size
font_bold = first_run.font.bold
font_italic = first_run.font.italic
else:
font_name, font_size, font_bold, font_italic = None, None, None, None
# 执行替换
for old, new in replacements:
full_text = full_text.replace(old, new)
# 清空并重新设置
para.clear()
run = para.add_run(full_text)
if font_name:
run.font.name = font_name
if font_size:
run.font.size = font_size
if font_bold is not None:
run.font.bold = font_bold
if font_italic is not None:
run.font.italic = font_italic
return cell
# 替换配置
replacements = [
('$acyear$', academic_year),
('$semester$', semester),
('$g$', grade),
('$major$', major),
('$total$', f'{len(students)}人'),
('$year$', str(year)),
('$month$', str(month)),
('$day$', str(day)),
]
# 替换表格中的文本
for table in doc.tables:
for row in table.rows:
for cell in row.cells:
replace_text_in_cell(cell, replacements)
# 替换段落中的文本(处理被拆分的情况,保留格式)
for para in doc.paragraphs:
replace_text_preserve_format(para, replacements)重要:
表格索引: 8
表头结构(前2行):
数据列对应关系:
| 列索引 | 内容 |
|---|---|
| 0 | 序号 |
| 1 | 学号 |
| 2 | 姓名 |
| 3 | 随机值 a (10-24),课程目标1得分 |
| 4 | a/25*100%,课程目标1达成值(百分比) |
| 5 | 随机值 b (20-28),课程目标2得分 |
| 6 | b/30*100%,课程目标2达成值(百分比) |
| 7 | 随机值 c (20-25),课程目标3得分 |
| 8 | c/26.5*100%,课程目标3达成值(百分比) |
| 9 | 随机值 d (15-18),课程目标4得分 |
| 10 | d/18.5*100%,课程目标4达成值(百分比) |
# 步骤4.1: 动态调整表格行数(在平均值行之前插入)
table = doc.tables[8]
current_rows = len(table.rows)
# 当前模板可以容纳的学生数(去掉2行表头和1行平均值)
template_capacity = current_rows - 3
# 调整行数:在倒数第2行(平均值行之前)插入
if len(students) > template_capacity:
# 需要插入行,在平均值行之前插入
for i in range(len(students) - template_capacity):
# 在倒数第2行之前插入(即平均值行之前)
new_row = table.add_row()
# 将新行移动到平均值行之前
# 由于add_row()是添加到末尾,需要交换位置
# 获取平均值行索引
avg_idx = len(table.rows) - 1
# 将新插入的行移到平均值行之前
table._element.remove(new_row._element)
table._element.insert(len(table.rows) - 2, new_row._element)
elif len(students) < template_capacity:
# 需要删除多余行(从数据区域末尾开始删,保留平均值行)
for i in range(template_capacity - len(students)):
# 删除倒数第2行(最后一个数据行)
delete_idx = 2 + len(students)
if delete_idx < len(table.rows) - 1:
table._element.remove(table.rows[delete_idx]._element)
# 步骤4.2: 清理数据行(保留前2行表头和最后1行平均值)
for row_idx in range(2, len(table.rows) - 1):
for cell in table.rows[row_idx].cells:
cell.text = ''
# 步骤4.3: 填入学生数据(达成值用百分比)
all_a, all_b, all_c, all_d = [], [], [], []
student_data = []
for i, (_, student) in enumerate(students.iterrows()):
row_idx = i + 2
if row_idx >= len(table.rows) - 1:
break
row = table.rows[row_idx]
a = random.randint(10, 24)
b = random.randint(20, 28)
c = random.randint(20, 25)
d = random.randint(15, 18)
all_a.append(a)
all_b.append(b)
all_c.append(c)
all_d.append(d)
# 转为百分比
v1, v2, v3, v4 = a/25*100, b/30*100, c/26.5*100, d/18.5*100
student_data.append({'v1': v1, 'v2': v2, 'v3': v3, 'v4': v4})
row.cells[0].text = str(i + 1)
row.cells[1].text = str(student['学号'])
row.cells[2].text = student['姓名']
row.cells[3].text = f"{a:.2f}"
row.cells[4].text = f"{v1:.0f}%" # 百分比
row.cells[5].text = f"{b:.2f}"
row.cells[6].text = f"{v2:.0f}%" # 百分比
row.cells[7].text = f"{c:.2f}"
row.cells[8].text = f"{v3:.0f}%" # 百分比
row.cells[9].text = f"{d:.2f}"
row.cells[10].text = f"{v4:.0f}%" # 百分比
n = len(student_data)
# 步骤4.4: 最后一行填写平均值(百分比)
avg_row = table.rows[-1]
avg_a = sum(all_a) / n
avg_b = sum(all_b) / n
avg_c = sum(all_c) / n
avg_d = sum(all_d) / n
avg_v1 = sum(s['v1'] for s in student_data) / n
avg_v2 = sum(s['v2'] for s in student_data) / n
avg_v3 = sum(s['v3'] for s in student_data) / n
avg_v4 = sum(s['v4'] for s in student_data) / n
avg_row.cells[0].text = "平均值"
avg_row.cells[3].text = f"{avg_a:.2f}"
avg_row.cells[4].text = f"{avg_v1:.0f}%"
avg_row.cells[5].text = f"{avg_b:.2f}"
avg_row.cells[6].text = f"{avg_v2:.0f}%"
avg_row.cells[7].text = f"{avg_c:.2f}"
avg_row.cells[8].text = f"{avg_v3:.0f}%"
avg_row.cells[9].text = f"{avg_d:.2f}"
avg_row.cells[10].text = f"{avg_v4:.0f}%"table7 = doc.tables[7]
table7.rows[5].cells[7].text = f"{avg_v1:.0f}%"
table7.rows[8].cells[7].text = f"{avg_v2:.0f}%"
table7.rows[11].cells[7].text = f"{avg_v3:.0f}%"
table7.rows[14].cells[7].text = f"{avg_v4:.0f}%"# 计算统计数据
max_v1 = max(s['v1'] for s in student_data)
min_v1 = min(s['v1'] for s in student_data)
# ... 其他目标类似
# 计算满足百分比阈值的学生比例
count_v1_80 = sum(1 for s in student_data if s['v1'] >= 80)
count_v1_60 = sum(1 for s in student_data if s['v1'] >= 60)
# ... 其他类似
pct_v1_80 = count_v1_80 / n * 100
pct_v1_60 = count_v1_60 / n * 100
# ... 其他类似
# 更新段落
new_texts = {
1: f"课程目标1的平均达成值为{avg_v1:.0f}%,最高达成值为{max_v1:.0f}%,最低达成值为{min_v1:.0f}%。其中{pct_v1_80:.1f}%的学生达成值在80%以上,{pct_v1_60:.1f}%的学生达成值在60%以上,说明...",
# ... 其他目标
}
# 找到并更新段落
for i, para in enumerate(doc.paragraphs):
if '课程目标1的平均达成值为' in para.text:
# 更新段落文本
breakdoc.save(output_path)
print(f"文件已保存至: {output_path}")import pandas as pd
import shutil
import random
from docx import Document
from datetime import datetime
random.seed(42) # 可选:固定随机种子
def replace_text_preserve_format(para, replacements):
"""替换段落文本但保留格式"""
# 先收集所有run的文本
full_text = ''.join(run.text for run in para.runs if run.text)
# 检查是否有占位符
has_placeholder = any(old in full_text for old, _ in replacements)
if not has_placeholder:
return
# 执行替换
for old, new in replacements:
full_text = full_text.replace(old, new)
# 获取第一个run的格式作为基准
if para.runs:
first_run = para.runs[0]
font_name = first_run.font.name
font_size = first_run.font.size
font_bold = first_run.font.bold
font_italic = first_run.font.italic
else:
font_name, font_size, font_bold, font_italic = None, None, None, None
# 清空并用新文本创建单一run,保留格式
para.clear()
run = para.add_run(full_text)
if font_name:
run.font.name = font_name
if font_size:
run.font.size = font_size
if font_bold is not None:
run.font.bold = font_bold
if font_italic is not None:
run.font.italic = font_italic
return para
def replace_text_in_table_cell(cell, replacements):
"""替换表格单元格中的文本(处理单元格内换行的情况)"""
for para in cell.paragraphs:
full_text = ''.join(run.text for run in para.runs if run.text)
has_placeholder = any(old in full_text for old, _ in replacements)
if has_placeholder:
if para.runs:
first_run = para.runs[0]
font_name = first_run.font.name
font_size = first_run.font.size
font_bold = first_run.font.bold
font_italic = first_run.font.italic
else:
font_name, font_size, font_bold, font_italic = None, None, None, None
for old, new in replacements:
full_text = full_text.replace(old, new)
para.clear()
run = para.add_run(full_text)
if font_name:
run.font.name = font_name
if font_size:
run.font.size = font_size
if font_bold is not None:
run.font.bold = font_bold
if font_italic is not None:
run.font.italic = font_italic
return cell
def generate_achievement_analysis():
# 1. 读取Excel
df = pd.read_excel('/Users/qztcm09/Desktop/temp/数据可视化技术23级计算机.xls')
df = df[df['备注'] != '旷考'].reset_index(drop=True)
students = df[['学号', '姓名']].copy()
print(f"学生人数: {len(students)}")
# 2. 复制模板
template_path = '/Users/qztcm09/Desktop/temp/课程目标达成情况分析表-数据可视化-模版.docx'
output_path = '/Users/qztcm09/Desktop/temp/课程目标达成情况分析表-数据可视化-23级计算机.docx'
shutil.copy(template_path, output_path)
doc = Document(output_path)
# 3. 通用文本替换
now = datetime.now()
year, month, day = now.year, now.month, now.day
# 根据班级提取专业信息(支持两种情况)
# 情况1: "23级计算机" → 专业="计算机"
# 情况2: "23级软工2班" → 专业="软工"
import re
class_name = df['班级'].iloc[0] if '班级' in df.columns else ''
match = re.search(r'(\d+)级', str(class_name))
grade = match.group(1) if match else ''
match = re.search(r'\d+级(.+?)(?:\d+班)?$', str(class_name))
major = match.group(1).strip() if match else ''
if 1 <= month <= 6:
academic_year = f"{year-1} - {year}"
semester = "一"
else:
academic_year = f"{year-1} - {year}"
semester = "二"
replacements = [
('$acyear$', academic_year),
('$semester$', semester),
('$g$', grade),
('$major$', major),
('$total$', f'{len(students)}人'),
('$year$', str(year)),
('$month$', str(month)),
('$day$', str(day)),
]
# 替换表格中的文本(使用新的函数处理换行)
for table in doc.tables:
for row in table.rows:
for cell in row.cells:
replace_text_in_table_cell(cell, replacements)
# 替换段落中的文本(保留格式)
for para in doc.paragraphs:
replace_text_preserve_format(para, replacements)
# 4. 更新表8
table = doc.tables[8]
current_rows = len(table.rows)
template_capacity = current_rows - 3
# 调整行数
if len(students) > template_capacity:
# 需要插入行,在平均值行之前插入
rows_to_add = len(students) - template_capacity
for i in range(rows_to_add):
# 在倒数第2行(平均值行之前)插入新行
new_row = table.add_row()
# 将新行从末尾移到平均值行之前
avg_idx = len(table.rows) - 1
# 获取新行的tr元素
new_tr = new_row._element
# 移除
table._element.remove(new_tr)
# 在平均值行之前插入
table._element.insert(avg_idx, new_tr)
print(f"插入{rows_to_add}行")
elif len(students) < template_capacity:
# 需要删除多余行
rows_to_remove = template_capacity - len(students)
for i in range(rows_to_remove):
delete_idx = 2 + len(students)
if delete_idx < len(table.rows) - 1:
table._element.remove(table.rows[delete_idx]._element)
print(f"删除{rows_to_remove}行")
# 清理数据行
for row_idx in range(2, len(table.rows) - 1):
for cell in table.rows[row_idx].cells:
cell.text = ''
# 填入数据
all_a, all_b, all_c, all_d = [], [], [], []
student_data = []
for i, (_, student) in enumerate(students.iterrows()):
row_idx = i + 2
if row_idx >= len(table.rows) - 1:
break
row = table.rows[row_idx]
a = random.randint(10, 24)
b = random.randint(20, 28)
c = random.randint(20, 25)
d = random.randint(15, 18)
all_a.append(a)
all_b.append(b)
all_c.append(c)
all_d.append(d)
v1, v2, v3, v4 = a/25*100, b/30*100, c/26.5*100, d/18.5*100
student_data.append({'v1': v1, 'v2': v2, 'v3': v3, 'v4': v4})
row.cells[0].text = str(i + 1)
row.cells[1].text = str(student['学号'])
row.cells[2].text = student['姓名']
row.cells[3].text = f"{a:.2f}"
row.cells[4].text = f"{v1:.0f}%"
row.cells[5].text = f"{b:.2f}"
row.cells[6].text = f"{v2:.0f}%"
row.cells[7].text = f"{c:.2f}"
row.cells[8].text = f"{v3:.0f}%"
row.cells[9].text = f"{d:.2f}"
row.cells[10].text = f"{v4:.0f}%"
n = len(student_data)
# 平均值(最后一行)
avg_row = table.rows[-1]
avg_a = sum(all_a) / n
avg_b = sum(all_b) / n
avg_c = sum(all_c) / n
avg_d = sum(all_d) / n
avg_v1 = sum(s['v1'] for s in student_data) / n
avg_v2 = sum(s['v2'] for s in student_data) / n
avg_v3 = sum(s['v3'] for s in student_data) / n
avg_v4 = sum(s['v4'] for s in student_data) / n
avg_row.cells[0].text = "平均值"
avg_row.cells[1].text = ""
avg_row.cells[2].text = ""
avg_row.cells[3].text = f"{avg_a:.2f}"
avg_row.cells[4].text = f"{avg_v1:.0f}%"
avg_row.cells[5].text = f"{avg_b:.2f}"
avg_row.cells[6].text = f"{avg_v2:.0f}%"
avg_row.cells[7].text = f"{avg_c:.2f}"
avg_row.cells[8].text = f"{avg_v3:.0f}%"
avg_row.cells[9].text = f"{avg_d:.2f}"
avg_row.cells[10].text = f"{avg_v4:.0f}%"
# 5. 更新表7
table7 = doc.tables[7]
table7.rows[5].cells[7].text = f"{avg_v1:.0f}%"
table7.rows[8].cells[7].text = f"{avg_v2:.0f}%"
table7.rows[11].cells[7].text = f"{avg_v3:.0f}%"
table7.rows[14].cells[7].text = f"{avg_v4:.0f}%"
# 6. 统计并更新段落(见步骤6)
# ...
# 7. 保存
doc.save(output_path)
print(f"完成!文件已保存至: {output_path}")
if __name__ == '__main__':
generate_achievement_analysis()| 课程目标 | 得分范围 | 满分 | 达成值计算 |
|---|---|---|---|
| 目标1 | 10-24 | 25 | a/25*100% |
| 目标2 | 20-29 | 30 | b/30*100% |
| 目标3 | 20-25 | 26.5 | c/26.5*100% |
| 目标4 | 15-18 | 18.5 | d/18.5*100% |
使用前确保模板已修正:
© LeoYeAI, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 1 other file in skills/achievement-qztc of LeoYeAI/openclaw-master-skills.
Open the folder on GitHubat commit e5199b5
Achievement Qztc next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Achievement Qztc this skillLeoYeAI/openclaw-master-skills | 2.2k | — | ~4.4k | Automated safety check: Pass | MIT | |
| MarkitdownImCa0/just-laws | 781 | 14 repos | ~3.2k | Automated safety check: Notes | MIT | |
| Data Table Managern8n-io/n8n | 207k | — | ~2.3k | Automated safety check: Pass | Custom licence | |
| Docx4jplutext/docx4j | 2.4k | — | ~2.5k | Automated safety check: Pass | None | |
| Instrument Data To Allotropeaws-samples/amazon-bedrock-agents-healthcare-lifesciences | 274 | 2 repos | ~2.7k | Automated safety check: Pass | Apache-2.0 | |
| Cyber Pptcrazyykhllc-bit/CyberPPT | 1.8k | — | ~10k | Automated safety check: Pass | MIT |
ImCa0/just-laws
Convert files and office documents to Markdown. An agent skill from ImCa0/just-laws.
n8n-io/n8n
Load before calling data-tables or parse-file. An agent skill from n8n-io/n8n.
plutext/docx4j
A skill your agent uses when writing Java code that creates, reads or edits Word (.docx), PowerPoint (.pptx) or Excel (.xlsx) files with docx4j — including generating documents, editing existing…
aws-samples/amazon-bedrock-agents-healthcare-lifesciences
Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV.
crazyykhllc-bit/CyberPPT
当用户需要把 DOCX、PDF、TXT、XLSX、研究报告、业务材料或原始数据转成高密度、可编辑、咨询风格 PPTX 时使用;也适用于需要 SCR 论证、视觉风格探索、详细图表和渲染质检的 PPT。
zai-org/ZCode
Professional PDF toolkit covering four production workflows: reports, creative visuals, academic LaTeX, and existing PDF processing.
LeoYeAI/openclaw-master-skills
Manages pipelines on a DevOps quality and efficiency platform through its OpenAPI: list workspaces and templates, create, update, run and cancel pipelines, and read run records.
LeoYeAI/openclaw-master-skills
Patches OpenClaw's Feishu extension so an edited document triggers an isolated agent session that reads the doc and replies inline, turning it into a live chat space.
LeoYeAI/openclaw-master-skills
Multi-context memory management system for OpenClaw agents with group-isolated storage, global shared memory, workspace organization, and group-specific skills isolation.
LeoYeAI/openclaw-master-skills
Runs a brand's AI-search visibility work end to end: diagnosing how AI platforms represent it, repositioning it, producing AI-optimized content and monitoring ongoing mentions.
LeoYeAI/openclaw-master-skills
Installs and authenticates the gws CLI, then automates Gmail, Drive, Sheets, Calendar, Docs, Chat and Tasks with ready-made recipes, persona bundles and security audits.
LeoYeAI/openclaw-master-skills
Runs four advisor roles, a fitness coach, nutritionist, data analyst and TCM practitioner, to build a health profile and track workouts, diet and wellness over time.
Works with
Categories
课程目标达成情况分析表生成工具。根据Excel学生数据替换Word模板中的课程目标达成情况,生成新的分析表. An agent skill from LeoYeAI/openclaw-master-skills. Achievement Qztc is an agent skill from LeoYeAI/openclaw-master-skills.
Achievement Qztc fits situations like: tasks that involve Excel spreadsheets.
Run `npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a claude-code`. Or copy the skill folder (skills/achievement-qztc in LeoYeAI/openclaw-master-skills) into .claude/skills/achievement-qztc in your project. Claude Code loads it when a task matches its description.
Run `npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a codex`. Or copy the skill folder (skills/achievement-qztc in LeoYeAI/openclaw-master-skills) into .agents/skills/achievement-qztc in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add LeoYeAI/openclaw-master-skills --skill achievement-qztc -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/achievement-qztc, .gemini/skills/achievement-qztc, .github/skills/achievement-qztc and .opencode/skills/achievement-qztc in your project.
SKILL.md names no scripts, command-line tools or credentials: Achievement Qztc is instructions for the agent only. Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Achievement Qztc is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 4.4k tokens (SKILL.md is roughly 17k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Achievement Qztc: Markitdown (ImCa0/just-laws, 781 stars), Data Table Manager (n8n-io/n8n, 207k stars), Docx4j (plutext/docx4j, 2.4k stars) and Instrument Data To Allotrope (aws-samples/amazon-bedrock-agents-healthcare-lifesciences, 274 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
LeoYeAI (a GitHub user) maintains it in LeoYeAI/openclaw-master-skills, which has 2,161 GitHub stars. The repository holds 1,235 skills in this directory. The repository was last updated on July 20, 2026.
Source: LeoYeAI/openclaw-master-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.