You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
samHomeAssistantTool=schema.NewTool("get_home_devices", "Return information about home devices")
28
-
samSystemPrompt=`Your name is Samantha, you are a personal assistant modelled on the personality of Samantha from the movie "Her". Your responses should be short and friendly.`
23
+
samName="sam"
24
+
samWeatherTool=schema.NewTool("get_current_weather", "Get the current weather conditions for a location")
25
+
samNewsHeadlinesTool=schema.NewTool("get_news_headlines", "Get the news headlines")
samHomeAssistantTool=schema.NewTool("get_home_devices", "Return information about home devices by type, including their state and entity_id")
28
+
samHomeAssistantSearch=schema.NewTool("search_home_devices", "Return information about home devices by name, including their state and entity_id")
29
+
samHomeAssistantTurnOn=schema.NewTool("turn_on_device", "Turn on a device")
30
+
samHomeAssistantTurnOff=schema.NewTool("turn_off_device", "Turn off a device")
31
+
samSystemPrompt=`Your name is Samantha, you are a personal assistant modelled on the personality of Samantha from the movie "Her". Your responses should be short and friendly.`
iferr:=samNewsSearchTool.AddParameter("query", "The query with which to search news", true); err!=nil {
75
78
returnerr
76
79
}
77
-
iferr:=samHomeAssistantTool.AddParameter("class", "The class of device, which should be one or more of door,lock,occupancy,motion,climate,light,switch,sensor,speaker,media_player,temperature,humidity,battery,tv,remote,light,vacuum separated by spaces", true); err!=nil {
80
+
iferr:=samHomeAssistantTool.AddParameter("type", "Query for a device type, which could one or more of door,lock,occupancy,motion,climate,light,switch,sensor,speaker,media_player,temperature,humidity,battery,tv,remote,light,vacuum separated by spaces", true); err!=nil {
81
+
returnerr
82
+
}
83
+
iferr:=samHomeAssistantSearch.AddParameter("name", "Search for device state by name", true); err!=nil {
84
+
returnerr
85
+
}
86
+
iferr:=samHomeAssistantTurnOn.AddParameter("entity_id", "The device entity_id to turn on", true); err!=nil {
87
+
returnerr
88
+
}
89
+
iferr:=samHomeAssistantTurnOff.AddParameter("entity_id", "The device entity_id to turn off", true); err!=nil {
0 commit comments