primer-finder
primer-finder finds the sequences that tell one group of genomes from another, so that a selective (q)PCR assay can be designed on them. Give it two folders of assembled genomes — the ones the assay should amplify (inclusion) and the ones it must not (exclusion) — and it reports the regions that every inclusion genome carries, that no exclusion genome carries, and whose differences are close enough together to sit in one primer or probe.
inclusion/ ──┐ ┌──► 1. kmers shared by all inclusion genomes (KMC)
├──► kmers ──► subtract ──► assemble ──► map ──► blast
exclusion/ ──┘ (KMC) (SKESA or (minimap2) (every genome)
SPAdes)
└──► final_kmers.fasta: the candidate regions,
with the specific bases in lower case
Quick start
conda create -n primer-finder -c conda-forge -c bioconda primer-finder
conda activate primer-finder
primer-finder -i inclusion/ -e exclusion/ -o results/
inclusion/ and exclusion/ hold one assembled genome per file (.fasta, .fna, .fa, gzipped or not;
subfolders and symbolic links are followed). The answer is results/final_kmers.fasta: one record per
candidate region, the specific bases in lower case and their positions in the header, the most promising
first. results/run_info.json records the parameters, the genomes and the version of every program used.
To install from the source code instead, see Installation.
primer-finder only keeps perfect matches: a kmer must be in all the inclusion genomes with no mismatch, and in none of the exclusion genomes. It is therefore very sensitive to the quality of the assemblies and to how the genomes were assigned to the two groups. Curate the input genomes; genome_comparator helps with that.
To check an installation, run the bundled example (simulated genomes with a known answer, a few seconds). It is in the repository, not in the conda package:
curl -sL https://github.com/duceppemo/primer-finder/archive/refs/tags/v1.0.0.tar.gz | tar -xz --strip-components=1 primer-finder-1.0.0/example
bash example/run_example.sh
Ordering the assays
Once an assay has been designed from a candidate region and ordered, primer-finder idt turns the IDT order
sheet into a fasta file of oligos, one record per primer and probe:
primer-finder idt order.xlsx assays.fasta my_target
Documentation
Everything else is in the wiki, whose sources are
maintained in docs/wiki:
| Page | Contents |
|---|---|
| Installation | conda, bioconda, from source, checking the installation |
| Usage | inputs, every option, choosing the two groups, performance |
| Methods | what each step does, the filtering rules, limits |
| Outputs | every file and field |
| Example | the simulated dataset and its expected result |
| FAQ | troubleshooting, "no contig passed" |
| Development | tests, continuous integration, releases |
Citation
If primer-finder helped your work, please cite it (see CITATION.cff) together with the programs it runs: KMC, SKESA or SPAdes, minimap2 and BLAST.
License
Metadata
Release files for primer-finder 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| primer_finder-1.0.0.tar.gz | 45.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| primer_finder-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 76.5 kB
Release files / primer_finder-1.0.0.tar.gz
| Download URL | primer_finder-1.0.0.tar.gz |
|---|---|
| Size | 45.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ab2c524ff1b0236dcf00e6898bcb1a024c02331c5c0c958256a4c97cfbbc5b25
|
|
BLAKE2b-256 checksum How to use checksums |
fe0b28ec6a06be64ca22519316bef1689d2adee19a5053e9513e86c14b7608c5
|
| 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 Oct 8, 2026.
Transparency logRelease files / primer_finder-1.0.0-py3-none-any.whl
| Download URL | primer_finder-1.0.0-py3-none-any.whl |
|---|---|
| Size | 31.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
14214940a2459b37d3cd02a0eb35fbd6a1b8ba8c5b41184e27e77f21c41b923f
|
|
BLAKE2b-256 checksum How to use checksums |
f33e4b53e973947de73c17d59c67ace59ea9e57e7dc49db48e0b315dd6daf8c1
|
| 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 Oct 8, 2026.
Transparency log