# Docx Toolkit

> Extract text, tables, and images from .docx and legacy .doc files. Handles large documents, CJK text, and complex table structures. Includes deduplication and filtering for extracted images.

- **Type:** Skill
- **Install:** `agentstack add skill-neu-zha-legal-ai-skills-docx-toolkit`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [NEU-ZHA](https://agentstack.voostack.com/s/neu-zha)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [NEU-ZHA](https://github.com/NEU-ZHA)
- **Source:** https://github.com/NEU-ZHA/legal-ai-skills/tree/main/skills/docx-toolkit

## Install

```sh
agentstack add skill-neu-zha-legal-ai-skills-docx-toolkit
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# DOCX Toolkit

A complete toolkit for processing Microsoft Word documents (.docx and legacy .doc formats).

## Capabilities

### 1. Text + Table Extraction (.docx)
```bash
python3 {baseDir}/scripts/extract_text.py input.docx output.txt
```
Extracts all paragraphs and tables with structure preserved. Tables are formatted as pipe-delimited rows for easy parsing.

### 2. Text Extraction (Legacy .doc)
```bash
python3 {baseDir}/scripts/extract_doc_text.py input.doc output.txt
```
Handles legacy OLE2 .doc format using olefile. Extracts Unicode text from the WordDocument stream.

### 3. Image Extraction (.docx)
```bash
python3 {baseDir}/scripts/extract_images.py input.docx output_dir/
```
Extracts all embedded images with:
- Automatic deduplication (MD5 hash comparison)
- Size filtering (skips tiny icons 200MB) may require significant RAM for olefile processing
- Image extraction preserves original format (png/jpg/gif/etc.)
- Deduplication catches exact duplicates; near-duplicates still pass through
- CJK (Chinese/Japanese/Korean) text is fully supported in both extractors

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [NEU-ZHA](https://github.com/NEU-ZHA)
- **Source:** [NEU-ZHA/legal-ai-skills](https://github.com/NEU-ZHA/legal-ai-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-neu-zha-legal-ai-skills-docx-toolkit
- Seller: https://agentstack.voostack.com/s/neu-zha
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
