RepoPilot

microsoft / markitdown

Search microsoft/markitdown

GitHub

Code

How microsoft/markitdown is laid out, and where to start for common changes.

A
Architecture grade
score 95/100
1
Import cycles
lower is better
92
Files mapped
129 imports between them
99%
Layering
of imports point one way

From the map of which files import which. It shows what depends on what, not a reading order.

Module map

Shade by
Entry points and orchestratorsShared coreFoundation_stream_info1 file · 0 commits__about__1 file · 5 commits_base_converter1 file · 1 commit_exceptions1 file · 2 commits_markitdown1 file · 7 commitsconverters24 files · 58 commitsconverter_utils9 files · 14 commits_uri_utils1 file · 4 commits__init__1 file · 0 commits__main__1 file · 7 commits

10 modules, 21 links. A link means one module imports another; thicker lines mean more imports. Select a module to trace it: blue lines go to what it uses, orange lines come from what uses it.

_stream_info1500Foundation
__about__1305Foundation
_base_converter1311Shared core
_exceptions1302Foundation
_markitdown1357Orchestrator
converters242658Orchestrator
converter_utils91114Shared core
_uri_utils1104Foundation
__init__1050Entry or leaf
__main__1037Entry or leaf

Where to start reading

  1. Repository root
  2. Likely public API
  3. Likely public API
  4. Likely start-up file
  5. Likely start-up file
  6. Suggested starting pointAI
  7. Suggested starting pointAI
  8. Suggested starting pointAI

Find files for a task

AI

Add support for a new file format

  • Register the converter in the registry at packages/markitdown/src/markitdown/converters/__init__.py by adding it to CONVERTERS list
  • Add optional dependency entry to packages/markitdown/pyproject.toml for format-specific libraries

Create a converter enhancement plugin

  • Create plugin module at packages/markitdown-plugin-name/src/markitdown_plugin_name/_plugin.py following pattern from markitdown-ocr
  • Define a plugin class that wraps or extends existing converters (e.g., _DocxConverterWithOCR inheriting from _DocxConverter)
  • Register plugin converters in __init__.py via get_plugin_converters() function
  • Create pyproject.toml declaring plugin as entry point with group markitdown.plugins

Add LLM-based image captioning to a converter

  • Import LLMCaption from packages/markitdown/src/markitdown/converters/_llm_caption.py in your converter
  • Pass image bytes to llm_caption.caption_image() with optional api_key parameter to generate alt text
  • Embed returned caption in markdown image syntax as alt text: ![caption](image_path)

Change the public API

Trace runtime behavior

Add or update tests

Change build or automation

RepoPilot lists up to 500 files, so a file missing here may still exist.

  • Files marked “likely” are guessed from their names.

Code quality and hotspots

Largest source files

  • Branch points18 per file on average
  • Code issues0 errors, 11 warnings
  • Largest file848 lines
  • Hotspot load2 high-risk files

Static checks on the 15 largest source files.

Tests, CI and tooling

  • CIGitHub Actions2 workflows
  • Tests111 test filesPytest · 2.0 test files per source file (file count, not coverage)
  • Dependency updatesDependabot
  • CI pass rate2%last 50 runs
  • First reply to issues4 daysmedian of 10 recent issues

Test folders: packages/markitdown-ocr/tests/ocr_test_data · packages/markitdown-ocr/tests · packages/markitdown-mcp/tests

Hotspots

Files that change often and branch heavily, highest first. Complexity is 0–100 from branch and nesting counts.