Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
米国カンファレンスで活躍したAzure AI Speech
Search
Yuta Matsumura
February 03, 2024
Technology
0
820
米国カンファレンスで活躍したAzure AI Speech
Fukuoka.NET Conf 2023 での登壇資料です
https://fukuten.connpass.com/event/303390/
Yuta Matsumura
February 03, 2024
Tweet
Share
More Decks by Yuta Matsumura
See All by Yuta Matsumura
Cloudflare の MCP サーバーをためしてみた
tsubakimoto_s
1
29
re:Invent の裏でアップデートされていた .NET Aspire で統合するAWS のクラウドリソース
tsubakimoto_s
1
97
.NET AspireでAzure Functionsやクラウドリソースを統合する
tsubakimoto_s
0
300
Microsoft Entra External IDとAzure AD B2C
tsubakimoto_s
0
1.6k
Minimal Observability on Minimal API
tsubakimoto_s
0
110
ワークフローのコピペを自作で解消した話
tsubakimoto_s
0
84
Azure AI ことはじめ
tsubakimoto_s
0
670
Azureのコアサーバーレス Azure Functions
tsubakimoto_s
0
670
GitHub Codespaces Updates
tsubakimoto_s
0
540
Other Decks in Technology
See All in Technology
テストを軸にした生き残り術
kworkdev
PRO
0
220
[ JAWS-UG 東京 CommunityBuilders Night #2 ]SlackとAmazon Q Developerで 運用効率化を模索する
sh_fk2
3
460
20250913_JAWS_sysad_kobe
takuyay0ne
2
250
AWSを利用する上で知っておきたい名前解決のはなし(10分版)
nagisa53
10
3.2k
「何となくテストする」を卒業するためにプロダクトが動く仕組みを理解しよう
kawabeaver
0
440
KotlinConf 2025_イベントレポート
sony
1
140
Snowflake Intelligence × Document AIで“使いにくいデータ”を“使えるデータ”に
kevinrobot34
1
120
企業の生成AIガバナンスにおけるエージェントとセキュリティ
lycorptech_jp
PRO
2
200
Oracle Cloud Infrastructure IaaS 新機能アップデート 2025/06 - 2025/08
oracle4engineer
PRO
0
110
Automating Web Accessibility Testing with AI Agents
maminami373
0
1.3k
roppongirb_20250911
igaiga
1
250
Generative AI Japan 第一回生成AI実践研究会「AI駆動開発の現在地──ブレイクスルーの鍵を握るのはデータ領域」
shisyu_gaku
0
330
Featured
See All Featured
Why You Should Never Use an ORM
jnunemaker
PRO
59
9.5k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
1.6k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
31
2.2k
Keith and Marios Guide to Fast Websites
keithpitt
411
22k
KATA
mclloyd
32
14k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
18
1.1k
A better future with KSS
kneath
239
17k
Code Review Best Practice
trishagee
71
19k
How STYLIGHT went responsive
nonsquared
100
5.8k
Reflections from 52 weeks, 52 projects
jeffersonlam
352
21k
The World Runs on Bad Software
bkeepers
PRO
70
11k
Transcript
#fukuten 米国カンファレンスで活躍した Azure AI Speech Fukuoka.NET Conf 2023 Yuta Matsumura
© 2023 Yuta Matsumura. #fukuten
#fukuten 松村 優大 (MLBお兄さん) Currently working for © 2023 Yuta
Matsumura. 株式会社オルターブース Chief Technical Architect Microsoft MVP for Developer Technologies Microsoft Top Partner Engineer Award C#, PHP, Azure, GitHub が好き #fukuten #devblogradio の中の人 @tsubakimoto_s
#fukuten © 2023 Yuta Matsumura.
#fukuten © 2023 Yuta Matsumura.
#fukuten © 2023 Yuta Matsumura.
#fukuten 海外カンファレンスに参加する気持ち • 発表はすべて英語です(当然) • 英語は得意じゃないけど、どんな内容が話されているかを 知りたい • 現地での熱量を体感したい •
スピーカーの小ネタで一緒に笑いたい © 2023 Yuta Matsumura.
#fukuten 翻訳アプリを探す旅が始まる 要件 • 英語を日本語に翻訳 • 音声でのリアルタイム翻訳 • 文字起こし •
翻訳結果の保存 • 長時間の翻訳 • PC で使いたい • なるべく安く © 2023 Yuta Matsumura.
#fukuten コレ!というアプリが見つからない ▼ 自分で作ろう © 2023 Yuta Matsumura.
#fukuten コレ!というアプリが見つからない ▼ 自分で作ろう ▼ Ignite 前日の夜中 © 2023 Yuta
Matsumura.
#fukuten © 2023 Yuta Matsumura. Azure AI Speech
#fukuten Azure AI Speech とは © 2023 Yuta Matsumura. テキスト読み上げ
リアルタイム翻訳 話者の認識 カスタムキーワード 音声コマンド 音声テキスト変換 Azure AI 音声 | Microsoft Azure
#fukuten Azure Cognitive Services ▼ Azure Applied AI Services ▼
Azure AI Services © 2023 Yuta Matsumura.
#fukuten © 2023 Yuta Matsumura. ①PCマイクで 音声入力 ②文字起こし &翻訳 ③英&日の出力
④テキストファイル に保存
#fukuten Azure AI Speech とは © 2023 Yuta Matsumura. 音声テキスト変換
テキスト読み上げ リアルタイム翻訳 話者の認識 カスタムキーワード 音声コマンド
#fukuten 候補言語 • Azure AI Speech でオーディオから検出する言語の指定 • 最大10個の候補を指定可能 •
“ja-JP”, “en-US” などを BCP-47 形式で指定 (言語+ロケール) • 同一言語で複数ロケールは指定不可 (例:“en-US”, “en-GB”) © 2023 Yuta Matsumura. 言語サポート - 音声サービス - Azure AI services | Microsoft Learn
#fukuten 言語識別 (Language identification / LID) 開始時識別 (1回識別) オーディオの最初の数秒間で言語の識別を1回行う 継続的識別
オーディオが再生している間は言語の識別を継続的に行う © 2023 Yuta Matsumura. 言語識別 - Speech サービス - Azure AI services | Microsoft Learn
#fukuten 翻訳エンジンのイベント イベント 内容 Canceled 音声からテキスト/合成への翻訳が取り消されたことを通知します。 Recognized 最終的な認識結果が受信されたことを通知します。 Recognizing 中間認識結果が受信されたことを通知します。
SessionStarted セッション開始イベントのイベント ハンドラーを定義します。 SessionStopped セッション停止イベントのイベント ハンドラーを定義します。 SpeechEndDetected 音声終了検出イベントのイベント ハンドラーを定義します。 SpeechStartDetected 音声開始検出イベントのイベント ハンドラーを定義します。 Synthesizing 変換合成結果が受信されたことを通知します。 © 2023 Yuta Matsumura. TranslationRecognizer クラス (Microsoft.CognitiveServices.Speech.Translation) - Azure for .NET Developers | Microsoft Learn
#fukuten TranslationRecognizer.Recognized イベント TranslationRecognitionEventArgs クラス (イベント引数) Result プロパティ (TranslationRecognitionResult クラス)
Reason プロパティ:音声認識結果 Text プロパティ:識別されたテキスト Translations プロパティ:翻訳結果 © 2023 Yuta Matsumura.
#fukuten ライブデモ © 2023 Yuta Matsumura. speech translator ミキサー
#fukuten ソースコード © 2023 Yuta Matsumura.
#fukuten tsubakimoto/speech-translator https://github.com/tsubakimoto/speech-translator © 2023 Yuta Matsumura.
#fukuten // 音声翻訳の構成 var config = SpeechTranslationConfig.FromEndpoint( endpointUrl, subscriptionKey); config.SpeechRecognitionLanguage
= "en-US"; config.AddTargetLanguage("ja-JP"); var detectConfig = AutoDetectSourceLanguageConfig.FromLanguages( [config.SpeechRecognitionLanguage]); var stopTranslation = new TaskCompletionSource<int>(); © 2023 Yuta Matsumura.
#fukuten // 既定の音声入力デバイスから識別 using (var audioInput = AudioConfig.FromDefaultMicrophoneInput()) using (var
recognizer = new TranslationRecognizer( config, detectConfig, audioInput)) { // 識別結果受信時のイベント処理 recognizer.Recognized += (s, e) => { 次のスライド }; // 継続的識別の開始 await recognizer.StartContinuousRecognitionAsync() .ConfigureAwait(false); // 継続的識別の停止 Task.WaitAny(new[] { stopTranslation.Task }); await recognizer.StopContinuousRecognitionAsync() .ConfigureAwait(false); } © 2023 Yuta Matsumura.
#fukuten // 識別結果受信時のイベント処理 recognizer.Recognized += (s, e) => { var
result = e.Result; if (result.Reason == ResultReason.TranslatedSpeech) { using (var sw = new StreamWriter(_filePath, true, Encoding.UTF8)) { Console.WriteLine($"{result.Text}"); // 識別テキストの標準出力 sw.WriteLine($"{result.Text}"); // 識別テキストのファイル出力 foreach (var element in result.Translations) { Console.WriteLine($"{element.Value}");// 翻訳テキストの標準出力 sw.WriteLine($"{element.Value}"); // 翻訳テキストのファイル出力 } } } }; © 2023 Yuta Matsumura.
#fukuten GitHub Codespaces GitHub 上にホストされる仮想マシンを使用して、 オンライン上に開発環境を構築することができます。 devcontainer.json をリポジトリに保管している場合、 記載されている構成がセットアップされます。 ©
2023 Yuta Matsumura.
#fukuten https://github.com/github/dotnet-codespaces © 2023 Yuta Matsumura.
#fukuten tsubakimoto/speech-translator © 2023 Yuta Matsumura. AOAIで色々やりたい・・・ .NET MAUI でモバイル版を作りたい
PR 待ってます!
#fukuten ご清聴ありがとうございました © 2023 Yuta Matsumura.