> ## Documentation Index
> Fetch the complete documentation index at: https://benchgen.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Using AI to Generate a Topic

> Bootstrap a Topic definition from a natural language prompt using the Generate with AI feature.

# Using AI to Generate a Topic

Use the **Generate with AI** feature to bootstrap a Topic definition (label, API name, classification description, scope, and instructions) from a natural language prompt. This page gives you patterns, validation criteria, and refinement tactics so output reaches production quality quickly.

***

## Summary

| You Get                            | Why It Helps                          |
| ---------------------------------- | ------------------------------------- |
| Structured draft (all core fields) | Eliminates blank‑page delay           |
| Enumerated rules                   | Encourages atomic, testable behaviors |
| Suggested triggers & scope         | Quicker classification coverage       |
| Rapid iteration loop               | Try multiple framings to converge     |

***

## Prerequisites

* Access to an Agent where you can create Topics
* Understanding of what the Topic should and should NOT handle
* (Optional) List of trigger phrases & default values you expect

***

## When to Use vs. Manual Authoring

| Use AI Generation When                             | Prefer Manual Authoring When         |
| -------------------------------------------------- | ------------------------------------ |
| You need a fast first draft                        | Regulatory / compliance heavy domain |
| Pattern is common (quiz, retrieval, summarization) | Highly bespoke workflows             |
| You want multiple alternative wordings             | Strict legal wording required        |
| You're standardizing voice across teams            | You already have a vetted template   |

***

## Step-by-Step

1. Open the **Topics** tab of your Agent and click **Create New Topic**.
2. Click **Generate with AI**.
3. Enter a descriptive prompt (see Prompt Patterns below).
4. Submit and wait for the draft.
5. Review each section (Label, API Name, Classification, Scope, Instructions).
6. Edit for clarity, compliance, and uniqueness.
7. Accept / insert the generation into the form.
8. Save the Topic and run initial test prompts.

***

## Prompt Patterns

| Goal                  | Prompt Example                                                                                                                                                                     | Key Inclusion                   |
| --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------- |
| Quiz generation       | Create a quiz generation topic that produces adjustable difficulty quizzes (easy/medium/hard) with a selectable number of questions. Default to 5 medium questions if unspecified. | Defaults for difficulty & count |
| Retrieval / knowledge | Topic for internal knowledge lookups across product docs; summarize and cite sources. Exclude financial or HR policy questions.                                                    | Explicit exclusions             |
| Coaching              | Topic that coaches junior support agents on tone and resolution steps; asks clarifying questions before drafting a reply.                                                          | Clarifying step                 |
| Compliance filter     | Topic that screens user requests for PII exposure risk; flags and suggests redactions; does not store raw data.                                                                    | Data handling constraints       |

**Tips:**

* State DEFAULTS (difficulty, count, format) explicitly
* Add EXCLUSIONS (what this topic must not do)
* Include ACTION verbs for classification: "explain", "quiz", "summarize", "coach"

***

## Screenshots

| Stage            | Screenshot                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| ---------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Drafting (input) | <img src="https://mintcdn.com/benchgen-8fc81371/2OCozHVviHUGu126/images/agentspace/topicinstructions.png?fit=max&auto=format&n=2OCozHVviHUGu126&q=85&s=f9016ebbc6b8447c7ac786362f6f9707" alt="AI Topic Prompt" width="874" height="770" data-path="images/agentspace/topicinstructions.png" /> |
| Generated Result | <img src="https://mintcdn.com/benchgen-8fc81371/2OCozHVviHUGu126/images/agentspace/topiccreated.png?fit=max&auto=format&n=2OCozHVviHUGu126&q=85&s=9b3d54420b99f1ec89cbae7aafa862ec" alt="AI Topic Result" width="1199" height="1554" data-path="images/agentspace/topiccreated.png" />                                     |

***

## Common Pitfalls & Fixes

| Pitfall            | Symptom                                      | Fix                                          |
| ------------------ | -------------------------------------------- | -------------------------------------------- |
| Over-broad scope   | Misclassification overlaps with other Topics | Narrow scope + add exclusions                |
| Missing defaults   | Inconsistent responses                       | Add explicit default rules                   |
| Ambiguous triggers | Random routing                               | Strengthen trigger verbs/nouns               |
| Instruction drift  | Model ignores later rules                    | Shorten + front‑load critical rules          |
| Weak naming        | Confusing or generic                         | Use domain + function (e.g., `Biology_Quiz`) |

***

## After Accepting the Draft

1. Adjust naming collisions (if any).
2. Save the Topic.
3. Run 3–5 varied user phrasing tests.
4. Confirm correct routing; tweak classification description if misrouted.
5. Add or edit an Action if the Topic requires external calls.

***

**Done.** You now have a repeatable method to translate intent into a production‑grade Topic definition using AI assistance.
