while yaqub beg asserted his authority over kashgaria, the situation back home in kokand changed radically. in may 1865, alim quli lost his life while defending tashkent against the russians. many of his soldiers (primarily, of kyrgyz and kipchak background) deemed it advisable to flee to the comparative safety of kashgaria. they appeared at the borders of yaqub beg's domain in early september 1865. afghan warriors also assisted yaqub beg.