Token-based replay technique is a conformance checking algorithm [1] that checks how well a process conforms with its model by replaying each trace on the model (in Petri net notation ).[2] Using the four counters produced tokens, consumed tokens, missing tokens, and remaining tokens, it records the situations where a transition is forced to fire and the remaining tokens after the replay ends. Based on the count at each counter, we can compute the fitness value between the trace and the model.
At the beginning, a token is produced for the source place (p = 1) and at the end, a token is consumed from the sink place (c' = c + 1). When the replay ends, the fitness value can be computed as follows:
Step 4: The activity needs to be fired but there are not enough tokens. One artificial token was produced and the missing token counter is increased by one (). The artificial token and the token at place are consumed () and one token is produced at place end ().File:Replay-tbr-abd-4.png
Step 5: The token in the end place is consumed (). The trace is complete. There is one remaining token at place ().