AigentFlow Desktop is in pre-release. This documentation reflects the current build and will change before general availability.
Keeping control
Rules and limits
Two different things carry the word rule in AigentFlow. One stops an agent mid-action. The other tells it what you expect. Knowing which is which saves a lot of confusion.
Limits that stop an action
These are checked before a tool runs, outside the agent’s reach: the session mode itself, the file budget, the loop guard, the dangerous command list and the blocked paths. They are covered on the session modes page. They are the only things that refuse an action outright.
Constraint rules
A constraint rule is a standard you want the project held to. It does two jobs, and neither of them is blocking a tool call.
- It watches your files. While a project is being watched, a rule that trips raises a violation naming the file and the reason, and the app counts it against the project.
- It becomes an instruction. Syncing writes the enabled rules into the project’s
CLAUDE.mdas prose the agent reads, each one marked MUST, SHOULD or MAY according to its severity.
The number of active rules travels with every instruction you send, so the agent knows how many standards it is working under even before it reads them.
The four kinds
| Type | What it checks |
|---|---|
| File pattern | A path against a pattern you supply |
| Banned import | An import or require of a module you do not want used |
| Required file | That a file exists, checked at start and then periodically |
| Naming convention | That a filename matches the shape you expect |
Each rule carries a severity of error, warning or info, and applies either to one project or to all of them. Nineteen templates are supplied across Security, Quality, Structure, Naming and Governance, covering things like hardcoded secrets, eval, the any type, disabled tests, a missing README and force-push flags. A template pre-fills the form, and you can edit anything before saving.
Syncing a project that already has a hand-written CLAUDE.md does not overwrite it. The generated block is added after a divider, and marked so the app knows which part is its own.
Behaviour rules
Separately from constraints, twenty-three behaviour rules travel with your instructions. They are grouped by when they apply: before acting, while working, and when claiming done. They cover the failures people actually hit, such as not assuming, not refactoring what you were not asked to touch, not weakening a test to make it pass, not claiming a command passed, and not saying done without evidence.
You can switch individual rules off. Two are off by default: reproducing the failure before fixing it, and not agreeing before checking.
As the context window fills, fewer rules are sent. The app rotates across the three groups rather than cutting the list short, so the rules about claiming completion do not quietly disappear at the point they matter most.
Thresholds
One threshold is yours to set. Context threshold is 70 by default and adjustable between 40 and 90. Once a session has used that share of its context window, the app prompts a handover, which carries the work into a fresh session before the conversation degrades.
Constraint rules live under the developer tools. If your sidebar shows Home, Ideas, Tech Lead and Settings, turn on Show the developer tools in Settings to reach them.