← 返回 Skills 市场
stephenlzc

Bibtex to Literature Review

作者 Big Stephen · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ 安全检测通过
16
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install bibtex-literature-review
功能描述
Build Word literature reviews from BibTeX, RIS, CSL JSON, CSV/TSV, or plain reference lists with GB/T 7714, APA, MLA, Chicago, IEEE, Vancouver, or Harvard bi...
使用说明 (SKILL.md)

BibTeX Literature Review

Purpose

Create .docx literature reviews from literature-source metadata with Chinese thesis-style numeric citations, clickable Word REF fields, superscript citation markers, and a bibliography that uses real Word automatic numbering paragraphs.

This skill is intentionally strict because Word cross-reference OOXML is fragile. Do not hand-wave the citation layer: generate, inspect, render, and validate.

Boundaries and Isolation

  • Treat sample Word files as read-only style/behavior references unless the user explicitly asks to edit them.
  • Do not perform external metadata lookup unless the user asks for web/library enrichment; format only from provided metadata by default.
  • Keep source normalization, review drafting, DOCX building, and DOCX validation as separate steps. Do not hide malformed reference data by silently fabricating missing fields.
  • Keep generated task artifacts outside the skill directory unless they are deliberate reusable resources. Do not leave __pycache__, test DOCX files, temporary JSON, or rendered pages inside the skill package.
  • Default APA/MLA/Chicago/Harvard support applies to bibliography text. Keep numeric clickable Word REF body citations unless the user explicitly asks for a non-numeric in-text citation system.
  • Use bundled scripts through explicit input/output paths. Scripts may write the requested output file and temporary working directories, but should not modify source files in place.

Core Workflow

  1. Inspect the user inputs:
    • Literature source file path (.bib, .ris, .json, .csv, .tsv, .txt, .md) or curated reference JSON.
    • Sample Word file, if provided, for style and field behavior only.
    • Topic, word count, target language, and output path.
  2. Normalize the source structurally. Do not rely on ad hoc string slicing for authors, titles, journals, years, volume/issue, or pages.
  3. Select only the references actually used in the review. Keep numbering in first-citation order unless the user asks for another order.
  4. Draft the review text with explicit citation markers as data, not as plain text.
  5. Convert references to the requested bibliography style from available metadata. Default to GB/T 7714 for Chinese thesis tasks. Do not invent missing volume, issue, page, DOI, publisher, or place fields.
  6. Build the DOCX with scripts/build_docx_from_review_json.py or an equivalent OOXML implementation.
  7. Validate the DOCX with scripts/validate_docx_crossrefs.py.
  8. Prefer code-level DOCX validation first. Render the DOCX when a renderer is available; if the active AI environment supports multimodal inspection, inspect PNG pages and iterate until clean.

Required REF Pattern

Use this default pattern unless the user explicitly asks for a different field-code variant:

  • Body citations are complex Word fields whose instruction text contains REF _RefBibNNN \h.
  • Body citation display is superscript, including brackets, commas, and ranges.
  • Bibliography paragraphs use real Word automatic numbering (w:numPr) with visible marker format [%1].
  • Each bibliography paragraph also contains a hidden bookmarked digit run (_RefBibNNN) so body REF fields return a clean digit. This avoids the double-bracket bug produced when REF ... \ reads an already bracketed list marker.

Read references/ooxml-ref-fields.md before changing the citation implementation, especially if the user asks for exact REF ... \ \h field codes.

JSON Build Contract

For repeatable generation, create a review JSON object and pass it to the builder:

{
  "title": "文献综述",
  "references": [
    {"gbt": "刘颖. 数字化转型背景下企业人力资源管理模式创新研究[J]. 知识经济, 2025(33): 157-159, 163."}
  ],
  "paragraphs": [
    [
      "数字化转型正在重塑企业人力资源管理的逻辑。刘颖认为,数据驱动和员工体验重构成为提升人才竞争优势的重要路径",
      {"cite": 1},
      "。"
    ]
  ]
}

Citation values:

  • {"cite": 1} creates superscript [1].
  • {"cite": [3, 4, 5]} creates superscript [3-5] by default.
  • {"cite": [10, 11], "collapse": false} creates superscript [10,11].

Read references/review-json-spec.md for the full JSON schema and examples.

Resource Routing

Non-Negotiable Acceptance Gate

