TalkJS needs a user ID to be able to know who a person is. You can get around this for visitors by creating anonymous user accounts and using that user id to identify the user with TalkJS.
Using our HTML panel feature you could ask the user for information during the chat. We have made an example asking the user for their email here: https://github.com/talkjs/talkjs-examples/tree/master/visitor-chat. This example will allow users to chat without account and optionally set their email to receive notifications.
If you wish to read more about HTML panels, see: talkjs.com/docs/Features/Customizations/HTML_Panels.html.