Yom Kippur is an important day. (Thank you, Capt. Obvious.) It is very important not to eat on Yom Kippur. (Aye, Cap'n; bucking for promotion to Major, 'er yah?) It is, in fact, a Torah obligation to add a margin to Yom Kippur and stop eating before that; d'oraisa. (Umm... what?)
The Shulchan Aruch, O.Ch. 608 discusses that s'uda mafsekes/last supper needs to be finished in time to add a margin -- known as tosef Yom Kippur -- that takes away from the weekday and adds onto Yom Kippur. That siman also discusses when, to whom, and it what manner to give reproof to a fellow Jew; that is not our topic today. What is our topic is how to stop eating and how to start fasting. Syef 3 tells us that it finished the last supper while it is still daytime, one is allowed to eat again again so long as he hasn't accepted upon himself to fast. The Rema adds that accepting the fast in his mind is not a sufficient acceptance of the fast, so I may resume eating. The Mishna Brura (sk 12) notes that not everyone agrees that with the Rema that what you have in mind doesn't count. Given that, we have five levels of decision:
- Saying out loud and with kavana, "I accept upon myself the holiness of Yom Kippur."
- Explicitly having the above in mind.
- No particular thoughts about Yom Kippur or eating; aka "stam da'as".
- Explicitly having in mind the intention to eat again before accepting the holiness of Yom Kippur (including its margin).
- Saying that (↑) out loud and with kavana.
Suppose you want to keep drinking up the to last possible moment before accepting the fast. In order to cover your bases, therefore, after finishing your s'uda mafsekes (before sundown, of course) be sure to speak out before bentching that you are not accepting the fast even though you are finished with your s'uda. Then, sometime -- at least a few minutes -- before sundown, speak out that you are accepting the holiness of Yom Kippur.
If you do all that between plahg ha'mincha and sundown, you are good to go. If you plan to finish your s'uda mafsekes before plahg ha'mincha and to stop eating then, but then change your mind... CYLOR.