ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

Office To Md V2

Skill by lkyyyy320

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/lkyyyy320/office-to-md-v2
Or

Office to Markdown Converter Skill (v2)

Description

Convert office documents (PDF, DOC, DOCX, PPTX) to Markdown format. This skill uses the word-extractor library for .doc support and provides full OpenClaw integration.

When to Use

  • When you need to extract text from office documents
  • When you want to convert documents to readable Markdown format
  • When analyzing document content in OpenClaw
  • Specifically when dealing with legacy .doc format files

Supported Formats

  • PDF (.pdf): Text extraction using pdf-parse
  • Word (.docx): Formatting preservation using mammoth + turndown
  • Legacy Word (.doc): Text extraction using word-extractor (supports Chinese encoding)
  • PowerPoint (.pptx): Basic text extraction using python-pptx

Dependencies

  • Node.js with npm packages: pdf-parse, mammoth, turndown, word-extractor
  • Python3 with python-pptx (for PPTX conversion, optional)
  • OpenClaw exec tool permission

Installation

1. Copy the skill to your workspace:

cp -r /root/.openclaw/workspace/office-to-md-v2/office-to-md /path/to/your/workspace/

2. Install dependencies:

cd /path/to/your/workspace/office-to-md
npm install

3. For PPTX support (optional):

pip3 install python-pptx

Usage in OpenClaw

Method 1: Direct exec call

// Convert any supported document
const result = await exec(
  'node /path/to/office-to-md/openclaw-skill.js /path/to/document.doc',
  { workdir: '/path/to/workspace', timeout: 60000 }
);

if (result.exitCode === 0) {
  console.log('✅ Document converted successfully');
  // Output file: /path/to/document.md
} else {
  console.error('❌ Conversion failed:', result.stderr);
}

Method 2: Using the wrapper function

// Import the converter
const { convertOfficeToMarkdown } = require('/path/to/office-to-md/openclaw-skill.js');

// Convert document
const conversionResult = await convertOfficeToMarkdown('/path/to/document.pdf');
if (conversionResult.success) {
  console.log(`Output: ${conversionResult.outputPath}`);
  console.log(`Preview: ${conversionResult.preview}`);
} else {
  console.error(`Error: ${conversionResult.error}`);
}

Metadata

Author@lkyyyy320
Stars1601
Views0
Updated2026-02-27
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-lkyyyy320-office-to-md-v2": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.