vdjmatch — TCR peptide–MHC annotation
Get started · Guides · Commands · API · Examples
vdjmatch annotates selected T-cell receptors and repertoires against
VDJdb, preserving query identities and
reporting peptide–MHC candidates, competing evidence and optional background calibration.
Native sequence search uses seqtree;
repertoire ingestion reuses published vdjtools readers.
Dependency versions and native CPU budgets are managed by the installed package.
Quick start
python -m pip install vdjmatch
vdjmatch annotate sample.tsv -o annotation
Use AIRR junction_aa (including conserved anchors) and V calls. The curated
VDJdb reference is fetched on first use; add --vdjdb reference.zip for offline
input. Single TRA/TRB receptors and paired receptors are supported. Exact hits
are retained by default. Scores describe sequence evidence, not proof of binding.
For a small offline example, download the examples directory and run
sh examples/annotate.sh annotation-demo from the repository root.
Choose a reference
The existing match command and Annotator API support three reference choices:
| Reference | Python | CLI |
|---|---|---|
| Official vdjdb-db release | Annotator.latest() |
vdjmatch match queries.tsv |
| Your VDJdb-format table/archive | Annotator.from_path("reference.tsv") |
vdjmatch match queries.tsv --reference reference.tsv |
| Your labeled chains or pairs | Annotator.from_labels(rows, locus="TRB") |
vdjmatch match queries.tsv --reference labels.csv --reference-format labels --locus TRB |
--vdjdb remains an alias for --reference. Ordinary queries retain exact matches.
Use --exclude-exact only when explicitly evaluating a classifier or assessing
record reliability; it filters hits while retaining the complete reference model.
A simple single-chain reference needs junction_aa,label (or epitope instead of
label). Supply --locus TRA/TRB or a reference locus column. For paired tables,
use junction_aa_alpha,junction_aa_beta,label and add --paired; each reference row
links its actual TRA/TRB pair. V/J, species and MHC metadata are optional. Missing
query locus fields use the explicit hint or the reference's sole locus; supplied
query metadata is retained. The sequences include conserved junction anchors.
from vdjmatch import Annotator
single = Annotator.from_labels([("CASSQYF", "class-a"), ("CATSRYF", "class-b")], locus="TRB")
calls = single.annotate(["CASSQYF", "CWWWWWWWF"])
paired = Annotator.from_labels([("CAVQYF", "CASSQYF", "class-a")])
Labeled references are indexed directly without VDJdb-specific curation or
reference-diagnostic preparation. Their labels are opaque class names, reported
in the existing epitope output fields. They default to uncalibrated matching;
request --evalue with the appropriate organism/controls for calibration.
Run the synthetic single/paired example for a
complete Python example.
Documentation
| Need | Guide |
|---|---|
| Learn the workflow | Getting started · Rendered notebooks |
| Annotate a cohort or use an offline reference | How-to guides · Runnable examples |
| Look up inputs, options and outputs | CLI reference · Python API |
| Understand methods and formulas | Scoring · Evidence and calibration |
| Test repertoire enrichment | Matching, nulls and count units |
| Estimate precursor frequency | Method · Experimental compendium |
The legacy Java/Groovy implementation remains on legacy-java
and Java tag 1.3.1, with
JitPack artifact com.github.antigenomics:vdjmatch:1.3.1.
License
ISALGO LAB Academic and Non-Commercial Research License v1.0. See LICENSE.
CPU budgets use threads=0 for automatic parallel work, capped at 16 allocated CPUs.
Use 1 for serial work or a positive
count to override the automatic cap within the scheduler/container allocation.
Sample workers keep their inner numerical kernels serial.
Candidate-only annotation coalesces up to 256 complete query identities and 64 MiB of queued expanded tables per reduction. Native search and alias expansion keep small blocks; larger complete-query frames are consumed directly.
Metadata
Release files for vdjmatch 1.2.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 | Provenance | Actions |
|---|---|---|---|---|
| vdjmatch-1.2.2.tar.gz | 2.0 MB | With provenance | Details for vdjmatch-1.2.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| vdjmatch-1.2.2-py3-none-any.whl | Python 3 | none | any | Details for vdjmatch-1.2.2-py3-none-any.whl |
Total release size: 2.9 MB
Release files / vdjmatch-1.2.2.tar.gz
| Download URL | vdjmatch-1.2.2.tar.gz |
|---|---|
| Size | 2.0 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
52840f0cd25e79d2f2df4020aee6b376e2d58574e1c7b0500c77cc9f5e3fa9e3
|
|
BLAKE2b-256 checksum How to use checksums |
c1032586bc1e03caa9896cf6d585f19d650dded65390c2ed2836da4fa4f7b9a9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 Nov 4, 2026.
Transparency logRelease files / vdjmatch-1.2.2-py3-none-any.whl
| Download URL | vdjmatch-1.2.2-py3-none-any.whl |
|---|---|
| Size | 883.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ed27ae9e0eef0cae77a952818f47cd990804e670272e135cc2b6c969e79105e2
|
|
BLAKE2b-256 checksum How to use checksums |
ede9c2e64fbcad113667cb759f36a48e40d412197fedb615fe85b61e9af9faac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 Nov 4, 2026.
Transparency logSecurity for vdjmatch 1.2.2
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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for vdjmatch-1.2.2.tar.gz
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 Nov 4, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.