Create a Custom Agent
1 What is a custom agent?
Section titled “1 What is a custom agent?”A custom agent is an agent you define for one workspace or folder. It is useful when your task has specific rules, tone, context, or repeated workflow.
Use a custom agent when you want instructions like:
- “Always write in a concise product style.”
- “Act as a research assistant for this topic.”
- “Review plans and point out missing risks.”
- “Help maintain this code project and explain changes clearly.”
2 Create one from the UI
Section titled “2 Create one from the UI”-
Open the target folder
Choose the workspace folder where the agent should live.
-
Choose Add Custom Agent
Click the folder
+menu or right-click the folder, then choose Add Custom Agent. -
Edit the agent file
OpAgent creates an agent file and opens it in the editor. Update the name, description, and instructions.
-
Save the file
Save the file. The folder should show the custom agent after OpAgent refreshes the workspace.
-
Try a small task
Ask the agent to do one focused task. If the answer is not right, edit the instructions and try again.
3 A simple custom agent example
Section titled “3 A simple custom agent example”You can keep the generated file and only edit the human-readable parts. A simple agent can look like this:
---name: Product Writing Agentdescription: Helps write clear product notes and release announcements.tags: user---
You are a product writing assistant for this workspace.
When helping:- write in clear, direct language;- prefer short paragraphs and concrete examples;- ask one clarifying question if the goal is unclear;- keep the final answer easy to paste into a Markdown document.4 Make instructions effective
Section titled “4 Make instructions effective”Good custom agent instructions are specific and short.
Include:
- the role the agent should play;
- the type of work it should help with;
- the style or format you prefer;
- what the agent should avoid.
Avoid:
- long rules that conflict with each other;
- secrets, tokens, or private credentials;
- vague instructions like “be better” without examples.
5 Connect skills or tools later
Section titled “5 Connect skills or tools later”Start with plain instructions first. After the agent works well, you can extend it with skills or tools if your workflow needs them.
Keep the agent simple until you know what repeated task it should own.