Edgemers
snipe is an alignment-free QC tool: it computes coverage, depth, and error- and mutation-rate metrics from a k-mer sketch rather than from aligned reads. Most sketching tools reduce a genome to a set of k-mers — every substring of length k. snipe works instead with edgemers, k-mer pairs. The edgemer is what lets snipe separate a sequencing error from a real mutation without aligning anything.
An edgemer is two k-mers
Section titled “An edgemer is two k-mers”An edgemer couples a base k-mer (K1) with a slightly longer extended k-mer (K2) that wraps K1 on both sides — K1 sits in the centre of K2, which adds (k2 − k1) / 2 bases to the left and the same number to the right:
By default k1 = 51 and k2 = 53, so the extension length is 2 — one base added on the left of K1 and one on the right. The diagram uses a shorter window for clarity — the concept is identical at any k.
- K1 is the base window: a canonical, murmur3-hashed 51-mer (seed 42).
- K2 is K1 flanked by one extra base on each side (a
53-mer, K1 centred). Whether that K2 can be formed — and whether it matches — is the extra signal the edgemer carries beyond a plain k-mer.
Why pairs? Errors vs. mutations
Section titled “Why pairs? Errors vs. mutations”Against a reference, snipe takes the K1s that match and asks whether their K2 extension matches too. When a K1 matches but its K2 differs from the reference’s expected extension, that mismatch marks a base change. Abundance then separates noise from signal: a mismatch seen once (a singleton) is usually a sequencing error — a random miscall; a mismatch seen repeatedly (a polyton) is usually a true mutation. snipe’s sequencing_error_rate and mutation_rate are derived from these two counts, each normalized by the extension length (k2 − k1).
A separate case: sometimes a K2 window can’t be used — for example when a K1 sits too close to the end of a read to leave room for the extension, or when the K2 window would contain a non-A/C/G/T base. snipe tags these as FAILED_K2 (internally k2_hash == FAILED_K2_HASH) and counts them on their own — a benign bookkeeping case, not a base change and not what the error/mutation rates measure.
Where edgemers live
Section titled “Where edgemers live”Edgemers are stored in the native .snipesig format (Parquet-encoded) with full fidelity, and they drive every downstream comparison and QC step. The K2 extension is specific to .snipesig; a K1-only export carries just the base-k-mer layer.
- FracMinHash & scale → — how snipe samples the hash space.
- The
.snipesigformat → — how edgemers are stored. - QC metrics explained → — the metrics the edgemer pair enables.