ask for 'merica's help japan!
of course swat would be the one to suggest asking for america's help  

---
the shogun launched his final assault this month
the division of troops was 11k to the west and 46k to the east (including the shogun himself)
of the 46k mobilized for the eastern attack, 15k were still traumatized from the initial push's devastation
superior technology decimated the western attempt (which was launched an hour too early), killing 7k shogun and 1k imperial troops. remaining shogun forces retreated to osaka and defending imperial troops rerouted to the eastern front.
the eastern assault was more successful for the shogun, however, as siege weapons got their jobs done and broke through kyoto defenses. leading up to the destruction of the wall, however, 10k troops were lost as they charged across open fields and towards hillsides for cover as siege equipment got set up. after the siege equipment was in place, however, the walls to outer kyoto fell. the shogun began inflicting heavy casualties on the emperor's more ranged units, causing 6k deaths in exchange for 2k.
as the fighting began to spill onto the streets of the imperial capital, civilian homes began catching on fire as shogunate firebombers came onto the scene. meanwhile, naginata and matchlock samurai set up a base of fire at the mouth of the hole in the wall, preventing an imperial counter-attack. 
as more shogun forces began to pour into the city, however, imperial marksmen would cut them down as they kept moving back from defensive line to defensive line, killing 9k in the process. it was at this point that the shogun's generals followed through with an earlier plan to reuse the 15k from the previous assault in a Self Delete attack. while shogunate forces had secured the initial hole in the wall, a second one was opened on another side of the city with a katana-only banzai charge of 15k leading the push towards nijo castle, the emperor's residence
the charge was quickly cut down by imperial rifle retainers, who postponed their push by killing 12k of them before being obliterated (all 4k of them)
it was at this point that the 3k from the second assault and the 18k from the first assault completely occupied parts of the city and made their war towards nijo castle
nijo castle, a heavily fortified position, was a slaughterhouse for both sides. the 3k from the second assault were quickly subdued by imperial sharpshooters. the remaining 18k performed a second katana charge, this time driving imperial troops from the gates and first line of defense, killing 9k and losing 6k.
nijo castle was now penetrated by shogun forces, but not captured. the emperor remained within the building during the assault, coordinating his troops and preparing to defend himself if need be
one-on-one samurai battles broke out in various sections of the castle as more sharpshooters picked off pursuing shogun forces, eventually routing some 5k after a failed third katana charge
despite their relatively high morale, shogun troops became exhausted due to prolonged combat and excessive running, reducing their effectiveness in combat and later their morale
seeing their allies running and imperial forces beginning to push, more shogun forces began routing. all shogun forces were now empty from nijo castle and heading out of the city as quickly as they could manage
all positions formerly held by the shogun were now abandoned and the city in a crumbling, burning mess with bodies scattered and civilians wounded
only one warrior walked the roads up towards nijo castle now
it was the shogun tokugawa yoshinobu, who knelt before emperor meiji and resigned his title of shogun, ending the japanese civil war, transferring 100% control to the emperor, and reuniting japan after nearly 500 years of constant warfare
yoshinobu, ashamed of this humiliating defeat, disbanded all remaining troops and decommissioned all generals who survived the ordeal
at the end of the battle of kyoto, the emperor lost 20k troops to the shogun's 39k
130 civilians were killed
japan now has the option to enact the meiji restoration and become a westernized nation