Opinionated Markdown converter with native LLM enhancement support
Project description
Markitai
English | 简体中文
Opinionated Markdown converter with native LLM enhancement support.
Features
- Multi-format Support - DOCX/DOC, PPTX/PPT, XLSX/XLS, PDF, TXT, MD, JPG/PNG/WebP, URLs
- LLM Enhancement - Format cleaning, metadata generation, image analysis
- Batch Processing - Concurrent conversion, resume capability, progress display
- OCR Recognition - Text extraction from scanned PDFs and images
- URL Conversion - Direct webpage conversion with SPA browser rendering support
- Smart Caching - LLM result caching, SPA domain learning, auto-proxy detection
Installation
One-Click Setup (Recommended)
# Linux/macOS
curl -fsSL https://raw.githubusercontent.com/Ynewtime/markitai/main/scripts/setup.sh | sh
# Windows (PowerShell)
irm https://raw.githubusercontent.com/Ynewtime/markitai/main/scripts/setup.ps1 | iex
Manual Installation
# Requires Python 3.11-3.13 (3.14 not yet supported)
uv tool install markitai
# Or using uv pip (for virtual environment)
uv pip install markitai
Quick Start
First Run
# Interactive mode (recommended for new users)
markitai -I
# Or convert a file directly
markitai document.pdf
# With LLM enhancement
markitai document.pdf --llm
Check Setup
# Verify all dependencies
markitai doctor
# Auto-fix missing components
markitai doctor --fix
Common Tasks
# Basic conversion
markitai document.docx
# URL conversion
markitai https://example.com/article
# LLM enhancement
markitai document.docx --llm
# Using presets
markitai document.pdf --preset rich # LLM + alt + desc + screenshot
markitai document.pdf --preset standard # LLM + alt + desc
markitai document.pdf --preset minimal # Basic conversion only
# Batch processing
markitai ./docs -o ./output
# Resume interrupted job
markitai ./docs -o ./output --resume
# Batch URL processing (auto-detect .urls files)
markitai urls.urls -o ./output
Output Structure
output/
├── document.docx.md # Basic Markdown
├── document.docx.llm.md # LLM-enhanced version
├── assets/
│ ├── document.docx.0001.jpg
│ └── images.json # Image descriptions
├── screenshots/ # Page screenshots (with --screenshot)
│ └── example_com.full.jpg
Configuration
Priority: CLI arguments > Environment variables > Config file > Defaults
# View configuration
markitai config list
# Initialize config file
markitai init
# View cache status
markitai cache stats
# Clear cache
markitai cache clear
# Check system health and dependencies
markitai doctor
Config file location: ./markitai.json or ~/.markitai/config.json
Local Providers (Subscription-based)
Use your existing Claude Code or GitHub Copilot subscription:
# Claude Agent (requires Claude Code CLI)
markitai document.pdf --llm # Configure claude-agent/sonnet in config
# GitHub Copilot (requires Copilot CLI)
markitai document.pdf --llm # Configure copilot/gpt-5.2 in config
Install CLI tools:
# Claude Code CLI
curl -fsSL https://claude.ai/install.sh | bash
# GitHub Copilot CLI
curl -fsSL https://gh.io/copilot-install | bash
Environment Variables
| Variable | Description |
|---|---|
OPENAI_API_KEY |
OpenAI API Key |
GEMINI_API_KEY |
Google Gemini API Key |
DEEPSEEK_API_KEY |
DeepSeek API Key |
ANTHROPIC_API_KEY |
Anthropic API Key |
JINA_API_KEY |
Jina Reader API Key (URL conversion) |
Dependencies
- pymupdf4llm - PDF conversion
- markitdown - Office documents and URL conversion
- LiteLLM - LLM gateway
- RapidOCR - OCR recognition
Documentation
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file markitai-0.5.0.tar.gz.
File metadata
- Download URL: markitai-0.5.0.tar.gz
- Upload date:
- Size: 6.2 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
17d167be75b043552478e5a1362c42812077f0d848dfbd86b6bc5b6115d74425
|
|
| MD5 |
67d2c6ce624c4d1bc0da7b18cbe4a8f2
|
|
| BLAKE2b-256 |
4022c1fd2f78f832a574c6d14bbe9abbcbbac779663c8406ba5676a12fa277ce
|
Provenance
The following attestation bundles were made for markitai-0.5.0.tar.gz:
Publisher:
publish.yml on Ynewtime/markitai
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
markitai-0.5.0.tar.gz -
Subject digest:
17d167be75b043552478e5a1362c42812077f0d848dfbd86b6bc5b6115d74425 - Sigstore transparency entry: 923731813
- Sigstore integration time:
-
Permalink:
Ynewtime/markitai@53f5a6b48a46636c51d3ab481cb6411395772e56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Ynewtime
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@53f5a6b48a46636c51d3ab481cb6411395772e56 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file markitai-0.5.0-py3-none-any.whl.
File metadata
- Download URL: markitai-0.5.0-py3-none-any.whl
- Upload date:
- Size: 305.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0663e71973252051005df675226ac05c666e06825c8ebb781bd6b142ede5e1e9
|
|
| MD5 |
3c76686c5103c73c263b86f1cdedd7ae
|
|
| BLAKE2b-256 |
f39de823d6a0c8739d32b5b31322915450a656d8d1c71c12c785ab6a3c5d75e8
|
Provenance
The following attestation bundles were made for markitai-0.5.0-py3-none-any.whl:
Publisher:
publish.yml on Ynewtime/markitai
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
markitai-0.5.0-py3-none-any.whl -
Subject digest:
0663e71973252051005df675226ac05c666e06825c8ebb781bd6b142ede5e1e9 - Sigstore transparency entry: 923731893
- Sigstore integration time:
-
Permalink:
Ynewtime/markitai@53f5a6b48a46636c51d3ab481cb6411395772e56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Ynewtime
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@53f5a6b48a46636c51d3ab481cb6411395772e56 -
Trigger Event:
workflow_dispatch
-
Statement type: