TrueMend
Find the bugs your AI coding assistant left behind — deterministically, offline, in seconds.
TrueMend reads your code as a syntax tree and reports what is wrong with it — swallowed exceptions, leftover debug statements, duplicated logic, unguarded LLM output, dead code. It never calls a language model to decide what is a defect, so the same input always produces the same findings, and nothing leaves your machine.
Then it fixes what can be fixed safely, and tells you honestly which problems need a human.
Install
pip install truemend
Or run it with no install at all — as an MCP server inside your editor:
claude mcp add truemend -- npx -y truemend-mcp
Standalone binaries for Linux, macOS and Windows are attached to every release.
Use it
truemend . # analyze the current directory
truemend audit . # full quality audit with a readiness verdict
truemend fix src/ --apply # apply only the fixes proven safe
A real run looks like this:
Health score: 93.4/100
Files analyzed: 247
Anti-patterns: 639
PRODUCTION READINESS: READY WITH WARNINGS
Warnings:
[WARN] 2 high-severity findings
[WARN] 18 dead code blocks (114 lines)
[WARN] 208 duplicate clusters (404 functions)
Passing:
[PASS] No critical-severity anti-patterns
[PASS] No empty catch blocks
[PASS] No hardcoded secrets detected
No configuration file, no API key, no account, no network call.
What it looks for
The detector library is generated into facts.json and currently
carries 4,709 detectors across 24 languages:
| Area | Detectors |
|---|---|
| Core languages | 2,376 |
| Quality & cross-cutting | 410 |
| Backend frameworks | 405 |
| AI / ML SDKs | 380 |
| DevOps & infrastructure | 378 |
| Web frontend | 333 |
| Database & ORM | 239 |
| Mobile | 188 |
Beyond pattern matching, it also does whole-project analysis: an import and call graph, duplicate-cluster detection, orphaned-file detection, and 20 behavioural dimensions derived from the Python AST.
Full inventory: Features · Languages & frameworks
How it fixes things
Not every problem deserves the same treatment, so TrueMend sorts every finding into one of three tiers and never blurs the line between them:
| Tier | What happens | Risk |
|---|---|---|
| Deterministic | An AST transform rewrites the code, then re-parses to verify | None — reverted if the result does not parse |
| Cataloged refactor | A constrained prompt for your own LLM, scoped to one pattern | Low — you review the diff |
| Structural rewrite | Described, never applied | Yours to decide |
Where it runs
| Surface | Setup |
|---|---|
| CLI | pip install truemend |
| Editor (MCP) | 28 tools and 10 resources over stdio — setup guide |
| CI | GitHub Actions, GitLab, pre-commit — CI guide |
| Coding agents | truemend install-skill --agent claude writes overlays for 10 agents |
# .github/workflows/truemend.yml
- uses: alsajoo/truemend-engine@v1.3.0
with:
targets: 'src/'
Documentation
| User guide | Every command and flag |
| MCP setup | Claude Code, Cursor, VS Code, Claude Desktop |
| CI integration | Pipelines, exit codes, SARIF |
| API reference | Using the engine as a library |
| Editions | What is free, what is licensed |
| Comparison | How it differs from SonarQube, Semgrep, ESLint |
| How-to guides | Adding languages, writing detectors, authoring skills |
Licensing in one paragraph
TrueMend is open core. The engine is Apache 2.0 — src/, cli.py,
truemend_mcp.py, and the launchers. The detection content is Elastic 2.0 —
the anti-pattern library and the agent skills. Internal use, modification and
self-hosting are all permitted; reselling TrueMend as a hosted service is not.
pip install truemend includes the core-language detectors; the framework,
AI/LLM, database and DevOps libraries require a licence.
LICENSING.md is the authoritative map of which licence covers
which path. docs/editions.md explains what each edition
actually contains.
Metadata
Release files for truemend 1.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| truemend-1.4.2.tar.gz | 4.7 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| truemend-1.4.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.6 MB
Release files / truemend-1.4.2.tar.gz
| Download URL | truemend-1.4.2.tar.gz |
|---|---|
| Size | 4.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c76e71588c8dcbea75ecaf6026965e596a128be499b04f4150c3ebc3617e0d42
|
|
BLAKE2b-256 checksum How to use checksums |
55a7e3fe73531addde42301a243cabc3aecfdc5593a29f47005b02b5a35e4d13
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 22, 2026.
Transparency logRelease files / truemend-1.4.2-py3-none-any.whl
| Download URL | truemend-1.4.2-py3-none-any.whl |
|---|---|
| Size | 4.9 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b7fca8db46140e4f2340b832bdd35a7f17cd89bee15e57a0757c458b94788fd0
|
|
BLAKE2b-256 checksum How to use checksums |
13575c25bc2709143453c09c67fc39f9ff1f35d24767189c2291db48db9f12e6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 22, 2026.
Transparency log