path matching now keeps track of its state so that future calls don't need to re-match the entire path, just the new observations