How do the prose and verse work together in this passage?

The Ḥulwān Maqāmah: Companionship, Poverty, and Parting