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
Chatting with Japanese using Firebase Extensions
Search
Firebase Thailand
November 09, 2019
Technology
0
300
Chatting with Japanese using Firebase Extensions
Get to know how to build Translator Chatbot in LINE using Firebase Extensions
Firebase Thailand
November 09, 2019
Tweet
Share
More Decks by Firebase Thailand
See All by Firebase Thailand
What's New in Firebase 2024
firebasethailand
1
230
Adding New Capabilities to Your Apps with Firebase and Gemini API
firebasethailand
1
220
Say Hello to Cloud Functions for Firebase 2nd Gen
firebasethailand
1
400
What's New in Firebase 2023
firebasethailand
3
580
Building a more Efficient Firestore Web App
firebasethailand
1
180
Developing with Firebase - Best Practices
firebasethailand
0
180
Analyze your production issue on Firebase Crashlytics more efficient with BigQuery
firebasethailand
0
400
What I learn from Firebase when build Saifah
firebasethailand
0
130
Security Rules Unit Testing Pipeline Integration for Firestore
firebasethailand
0
130
Other Decks in Technology
See All in Technology
AI導入の理想と現実~コストと浸透〜
oprstchn
0
150
タイミーのデータモデリング事例と今後のチャレンジ
ttccddtoki
4
1.4k
あなたの声を届けよう! 女性エンジニア登壇の意義とアウトプット実践ガイド #wttjp / Call for Your Voice
kondoyuko
4
510
さくらのIaaS基盤のモニタリングとOpenTelemetry/OSC Hokkaido 2025
fujiwara3
2
240
KubeCon + CloudNativeCon Japan 2025 Recap Opening & Choose Your Own Adventureシリーズまとめ
mmmatsuda
0
230
論文紹介:LLMDet (CVPR2025 Highlight)
tattaka
0
240
React開発にStorybookとCopilotを導入して、爆速でUIを編集・確認する方法
yu_kod
1
100
なぜ私はいま、ここにいるのか? #もがく中堅デザイナー #プロダクトデザイナー
bengo4com
0
1.3k
WordPressから ヘッドレスCMSへ! Storyblokへの移行プロセス
nyata
0
340
使いたいMCPサーバーはWeb APIをラップして自分で作る #QiitaBash
bengo4com
0
1.3k
Zephyr RTOSを使った開発コンペに参加した件
iotengineer22
0
140
Understanding_Thread_Tuning_for_Inference_Servers_of_Deep_Models.pdf
lycorptech_jp
PRO
0
150
Featured
See All Featured
How GitHub (no longer) Works
holman
314
140k
What’s in a name? Adding method to the madness
productmarketing
PRO
23
3.5k
Keith and Marios Guide to Fast Websites
keithpitt
411
22k
[RailsConf 2023] Rails as a piece of cake
palkan
55
5.6k
Visualization
eitanlees
146
16k
YesSQL, Process and Tooling at Scale
rocio
173
14k
Testing 201, or: Great Expectations
jmmastey
42
7.6k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
233
17k
Six Lessons from altMBA
skipperchong
28
3.9k
What's in a price? How to price your products and services
michaelherold
246
12k
Building Better People: How to give real-time feedback that sticks.
wjessup
367
19k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
5
230
Transcript
GDG Thailand Firebase Thailand Organized by Chatting with Japanese using
Firebase Extensions Firebase Extensionsを使用して日本人とチャットする Warit Wanwithu LINE Thailand
#FirebaseDevDay DEVELOPERS นักพัฒนา デベロッパーズ
#FirebaseDevDay “How’s it Going” “Hello!”
None
#FirebaseDevDay Sending Email Resize Images Deleted User Data
https://github.com/firebase/functions-samples
#FirebaseDevDay ファイアーベース エクステンションズ
None
#FirebaseDevDay Install Functions Firestore Send email
None
#FirebaseDevDay DEMO デモ
#FirebaseDevDay CHATTING チャッティング
#FirebaseDevDay Functions Extensions Firestore 1.Webhook 2.Save 3.Translated 5.Push 4.Trigger
#FirebaseDevDay ❤ 0. Install Translation extension 1. Create LINE Chatbot
2. Handle LINE Webhook using Cloud Functions and save to Firestore 3. Listen to Firestore trigger and push message back to LINE group
1. Create LINE Chatbot https://developers.line.biz/
#FirebaseDevDay { "destination": "xxxxxxxxxx", "events": [{ "replyToken": "0f3779fba3b349968c5d07db31eab56f", "type": "message",
"timestamp": 1462629479859, "source": { "type": "user", "userId": "U4af4980629..." }, "message": { "id": "325708", "type": "text", "text": "Hello" } }]} 2. Handle LINE Webhook
#FirebaseDevDay exports.LineWebhook = functions.region(region).runWith(runtimeOpts) .https.onRequest(async (req, res) => { let
event = req.body.events[0]; if (event.message.type === 'text') { let input = event.message.text; await admin.firestore().collection('translations').doc('inputText') .set({ input: input }); } return res.status(200).send(req.method);; });
#FirebaseDevDay Functions Extensions Firestore Webhook Save Translated Push Trigger 3.
Listen to Firestore trigger
#FirebaseDevDay exports.LineBotPush = functions.region(region).runWith(runtimeOpts) .firestore.document('translations/inputText').onWrite(async (change, context) => { let
latest = change.after.data(); let input = latest.input; let containsJapanese = input.match(/[\u3000-\u303f\u3040-...]/); if (containsJapanese) { push(GROUP_ID, latest.translated.th); } else { push(GROUP_ID, latest.translated.ja); } });
None
#FirebaseDevDay MISSION ミッション
#FirebaseDevDay INSTALL CLOUD FUNCTIONS OPEN SOURCE CONFIG BETA
Thank You! #FirebaseDevDay Helpful resources fb.com/LINEDevTH fb.com/groups/LINEDevTH medium.com/LINEDevTH Warit Wanwithu
ありがとうございます