Skip to content

Commit 7ad3023

Browse files
committed
Added translations and readme
1 parent eb21e77 commit 7ad3023

File tree

3 files changed

+69
-13
lines changed

3 files changed

+69
-13
lines changed

Changelog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
RELEASE_07
2+
- Introducing VIM: Vector Instant Messaging, with emoticons. Using a shared server on the internet, different Vectors
3+
all around the world can communicate! Or you can keep it into your local network and just exchange messages
4+
with your local bots.
5+
16
RELEASE_06
27
- Added "bingo" intent: Vector pulls out the numbers from 1 to 90.
38
To pull a number, touch Vector. You can also shake it or just caress it, it reacts to touch on

README.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,41 @@ Hey Vector...
3939
- **let's play a classic**
4040
- Play Pong against Vector. You need to use the standard Vector cube. Move it up and down in front of the camera to move the left paddle correspondly.
4141
The game ends when you or Vector reach 9 points.
42+
- **let's play a classic**
43+
- **bingo**
44+
- Vector will act as a bingo machine. Rub Vector's back to have him pull out a random number between 1 and 90. You can go on until all 90 numbers are pulled out,
45+
or press the button on Vector's back to quit.
4246
All commands are fully localized in the 5 supported languages. Feel free to help with the trenslations, that can surely be improved!
4347

