Professional Documents
Culture Documents
설계 및 개발
Voice User Interface & Assistant & Bots & IoT
황주필 (jupil.hwang@oracle.com)
유원조 (wonjo.yoo@oracle.com)
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted
Safe Harbor Statement
The following is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted
User Interface의 변화
CLI / GUI ??
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 3
HAL & Computer
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 4
User Interface
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 5
User Interface
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 6
User Interface – CLI
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 8
User Interface – GUI (마우스에서 손가락으로)
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 10
User Interface - Voice
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 11
Mobile Voice Interface
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 12
Voice User Interface - Wars
스마트폰에서 Apple Siri와 Google Now같은 음성인식 AI비서 서비스로
경쟁을 했지만, Amazon이 2014년 인공지능 스피커 Echo를 출시,
음성인식 소프트웨어인 Alexa의 개발자 키트를 외부에 오픈 Skill이
빠르게 늘어남 (검색, 쇼핑, 뱅킹 등등..) Echo 판매량 증가
기업명 내용
Apple - 2010년 ‘Siri’ (음성인식 소프트웨어) 인수
- 2016년 VocalIQ (음성 인터페이스) 인수
Amazon - 2011년 ‘Yap’ (STT : Speech-to-Text) 인수
- 2014년 ‘Evi’ (지식기반 Semantic Search Engine), ‘INOVA’ (TTS : Text-to-Speech) 인수
Facebook - 2013년 ‘Jibbigo’ (모바일 다국어 음성번역) 인수
- 2015년 ‘Wit.at’ (음성인식), ‘Two Big Ears’ (VR 오디오) 인수
Google - 2014년 ‘DeepMind technologies’ (AI 머신러닝) 인수
- 2016년 API.AI (음성인식, 자연어 처리) 인수, Limes Audio(음성처리) 인수
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 13
Voice User Interface - Wars
회사 이름 API / SDK
Apple Siri (2011) Siri SDK for iOS, macOS 제공, 한국어 지원
Naver Wave (2017) 음성인식 ‘Clova’ API 공개(Android iOS SDK), 일 3600초까지 무료
Kakao Kakao mini (2017) 3분기 AI앱/스피커 출시 예정, 음성인식 “뉴톤” Android,iOS SDK
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 14
Voice User Interface - Wars
• Amazon – Alexa Voice Service (AVS)
• 2015 – Alexa Skills Kit (ASK) 공개,
2017년 1분기 이용 가능한 Skills 개수가 10,000 개 (Uber호출, Amazon
물건구입, 스타벅스 커피주문 등..)
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 15
나만의 음성인식 비서를 만들어보자
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 16
DIY Alexa !
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 17
DIY Alexa !
Step 1 … 10 따라하기
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 18
DIY Alexa !
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 19
Google Assistant 는?
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 20
DIY Google Home !
• Raspberry Pi – Audio Enable • google-oauthlib-tool –client-serect
• Audio Lib 설치 /home/pi/client_id.json –scope
https://www.googleapis.com/auth/
• Python Module 설치 with pip assistant-sdk-prototype --save --
– pip install –upgrade google-assistant- headless
sdk
• googlesampeles-assistant-hotword
– pip install –upgrade google-auth-
oauthlib
• Google APIs > credentials > client id
등록 및 client-secret json
다운로드 후 oAuth tool을 통해서
credentials.json 생성
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 21
한번 보시죠
Demo
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 22
Home Automation with Google Assistant
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 23
AI Speaker - 아키텍처
Intent 파악
기본 기능
인터넷 검색
시간,날씨,메모,음악
Intent 파악
Python
Simple Http
Server
AI Speaker SDK
IR
(적외선)
Talk to
“My Action” Google
BroadLink TCP IR
Custom Assistant SDK
RM3 Mini
Action Python API
Google
Actions
https Python
Google
ngrok Simple Http
Api.AI Webhook Server
Home
Network
Server
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 27
ngrok 이란?
이미지 출처 https://ngrok.com/
직접 만들 수 있음
Receiver, Sender, LIRC BroadLink RM3 Mini
단점: 공구 비용, 단 방향
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 29
TV, 에어컨 제어 - IR (적외선)
TV
TV ON Code : 26001399401923….
Audio ON Code : 14454512345451….
Aircon ON Code : 6234973491-384…. Audio
Send SIGNAL Code IR Signal
TCP Aircon
Learn SIGNAL
192.168.1.100
192.168.1.111
사용자 추가 기기
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 30
TV, 에어컨 제어 - Code
pi@raspberrypi:~/rm3/python-broadlink/cli $ ls
README.md aircon.turnoff broadlink_discovery tv.channel1 tv.channel5 tv.channel9 tv.turnon
aircon.downtemp aircon.turnon MyHomeServer.py tv.channel2 tv.channel6 tv.channeldown tv.volumedown
aircon.morewind aircon.uptemp device.info tv.channel3 tv.channel7 tv.channelup tv.volumeup
aircon.smallwind broadlink_cli tv.channel0 tv.channel4 tv.channel8 tv.turnoff
pi@raspberrypi:~/rm3/python-broadlink/cli $ ./broadlink_cli -h
usage: broadlink_cli [--device DEVICE] [--type TYPE] [--host HOST] [--send SEND] [--sensors] [--learn] [--learnfile
LEARNFILE]
--send SEND send command
--learnfile LEARNFILE learn command and save to specified file
https://github.com/mjg59/python-broadlink
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 31
TV, 에어컨 제어 - Code
if command == 'channel':
if level != '':
if level == '11':
exeCmd = './broadlink_cli --send @' + device + '.' + command + "1"
subprocess.call(shlex.split(exeCmd))
exeCmd = './broadlink_cli --send @' + device + '.' + command + "1"
subprocess.call(shlex.split(exeCmd))
elif command == 'volumedown' or command == 'volumeup':
for i in range(1,numlevel):
exeCmd = './broadlink_cli --send @' + device + '.' + command
subprocess.call(shlex.split(exeCmd))
...
...
def run(server_class=HTTPServer, handler_class=S, port=9876):
server_address = ('', port)
httpd = server_class(server_address, handler_class) Python BroadLink
print("Starting httpd... 9876") Simple Http RM3 Mini
httpd.serve_forever() Server Python API
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 32
Oracle Bot Integration with Alexa
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 33
Live Demo - Pizza 주문
피자주문
접속 요청 사이즈
피자 종류
사이드
User
결제수단
기존 카드 정보 확인
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 34
Oracle Bot Integration with Alexa - 아키텍처
Cloud
Oracle Intelligent Bot
ask
Amazon “Oracle Pizza” Channel
Custom AI
AVS SDK Alexa Skill Welcome to Components Engine
(Oracle Pizza) oracle pizza
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 35
Alexa Skill 설정
{
"intents": [
{
"slots": [
{
"name": "command",
"type": "LITERAL"
}
],
"intent": "CommandBot"
},
{
"intent": "AMAZON.StopIntent"
}
]
}
Skill invocation name Intent schema
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 36
Oracle Intelligent Bot 의 Alexa Channel 설정
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 37
Oracle Intelligent Bot 동작방식
메시지 수신 처리를 위한 특정 정보 기억
Entity
1 Utterance 3
Intent
의미 파악 답변 수행
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 38
Oracle Intelligent Bot 의 Intent, Entity 설정
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 39
Web기반 음성인식 with Oracle Bot
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 40
Web기반 음성인식 with Oracle Intelligent Bot
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 41
Live Demo - 한국어 음성인식 Oracle Bot Demo
recognition.onresult = function(event) {
var interim_transcript = '';
for (var i = event.resultIndex; i < event.results.length; ++i) {
if (event.results[i].isFinal) {
var recData = event.results[i][0].transcript;
sendToBot(recData); Ajax로 Oracle
Bot 호출
...
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 43
Summary
• AI Speaker 시장의 확대
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 44
Let’s go home to Code!!
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 45
Safe Harbor Statement
The preceding is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 46