はじめに ChatGPTの肝になる機能の一つが Function Calling です。これはLLMで質問の内容を解析して、必要な関数を呼び出すというものです。 「必要な関数」 をどのように判定しているかといえば、それは関数の説明文から判断します。今までもキーワードに応じて何かの処理をするようなプログラムは良くあったと思いますが、LLMの強力な言語処理能力を使うことで 「呼び出すべき関数」 と 「適切な引数」 を自動的に判定してくれます。SiriやAlexaみたいなツールが簡単に作れちゃいます。 今回はそのFunction callingをLangChain経由で使って天気予報APIをAITuberの「紅月れん」から呼べるようにしたので、その試行錯誤等を載せておきたいと思います。 なお、AITuber自体の作り方やLLMに関する全般的な話は下記の記事で取り扱っていますので、良ければ読んでみ
以下の記事が面白かったので、かるくまとめました。 ・New models and developer products announced at DevDay 1. GPT-4 Turbo「GPT-4 Turbo」は、「GPT-4」より高性能です。2023年4月までの知識と128kのコンテキストウィンドウを持ちます。さらに、「GPT-4」と比較して入力は1/3、出力は1/2の安い価格で提供します。 開発者はモデルID「gpt-4-1106-preview」で試すことができます。今後数週間以内に、安定した実稼働モデルをリリースする予定です。 1-1. Function Calling の更新「Function Calling」に、単一メッセージから複数のFunction (「車の窓を開けてエアコンをオフにする」など) を呼び出す機能などが追加されました。精度も向上しています。 1-2. 構造
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く