Documentation ¶
Index ¶
- Constants
- Variables
- func CreateAIReq(transcribedText, esn string, gpt3tryagain bool) openai.ChatCompletionRequest
- func CreatePrompt(origPrompt string, model string) string
- func DoGetImage(msgs []openai.ChatCompletionMessage, param string, robot *vector.Vector)
- func DoPlayAnimation(animation string, robot *vector.Vector) error
- func DoPlayAnimationWI(animation string, robot *vector.Vector) error
- func DoPlaySound(sound string, robot *vector.Vector) error
- func DoSayText(input string, robot *vector.Vector) error
- func GetChat(esn string) vars.RememberedChat
- func IntentPass(req interface{}, intentThing string, speechText string, ...) (interface{}, error)
- func KGSim(esn string, textToSay string) error
- func LoadPlugins()
- func ModelIsSupported(cmd LLMCommand, model string) bool
- func ParamChecker(req interface{}, intent string, speechText string, botSerial string)
- func ParamCheckerSlotsEnUS(req interface{}, intent string, slots map[string]string, isOpus bool, ...)
- func PerformActions(msgs []openai.ChatCompletionMessage, actions []RobotAction, ...) bool
- func PlaceChat(chat vars.RememberedChat)
- func ProcessTextAll(req interface{}, voiceText string, intents []vars.JsonIntent, isOpus bool) bool
- func Remember(user, ai openai.ChatCompletionMessage, esn string)
- func StartAnim_Queue(esn string)
- func StopAnim_Queue(esn string)
- func StreamingKGSim(req interface{}, esn string, transcribedText string) (string, error)
- func WaitForAnim_Queue(esn string)
- type AnimationQueue
- type LLMCommand
- type RobotAction
- type WeatherStruct
Constants ¶
View Source
const ( // arg: text to say // not a command ActionSayText = 0 // arg: animation name ActionPlayAnimation = 1 // arg: animation name ActionPlayAnimationWI = 2 // arg: now ActionGetImage = 3 // arg: sound file ActionPlaySound = 4 )
Variables ¶
View Source
var AnimationQueues []AnimationQueue
View Source
var PluginList []*plugin.Plugin
View Source
var PluginNames []string
View Source
var PluginUtterances []*[]string
View Source
var ValidLLMCommands []LLMCommand = []LLMCommand{ { Command: "playAnimationWI", Description: "Plays an animation on the robot without interrupting speech. This should be used FAR more than the playAnimation command. This is great for storytelling and making any normal response animated. Don't put two of these right next to each other. Use this MANY times. The param choices are the onlyy choices you have. You can't create any.", ParamChoices: "happy, veryHappy, sad, verySad, angry, frustrated, dartingEyes, confused, thinking, celebrate, love", Action: ActionPlayAnimationWI, SupportedModels: []string{"all"}, }, { Command: "playAnimation", Description: "Plays an animation on the robot. This will interrupt speech. Only use this if you are directed to play an animaion.", ParamChoices: "happy, veryHappy, sad, verySad, angry, frustrated, dartingEyes, confused, thinking, celebrate, love", Action: ActionPlayAnimation, SupportedModels: []string{"all"}, }, { Command: "getImage", Description: "Gets an image from the robot's camera and places it in the next message. If you want to do this, tell the user what you are about to do THEN use the command. This command should END a sentence. Your response will be stopped when this command is recognized. If a user says something like 'what do you see', you should assume that you need to take a new photo. Do NOT automatically assume that you are analyzing a previous photo.", ParamChoices: "front, lookingUp", Action: ActionGetImage, SupportedModels: []string{openai.GPT4o}, }, }
Functions ¶
func CreateAIReq ¶ added in v1.4.0
func CreatePrompt ¶ added in v1.2.5
func DoGetImage ¶ added in v1.3.9
func DoPlayAnimation ¶ added in v1.2.5
func DoPlayAnimationWI ¶ added in v1.2.5
func GetChat ¶ added in v1.1.6
func GetChat(esn string) vars.RememberedChat
func IntentPass ¶
func LoadPlugins ¶
func LoadPlugins()
func ModelIsSupported ¶ added in v1.4.0
func ModelIsSupported(cmd LLMCommand, model string) bool
func ParamChecker ¶
stt
func ParamCheckerSlotsEnUS ¶
func ParamCheckerSlotsEnUS(req interface{}, intent string, slots map[string]string, isOpus bool, botSerial string)
stintent
func PerformActions ¶ added in v1.2.5
func PerformActions(msgs []openai.ChatCompletionMessage, actions []RobotAction, robot *vector.Vector) bool
func PlaceChat ¶ added in v1.1.6
func PlaceChat(chat vars.RememberedChat)
func ProcessTextAll ¶
func ProcessTextAll(req interface{}, voiceText string, intents []vars.JsonIntent, isOpus bool) bool
func Remember ¶ added in v1.1.6
func Remember(user, ai openai.ChatCompletionMessage, esn string)
remember last 16 lines of chat
func StartAnim_Queue ¶ added in v1.3.6
func StartAnim_Queue(esn string)
func StopAnim_Queue ¶ added in v1.3.6
func StopAnim_Queue(esn string)
func StreamingKGSim ¶ added in v1.1.6
func WaitForAnim_Queue ¶ added in v1.3.6
func WaitForAnim_Queue(esn string)
Types ¶
type AnimationQueue ¶ added in v1.3.6
type LLMCommand ¶ added in v1.2.5
type RobotAction ¶ added in v1.2.5
func CmdParamToAction ¶ added in v1.2.5
func CmdParamToAction(cmd, param string) RobotAction
func GetActionsFromString ¶ added in v1.2.5
func GetActionsFromString(input string) []RobotAction
Click to show internal directories.
Click to hide internal directories.