<human>:  When did the Tokugawa shogunate end?
<bot>: The Tokugawa shogunate ended in 1867, when Japan was finally opened to the rest of the world. The shogunate was a military government that ruled Japan for 250 years.