Token导航 LogoToken导航TokenDH.com
研究检索执行命令github未标认证来源可访问clear审计通过

docx-format-replicatorDOCX format replicator 搜索

Agent Skill

docx-format-replicator 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

4,633

周安装

197

GitHub Stars

284

下载量

1,623
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:docx-format-replicator(DOCX format replicator 搜索)
来源仓库:https://github.com/iamzhihuix/happy-claude-skills
仓库路径:skills/docx-format-replicator
安装命令:
npx skills add https://github.com/iamzhihuix/happy-claude-skills --skill docx-format-replicator
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/iamzhihuix/happy-claude-skills --skill docx-format-replicator

简介

从现有 DOCX 提取格式信息,生成具有相同样式但内容不同的新文档。

  • 支持模板复制与批量文档创建,保持企业级格式一致性。
  • 适用于年度报告、会议纪要等需统一外观的多文档产出场景。
  • 通过 GitHub 安装,建议先分析源文件结构再启动复制流程。
  • docx-format-replicator 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

DOCX Format Replicator

Overview

Extract formatting information from existing Word documents (.docx) and use it to generate new documents with identical formatting but different content. This skill enables creating document templates, maintaining consistent formatting across multiple documents, and replicating complex Word document structures.

When to Use This Skill

Use this skill when the user:

  • Wants to extract formatting from an existing Word document
  • Needs to create multiple documents with the same format
  • Has a template document and wants to generate similar documents with new content
  • Asks to "replicate", "copy format", "use the same style", or "create a document like"
  • Mentions document templates, corporate standards, or format consistency

Workflow

Step 1: Extract Format from Template

Extract formatting information from an existing Word document to create a reusable format configuration.

python scripts/extract_format.py <template.docx> <output.json>

Example:

python scripts/extract_format.py "HY研制任务书.docx" format_template.json

What Gets Extracted:

  • Style definitions (fonts, sizes, colors, alignment)
  • Paragraph and character styles
  • Numbering schemes (1, 1.1, 1.1.1, etc.)
  • Table structures and styles
  • Header and footer configurations

Output: JSON file containing all format information (see references/format_config_schema.md for details)

Step 2: Prepare Content Data

Create a JSON file with the actual content for the new document. The content must follow the structure defined in references/content_data_schema.md.

Content Structure:

{
  "metadata": {
    "title": "Document Title",
    "author": "Author Name",
    "version": "1.0",
    "date": "2025-01-15"
  },
  "sections": [
    {
      "type": "heading",
      "content": "Section Title",
      "level": 1,
      "number": "1"
    },
    {
      "type": "paragraph",
      "content": "Paragraph text content."
    },
    {
      "type": "table",
      "rows": 3,
      "cells": [
        ["Header 1", "Header 2"],
        ["Data 1", "Data 2"]
      ]
    }
  ]
}

Supported Section Types:

  • heading - Headings with optional numbering
  • paragraph - Text paragraphs
  • table - Tables with configurable rows and columns
  • page_break - Page breaks

See assets/example_content.json for a complete example.

Step 3: Generate New Document

Generate a new Word document using the extracted format and prepared content.

python scripts/generate_document.py <format.json> <content.json> <output.docx>

Example:

python scripts/generate_document.py format_template.json new_content.json output_document.docx

Result: A new.docx file with the format from the template applied to the new content.

Complete Example Workflow

User asks: "I have a research task document. I need to create 5 more documents with the same format but different content."

  1. Extract the format:
python scripts/extract_format.py research_task_template.docx template_format.json
  1. Create content files for each new document (content1.json, content2.json, etc.)
  2. Generate documents:
python scripts/generate_document.py template_format.json content1.json document1.docx
python scripts/generate_document.py template_format.json content2.json document2.docx
# ... repeat for all documents

Common Use Cases

Corporate Document Templates

Extract format from a company template and generate reports, proposals, or specifications with consistent branding.

# One-time: Extract company template
python scripts/extract_format.py "Company Template.docx" company_format.json

# For each new document:
python scripts/generate_document.py company_format.json new_report.json "Monthly Report.docx"

Technical Documentation Series

Create multiple technical documents (specifications, test plans, manuals) with identical formatting.

# Extract from specification template
python scripts/extract_format.py spec_template.docx spec_format.json

# Generate multiple specs
python scripts/generate_document.py spec_format.json product_a_spec.json "Product A Spec.docx"
python scripts/generate_document.py spec_format.json product_b_spec.json "Product B Spec.docx"

Research Task Documents

The included example template (assets/hy_template_format.json) demonstrates a complete research task document format with:

  • Approval/review table in header
  • Multi-level numbering (1, 1.1, 1.1.1)
  • Technical specification tables
  • Structured sections

Use this as a starting point for similar technical documents.

Advanced Usage

Customizing Extraction

Modify scripts/extract_format.py to extract additional properties not covered by default:

  • Custom XML elements
  • Advanced table features (merged cells, borders)
  • Embedded objects
  • Custom properties

Extending Content Types

Add new section types in scripts/generate_document.py:

  • Images with captions
  • Bulleted or numbered lists
  • Footnotes and endnotes
  • Custom content blocks

See references/content_data_schema.md for extension guidelines.

Batch Processing

Create a wrapper script to generate multiple documents:

import json
import subprocess

format_file = "template_format.json"
content_files = ["content1.json", "content2.json", "content3.json"]

for i, content_file in enumerate(content_files, 1):
    output = f"document_{i}.docx"
    subprocess.run([
        "python", "scripts/generate_document.py",
        format_file, content_file, output
    ])

Dependencies

The scripts require:

  • Python 3.7+
  • python-docx library: pip install python-docx

No additional dependencies are needed for the core functionality.

Resources

scripts/

  • extract_format.py - Extract formatting from Word documents
  • generate_document.py - Generate new documents from format + content

Both scripts include built-in help:

python scripts/extract_format.py --help
python scripts/generate_document.py --help

references/

  • format_config_schema.md - Complete schema for format configuration files
  • content_data_schema.md - Complete schema for content data files

Read these for detailed information on file structures and available options.

assets/

  • hy_template_format.json - Example extracted format from a technical research task document
  • example_content.json - Example content data showing all section types

Use these as references when creating your own format and content files.

Troubleshooting

Missing styles in output: Ensure style IDs in content data match those in format config. Check format.json for available style IDs.

Table formatting issues: Verify table dimensions (rows/columns) match between content data and format config. See format_config_schema.md for table structure.

Font not displaying correctly: Some fonts may not be available on all systems. Check that referenced fonts are installed.

Dependencies missing: Install required Python packages:

pip install python-docx

Tips

  1. Test with examples first: Use the included hy_template_format.json and example_content.json to understand the workflow before extracting your own formats.
  2. Start simple: Begin with basic headings and paragraphs, then add tables and complex formatting.
  3. Validate JSON: Use a JSON validator to check content data files before generating documents.
  4. Keep format configs: Store extracted format configurations for reuse across multiple projects.
  5. Version control: Track both format configs and content data in version control for reproducible document generation.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

29.92%
按下载量换算486

OpenCode

22.94%
按下载量换算372

Cursor

16.53%
按下载量换算268

Codex

12.39%
按下载量换算201

Gemini CLI

7.89%
按下载量换算128

Antigravity

3.24%
按下载量换算53

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/iamzhihuix/happy-claude-skills --skill docx-format-replicator;npx skills add iamzhihuix/happy-claude-skills --skill "docx-format-replicator" 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills