If you run an agency or sell automation to small businesses, you have probably built the same thing more than once: a custom agent for client A, a near copy for client B, and a third for client C. Each one learns slowly, and when you fix a mistake in one, the other two keep making it. A post published on 14 November 2026 by LangChain, "Goal Engineering: How to Design Goals", by Harrison Chase with M. Garimella and A. Gupta of Actively AI, describes how one company changed its agent design to fix exactly this problem. The pattern is simple enough to copy this weekend.
The pattern
The authors argue that you should scope an agent so that it is as easy as possible for a person to give it feedback while it works. Their reasoning: agents often fail because they lack the right context, and the hardest context to supply is the kind that is written down nowhere. It lives in an expert's head (how aggressive to be, what tone suits the brand, when to push and when to wait) and the agent only learns it through human feedback.
Their case study is Actively AI, which builds agents for sales teams. According to the post, Actively's first version gave each account (a prospective customer) its own agent, tasked with moving that account forward. The team found that the agent also needed a second kind of context: how to do the job well, such as how to write outbound emails, how to reply and how to plan a deal. A lesson about outbound learned on one account was usually wanted on every other account, yet it was trapped inside one agent. Reviewers also had to keep switching between agents, because each had only a few items waiting at any time.
The second version, built on LangChain's Deep Agents, organises agents around "motions". A motion is a job to be done, like outbound or early-stage deal progression, and it runs across many accounts. Because a motion is a set of similar tasks, a salesperson can review them together, and feedback on one task carries over to the rest. Account facts still matter, the authors say, but they are usually written down and objective, so Actively has context-gathering agents assemble them in the background and each motion pulls in an account's context as needed.
For a solo builder, the translation is direct: build one agent per job instead of one per client, run it across all clients from a shared store of client facts, and route every correction into that job's instructions so all clients benefit.
When to use it and when not
Use it when you do the same kind of work for several clients: follow-up emails, weekly reports, social posts, proposal drafts, review replies. The test is whether a correction you give for one client would also be right for another. If you catch yourself typing the same fix twice, the job is a good candidate.
Hold back in three cases. First, when one client's work is truly unlike anything else you do; a single bespoke agent is simpler there. Second, when a client's contract or data rules forbid their data sitting in a shared store; keep that client in a separate project. Third, when the "lesson" is really a client preference (one client hates exclamation marks). That belongs in the client's facts row, not in the job's shared instructions. Keeping those two apart is most of the skill.
How it works (input → step → output)
Input: a facts table with one row per client (business, offer, audience, tone notes, do-not-say list, last updated date) plus the work item, such as a lead that needs a follow-up.
Step: the job agent loads its instructions, appends its lessons list, pulls only the matching client's row, and drafts the output.
Output: a draft placed in a review queue, grouped by job. You approve, edit or reject. If you edit, you tag the reason as either a job lesson (applies to everyone) or a client note (applies to this client only), and the system saves it to the right place.
Components
Facts table: one row per client, kept current by a background workflow that pulls from your CRM, intake form or website notes.
Job agents: one workflow per recurring job, each with its own instructions and its own lessons list.
Review queue: a table or board filtered by job, so you review all follow-ups in one sitting, then all reports.
Lessons store: a short, dated list per job that gets appended to the job prompt on every run.
Router for corrections: a simple choice on each edit, "job lesson" or "client note", that decides where the correction is written.
Minimal implementation
In n8n, use Data tables for the facts table, the review queue and the lessons, or a Google Sheet if your clients already live there. n8n's docs say data tables suit light to moderate storage and that, by default, tables in a project are visible to every team member in that project, which is worth knowing before you put client data in them.
Build one workflow per job. Here is the outline for a follow-up job, written as pseudo-code:
TRIGGER: new lead row where job = "follow_up" and status = "new"
client = facts.get(where client_id = lead.client_id) // exactly one row, or stop
if client.updated_at older than 30 days: flag "stale facts" and stop
lessons = lessons.list(where job = "follow_up" and active = true)
prompt = JOB_INSTRUCTIONS + "\nLessons:\n" + lessons + "\nClient facts:\n" + client + "\nLead:\n" + lead
draft = LLM(prompt)
review_queue.add(job = "follow_up", client_id, lead_id, draft, status = "pending")
Then a second, small workflow handles reviews:
ON review_queue row updated where status = "edited"
if edit.scope = "job": lessons.add(job, edit.reason, source_client_id, date)
if edit.scope = "client": facts.append_note(client_id, edit.reason)
send approved text
Keep each lesson to one sentence, written as a rule ("Open with the lead's question before any offer"). Store which client it came from, so you can trace it later. The 30-day staleness threshold above is an illustrative choice; set your own. The key design rule is that the client filter lives in code, where the model cannot override it. That idea is covered in our earlier post on keeping order in code and judgment in the prompt.
Failure modes and evals
Cross-client data leakage. The agent sees one client's facts while writing for another. Prevent it by fetching a single row by ID and stopping if the count is not one. Test: run the job for client A and search the draft for client B's name, product and domain. Any match fails the run. Pair this with tight credentials per workflow, as in our post on plan-scoped credentials for agents.
A correction for one client generalises wrongly. You note "keep it formal" for a law firm, tag it as a job lesson by mistake, and your café client starts getting stiff emails. Test: when a new lesson is added, re-run the last approved draft for two other clients and compare. If either changes in a way you would not approve, demote the lesson to a client note.
Stale facts. The agent quotes last season's offer. Test: the staleness check in the pseudo-code, plus a weekly report of rows past their date.
Lesson bloat. Lessons pile up and start to contradict each other. Test: once a month, read the list aloud, merge duplicates and retire anything you would no longer approve.
Build-it-this-weekend exercise
Pick one job you do for at least three clients, such as lead follow-ups.
Create a facts table with one row per client and a last-updated date.
Write the job instructions in ten lines or fewer.
Build the job workflow and the review workflow from the pseudo-code above.
Run five items per client, review them in one sitting, and tag every edit as job or client.
Run the leakage test and the generalisation test before you send anything live.
The point the LangChain and Actively authors keep returning to is that review is where the agent learns. Shape the agent around the work you can review quickly, and each fix you make reaches every client you serve.
Sources
"Goal Engineering: How to Design Goals", H. Chase, M. Garimella (Actively AI) and A. Gupta (Actively AI), LangChain blog, 14 November 2026: https://www.langchain.com/blog/goal-engineering
Actively AI, company website, accessed 15 November 2026: https://www.actively.ai/
Deep Agents, LangChain, GitHub repository, accessed 15 November 2026: https://github.com/langchain-ai/deepagents
"Data tables", n8n Docs, accessed 15 November 2026: https://docs.n8n.io/build/work-with-data/data-tables

