LLMSynthesize
✖
LLMSynthesize
[実験的]
この機能には次が必要です:LLMアクセス »
詳細とオプション




- LLMSynthesizeは,大規模言語モデル(LLM)を使い,プロンプトで指定された指示に従ってテキストを生成する.この関数は,’コンテンツの作成,文の完成,情報の抽出等ができる.
- LLMSynthesizeは,外部サービスの認証,請求,インターネット接続を必要とする.
- 以下は,prompt の可能な値である.
-
"text" 静的テキスト LLMPrompt["name"] リポジトリプロンプト StringTemplate[…] テンプレートテキスト TemplateObject[…] プロンプト作成用テンプレート Image[…] 画像 {prompt1,…} プロンプトのリスト - テンプレートオブジェクトはTemplateObject[…][]を介して自動的に文字列に変換される.
- TemplateObjectで作成したプロンプトにはテキストと画像を入れることができる.
- すべてのLLMが画像入力をサポートする訳ではない.
- 次は,prop のサポートされている値である.
-
"CompletionText" LLMからのテキストによる答 "CompletionToolsText" ツールとのインタラクションを含んだテキストによる答 "FullText" "History"の文字列表現 "History" プロンプトと完成文を含む完全な履歴 "Prompt" LLMに送信されたコンテンツ "PromptText" "Prompt"の文字列表現 "ToolRequests" LLMToolRequestオブジェクトのリスト "ToolResponses" LLMToolResponseオブジェクトのリスト "Usage" 使用法のトークン {prop1,prop2,…} 複数の特性 All すべての特性 - "FullTextAnnotations","ToolRequests"および"ToolResponses"は{start,end}val の形式の要素を含む連想を返す.ただし,val はオブジェクトを参照し,start と end は文字列の範囲を参照する.val は"FullText"で指定される.
- 次は,指定可能なオプションである.
-
Authentication Automatic 明示的なユーザIDとAPIキー LLMEvaluator $LLMEvaluator 使用するLLM設定 ProgressReporting $ProgressReporting 計算の進捗状況の報告方法 - LLMEvaluatorは,LLMConfigurationオブジェクトまたは以下のキーの任意のものを含む連想に設定できる.
-
"MaxTokens" 生成するトークンの最大数 "Model" ベースモデル "PromptDelimiter" プロンプト間に使用するデリミタ "Prompts" 初期プロンプトまたはLLMPromptGeneratorオブジェクト "StopTokens" 生成を止めるトークン "Temperature" サンプリング温度 "ToolMethod" ツールの呼出しに使用するメソッド "Tools" 使用可能にするLLMToolオブジェクトのリスト "TopProbabilities" サンプリングクラスのカットオフ "TotalProbabilityCutoff" サンプリング確率のカットオフ(核サンプリング) - 次は,"Model"の有効な形式である.
-
name 名前付きのモデル {service,name} service からの名前付きのモデル <"Service"service,"Name"name,"Task"task > 完全に指定されたモデル - タスクの可能な値には"Chat"と"Completion"がある.
- 生成されたテキストは,配布物からサンプリングされる.サンプリングの詳細は,LLMEvaluatorの以下の特性で指定できる.
-
"Temperature"t Automatic 正の温度 t を使ったサンプリング "TopProbabilities"k Automatic 最もありそうな k 個のクラスのみからのサンプリング "TotalProbabilityCutoff"p Automatic 最低でも p の累積確率を持つ最もありそうな選択肢からのサンプリング(核サンプリング) - これらのパラメータの値Automaticには,指定された"Model"のデフォルト値が使われる.
- LLMEvaluatorの"Prompts"特性で指定されたプロンプトは,タスクが"Chat"の場合はロール(役割)が"System"に設定されて入力 prompt の前に加えられる.
- 複数のプロンプトはLLMEvaluatorの"PromptDelimiter"特性で分離される.
- 次は,Authenticationの可能な値である.
-
Automatic 認証スキームを自動選択する Environment 環境変数のキーをチェックする SystemCredential システムキーチェーンのキーをチェックする ServiceObject[…] サービスオブジェクトから認証を継承する assoc 明示的なキーとユーザIDを与える - AuthenticationAutomaticのとき,関数はEnvironmentとSystemCredentialの変数ToUpperCase[service]<>"_API_KEY"をチェックする.それ以外の場合はServiceConnect[service]が使われる.
- Authenticationassoc の assoc は以下のキーを含むことができる.
-
"ID" ユーザID "APIKey" 認証に使われるAPIキー - LLMSynthesizeは機械学習を使う.含まれるメソッド,訓練集合,バイアスはWolfram言語のバージョンによって異なることがあり,与えられる結果も異なる可能性がある.
例題
すべて開くすべて閉じる例 (3)基本的な使用例
スコープ (3)標準的な使用例のスコープの概要
オプション (8)各オプションの一般的な値と機能
Authentication (4)
In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-hjhy5v
Out[2]=2

