Make your agent’s good work repeatable
Stop repeating the same corrections. Give your agent a method it can use on the next job.
Make a good result easier to repeat
Set up one recurring job so you can give the agent new inputs without explaining the whole method again. You’ll have clear standards, a saved process with checks, and tested code for the repetitive parts. When something goes wrong, you’ll know which part to improve.
Start with a good result
You’ve worked with Hyperagent to get a result you’re happy with. Now you want an agent that can do that kind of job again, without repeating all your directions.
Start by turning the thread into an agent. Then use this guide to organize what made the result work:
- How the agent should behave: save your standards and boundaries in the System Prompt.
- How to do the job and check the result: save the process in a skill.
- Work the computer should repeat consistently: save it as a script.
This guide shows you how to turn a job you have worked through with your agent into a method it can reuse. You’ll then test the setup on a fresh job and learn which part to improve when something goes wrong.
Apply this guide to your agentPrompt
Read https://hyperagent.com/docs/guides/where-instructions-belong and use its guidelines to turn the job we worked through in this thread into a reusable agent setup. Create a System Prompt for the agent’s role, standards, and boundaries, and skills for the process and checks. Tell the agent when to read each skill. Put repeatable calculations or data transformations in scripts where useful. Keep one-off details out of the reusable instructions, ask about anything essential that is missing, and show me what you created so we can test it on a fresh job.
Paste it into the same conversation to continue working with your agent.
Give your agent a role and define its standards
Use the agent’s System Prompt for directions that apply across its work. This gives it standards to follow on the next job, so you do not have to repeat how to handle missing facts or what a useful answer looks like.
We’ll use a call-preparation agent as the example. Its role is to help you arrive at customer meetings prepared. For each day you ask it to cover, it checks your calendar, finds the matching customer records, and prepares a short webpage with briefs for your calls. Each brief brings together who you’re meeting, recent conversations, open issues, and useful questions to ask, with links to the sources.
A call-preparation agent
Here’s a setup you can ask your agent to create, with skills tailored to the job.
# Role and outcome
Help me prepare for customer calls with clear, sourced briefs.
# Ownership and boundaries
Prepare research and recommendations.
Do not contact customers or change their records unless I ask.
# Standing standards
Highlight risks, open questions, and useful next actions.
Link factual claims to sources and distinguish facts from assumptions.
Flag missing or conflicting information instead of guessing.
# When to use skills
Before preparing a call brief, read Daily Briefing
and follow its method.
Before checking the brief’s claims, read Source Review.
Before formatting the final webpage, read Webpage Publishing.
If a required skill or an essential source is unavailable, explain
what is missing and ask how to proceed.
# Communication
Write for someone preparing for a call with limited time.
Lead with risks and next actions. Keep background concise.| Include | What to explain |
|---|---|
| Role and outcome | What the agent is responsible for achieving. |
| Ownership and boundaries | What it handles, when to ask, and what belongs to someone else. |
| Standing standards | How to handle evidence, uncertainty, and the quality of its work. |
| When to use skills | Which method to read for each recurring kind of job. |
| Communication | Who the result is for and how to present it. |
Keep the System Prompt focused
- Keep customer details and temporary deadlines in the task request.
- Put lengthy procedures in skills.
- Instructions describe boundaries. Tools and connections determine what is available, while autonomy and approval settings govern when the agent must ask.
Put the process and checks in a skill
Skills teach reusable ways of working, such as preparing a call brief or reviewing a draft. The skill names below are examples you can adapt for your own agent. Save the steps, decisions, and checks that made the first result useful. The next job can follow that method without relying on details buried in the original conversation.
# When to use
Prepare a brief before customer calls.
# Inputs
Meeting date, calendar events with attendees, customer and outreach
records, and relevant meeting notes.
# Process
1. Gather calendar events and customer and outreach records.
2. Run match_calls.py to identify calls with matching customer records.
3. Research the matched customers and review relevant meeting notes.
4. Identify risks, open questions, and useful next actions.
5. Produce a concise webpage with a section for each matched call.
# Checks
Link factual claims to their sources.
Check that each brief refers to the right meeting and customer.
Flag missing or conflicting information instead of estimating.
Do not create a customer brief for an unmatched meeting.
If the lookup succeeds but no customer calls match, say so.
If inputs are missing or the script fails, report the gap instead.Tell the agent when to read it
Point to the skill from the System Prompt instead of copying its process there.
# When to use skills
Before preparing a call brief, read Daily Briefing
and follow its method.
Before checking the brief’s claims, read Source Review.
Before formatting the final webpage, read Webpage Publishing.
If a required skill or an essential source is unavailable, explain
what is missing and ask how to proceed.Name the job and the skill to read.
“Before preparing a customer-call brief, read the Daily Briefing skill and follow its method.”
Leave the agent to guess which method applies.
“Use my skills.”
Make the skill available through the agent’s knowledge settings. In discovery mode, finding its summary is different from reading the full instructions. Give it a clear name and description, and tell the agent to read it before starting the relevant work.
For other ways skills can guide work, see Teach your agent how you work.
Use scripts for work that needs exact rules
A script is a small program that follows exact steps, such as calculating figures, cleaning up data, or formatting files the same way each time. You do not need to write the code yourself. Describe what you want done and ask your agent to write and test the script.
A skill can include both instructions and scripts. Ask your agent to save the code with the skill and explain when to run it, what information it needs, and how to check the result. That makes the code available for future jobs, rather than leaving it only in the original thread.
Find the customer calls to prepare for
Before preparing briefs, the agent needs to know which meetings involve customers. In our example, match_calls.py compares calendar attendees with customer and outreach records.
The skill tells the agent what to run. It explains which records to supply, when to run the script, and how to check the matches.
The script applies the matching rules. It ignores internal attendees and matches customer emails or company domains. A shared email provider such as Gmail does not count as a company match.
The agent turns the matches into useful recommendations. It runs the script on the thread’s computer, reads the matched records, and identifies risks and questions for each call.
Format each brief the same way
Once the agent has researched the customer, a script can turn its findings into a webpage with a consistent layout. Ask your agent to create the template and the script that fills it with each call’s details.
The skill defines what the brief needs. It specifies the sections, required sources, and checks to complete before formatting the webpage.
The script builds the webpage. Ask it to place the supplied findings into the template, format headings and source links, and flag missing required fields.
The agent checks the finished brief. It chooses the findings and recommendations, runs the script, and reviews the webpage for missing content or layout problems before sharing it.
Bring support history into the brief
An API lets a script exchange information with another service. This example uses a custom Intercom API skill: intercom_utils.py and its contact-360 command gather a customer profile, recent notes and conversation summaries, and an events summary when available. This is a recent snapshot, not a complete support history. See Call APIs from a skill to build a similar skill.
The skill explains how to look up the customer. It documents the customer lookup, the available commands, and when to retrieve conversation details rather than relying only on a summary.
The scripts gather the support history.
intercom_utils.pyassembles the customer snapshot.intercom_conversations.pyretrieves details for selected conversations. Their shared code fetches additional pages and retries certain temporary failures. The skill explains the result limits and how to report missing information.The agent decides what matters for the call. It reads the customer’s messages, identifies unresolved issues or promises, and recommends what to discuss. Retrieving a conversation does not tell it whether the customer’s problem was actually solved.
Make the script easy to use and check
Ask your agent to include these details in the skill.
What goes in and comes out The information the script needs and what its result means.
What it changes Whether it only reads information or also creates files or updates records.
What to do when it fails How to handle missing inputs, errors, or unexpected results.
How to check it Test with a known answer before relying on it. For this example, include a customer call that should match and an internal meeting that should not.
# Match customer calls
Run match_calls.py before researching the calls.
## Inputs and results
Supply calendar events with attendee emails
and customer records with emails and domains.
Use the returned matches to select calls to brief.
## Changes
Read the supplied records only.
Do not update the calendar or customer records.
## If something goes wrong
If attendee emails or customer records are missing,
report the gap instead of guessing a match.
If the script fails, report the error.
Do not treat a failed lookup as “no customer calls.”
## Check the result
Test with a known customer call and an internal meeting.
Confirm that only the customer call matches.
Check that a shared Gmail domain does not create a match.Keep the method and code in agreement
If the skill promises a check that the script does not perform, fix the mismatch. Adding more reminders to the System Prompt will not repair the matching logic.
Test the three together on a fresh job
Ask your agent to save the updated System Prompt and skills, make the skills available through its knowledge settings, and confirm anything you still need to review.
Then start a fresh thread with that agent selected, using a different customer or date. Supply the request and its source material. Check the recorded skill reads and script execution as well as the finished result, without repeating the original coaching.
- Behavior: did it follow the System Prompt’s standards and boundaries?
- Process: did it read the right skill’s full instructions, follow the method, and complete its checks? Finding the summary alone is not enough.
- Computation: did it run the script with the right inputs and verify the result?
- Missing information: did it identify gaps rather than inventing an answer?
If something fails, update the responsible part. Fix standing behavior in the System Prompt, missing steps in the skill, and incorrect matching or calculations in the script. Supply missing task facts through the request and sources.
What success looks like
You ask for tomorrow’s call brief and supply any new sources. The agent uses the saved method, matches the right customer calls, produces the agreed format, and flags missing information without needing the same reminders. You can spend your review on the substance instead of teaching the process again.
Once the workflow is dependable, learn how to spend less running it.