preliminary work on chat
various tweaks
chat improvement