I am very sorry to hear about your friend.
These situations are never easy. As well, chronic diseases causing these kinds of signs can muddy the waters and make deciding whether it is time even harder.
Still, with his Remi's current signs, I am concerned that it is nearing his time and that we will need to make that decision. The black vomit despite only having chicken baby food raises worries that he may be bleeding
into his stomach
. Therefore, with that alone, we'd need to consider whether we want to have his vet try more treatment (ie medication to halt the vomiting, treat nausea, and a gastroprotectant and pain relief if an ulcer is present) to try to help him overcome this complication or consider taking it as our sign to let him go.
Further to that worrying sign, our decision to put our pets to sleep will depend on whether he is still doing those things that have always made his dog life worth living; if he is interacting with you and the world around him as he used to; and whether can he do the things he must for life (ie go outside to pass urine/feces, eat, sleep). If he is only rarely keen for a walk and doing those things he always had; that may not be enough. But if he can still do so regularly, then we could consider speaking to his vet about further treatment for him.
Finally, I have to warn you that as his disease progresses, Remi will continue to feel worse. So, even though the bleeding into his stomach and suspect ulcer could be treated; sometimes it is best to let them go at a stage like this to prevent them feeling any more poorly.
Please take care,