package eliza // Personality defines whats in a bot script type Personality struct { Name string `json:"name" yaml:"name"` Version string `json:"version,omitempty" yaml:"version,omitempty"` Commands map[string][]string `json:"commands,omitempty" yaml:"commands,omitempty"` Introductions []string `json:"introductions,omitempty" yaml:"introductions,omitempty"` Goodbyes []string `json:"goodbyes,omitempty" yaml:"goodbyes,omitempty"` Psychobabble []SimilarQuestionResponse `json:"psychobabble,omitempty" yaml:"psychobabble,omitempty"` DefaultResponses []string `json:"defaultresponses,omitempty" yaml:"defaultresponses,omitempty"` QuitResponses []string `json:"quitresponses,omitempty" yaml:"quitresponses,omitempty"` ReflectedWords map[string]string `json:"reflectedwords,omitempty" yaml:"reflectedwords,omitempty"` } // SimilarQuestionResponse is a structure which defines questions and their responses ... maps to an actual response from the bot. // There are many ways to say "hello" and to respond to it. So we are changing from a map of string-*string to a list of *string->*string type SimilarQuestionResponse struct { SimilarQuestions []string `json:"similarQuestions,omitempty" yaml:"similarQuestions,omitempty"` Responses []string `json:"responses,omitempty" yaml:"responses,omitempty"` }