-
IBM Watson Assistant와 slack 연동하기프로젝트/IBM C:Louders 2020. 9. 21. 18:14
이번엔 지난 포스팅에서 사용해보았던 watson assistant를 slack과 연동해보려고 해요!
저는 도서 대여나 구매를 위한 챗봇을 만들어보고자 했어요🔔
챗봇이 제가 원하는 대화를 수행하도록 하기 위해 간단한 intent들을 생성하고, dialog를 구성해보았습니다!
assistant를 수행해보니, 학습은 잘 된듯 하네요
이제 이 assistant를 slack과 연동해볼까요?
0. Slack API 사이트에서 app을 생성하기
Slack API 사이트에 접속하여
app을 생성한 뒤, token을 발급받습니다.
(Basic Information > App Credential Tab에서 발급받은 token을 확인해 볼 수 있습니다)
1. Slack과 연동하기
assistant 상세 페이지에서, 오른쪽의 integration 메뉴를 클릭하고, slack을 선택합니다
잠시 Slack App settings 페이지로 돌아갈게요!
OAuth & Permissions > Bot Token Scopes 탭에서 Add an Oauth scope 버튼을 클릭하여, 다음 scope들을 추가해주고,
OAuth & Permissions > Install App to Workspace를 수행, Allow 버튼을 클릭하면, OAuth access token이 생성됩니다
token 발급이 끝났으니, 이제 assistant integration 페이지로 다시 돌아옵니다
Step2 <Connect Watson Assistant to Slack>의 1번 항목에는 발급받은 app verification token을,
3번 항목에는 bot user OAuth access token을 넣어주세요!
Step3 <Configure your Slack bot>에서 URL을 생성한 뒤,
Slack App Settings 페이지의 Event Subscription tab에서 Enable Events를 toggle시키고, 생성한 URL을 넣어줍니다.
하단의 Subscribe to bot events tab에서 Add Bot User Event 버튼을 클릭, 다음 event들을 추가해주고
Save Changes를 수행하면 끝!
slack에 보여질 챗봇 프로필은 Basic Information > Display Information tab에서 설정할 수 있어요
이제 slack에서 챗봇과 대화를 해볼까요?
조사까지 일일이 예제와 동일하게 적어주어야 대화가 되네요ㅜㅜ 똑똑하진 않아요,,,
그래도 intent에 입력된 예제들에 한해서는 대답을 잘 수행해줍니다!
오늘도 한층 업그레이드된 slack 홀릭,,💜
'프로젝트 > IBM C:Louders' 카테고리의 다른 글
C:Louders와 함께, 7월부터 9월까지. (0) 2020.09.22 IBM Watson Assistant 사용하기 (0) 2020.09.10 IBM Watson의 Visual Recognition을 활용한 iOS에서의 머신러닝 (0) 2020.08.03 [IBM C:Loud Essential] module2. Infrastructure Services (0) 2020.07.25 [IBM C:Loud Essential] module1. Introduction to the IBM Cloud (0) 2020.07.20