padosory5 / elaina1.0

【 Unity x Live2d x NaverClova x DL 】 Personal Assistant bot that has an avatar from Live2d and connecting it with Unity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

elaina1.0

Elaina is a personal voice assitant bot with an avatar. It has functions to help people in their daily lives.


Development environment

  • Operating System : Windows 10 64 bit
  • Network Socket : TCP (Transmission Control Protocol)
  • Language : C#, Python
  • Model Algorith : Deep Learning
  • Voice : Naver CLOVA Voice
  • Voice Recognition : Google Voice Search
  • Engine : Unity
  • Model : Live2d Cubism
  • Environment : python 3.7 Anaconda 4.8

API

Google supports Speech-To-Text for everyone. Therefore, it can read out the voice and transform it to a text. and that text will be sent to speak function. With the support from Naver Clova Premium Voice product it is able to read out the texts that are being generated.

def speak(audio_string):
    encText = urllib.parse.quote(audio_string)
    data = "speaker=nbora&volume=0&speed=0&pitch=1&format=mp3&text=" + encText
    url = "https://naveropenapi.apigw.ntruss.com/tts-premium/v1/tts"
    request = urllib.request.Request(url)
    request.add_header("X-NCP-APIGW-API-KEY-ID", client_id)
    request.add_header("X-NCP-APIGW-API-KEY", client_secret)
    response = urllib.request.urlopen(request, data=data.encode('UTF-8'))
    rescode = response.getcode()
    if(rescode == 200):
        print(audio_string)
        response_body = response.read()
        with open('1111.mp3', 'wb') as f:
            f.write(response_body)
        playsound.playsound("1111.mp3")
        os.remove("1111.mp3")
    else:
        print("Error Code:" + rescode)

more infomration about this API can be explained in here https://api.ncloud-docs.com/docs/en/ai-naver-clovavoice-ttspremium


Functions

  • File generate, add_content, type ⚠️
  • searching through google ⚠️
  • playing music ❌
  • alarm ❌
  • schedule ❌
  • remote control (ex : Air conditioning, television, curtains) ❌
  • time, date, weather ❌
  • message response ❌

✔️ : fully operating ⚠️ : working in progress ❌ : not operating

There will be further updates on the fucntion.

About

【 Unity x Live2d x NaverClova x DL 】 Personal Assistant bot that has an avatar from Live2d and connecting it with Unity

License:MIT License


Languages

Language:Python 78.0%Language:C# 20.9%Language:Batchfile 1.1%