Before delivering a .docx, confirm all of the following:

  • 正文引用是 Word REF 字段,不是 HYPERLINK
  • 正文引用显示为上标。
  • 文末参考文献是 Word 自动编号段落,XML 中有 w:numPr
  • 每条正文引用都有可跳转到参考文献位置的 _RefBibNNN 锚点。
  • 组合引用能正常显示,例如 [3-5][4,5][10,11]
  • 参考文献列表只包含正文实际引用的文献。
  • 渲染后的页面没有引用丢失、双括号、字段占位符、重叠或明显排版问题。

Use:

python scripts/validate_docx_crossrefs.py output.docx --expect-bib-count 12 --forbid-hyperlinks --require-ref --require-superscript --require-auto-numbered-bib

Then render and visually inspect with the available DOCX renderer.

Helpful Scripts

  • scripts/sources_to_json.py: normalize .bib, .ris, CSL JSON, CSV/TSV, or plain reference lists into JSON candidates.
  • scripts/bibtex_to_json.py: backwards-compatible BibTeX-only parser.
  • scripts/markdown_review_to_json.py: convert Markdown review drafts with [cite:1] or [@key] markers into review JSON.
  • scripts/build_docx_from_review_json.py: build the final .docx from curated review JSON.
  • scripts/validate_docx_crossrefs.py: inspect DOCX OOXML for REF fields, superscript results, forbidden hyperlinks, bookmarks, and bibliography numbering.
  • scripts/self_check.py: run an isolated end-to-end regression check against a real BibTeX fixture; fails on package pollution, invalid frontmatter, malformed scripts, or DOCX cross-reference regressions.
安全使用建议
Install only if you are comfortable letting the skill read the reference files you provide and write DOCX/JSON outputs to paths you specify. Prefer explicit output directories, review generated bibliographies for accuracy, and avoid enabling external metadata lookup unless you intentionally want web/library enrichment.
能力评估
Purpose & Capability
The stated purpose is to build and validate Word literature reviews from BibTeX/RIS/CSL/CSV/plain reference inputs, and the bundled scripts implement parsing, formatting, DOCX generation, and DOCX validation consistent with that purpose.
Instruction Scope
Instructions are generally bounded to explicit input/output paths and warn against modifying source/sample files or doing external metadata lookup unless asked. The bundled AGENTS.md includes development memory-context text, which is not needed for the main workflow but does not direct harmful behavior.
Install Mechanism
No package installer, post-install hook, or automatic dependency installation is present; scripts rely on ordinary Python modules and fail with messages if python-docx or lxml are missing.
Credentials
The skill uses shell-invoked Python scripts, reads local literature/source files, writes JSON/DOCX outputs, and creates temporary directories, which is proportionate for DOCX generation but should be limited to user-provided paths.
Persistence & Privilege
No background worker, startup persistence, credential/session access, privilege escalation, broad local indexing, or automatic network transmission was found. Temporary workspaces are used for DOCX processing and self-checks.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install bibtex-literature-review
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /bibtex-literature-review 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release: Build Word literature reviews with accurate, clickable numeric citations and strict DOCX validation. - Converts BibTeX, RIS, CSL JSON, CSV/TSV, or plain reference lists to `.docx` literature reviews with superscript numeric citations. - Supports major bibliography styles (GB/T 7714, APA, MLA, Chicago, IEEE, Vancouver, Harvard) with separate control over citation and bibliography formatting. - Guarantees native Word REF fields for clickable citations, avoids HYPERLINKs, and enforces auto-numbered bibliography paragraphs. - Keeps sourcing, drafting, building, and validation as strict, isolated steps; never fabricates missing reference fields. - Bundles scripts for transforming source metadata, composing review text, building DOCX, and validating OOXML field integrity. - Enforces acceptance criteria: only cited references included, valid cross-reference anchors, correct superscripted citation display, and passing automated document checks.
元数据
Slug bibtex-literature-review
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Bibtex to Literature Review 是什么?

Build Word literature reviews from BibTeX, RIS, CSL JSON, CSV/TSV, or plain reference lists with GB/T 7714, APA, MLA, Chicago, IEEE, Vancouver, or Harvard bi... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 16 次。

如何安装 Bibtex to Literature Review?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install bibtex-literature-review」即可一键安装,无需额外配置。

Bibtex to Literature Review 是免费的吗?

是的,Bibtex to Literature Review 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Bibtex to Literature Review 支持哪些平台?

Bibtex to Literature Review 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Bibtex to Literature Review?

由 Big Stephen(@stephenlzc)开发并维护,当前版本 v1.0.0。

💬 留言讨论