48+
## Instant messaging
49+
Since RELEASE_07, the VIM (Vector Instant Messaging) feature is enabled. You can run VIM server on your local network (preferred) or use a shared server (experimental).
50+
VIM Server source code is available on Github [here](https://github.com/fforchino/VIM).
51+
To enable VIM, run "sudo ./setup.sh". This will also install a daemon that checks for incoming messages for your bots.
52+
53+
Hey Vector...
54+
- **Sign up to chat service**
55+
- Signs up to chat service. You need to do this the first time only. It will use your robot name to sign up.
56+
If you haven't set one, Vector will complain.
57+
- **Login to chat service**
58+
- Logs in to chat service, provided that you have signed up before. You also need to do this just once, you will be logged in until you log out.
59+
- **Quit chat service**
60+
- Logs out to chat service. This Vector won't receive anymore messages and will appear as "away" to others.
61+
- **Chat with [username]**
62+
- Sets the chat target. For example, "Chat with Filippo". All messages will be sent to user Filippo.
63+
- **Who are you chatting with?**
64+
- Queries the chat target. In case you forgot with whom this Vector is chatting.
65+
- **Say [sentence]**
66+
- Sends a text message with payload [sentence] to the current chat target
67+
68+
When a messga is received from another user, Vector will play a tune and then say:
69+
70+
**[Human|Vector] [username] says: [sentence]**
71+
72+
In the special case that an emoticon is received, Vector will show the emoticon.
73+
Available emoticons: angel, angry, annoyed, blue, devil, disappointed, eheh, happy, heart,
74+
hmm, hurt, inlove, kiss, lol, nooo, ok, panic, polemic, sad, shades, sick, smile, star, surprised,
75+
tear, tongue, wink, wow, xxx
76+
4477
## Setup
4578
1. Install Wirepod (https://github.com/kercre123/wire-pod). In the setup procedure, choose VOSK as a TTS
4679
engine since VectorX aims to fully support localization in different languages, and VOSK is currently the

pkg/intents/voicecommand-vim.go

Lines changed: 31 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,16 @@ func VIM_Register(intentList *[]IntentDef) error {
2828
registerQueryChatTarget(intentList)
2929
registerSendMessageToChat(intentList)
3030

31-
addLocalizedString("STR_VIM_SIGN_UP_SUCCESSFUL", []string{"Sign up successful as %s1", "", "", "", ""})
32-
addLocalizedString("STR_VIM_ERROR_ALREADY_REGISTERED", []string{"Username %s1 is already registered", "", "", "", ""})
33-
addLocalizedString("STR_VIM_ERROR", []string{"Error", "", "", "", ""})
34-
addLocalizedString("STR_VIM_LOGIN_SUCCESSFUL", []string{"Logged into chat service as %s1", "", "", "", ""})
35-
addLocalizedString("STR_VIM_LOGOUT_SUCCESSFUL", []string{"Logout successful", "", "", "", ""})
36-
addLocalizedString("STR_VIM_MESSAGE_SENT", []string{"Message to %s1 sent", "", "", "", ""})
37-
addLocalizedString("STR_VIM_SEND_MESSAGE", []string{"say ", "invia ", "", "", ""})
38-
addLocalizedString("STR_USER_SAYS_MESSAGE", []string{"%s1 says: %s2", "%s1 dice: %s2", "", "", ""})
39-
addLocalizedString("STR_CHAT_TARGET_SET", []string{"chatting with %s1", "parliamo con %s1", "", "", ""})
40-
addLocalizedString("STR_CHAT_TARGET_UNKNOWN", []string{"not chatting with anyone", "non sto parlando con nessuno", "", "", ""})
31+
addLocalizedString("STR_VIM_SIGN_UP_SUCCESSFUL", []string{"Signed up as %s1", "Registrato come %s1", "Registrado como %s1", "Enregistré comme %s1", "Aufgezeichnet wie %s1"})
32+
addLocalizedString("STR_VIM_ERROR_ALREADY_REGISTERED", []string{"Username %s1 is already registered", "Il nome %s1 è già in uso", "El nombre %s1 ya está registrado", "Le nom %s1 est déjà enregistré", "Benutzername %s1 ist bereits registriert"})
33+
addLocalizedString("STR_VIM_ERROR", []string{"Error", "Errore", "Error", "Erreur", "Fehler"})
34+
addLocalizedString("STR_VIM_LOGIN_SUCCESSFUL", []string{"Logged into chat service as %s1", "", "Acceso al servicio de chat como %s1", "Connecté au service de chat comme %s1", "Zugriff auf den Chat Service wie %s1"})
35+
addLocalizedString("STR_VIM_LOGOUT_SUCCESSFUL", []string{"Logout successful", "", "Desconexión realizada", "Déconnexion réussie", "Erfolgreich abmelden"})
36+
addLocalizedString("STR_VIM_MESSAGE_SENT", []string{"Message to %s1 sent", "Messaggio inviato a %s1", "Mensaje a %s1 enviado", "Message à %s1 envoyé", "Nachricht an %s1 gesendet"})
37+
addLocalizedString("STR_VIM_SEND_MESSAGE", []string{"say ", "invia ", "decir ", "dire ", "sagen "})
38+
addLocalizedString("STR_USER_SAYS_MESSAGE", []string{"%s1 says: %s2", "%s1 dice: %s2", "%s1 dice: %s2", "%s1 dit: %s2", "%s1 sagt: %s2"})
39+
addLocalizedString("STR_CHAT_TARGET_SET", []string{"chatting with %s1", "parliamo con %s1", "Chateando con %s1", "Discuter avec %s1", "Chatten mit %s1"})
40+
addLocalizedString("STR_CHAT_TARGET_UNKNOWN", []string{"not chatting with anyone", "non sto parlando con nessuno", "No estoy chateando con nadie", "Je ne parle à personne", "Nicht mit jemandem plaudern"})
4141
}
4242
return nil
4343
}
@@ -49,7 +49,10 @@ func VIM_Register(intentList *[]IntentDef) error {
4949
func registerSignUpToChat(intentList *[]IntentDef) error {
5050
utterances := make(map[string][]string)
5151
utterances[LOCALE_ENGLISH] = []string{"sign up to chat service"}
52-
utterances[LOCALE_ITALIAN] = []string{"registrati al servizio di chat"}
52+
utterances[LOCALE_ITALIAN] = []string{"registrati alla chat"}
53+
utterances[LOCALE_SPANISH] = []string{"Regístrese en el servicio de chat"}
54+
utterances[LOCALE_FRENCH] = []string{"Inscrivez-vous au service de chat"}
55+
utterances[LOCALE_GERMAN] = []string{"Registrieren Sie sich im Chat"}
5356

5457
var intent = IntentDef{
5558
IntentName: "extended_intent_vim_signup",
@@ -91,7 +94,10 @@ func signUpToChat(intent IntentDef, speechText string, params IntentParams) stri
9194
func registerLoginToChat(intentList *[]IntentDef) error {
9295
utterances := make(map[string][]string)
9396
utterances[LOCALE_ENGLISH] = []string{"login to chat service"}
94-
utterances[LOCALE_ITALIAN] = []string{"attiva il servizio di chat"}
97+
utterances[LOCALE_ITALIAN] = []string{"accedi alla chat"}
98+
utterances[LOCALE_SPANISH] = []string{"Conéctese al chat"}
99+
utterances[LOCALE_FRENCH] = []string{"Connectez-vous au chat"}
100+
utterances[LOCALE_GERMAN] = []string{"Verbindung zum Chat herstellen"}
95101

96102
var intent = IntentDef{
97103
IntentName: "extended_intent_vim_login",
@@ -128,7 +134,10 @@ func loginToChat(intent IntentDef, speechText string, params IntentParams) strin
128134
func registerLogoutChat(intentList *[]IntentDef) error {
129135
utterances := make(map[string][]string)
130136
utterances[LOCALE_ENGLISH] = []string{"quit chat service"}
131-
utterances[LOCALE_ITALIAN] = []string{"esci dal servizio di chat"}
137+
utterances[LOCALE_ITALIAN] = []string{"esci dalla chat"}
138+
utterances[LOCALE_SPANISH] = []string{"Salir del chat"}
139+
utterances[LOCALE_FRENCH] = []string{"Sortez du chat"}
140+
utterances[LOCALE_GERMAN] = []string{"Aus dem Chat rauskommen"}
132141

133142
var intent = IntentDef{
134143
IntentName: "extended_intent_vim_logout",
@@ -166,6 +175,9 @@ func registerQueryChatTarget(intentList *[]IntentDef) error {
166175
utterances := make(map[string][]string)
167176
utterances[LOCALE_ENGLISH] = []string{"who are you chatting with"}
168177
utterances[LOCALE_ITALIAN] = []string{"con chi stai parlando"}
178+
utterances[LOCALE_SPANISH] = []string{"con quién estás hablando"}
179+
utterances[LOCALE_FRENCH] = []string{"A qui parles-tu"}
180+
utterances[LOCALE_GERMAN] = []string{"mit wem sprichst Du"}
169181

170182
var intent = IntentDef{
171183
IntentName: "extended_intent_vim_set_chat_target",
@@ -197,6 +209,9 @@ func registerSetChatTarget(intentList *[]IntentDef) error {
197209
utterances := make(map[string][]string)
198210
utterances[LOCALE_ENGLISH] = []string{"chat with"}
199211
utterances[LOCALE_ITALIAN] = []string{"parla con"}
212+
utterances[LOCALE_SPANISH] = []string{"Habla con"}
213+
utterances[LOCALE_FRENCH] = []string{"Parler à"}
214+
utterances[LOCALE_GERMAN] = []string{"Sprechen Sie mit"}
200215

201216
var intent = IntentDef{
202217
IntentName: "extended_intent_vim_set_chat_target",
@@ -226,6 +241,9 @@ func registerSendMessageToChat(intentList *[]IntentDef) error {
226241
utterances := make(map[string][]string)
227242
utterances[LOCALE_ENGLISH] = []string{"say"}
228243
utterances[LOCALE_ITALIAN] = []string{"invia"}
244+
utterances[LOCALE_SPANISH] = []string{"enviar"}
245+
utterances[LOCALE_FRENCH] = []string{"soumettre"}
246+
utterances[LOCALE_GERMAN] = []string{"senden"}
229247

230248
var intent = IntentDef{
231249
IntentName: "extended_intent_vim_message",

0 commit comments

Comments
 (0)