# 最初のflow

> 最初のflowを作成し、templatesでプロンプトを再利用し、agentsの作業を追跡・誘導し、最後にreportをダウンロードします。

**Flow** とはPentAGIの1回の実行であり、目標、メッセージから作成された[tasks](https://pentagi.com/ja/docs/glossary/#task)、および[agents](https://pentagi.com/ja/docs/glossary/#agent)が実行したすべての作業を含みます。

## [Flowを作成する](https://pentagi.com/ja/docs/getting-started/first-flow/#create-a-flow)

![新しいflowフォーム](https://pentagi.com/images/product/new-flow.webp)

1. サイドバーで **Flows** を開き、**New Flow** をクリックします。
2. モードを選択します。

   * **Automation** — PentAGIが目標を最初から最後まで自律的に実行します。
   * **Assistant** — ユーザーが段階的に指示できる対話型の会話です。**Use Agents** を有効にすると、[assistant](https://pentagi.com/ja/docs/glossary/#assistant)が[subtasks](https://pentagi.com/ja/docs/glossary/#subtask)を専門のagentsに委任できるようになります。
3. この[flow](https://pentagi.com/ja/docs/glossary/#flow)で使用するLLM [provider](https://pentagi.com/ja/docs/glossary/#provider)を選択します。
4. ターゲットと目的を自然言語で記述します。

適切な最初のプロンプトには、ターゲット、評価の種類、スコープの制限、および期待する結果を明記します。

```text
Assess https://target.example for common web application vulnerabilities.
Focus on authentication, file handling, and injection issues. Stay within the
provided target only and summarize confirmed findings with reproduction steps.
```

> [!WARNING]
> テスト対象は、自身が所有するか、明示的に評価の許可を得ているシステムに限ってください。

## [Templatesでプロンプトを再利用する](https://pentagi.com/ja/docs/getting-started/first-flow/#reuse-prompts-with-templates)

新しいflowのフォームには[template](https://pentagi.com/ja/docs/glossary/#template)選択機能があり、**Templates** に保存されたtemplateからメッセージを自動入力できます。Templatesは通常の自然言語であり、特別な構文は不要です。

## [作業の進捗を確認する](https://pentagi.com/ja/docs/getting-started/first-flow/#follow-the-work)

Flowが開始されると、PentAGIはすぐにflowページを開きます。

* **Automation** はagentsのメッセージと進捗を表示します。**Assistant** は同じ[tools](https://pentagi.com/ja/docs/glossary/#tool)を利用できるチャット画面であり、**Dashboard** はモデル、[agent type](https://pentagi.com/ja/docs/glossary/#agent-type)、機能ごとの使用状況を内訳表示します。
* **Tasks** には計画が一覧表示され、tasksとsubtasksおよびそのステータスが確認できます。
* **Terminal** は[sandbox](https://pentagi.com/ja/docs/glossary/#sandbox)からのすべてのコマンドとその出力をストリーミング表示します。
* **Agents**、**Searches**、**Vector Store** では、タスクの委任、Web調査、[memory](https://pentagi.com/ja/docs/glossary/#memory)検索の状況を確認できます。
* **Files** にはアップロードファイル、添付リソース、コンテナから取得したファイルが保存され、**Screenshots** にはagentsが開いたページのスクリーンショットが保持されます。

![実行中のflow：左側にagentのメッセージ、右側にtasksとsubtasksの計画](https://pentagi.com/images/product/flow-tasks.webp)

![Terminalタブに表示されるsandboxからのすべてのコマンドとその出力](https://pentagi.com/images/product/flow-terminal.webp)

## [実行中のflowを制御する](https://pentagi.com/ja/docs/getting-started/first-flow/#steer-a-running-flow)

同じflowの **Assistant** ビューを開くことで、flowを再起動することなく、状態の確認、現在のtaskの停止、追加指示の送信、または残りの計画済みsubtasksの調整を行えます。

## [Reportを取得する](https://pentagi.com/ja/docs/getting-started/first-flow/#get-the-report)

Flowページの **Report** メニューを使用して、Web上で[report](https://pentagi.com/ja/docs/glossary/#report)を開いたり、コピーしたり、MarkdownまたはPDF形式でダウンロードしたりできます。

> [!NOTE]
> 最初は狭い範囲のターゲットと単一の明確な目的から始めましょう。短く焦点を絞ったflowsはレビューが容易で、大規模なflowsを実行する前にプロンプトを洗練させるのに役立ちます。