O'Reilly logo

Isomorphic Go by Kamesh Balasubramanian

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The agent's brain

The chat bot type that we will use for the live chat feature, AgentCase, will implement the following Bot interface:

type Bot interface {  Greeting() string  Reply(string) string  Name() string  Title() string  ThumbnailPath() string  SetName(string)  SetTitle(string)  SetThumbnailPath(string)}

The Greeting method will be used to send an initial greeting to the user, enticing them to interact with the chat bot.

The Reply method accepts a question (a string) and returns a reply (also a string) for the given question.

The rest of the methods implemented are for purely psychological reasons to give humans the illusion that they are communicating with someone, rather than something.

The Name method is a getter method that returns the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required