In[4]:=4

✖
https://wolfram.com/xid/0mle7tobhd6u-26n13x
Out[4]=4

オペレーティングシステムのキーチェーンを使ってAPIキーを格納する:
In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-bdfisk
In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-cntmim
Out[2]=2

In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-wra5l
In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-fy6sex
Out[2]=2

In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-f8oogn
In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-gdu4z5
In[3]:=3

✖
https://wolfram.com/xid/0mle7tobhd6u-hae6g6
Out[3]=3

LLMEvaluator (4)
デフォルトで,テキストの生成は中止トークンが生成されるまで続く:
In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-4deaiq
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-d6g3qu
Out[2]=2

In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-dtptgp
Out[1]=1

より多くのバリエーションが生成されるようにより高い温度を指定する:
In[2]:=2

✖
https://wolfram.com/xid/0mle7tobhd6u-r3p372
Out[2]=2

In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-grgwys
Out[1]=1

In[1]:=1

✖
https://wolfram.com/xid/0mle7tobhd6u-jpl8jr
Out[1]=1

アプリケーション (1)この関数で解くことのできる問題の例
Wolfram Research (2023), LLMSynthesize, Wolfram言語関数, https://reference.wolfram.com/language/ref/LLMSynthesize.html (2025年に更新).
✖
Wolfram Research (2023), LLMSynthesize, Wolfram言語関数, https://reference.wolfram.com/language/ref/LLMSynthesize.html (2025年に更新).
テキスト
Wolfram Research (2023), LLMSynthesize, Wolfram言語関数, https://reference.wolfram.com/language/ref/LLMSynthesize.html (2025年に更新).
✖
Wolfram Research (2023), LLMSynthesize, Wolfram言語関数, https://reference.wolfram.com/language/ref/LLMSynthesize.html (2025年に更新).
CMS
Wolfram Language. 2023. "LLMSynthesize." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2025. https://reference.wolfram.com/language/ref/LLMSynthesize.html.
✖
Wolfram Language. 2023. "LLMSynthesize." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2025. https://reference.wolfram.com/language/ref/LLMSynthesize.html.
APA
Wolfram Language. (2023). LLMSynthesize. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/LLMSynthesize.html
✖
Wolfram Language. (2023). LLMSynthesize. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/LLMSynthesize.html
BibTeX
✖
@misc{reference.wolfram_2025_llmsynthesize, author="Wolfram Research", title="{LLMSynthesize}", year="2025", howpublished="\url{https://reference.wolfram.com/language/ref/LLMSynthesize.html}", note=[Accessed: 02-April-2025
]}
BibLaTeX
✖
@online{reference.wolfram_2025_llmsynthesize, organization={Wolfram Research}, title={LLMSynthesize}, year={2025}, url={https://reference.wolfram.com/language/ref/LLMSynthesize.html}, note=[Accessed: 02-April-2025
]}