Aspose.Words for MarkItDown plugin

Aspose.Words for MarkItDown is a free plugin for MarkItDown based on Aspose.Words for Python via .Net commercial library.
The plugin is designed for parsing multiple document formats and converting them into Markdown suitable for AI processing.
The project is located in the GitHub repository.

Features

Aspose.Words for MarkItDown supports the following features:

  • Parsing new .doc, .rtf, .odt, .mhtml, .mobi and .azw3 formats
  • Improved conversion of .docx, .pdf, .html, .epub and .txt documents
  • Support all document components, including paragraphs, tables, images, headers, and footers
  • Fully integrated with MarkItDown tool. You don’t need to change your code to use the Aspose.Words plugin

Requirements

You’ll need to obtain valid license for Aspose.Words. The package will install this dependency, but you’re responsible for complying with Aspose’s licensing terms.

How to Install Aspose.Words for MarkItDown

To install Aspose.Words MCP Server via pip, run the following:

pip install aspose-words-markitdown

How to Use Aspose.Words for MarkItDown

  1. Make sure the plugin is installed correctly:
  • List MarkItDown plugins with the command: markitdown --list-plugins
  • Check the plugin is installed:
Installed MarkItDown 3rd-party Plugins:
  * aspose_words_markitdown  (package: aspose_words_markitdown)
  1. Use the original markitdown CLI in the common way. Just add the --use-plugins option to enable the plugin.

  2. Convert a Single File:

markitdown test.doc -o out.md --use-plugins
  1. Use Python API:
      
      from markitdown import MarkItDown  
    
      md = MarkItDown(enable_plugins=True) # Set to True to enable the plugin  
      result = md.convert("test.doc")  
      print(result.text_content)  
      

Aspose.Words License

To activate your Aspose.Words for Python license, set the corresponding environment variable.

Refer to the OS-specific instructions below:

Unix-based (Linux/macOS):

export ASPOSE_WORDS_LICENSE_PATH="/path/to/license/aspose.words.lic"

Windows-based:

set ASPOSE_WORDS_LICENSE_PATH=c:\path\to\license\aspose.words.lic

Python API:

  
from aspose_words_markitdown import LicenseManager

LicenseManager().apply_license("/path/to/license/aspose.words.lic")  

How to Run Tests

To run unit tests for Aspose.Words for MarkItDown, follow these steps:

  1. Navigate to the package directory: From the root of the repository, change into the package directory:
cd /packages/aspose-words-markitdown/tests
  1. Install test dependencies: Make sure pytest is installed:
pip install pytest
  1. Run all the tests using pytest:
pytest