As an example, suppose there are 10 candidates, and a voter votes A>B. In the usual pairwise counting approach, 9 markings are made to indicate A’s dominance over 9 other candidates on this voter’s ballot, and likewise 8 for B. But note that because A is this voter’s 1st choice, we could’ve simply said “A is 1 voter’s 1st choice”, and then at the central vote-counting place, they can simply “unpack” this to put 1 vote in every matchup A has against other candidates. Note that this naturally allows you to handle write-in candidates.
This approach can be generalized to handle 2nd choices as well: ignoring A, B is this voter’s 1st choice. So the same trick can be applied to B. To prevent A and B from simultaneously getting votes against each other in the A vs B matchup, the precinct vote-counters can put a “negative vote” in the B>A side of the matchup. When the central vote-counters unpack B’s 1st choice support, this will result in the negative vote and the 1st choice support cancelling each other out, leaving only 1 vote for A>B and 0 for B>A. Note that this only required 3 markings, as opposed to 17.
A small issue is if the voter votes A=B; this could mean 1 vote is added to both A>B and B>A, resulting in no change in the margin between the two candidates (good) but a change in the “winning votes” totals for each candidate (potentially bad). So if you want perfectly accurate vote totals, you have to subtract one vote on both sides of this matchup, either by manually putting a negative vote for both sides (2 markings), or making some special marking which indicates the same (1 marking).