The present invention provides a compound represented by the following formula (I), a pharmaceutically acceptable salt thereof, or a solvate thereof. wherein: R 1 and R 2 are each separately selected from the group consisting of hydrogen, alkyl, alkenyl, acyl, and hydroxyalkyl; R 3 is hydrogen or halogen; ring A is a benzene ring or a pyridine ring; ring B is selected from the group consisting of the following formulas (i), (ii), (iii), and (iv): in the formula (ii), R a is alkyl; R 4 and R 5 are each separately selected from the group consisting of hydrogen, hydroxy, alkoxy, haloalkoxy, halohydroxyalkoxy, and aminoalkyl; and represents a double bond or a triple bond. The above compound can be used as a molecular probe for imaging tau proteins that accumulate in the brain.