LoginSignup
1
0

More than 3 years have passed since last update.

無料のOpenShift on IBM CloudでWatson音声認識アプリを試す。

Last updated at Posted at 2020-10-06

無料で試せるOpenShiftアプリ、今回はWatsonの音声認識を試してみました。
元ネタはこちらです。
https://developer.ibm.com/patterns/transcribe-audio-in-real-time-or-from-an-audio-file/
Githubのページはこちら
https://github.com/IBM/speech-to-text-code-pattern/blob/master/README.md

アプリ画面は
image.png
 左下のメニューでサンプル音声を再生したり、パソコンの音声で試したり、音声ファイルをアップロードしたりして音声認識を試せます。

やり方は
- OpenShiftの準備
- Watson Speech to Textサービスの作成
- OpenShiftのポータルでデプロイ

OpenShiftの準備

https://qiita.com/osonoi/items/a5d3a5fe78455c842f42 のページに上の方法を使ってOpenShiftのコンソール画面に行ってください。
IBM Demos https://www.ibm.com/demos/

Watson Speech to Textサービスの作成

IBM Cloudのページにログイン、カタログからSpeech to textを作成してください。
image.png
作成したらSpeech to textのページンい行ってAPI Key, URLをどこかにコピーしておいてください。
image.png

OpenShiftのポータルでデプロイ

最初にS2Iを使ってアプリをデプロイします。
左上のAdministratorをDeveloperにして”From Git"を選択
URLは https://github.com/IBM/speech-to-text-code-pattern
言語はnode.jsを選択します。
image.png

そのあとは手順通りにやればいいのですが、私はconfig mapではなくSecretでやりました。
https://github.com/IBM/speech-to-text-code-pattern/blob/master/doc/source/openshift.md
Secretの作り方はProject DetailsからSecretをクリック
image.png
"Create" --> "Key?Value Secret"を選択
image.png
一つ一つ入れていきます。
image.png
入力するのは下の4つ。先ほどIBM Cloud, Speech to textでコピーしたAPI Key, URLを使ってください。
image.png
入力したらSaveしてアプリに関連づけてください。
image.png
自動的にデプロイされます。Topologyを見て下さい。
image.png
Routeをクリックするとアプリは面がブラウザーの別タブで開きます。
image.png

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0