소스 정보
- 저장소
- johnalbertini14-glitch/openclaw-skills
- 최근 소스 활동
- 2026년 1월 30일 04:35
- 감지된 SKILL.md 언어
- 영어
- 스타
- 1
- 포크
- 0
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/johnalbertini14-glitch/openclaw-skills --skill batch-convert명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
Use this skill to create a Polymarket wallet for your agent and trade on prediction markets. Browse markets, place bets, manage positions — all without exposing private keys.
ClawSec suite manager with embedded advisory-feed monitoring, cryptographic signature verification, approval-gated malicious-skill response, and guided setup for additional security skills.
Automated daily security audits for OpenClaw agents with email reporting. Runs deep audits and sends formatted reports.
SKILL.md 표시 중
SOC 직업 분류 기준
| name | batch-convert |
| description | Batch convert documents between multiple formats using a unified pipeline |
| author | claude-office-skills |
| version | 1.0 |
| tags | ["conversion","batch","automation","pipeline","formats"] |
| models | ["claude-sonnet-4","claude-opus-4"] |
| tools | ["computer","code_execution","file_operations"] |
This skill enables batch conversion of documents between multiple formats using a unified pipeline. Convert hundreds of files at once with consistent settings, automatic format detection, and parallel processing for maximum efficiency.
Example prompts:
| From | To: DOCX | To: PDF | To: MD | To: HTML | To: PPTX |
|---|---|---|---|---|---|
| DOCX | - | ✅ | ✅ | ✅ | - |
| ✅ | - | ✅ | ✅ | - | |
| MD | ✅ | ✅ | - | ✅ | ✅ |
| HTML | ✅ | ✅ | ✅ | - | - |
| XLSX | - | ✅ | ✅ | ✅ | - |
| PPTX | - | ✅ | ✅ | ✅ | - |
from pathlib import Path
from concurrent.futures import ThreadPoolExecutor, as_completed
import subprocess
import os
class DocumentConverter:
"""Unified document conversion pipeline."""
def __init__(self, max_workers=4):
self.max_workers = max_workers
self.converters = {
('md', 'docx'): self._md_to_docx,
('md', 'pdf'): self._md_to_pdf,
('md', 'html'): self._md_to_html,
('md', 'pptx'): self._md_to_pptx,
('docx', 'pdf'): self._docx_to_pdf,
('docx', 'md'): self._docx_to_md,
('pdf', 'docx'): self._pdf_to_docx,
('pdf', 'md'): self._pdf_to_md,
('xlsx', 'pdf'): self._xlsx_to_pdf,
('xlsx', 'md'): self._xlsx_to_md,
('pptx', 'pdf'): ._pptx_to_pdf,
(, ): ._pptx_to_md,
(, ): ._html_to_md,
(, ): ._html_to_pdf,
}
():
input_path = Path(input_path)
input_format = input_path.suffix[:].lower()
output_dir:
output_path = Path(output_dir) /
:
output_path = input_path.with_suffix()
converter_key = (input_format, output_format)
converter_key .converters:
ValueError()
converter = .converters[converter_key]
converter(input_path, output_path)
():
input_path = Path(input_dir)
output_path = Path(output_dir) output_dir input_path /
output_path.mkdir(exist_ok=)
recursive:
files = (input_path.rglob(file_pattern))
:
files = (input_path.glob(file_pattern))
supported_ext = [, , , , , ]
files = [f f files f.suffix.lower() supported_ext]
results = []
ThreadPoolExecutor(max_workers=.max_workers) executor:
future_to_file = {
executor.submit(.convert, f, output_format, output_path): f
f files
}
future as_completed(future_to_file):
file = future_to_file[future]
:
result = future.result()
results.append({: (file), : , : (result)})
Exception e:
results.append({: (file), : , : (e)})
results
# Markdown conversions (using Pandoc)
def _md_to_docx(self, input_path, output_path):
subprocess.run(['pandoc', str(input_path), '-o', str(output_path)], check=True)
return output_path
def _md_to_pdf(self, input_path, output_path):
subprocess.run(['pandoc', str(input_path), '-o', str(output_path)], check=True)
return output_path
def _md_to_html(self, input_path, output_path):
subprocess.run(['pandoc', str(input_path), '-s', '-o', str(output_path)], check=True)
return output_path
def _md_to_pptx(self, input_path, output_path):
subprocess.run(['marp', str(input_path), '-o', str(output_path)], check=True)
return output_path
# Office to Markdown (using markitdown)
def _docx_to_md(self, input_path, output_path):
from markitdown import MarkItDown
md = MarkItDown()
result = md.convert(str(input_path))
with open(output_path, ) f:
f.write(result.text_content)
output_path
():
markitdown MarkItDown
md = MarkItDown()
result = md.convert((input_path))
(output_path, ) f:
f.write(result.text_content)
output_path
():
markitdown MarkItDown
md = MarkItDown()
result = md.convert((input_path))
(output_path, ) f:
f.write(result.text_content)
output_path
():
pdf2docx Converter
cv = Converter((input_path))
cv.convert((output_path))
cv.close()
output_path
():
markitdown MarkItDown
md = MarkItDown()
result = md.convert((input_path))
(output_path, ) f:
f.write(result.text_content)
output_path
():
subprocess.run([
, , , ,
, (output_path.parent), (input_path)
], check=)
output_path
():
subprocess.run([
, , , ,
, (output_path.parent), (input_path)
], check=)
output_path
():
subprocess.run([
, , , ,
, (output_path.parent), (input_path)
], check=)
output_path
from tqdm import tqdm
def batch_convert_with_progress(converter, input_dir, output_format, output_dir=None):
"""Batch convert with progress bar."""
input_path = Path(input_dir)
files = list(input_path.glob('*'))
results = []
for file in tqdm(files, desc=f"Converting to {output_format}"):
try:
result = converter.convert(file, output_format, output_dir)
results.append({'file': str(file), 'status': 'success'})
except Exception as e:
results.append({'file': str(file), 'status': 'error', 'error': str(e)})
return results
def detect_and_convert(file_path, target_format):
"""Automatically detect format and convert."""
import mimetypes
mime_type, _ = mimetypes.guess_type(str(file_path))
format_map = {
'application/pdf': 'pdf',
'application/vnd.openxmlformats-officedocument.wordprocessingml.document': 'docx',
'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet': 'xlsx',
'application/vnd.openxmlformats-officedocument.presentationml.presentation': 'pptx',
'text/markdown': 'md',
'text/html': 'html',
}
source_format = format_map.get(mime_type, Path(file_path).suffix[1:])
converter = DocumentConverter()
return converter.convert(file_path, target_format)
def convert_to_multiple_formats(input_file, output_formats, output_dir):
"""Convert one file to multiple formats."""
converter = DocumentConverter()
results = {}
for fmt in output_formats:
try:
output = converter.convert(input_file, fmt, output_dir)
results[fmt] = {'status': 'success', 'path': str(output)}
except Exception as e:
results[fmt] = {'status': 'error', 'error': str(e)}
return results
# Convert README to multiple formats
results = convert_to_multiple_formats(
'README.md',
['docx', 'pdf', 'html'],
'./exports'
)
from pathlib import Path
import json
def export_documentation(docs_dir, export_dir):
"""Export all documentation to multiple formats."""
converter = DocumentConverter(max_workers=8)
docs_path = Path(docs_dir)
export_path = Path(export_dir)
# Create format directories
for fmt in ['pdf', 'docx', 'html']:
(export_path / fmt).mkdir(parents=True, exist_ok=True)
all_results = {}
# Find all markdown files
md_files = list(docs_path.rglob('*.md'))
for md_file in md_files:
file_results = {}
for fmt in ['pdf', 'docx', 'html']:
output_dir = export_path / fmt
try:
output = converter.convert(md_file, fmt, output_dir)
file_results[fmt] = 'success'
except Exception as e:
file_results[fmt] = f'error: {e}'
all_results[str(md_file)] = file_results
print(f"Processed: {md_file.name}")
# Save report
with open(export_path / 'export_report.json', 'w') as f:
json.dump(all_results, f, indent=2)
all_results
results = export_documentation(, )
def migrate_legacy_docs(source_dir, target_dir):
"""Migrate legacy documents to modern formats."""
converter = DocumentConverter(max_workers=4)
# Migration rules
migrations = [
('*.doc', 'docx'), # Old Word to new
('*.xls', 'xlsx'), # Old Excel to new
('*.ppt', 'pptx'), # Old PowerPoint to new
('*.rtf', 'docx'), # RTF to Word
]
source_path = Path(source_dir)
target_path = Path(target_dir)
target_path.mkdir(exist_ok=True)
total_migrated = 0
errors = []
for pattern, target_format in migrations:
files = list(source_path.glob(pattern))
for file in files:
try:
# Use LibreOffice for legacy formats
subprocess.run([
'soffice', '--headless',
'--convert-to', target_format,
'--outdir', str(target_path),
str(file)
], check=True)
total_migrated += 1
print(f"Migrated: {file.name}")
except Exception as e:
errors.append({'file': (file), : (e)})
()
()
{: total_migrated, : errors}
def generate_reports_pipeline(data_files, template_dir, output_dir):
"""Generate reports from data files using templates."""
from datetime import datetime
converter = DocumentConverter()
output_path = Path(output_dir)
output_path.mkdir(exist_ok=True)
timestamp = datetime.now().strftime('%Y%m%d_%H%M%S')
reports = []
for data_file in data_files:
# Load data
data_path = Path(data_file)
# Generate markdown report
md_content = f"""---
title: Report - {data_path.stem}
date: {datetime.now().strftime('%Y-%m-%d')}
---
# {data_path.stem} Report
Generated: {datetime.now().strftime('%Y-%m-%d %H:%M:%S')}
## Data Summary
"""
# Add data content (simplified)
if data_path.suffix == '.xlsx':
from markitdown import MarkItDown
md = MarkItDown()
result = md.convert(str(data_path))
md_content += result.text_content
# Save markdown
md_file = output_path / f"{data_path.stem}_{timestamp}.md"
with open(md_file, 'w') as f:
f.write(md_content)
# Convert to PDF and DOCX
for fmt in ['pdf', 'docx']:
try:
output = converter.convert(md_file, fmt, output_path)
reports.append({: (data_file), : (output), : fmt})
Exception e:
()
reports
# Core dependencies
pip install pdf2docx markitdown python-docx openpyxl
# Pandoc (for MD conversions)
brew install pandoc # macOS
apt install pandoc # Ubuntu
# Marp (for PPTX)
npm install -g @marp-team/marp-cli
# LibreOffice (for Office formats)
brew install libreoffice # macOS
apt install libreoffice # Ubuntu