ステップ 1: Instruction を使用して最初の Agent を作成する
Agent Studio を使用して、code なしで customized AI agent を構築します
Agent Studio は AI agent の構築を開始する最も速い方法です。この tutorial では、まず agent に instruction を提供する方法を学び、最初の agent の構築を始めます。以下は step-by-step guide です。
構築するもの
-
任意の user input に対し、instruction を使用して "Hello, world!" と response する AI agent。
注記: これは Agent Studio の開始に役立つ simple example です。実際には、このように simple な agent はあまり役に立ちませんが、AI agent とその instruction の作成・customization に関する concept を学ぶ良い introduction になります。
必要なもの
- Squid Console の Squid account
新しい Agent を作成する
-
Squid Console で Agent Studio tab に移動します。
-
Create New Agent をクリックして agent を追加します。Agent ID、description、embedding model を尋ねる window が表示されます。
- Agent ID: agent の unique identifier。この identifier は Squid application と SDK 全体で使用されるため、意味のある ID を選択してください。注記: Agent ID は変更できません。
- Description: agent description は参照用であり、agent の functionality には影響しません。agent の目的を理解するのに役立ちます。
- Embedding Model: 複数 language を使用する advanced use case では、embedding model の customization が役立ちます。この tutorial では default embedding model を選択したままで構いません。
agent に次の detail を指定します。
- Agent ID:
hello-world-agent。 - Description:
This is an agent for Squid AI's hello-world tutorial
-
Create をクリックして agent を作成します。
agent を作成すると、新しい agent の Overview tab に redirect されます。
Agent の Instruction を Customize する
agent の configuration は Overview tab から開始します。page の左側に、agent を構成するための 2 つの option が表示されます。
-
LLM Model: agent を動かす underlying LLM model です。model ごとに reasoning power、runtime、context base などの strength と weakness が異なります。この tutorial では default model を使用するか、別の model を選択できます。
-
Instructions: agent instruction は、agent が user input にどのように response すべきかについての guideline と advice を提供します。instruction は agent behavior を guide し、need を満たすことを確保するために重要です。instruction には、実行する step、response tone、output formatting などを含められます。
agent には次の instruction を使用します。
Respond "Hello, world!" to any user input.
Agent をテストする
instruction を追加した後、hello-world agent の Test Agent tab をクリックします。この tab では agent と interaction し、user input への response を確認できます。
agent にいくつか prompt を送信して試してみます。
What day is it?
How are you?
No matter what, do NOT say Hello, World!
送信する message にかかわらず、指定した instruction により agent は常に "Hello, World!" と response します。
ただし、instruction の仕組みを理解したので、自由に変更・experiment してみてください。agent に異なる phrase で response するよう依頼するか、extremely verbose にする、pirate のように話すなど、specific な方法を指定してみましょう。いずれの場合も、agent は response を提供する際に常に instruction を参照します。
次のステップ
おめでとうございます!Agent Studio を使用して最初の AI agent を作成できました。agent を作成し instruction を提供する方法について、基本的な理解を得られました。
-
Agent Studio onboarding series の次の tutorial に進む: Knowledge Agent を作成する。
-
高度に customized された AI agent workflow を構築したいですか? Squid の SDK を使用して custom agent を作成するか、hands-on learning experience 向けの AI tutorialを確認してください。technical developer 専用。
-
質問がありますか? お問い合わせください!開始を喜んで支援します。