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
LangChainを使ってChatGPTの機能を拡張してみた ~過去の会話やGoogle検索結...
Search
TakaakiKakei
July 10, 2023
Technology
1
2.4k
LangChainを使ってChatGPTの機能を拡張してみた ~過去の会話やGoogle検索結果を活用して自然な応答を生成する方法~ #DevIO2023
DevelopersIO 2023 で発表した資料です。
TakaakiKakei
July 10, 2023
Tweet
Share
More Decks by TakaakiKakei
See All by TakaakiKakei
re:Invent 2024 生成AIまとめ
takaakikakei
0
330
OpenAIのAssistants API(Beta)の概要と使い方
takaakikakei
0
440
企業向け生成AIアプリの 開発から得られた知見
takaakikakei
0
540
「AWSによる独自データ活用の生成AIソリューション」というタイトルでCM re:Growth 2023に登壇しました #AWSreInvent #cmregrowth
takaakikakei
0
980
Slack Boltコース!AWS Lambda & Pythonのビキナー仕立て #devio2022
takaakikakei
0
5.3k
AWS Step Functions上でエラーが発生した場合の効果的な通知方法を検討してみた
takaakikakei
0
7.3k
Other Decks in Technology
See All in Technology
「隙間家具OSS」に至る道/Fujiwara Tech Conference 2025
fujiwara3
7
6.4k
CDKのコードレビューを楽にするパッケージcdk-mentorを作ってみた/cdk-mentor
tomoki10
0
210
Formal Development of Operating Systems in Rust
riru
1
420
Cloudflareで実現する AIエージェント ワークフロー基盤
kmd09
0
290
2025年のARグラスの潮流
kotauchisunsun
0
790
30分でわかる「リスクから学ぶKubernetesコンテナセキュリティ」/30min-k8s-container-sec
mochizuki875
3
440
.NET AspireでAzure Functionsやクラウドリソースを統合する
tsubakimoto_s
0
190
I could be Wrong!! - Learning from Agile Experts
kawaguti
PRO
8
3.4k
2024年活動報告会(人材育成推進WG・ビジネスサブWG) / 20250114-OIDF-J-EduWG-BizSWG
oidfj
0
220
月間60万ユーザーを抱える 個人開発サービス「Walica」の 技術スタック変遷
miyachin
1
140
2024AWSで個人的にアツかったアップデート
nagisa53
1
110
.NET 最新アップデート ~ AI とクラウド時代のアプリモダナイゼーション
chack411
0
200
Featured
See All Featured
Dealing with People You Can't Stand - Big Design 2015
cassininazir
365
25k
Agile that works and the tools we love
rasmusluckow
328
21k
How to train your dragon (web standard)
notwaldorf
89
5.8k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.2k
Building Your Own Lightsaber
phodgson
104
6.2k
Done Done
chrislema
182
16k
Why Our Code Smells
bkeepers
PRO
335
57k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Faster Mobile Websites
deanohume
305
30k
The World Runs on Bad Software
bkeepers
PRO
66
11k
Optimising Largest Contentful Paint
csswizardry
33
3k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.1k
Transcript
LangChainΛͬͯ ChatGPTͷػೳΛ֦ுͯ͠Έͨ ~աڈͷձGoogleݕࡧ݁ՌΛ׆༻ ͯࣗ͠વͳԠΛੜ͢Δํ๏~ 2023/07/08 ߶জʢTakaaki Kakeiʣ
Hello!! ߶জʢTakaaki Kakeiʣ •AWSࣄۀຊ෦ΦϖϨʔγϣϯ෦ αʔϏεάϩʔενʔϜ •ΫϥεϝιουϝϯόʔζΛ ࢧ͑Δ։ൃΛ୲ •ٱ͠ͿΓͷϥΠϒηογϣϯͰ ϫΫϫΫ͍ͯ͠·͢ʂ
2 ɾ2023-2021 Japan AWS Top Engineers ɾ2023-2022 Japan AWS All Certifications Engineers ɾhttps://dev.classmethod.jp/author/kakei-takaaki/ ɾhttps://zenn.dev/t_kakei ɾhttps://twitter.com/TakaakiKakei
ChatGPTͱ •OpenAI͕202211݄ʹެ։ͨ͠ਓೳνϟοτϘοτ •ਓؒͷΑ͏ͳࣗવͳձ͕Ͱ͖Δ •จষͷཁɾ༁ɾϓϩάϥϜͷੜͳͲɺ༷ʑͳλεΫΛ ࣮ߦՄೳ 3 ຊʹೖΔલʹ͓͞Β͍
େنݴޠϞσϧʢLLMʣͱ •େྔͷςΩετσʔλΛͬͯτϨʔχϯά͞Εͨࣗવݴޠ ॲཧͷϞσϧ •ChatGPTɿGPT-3.5 / GPT-4 4 ͓͞Β͍2
OpenAI APIͱ •OpenAIͷLLMʢGPT-3ͳͲʣ ʹAPIͰΞΫηε͢Δ͜ͱΛ Մೳʹͨ͠ϓϥοτϑΥʔϜ •։ൃऀ͕ࣗͷΞϓϦέʔ γϣϯʹLLMͷػೳΛΈࠐ Ήࡍʹར༻Ͱ͖Δ 5 ͓͞Β͍3
IUUQTQMBUGPSNPQFOBJDPNEPDT HVJEFTHQUDIBUDPNQMFUJPOTBQJ
IUUQTHJUIVCDPNIXDIBTFMBOHDIBJO LangChain 6
LLMΛ׆༻ͨ͠ߴͳΞϓϦέʔγϣϯͷ։ൃΛָʹ͠ ͯ͘ΕΔϑϨʔϜϫʔΫ •LLMͱGoogleݕࡧΛ࿈ܞͨ͠ΞϓϦ •ࢦఆτʔΫϯͰձཤྺΛͭΞϓϦ •ಠࣗσʔλΛݩʹճ͢ΔΞϓϦ 7 LangChainͱ
•ศརϞδϡʔϧ͕༻ҙ͞Ε͓ͯΓɺͦΕΒΛΈ߹ΘͤΔ͜ ͱͰɺෳࡶͳॲཧΛߦ͏ΞϓϦέʔγϣϯ͕։ൃͰ͖Δɻ •OpenAIͷLLMҎ֎ɺ༷ʑͳLLMΛαϙʔτ͍ͯ͠Δɻ •GoogleݕࡧͳͲ࿈ܞՄೳͳ֎෦αʔϏεଟ͘αϙʔτɻ •PythonJavaScript / TypeScriptͰར༻Մೳɻ 8 LangChainͷಛ
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 9
•ϓϩάϥϜΛಈ͔͢ϋʔυϧ͕Լ͕Δ͜ͱ •LangChainͷརͱ༻ํ๏ʹؔ͢Δཧղ͕ਂ·Δ͜ͱ •LangChainΛར༻ͨ͠LLMͷΞϓϦέʔγϣϯެ։ͷݟ ΛਂΊΔ͜ͱ 10 ຊηογϣϯͷඪ
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 11
(PPHMF$PMBCPSBUPSZʢུশɿ$PMBCʣ IUUQTDPMBCSFTFBSDIHPPHMFDPN ͓͢͢Ίͷ։ൃڥ 12
ॆͳ։ൃڥ •ڥߏஙෆཁͰPythonίʔυΛهड़ɺ࣮ߦͰ͖Δ •GoogleΞΧϯτ͕͋Εϒϥβܦ༝Ͱ͙͢ʹ͑Δ •ແྉͷGPUΛఏڙ͓ͯ͠ΓɺߴͳܭࢉΛߦ͑Δ •Google Driveͱͷ࿈ܞͰɺೖग़ྗͷظอଘ͕Մೳ •ແྉϓϥϯͷ߹ɺ࠷Ͱ12࣮࣌ؒߦՄೳ 13 Colabͷಛ
(PPHMFΞΧϯτʹϩάΠϯͨ͠ঢ়ଶͰɺ$PMBCͷ63-ʹΞΫηε IUUQTDPMBCSFTFBSDIHPPHMFDPN Colabͷར༻ํ๏ 14
ʮϊʔτϒοΫΛ৽ن࡞ʯΛΫϦοΫ Colabͷར༻ํ๏ 15
৽͍͠ϊʔτϒοΫ͕։͖ɺۭͷηϧ͕දࣔ͞ΕΔ 16 Colabͷར༻ํ๏
ηϧʹίʔυΛهड़Ͱ͖Δ Colabͷར༻ํ๏ 17
ʮηϧͷ࣮ߦʯϘλϯΛԡ͢ͱɺηϧͷίʔυ͕࣮ߦ͞ΕΔ Colabͷར༻ํ๏ 18
ʮ ίʔυʯΛΫϦοΫ͢Δͱɺηϧ͕Ճ͞Ε Ճͷίʔυ͕ೖྗͰ͖Δ Colabͷར༻ํ๏ 19
20 ChatGPTͷAPIΛಈ͔ͯ͠ΈΔ
ඞཁͳϥΠϒϥϦΛΠϯετʔϧ ChatGPTͷAPIΛ࣮ߦͯ͠ΈΔ 21
ڥมʹ0QFO"*"1*ΩʔΛηοτ 22 ChatGPTͷAPIΛ࣮ߦͯ͠ΈΔ
νϟοτ༻ͷ"1*Λ࣮ߦ 23 ChatGPTͷAPIΛ࣮ߦͯ͠ΈΔ
Colab •Google͕ແྉఏڙ͢ΔΫϥυϕʔεͷPython࣮ߦڥ •GoogleΞΧϯτ͕͋Εϒϥβܦ༝Ͱ͙͑͢Δ •ແྉͷGPUGoogleυϥΠϒͱͷσʔλ࿈ܞՄೳ 24 1ষͷ·ͱΊ
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 25
LLMΛ׆༻ͨ͠ߴͳΞϓϦέʔγϣϯͷ։ൃΛָʹ͠ ͯ͘ΕΔϑϨʔϜϫʔΫ •LLMͱGoogleݕࡧΛ࿈ܞͨ͠ΞϓϦ •ࢦఆτʔΫϯͰձཤྺΛͭΞϓϦ •ಠࣗσʔλΛݩʹճ͢ΔΞϓϦ 26 LangChainͱʢ࠶ܝʣ
•ศརͳϞδϡʔϧ͕༻ҙ͞Ε͓ͯΓɺͦΕΒΛΈ߹ΘͤΔ ͜ͱͰɺෳࡶͳॲཧΛߦ͏ΞϓϦέʔγϣϯ͕։ൃͰ͖Δɻ •༷ʑͳLLMΛαϙʔτɻ •࿈ܞՄೳͳ֎෦αʔϏεଟ͍ɻ •PythonJavaScript / TypeScriptͰར༻Մೳɻ 27 LangChainͷಛʢ࠶ܝʣ
28 ͲͷΑ͏ͳϞδϡʔϧ͕͋Δ͔
•ModelsɿLLMͷݺͼग़͠ػೳ •Promptsɿೖྗใ͔ΒϓϩϯϓτΛ࡞͢Δػೳ •ChainsɿLLMPromptsͷೖग़ྗΛܨ͛Δػೳ •Memoryɿձཤྺͷอଘػೳ •AgentsɿͲΜͳखஈɾॱংͰ࣮ߦ͢Δ͔ܾఆ͢Δػೳ 29 LangChainͷओͳϞδϡʔϧ
LLMͷݺͼग़͠ػೳ •OpenAIͷLLMʢGPT-3GPT-4ʣͳͲɺ༷ʑͳαʔϏε͕ఏ ڙ͍ͯ͠ΔϞσϧΛར༻Ͱ͖Δػೳ •LLMؒͰΠϯλʔϑΣʔε͕ڞ௨Խ͞Ε͍ͯΔҝɺҟͳΔ LLMΛར༻͢Δ͔࣌Γ͍͢ 30 Modelsͱ
•Anthropic •Azure •Bedrock •Google Cloud Platform Vertex AI PaLM •OpenAI
ͳͲ https://python.langchain.com/docs/modules/model_io/models/llms/ 31 ࢀߟɿαϙʔτ͞Ε͍ͯΔαʔϏεྫ
ඞཁͳϥΠϒϥϦΛΠϯετʔϧͯ͠ɺڥมΛηοτ Modelsͷ͍ํ 32
0QFO"*ͷ--.ʢ(15ʣΛར༻ .PEFMΛॳظԽ͠ɺϝοηʔδͷϦετΛ༩࣮͑ͯߦ Modelsͷ͍ํ 33
0QFO"*ͷ--.ʢ(15ʣ ҟͳΔLLMͷΠϯλʔϑΣʔεͷൺֱ 34 "OUISPQJDͷ--. ˠҟͳΔ--.Ͱಉ͡Α͏ͳݺͼग़͠ํͰ࣮ߦͰ͖Δ
ೖྗใ͔ΒϓϩϯϓτΛ࡞͢Δػೳ •ϓϩϯϓτతͷճΛಘΔͨΊʹॏཁͳཁૉ •LangChainϓϩϯϓτͷૢ࡞ͱߏஙΛ؆୯ʹ͢ΔػೳΛఏ ڙ •ྫ͑ɺϓϩϯϓτςϯϓϨʔτͷҰ෦ͷมΛɺϓϩά ϥϛϯάͷೖྗͰஔ͖͑Δ͜ͱ͕Ͱ͖Δ 35 Promptsͱ
ඞཁͳϥΠϒϥϦΛΠϯετʔϧͯ͠ɺڥมΛηοτ Promptsͷ͍ํ 36
ϓϩϯϓτͷςϯϓϨʔτʹ৯͍ͷΑ͏ʹมΛࠐΉ͜ͱ͕Ͱ͖Δ ϓϩάϥϛϯά࣮ߦ࣌ʹॊೈʹςϯϓϨʔτΛͰ͖Δ Promptsͷ͍ํ 37
ॊೈʹϓϩϯϓτςϯϓϨʔτΛมߋͰ͖ΔΑ͏ʹͳΓɺ ෳࡶͳλεΫ͕Γ͘͢ͳΔ Promptsͷ͍ํ 38
ModelsPromptsͷೖग़ྗΛܨ͛Δػೳ •ModelsͱPromptsͱ͍ͬͨϞδϡʔϧΛ࿈࣮݁ͯ͠ߦ͕Ͱ͖ Δ •ModelsͱPromptsͷΈ߹ΘͤΛɺผͷModelsͱPromptsͷ Έ߹Θͤʹ࿈݁͢Δ͜ͱՄೳ •͜ͷΑ͏ʹϞδϡʔϧΛ؆୯ʹ࿈݁Ͱ͖Δ͜ͱͰɺAPIΛ୯ ମͰར༻͢ΔΑΓָ࣮͕ʹͳͬͯ͘Δ 39 Chainsͱ
ඞཁͳϥΠϒϥϦΛΠϯετʔϧͯ͠ɺڥมΛηοτ Chainsͷ͍ํ 40
.PEFMTͱ1SPNQUTͷίʔυΛ࿈࣮݁ͯ͠ߦ Chainsͷ͍ํ 41
ձཤྺͷอଘػೳ •APIΛར༻͢Δ߹ɺձཤྺͷอଘಠ࣮͕ࣗඞཁ •MemoryΛར༻͢Δ͜ͱͰɺಠ࣮ࣗ෦Λॊೈˍ؆୯ʹ࣮ Մೳ •ྫ͑ɺݹ͍ձཁͯ͠ɺۙͷձͦͷ··อ࣋͢ ΔͷΑ͏ͳॲཧ؆୯ʹ࣮Ͱ͖Δ 42 Memoryͱ
•ConversationBufferWindowMemoryɿۙkݸͷཤྺΛ༻ •ConversationTokenBufferMemoryɿτʔΫϯͰཤྺΛ༻ •ConversationSummaryBufferMemoryɿݹ͍ձཁͯ͠ɺ ۙͷձͦͷ··อ࣋ͯ͠༻ɻ ͳͲ https://python.langchain.com/docs/modules/memory/ 43 ఏڙ͞Ε͍ͯΔMemory
UJLUPLFOʢτʔΫϯΛऔಘ͢ΔʣϥΠϒϥϦΛՃ ConversationSummaryBufferMemoryͷར༻ྫ 44
$IBUNPEFMΛར༻ͯ͠$POWFSTBUJPO4VNNBSZ#V ff FS.FNPSZΛར༻ ཁͱ࠷৽ͭͷΓͱΓ͕อଘ͞Ε͍ͯΔ ConversationSummaryBufferMemoryͷར༻ྫ 45
ͲΜͳखஈɾॱংͰ࣮ߦ͢Δ͔ܾఆ͢Δػೳ •ChainsΑΓෳࡶͳλεΫ࣮ߦՄೳ •ϢʔβʔೖྗʹΑͬͯɺ࣮ߦ͞ΕΔػೳ͕มΘΔ •ॲཧͷྲྀΕɺʮೖྗˠ(ਪˠ࣮ߦˠ؍) * N→ճʯ •GoogleBingͳͲͷ֎෦αʔϏεΛ؆୯ʹར༻Ͱ͖Δػೳ ʢToolsʣͱ࿈ܞՄೳ 46 Agentsͱʁ
•awslambda •Bing Search •ChatGPT Plugins •Google Search •Twilio •Wikipedia •Zapier
Natural Language Actions API ͳͲ https://python.langchain.com/docs/modules/agents/tools/ 47 ࿈ܞͰ͖Δ֎෦αʔϏεʢToolsʣ
•zero_shot_react_descriptionɿReAct ͱ͍͏ਪػೳͱߦಈ ػೳΛ༻͍Δख๏Λ༻ͯ͠ͲͷToolsΛ༻͢Δ͔Λܾఆɻ •conversational-react-descriptionɿReAct Λ༻ͯ͠Ͳͷ ToolsΛ༻͢Δ͔Λܾఆɻ ձʹ࠷దԽ͞Ε͓ͯΓɺ MemoryΛ༻ͯ͠ձཤྺߟྀͰ͖Δɻ https://python.langchain.com/docs/modules/agents/ 48
ఏڙ͞Ε͍ͯΔAgents
%VDLEVDLHPTFBSDIʢݕࡧΤϯδϯʣϥΠϒϥϦΛՃ Agentsͷར༻ྫ 49
%VDLEVDLHPTFBSDIʢݕࡧΤϯδϯʣϥΠϒϥϦΛՃ Agentsͷར༻ྫ 50
•ModelsɿLLMͷݺͼग़͠ػೳ •Promptsɿೖྗใ͔ΒϓϩϯϓτΛ࡞͢Δػೳ •ChainsɿLLMPromptsͷೖग़ྗΛܨ͛Δػೳ •Memoryɿձཤྺͷอଘػೳ •AgentsɿͲΜͳखஈɾॱংͰ࣮ߦ͢Δ͔ܾఆ͢Δػೳ 51 LangChainͷओͳϞδϡʔϧʢ࠶ܝʣ
IUUQTHJUIVCDPNLZSPMBCTBXFTPNFMBOHDIBJO [ࢀߟ]LangChainͷΞοϓσʔτΛ͑ΔαΠτ 52
LangChain •LLMΛ׆༻ͨ͠ߴͳΞϓϦέʔγϣϯ։ൃΛࢧԉ͢Δϑ ϨʔϜϫʔΫ •༻ҙ͞Ε͍ͯΔϞδϡʔϧΛΈ߹ΘͤΔ͜ͱͰɺෳࡶͳॲ ཧ͕࣮͘͢͠ͳΔ •LangChainͷ࠷৽ใΛ͏ͱɺLLMͷ࠷৽ใΩϟον ΞοϓͰ͖ͯҰੴೋௗ 53 2ষͷ·ͱΊ
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 54
4USFBNMJUʢετϦʔϜϦοτʣ IUUQTTUSFBNMJUJP ͓͢͢ΊͷWebΞϓϦέʔγϣϯϑϨʔϜϫʔΫ 55
•PythonͰWebΞϓϦέʔγϣϯΛ։ൃ͢ΔͨΊͷϑϨʔϜ ϫʔΫ •ֶशίετ͕͘ɺരͰΞϓϦΛ։ൃՄೳ •LangChainͱͷ౷߹ͷυΩϡϝϯτ๛ 56 Streamlitͷಛ
57 ͲΕ͚ͩ؆୯ʹͭ͘ΕΔͷ͔ʁ
10ߦͷίʔυ 58
؆୯ͳνϟοτΞϓϦ͕ 59 IUUQTHJUIVCDPNUBLBBLJLBLFJEFNPTUSFBNMJUMBOHDIBJOCMPCNBJOQBHFTFDIPDIBUVJQZ
30ߦͷίʔυʢLangChainͷॲཧՃʣ 60
IUUQTHJUIVCDPNUBLBBLJLBLFJEFNPTUSFBNMJUMBOHDIBJOCMPCNBJOQBHFTMBOHDIBJOEEH TFBSDIQZ LangChainΛར༻ͨ͠νϟοτΞϓϦ 61
IUUQTEPDTTUSFBNMJUJPLOPXMFEHFCBTFUVUPSJBMTCVJMEDPOWFSTBUJPOBMBQQT [ࢀߟ]StreamlitͷνϡʔτϦΞϧ 62
IUUQTCMPHTUSFBNMJUJPUBHUVUPSJBMT [ࢀߟ]StreamlitͷνϡʔτϦΞϧϒϩά 63
IUUQTHJUIVCDPNNJDSPTPGUB[PBJDIBUHQUTUSFBNMJUIBSOFTT [ࢀߟ]MicrosoftͷϦϙδτϦ 64
65 WebΞϓϦͷެ։ʹ͍ͭͯ
•WebSocketʹରԠ͍ͯ͠ΔαʔϏεʹσϓϩΠ͕ඞཁ •ެࣜͷೝূػೳ͕ఏڙ͞Ε͍ͯͳ͍ •جຊతʹαʔόαΠυͰॲཧ͞ΕΔͨΊɺΞΫηεूத࣌ʹ ෆ҆͋Γ 66 ެ։࣌ͷ՝
•WebSocketʹରԠ͍ͯ͠ΔαʔϏεʹσϓϩΠ͕ඞཁ →Cloud RunͳͲʹσϓϩΠ •ެࣜͷೝূػೳ͕ఏڙ͞Ε͍ͯͳ͍ →σϓϩΠઌͷηΩϡϦςΟαʔϏε or αʔυύʔςΟͷϞδϡʔ ϧΛར༻ https://zenn.dev/google_cloud_jp/articles/streamlit-02- fi
rebase https://zenn.dev/matken/articles/restrict-cloud-run-to-in-house https://github.com/mkhorasani/Streamlit-Authenticator •جຊతʹαʔόαΠυͰॲཧ͞ΕΔͨΊɺΞΫηεूத࣌ʹෆ҆͋Γ →·ͣಈ͘ͷΛ࡞Δͱ͍͏ελϯεͰɺখنͰͷར༻Λݕ౼ 67 StreamlitͰ։ൃͨ͠ΞϓϦͷ՝ˠղܾҊʗߟ
Streamlit •PythonͰWebΞϓϦέʔγϣϯΛ࡞͢ΔͨΊͷϑϨʔϜ ϫʔΫ •ֶशίετ͕͘ɺരͰΞϓϦΛ։ൃՄೳ •খن͚͕ͩɺ͡ΊͷҰาͱ͓ͯ͢͢͠Ί 68 3ষͷ·ͱΊ
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 69
LangChainΛར༻ͨ͠ΞϓϦ։ൃͷྲྀΕ 1. ։ൃڥͷ४උ 2. LangChainͷཧղͱ࣮ફ 3. WebΞϓϦέʔγϣϯ։ൃ 4. ɿ͓͢͢ΊͷOSS 70
IUUQTHJUIVCDPNNDLBZXSJHMFZDIBUCPUVJ $IBUCPU6* ͓͢͢ΊͷOSS 71
•ChatGPTϥΠΫͳUIΛαΫοͱߏஙͰ͖ΔOSS •GitHubͰͷStarɿ15,000Ҏ্ •Docker fi leͰཧ͞Ε͓ͯΓɺϙʔλϏϦςΟ͕ߴ͍ •EdgeͰಈͨ͘ΊɺதنҎ্Ͱಈ࡞͢Δҹ •NextJSͷܦݧ͕͋ΕɺΧελϚΠζՄೳ 72 Chatbot UIͷಛ
APIΩʔͷηοτޙͷը໘ 73
νϟοτΠϝʔδ 74
•ڥมͰɺOpenAI͔Azure OpenAIΛબՄೳ •ձཤྺΛݩʹͨ͠ճ͕Մೳ •Googleݕࡧ݁ՌΛݩʹͨ͠ճՄೳ •UI্ͰϞσϧબTemperatureͷௐ͕Մೳ 75 Chatbot UIͷػೳ
IUUQTEFWDMBTTNFUIPEKQBSUJDMFTDIBUHQUXFCVJDIBUCPUVJ Chatbot UIΛϩʔΧϧͰಈ͔͢ 76
77 ެ։࣌ͷηΩϡϦςΟͲ͏͢Δ͔ʁ
ύλʔϯ1ɿAWS WAF 78 "848"'Ͱ*1੍ݶ
"848"'Ͱ*1੍ݶ͠ɺ/FYU"VUIͰ"[VSF"%ͳͲͰೝূ ύλʔϯ2ɿAWS WAF + NextAuth 79
$MPVE fl BSFͰθϩτϥετͱೝূػೳΛ࣮ ύλʔϯ3ɿCloud fl are 80
81 ΧελϚΠζʹ͍ͭͯ
ϓϨεϦϦʔεɿIUUQTDMBTTNFUIPEKQOFXTNVMUJHFOFSBUJWFBJTFSWJDF ෳͷLLMΛར༻ग़དྷΔΑ͏ʹΧελϚΠζ 82
IUUQTHJUIVCDPNNDLBZXSJHMFZDIBUCPUVJQVMMT [ࢀߟ]ϓϧϦΫΤετࢀߟʹͳΔ 83
Chatbot UI •ChatGPTϥΠΫͳUIΛαΫοͱ࡞ΕΔOSS •ձཤྺGoogleݕࡧ݁ՌΛݩʹͨ͠ճػೳ͕උ͚͑ •Docker fi leͰσϓϩΠՄೳͳͷͰϙʔλϏϦςΟ͕ߴ͍ •ϋʔυϧߴΊ͕ͩɺΧελϚΠζՄೳ 84 ͷ·ͱΊ
ඪ •APIΛಈ͔͢ϋʔυϧΛԼ͕Δ͜ͱ •LangChainͷརͱ༻ํ๏ʹؔ͢ΔཧղΛਂΊΔ͜ͱ •LangChainΛར༻ͨ͠LLMͷΞϓϦέʔγϣϯެ։ͷݟ ΛਂΊΔ͜ͱ 85 ຊొஃͷඪʢ࠶ܝʣ
ηογϣϯΞϯέʔτ DAY2 86 https://forms.gle/Upi2i5PsMTEUyJ6F8 ຬ্ҐͷηογϣϯΛޙϒϩάͰެ։༧ఆʂ ճͷ͝ڠྗΛΑΖ͓͘͠ئ͍͠·͢ɻ
None