mangiucugna/json_repair

A python module to repair invalid JSON from LLMs

87
/ 100
Verified

Provides syntax error correction for common LLM output mistakes—missing quotes, unescaped characters, incomplete arrays/objects—while preserving content integrity. Uses a two-stage approach: first attempts standard library `json.loads()` for performance, then falls back to a custom repair parser only on failure. Offers drop-in replacements for `json.load()` and `json.loads()`, with optional `skip_json_loads` and `strict` modes for performance tuning and validation control.

4,585 stars and 16,557,243 monthly downloads. Used by 31 other packages. Actively maintained with 10 commits in the last 30 days. Available on PyPI.

Maintenance 20 / 25
Adoption 25 / 25
Maturity 25 / 25
Community 17 / 25

How are scores calculated?

Stars

4,585

Forks

175

Language

Python

License

MIT

Last pushed

Mar 07, 2026

Monthly downloads

16,557,243

Commits (30d)

10

Reverse dependents

31

Get this data via API

curl "https://pt-edge.onrender.com/api/v1/quality/llm-tools/mangiucugna/json_repair"

Open to everyone — 100 requests/day, no key needed. Get a free key for 1,000/day.