The total chat app, including the ask/answer component for soliciting a name comments, etc. is listed on this page. There is no special code to support AJAX/Comet (all the wrapping is done automatically by Lift).
When the Chat comet widget is added to the page, it needs to solict the user for a "chat name". It asks the "AskName" comet widget for the name. Until the AskName comet widget provides a name, all rendering messages are forwarded to AskName. Here's the code for the "AskName":
This example demonstrates the power of Scala's Actors and Lift. With very few lines of code, we've got a complete AJAX/Comet app that has Seaside style Ask/Answer for building modal dialogs.