Chapter 3. Rules and Skills — No Moving Needed
Required Read this to follow this stage.In one line: Antigravity reads
AGENTS.mdin your folder as an always-on rule, and automatically picks skills from.agents/skills. The files you made in the Codex chapters work as they are. You will verify this with the same memo: once withAGENTS.mdmoved out of the way, and once after putting it back.
First, let's go over two words.
- A rule file is a file that lists the promises the AI keeps every time it works in this folder.
- A skill is a bundle of instructions that writes down the steps for a task you do often.
You can find a more detailed explanation in Claude Code Chapters 6 and 7 (optional).
The results in this chapter come from this guide running the terminal program agy itself. The app and CLI use the same agent (Chapter 1), so you can follow along in the app too.[1]
Where Antigravity Looks
Antigravity looks for rules and skills in fixed folders.[2]
| What | This folder (project) | All my folders |
|---|---|---|
| Rules | AGENTS.md, GEMINI.md, .agents/rules/ | ~/.gemini/AGENTS.md, etc. |
| Skills | .agents/skills/name/SKILL.md | ~/.gemini/config/skills/ |
Source: Antigravity official docs (excerpted)[2:1][3][4]
The file names and locations match what you made in the Codex chapters. That means the rule file AGENTS.md and the skill folder .agents/skills. So you can open your organizer folder as is, without moving anything.
CLAUDE.md is not on the list of rule files.[5] If you have rules that you only kept in Claude Code, write them in AGENTS.md too (for the same reason as in Codex Chapter 3).
You write AGENTS.md as is, without adding any settings lines at the very top of the file. And its entire content stays turned on at all times (always_on).[6] Edited rules and skills apply right away starting from your next message.[7]
Quick check
Which file names does Antigravity read as rule files in this folder?
Testing with the Same Memo
AGENTS.md has the rule we added in Codex Chapter 3: "Put a 'Check against the original (원본과 대조할 것)' section at the very bottom of the organized file." Because this rule is only in AGENTS.md, checking whether the result has that section tells you whether AGENTS.md was read.
We ran it twice with the exact same memo and the exact same request. The conditions must be the same to know whether a difference comes from AGENTS.md.[8]
Organize the memo inbox/meeting-2026-10-27-weekly.txt into meeting notes and save it as a new file in the notes/ folder.| Run | "Check against the original" section |
|---|---|
With AGENTS.md moved out of the folder | None |
After putting AGENTS.md back | Present |
Source: Practice results from this guide (2026-11-01, 1 run each)
Results: Without AGENTS.md · With AGENTS.md
Looking at the run logs makes the difference even clearer.
- When
AGENTS.mdwas missing: The agent searched for and openedAGENTS.md,CLAUDE.md, andGEMINI.mdon its own. - When
AGENTS.mdwas present: It followed the new rule without opening that file separately. That is likely because the file was already loaded from the start as an always-on rule.
In both runs, the agent opened and read CLAUDE.md on its own. It was not loaded automatically as a rule file. This suggests the agent can read it as reference material if it is in the folder.
However, these results come from running each test only once. Also, this computer had a personal rule file (~/.gemini/GEMINI.md) that was loaded during the runs. So we cannot tell whether reading CLAUDE.md was influenced by it. Read this as what we saw in this practice, not as a firm rule.
There was also one wrong date. In the meeting notes created with AGENTS.md present, the deadline for researching mulled wine cost was written as 10/30(Fri) instead of 10/31(Fri) (the memo says "by Friday"). Even when the rule section is followed, dates can still be wrong. Do not let the "Check against the original" section make you let your guard down—check it against the original yourself.
More details (click to expand)
- Even with the same memo, there was one more difference in the results. Codex fixed the day of the week in the memo to match the 2026 calendar, whereas Antigravity kept the day of the week written in the memo (
10/27(Mon)). The days of the week in the practice memos were made up for the story and do not match the real calendar. Different tools make different calls like this, so always check dates against your original.
Quick check
How did this guide test whether AGENTS.md was actually being read?
Skills Are Picked Automatically
On every turn, the agent looks at the list of skill names and descriptions (description). When a skill fits the task, the agent reads its full instructions.[9] You do not need to tell it to use a skill every time, though you can mention the skill by name if you want to make sure it gets used.[10]
In the two runs above, we never mentioned any skill, yet its very first action was reading .agents/skills/meeting-notes/SKILL.md. It recognized the skill we moved over in Codex Chapter 5 right away.
To call a skill yourself, type /skill-name in the app message box.[11] This differs from $name in Codex and matches /name in Claude Code.
/weekly-reviewIn this guide, we ran it in the terminal by naming the skill: "Organize this week's review using the weekly-review skill." The agent read .agents/skills/weekly-review/SKILL.md and created a weekly review from the three review memos.
Result: Weekly review made with the skill
All eight facts to check against the original memos were included: 12 likes, the 6,000-won pricing error, 4 sets, 11 in total, 3 Instagram posts, 1,800-won mulled wine, the light bulb, and 2 hours spent writing captions. In the review Codex made with the exact same skill, 3 facts were missing (Codex Chapter 5). This shows how results can differ from tool to tool even with the same instructions.
The result also has (Not in memo) marked in several places. That does not mean a fact is wrong; it shows that things required by the template, such as "why it went well" or "when to do it," were not in the memo. Along with checking for wrong or missing items, check whether notes like these are placed accurately.
Quick check
How do you call the weekly-review skill directly in the Antigravity app?
Conditional Rules and Saving What It Learns
When you have many rules, you can split them into files inside the .agents/rules/ folder. In the settings lines at the very top of each of these files, you must write when it should turn on (trigger). If you leave this out or write it wrong, the rule is silently discarded.[12]
The value must be exact, down to the spelling. For example, the value for always-on is always_on, in lowercase with an underscore. If you write it run together like alwaysOn, it is not recognized and is discarded.[12:1][6:1] When you only have a few lines of rules like in our organizer folder, a single AGENTS.md file is enough.
Use rules for "things to always follow" and skills for "multi-step tasks."[13] For example, "Write dates like 10/27(Mon)" is a rule, while "Gather three review memos to make a weekly review" is a skill.
If you want to save something you corrected during a conversation as a rule or skill, type /learn in the message box. The agent proposes what to change and writes the file only after you approve it.[14]
For example, say you once corrected it during a conversation: "Write dates like 10/27(Mon)." If you then type /learn, the agent proposes saving this as a rule. It is written to the file only after you read it and approve.
Quick check
What must you include when creating a rule file inside the .agents/rules/ folder?
Try It Yourself
- Open the organizer folder as an Antigravity project (Chapter 2). Do not move anything.
- Ask it to organize a meeting memo, and check whether the "Check against the original" section appears at the very bottom of the result.
- If you want to be extra sure, temporarily move
AGENTS.mdsomewhere else, run the exact same request again, and compare. Put it back when you are done. - Create a weekly review with
/weekly-review, and count any wrong or missing items against the original memos.
Up next: Chapter 4 compares Antigravity's permission presets and undo feature with Claude Code and Codex.
Summary
- Antigravity reads
AGENTS.md,GEMINI.md, and.agents/skills. The files you made in Codex work as they are. - Tested with the same memo: 0 without
AGENTS.md→ 1 withAGENTS.md(the "Check against the original" section). - The agent picked the right skill on its own without being told. To call one yourself, type
/skill-name. - Files in
.agents/rules/must include atrigger. Use/learnto review and save lessons from a conversation.
Glossary
| Term | One-line meaning |
|---|---|
| always_on | A rule that stays turned on at all times |
| trigger | The setting that decides when to turn on a rule |
/learn | A command that proposes saving lessons from your chat as a rule or skill |
Finished this chapter?
Progress is saved only in this browser. See your progress on the full table of contents.
Next chapter: Chapter 4. Permissions and Undo
References (14)
This chapter is based on the Antigravity official docs checked on November 1, 2026, and the results of running Antigravity CLI
agy1.4.12 for this guide. For our hands-on test, this guide ranagyfrom inside another AI tool. Because the official FAQ does not support this kind of use on individual plans (Chapter 7), run it directly in the app or terminal when you follow along. ↩︎Antigravity official docs, "Customization discovery". "Workspace: the
.agents/folder in your project, plusAGENTS.mdandGEMINI.mdfiles." / "| Rules |rules/*.md,AGENTS.md,GEMINI.md|" / "| Skills |skills/<name>/SKILL.md|" antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Rules". "Standalone global files (no frontmatter needed, always active):
~/.gemini/AGENTS.md,~/.gemini/GEMINI.md,~/.gemini/config/AGENTS.md, or~/.gemini/config/GEMINI.md" antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Customization discovery". "To use a personal skill in both the Antigravity App and the Antigravity CLI, put it in
~/.gemini/config/skills/." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Rules". "You can place an
AGENTS.mdorGEMINI.mdfile—or a.agents/rules/directory—in your workspace folder and in any parent folder up to the repository root." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Rules". "
AGENTS.mdandGEMINI.mddo not use frontmatter. Antigravity treats its entire content as plain Markdown and keeps it continuously active (always_on)." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Customization discovery". "Antigravity rereads your rules and skills before each turn, so a new or edited file applies to your next message without a restart." antigravity.google (checked on 2026-11-01) ↩︎
During a review of the Codex chapters, it was pointed out that using different memos before and after is not a strict comparison. So this time, we ran it twice with the same memo. ↩︎
Antigravity official docs, "Agent skills". "On every turn, the agent sees a list of available skills with their names and descriptions. If a skill looks relevant to your task, the agent reads the full instructions and follows them." antigravity.google (checked on 2026-11-01) ↩︎
Antigravity official docs, "Agent skills". "You don’t need to explicitly tell the agent to use a skill—it decides based on context. However, you can mention a skill by name if you want to ensure it’s used." antigravity.google (checked on 2026-11-01) ↩︎
Antigravity official docs, "Agent skills". "Manual slash command: Type
/<skill-name>in the message box to explicitly invoke a skill." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Rules". "Every
.mdfile insiderules/must start with YAML frontmatter declaring a validtrigger." / "If a file in.agents/rules/*.mdomits frontmatter or specifies an unrecognizedtriggervalue (such as camelCasealwaysOnormodelDecision), Antigravity silently discards the rule." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Rules". "Rule vs. Skill: Write a rule for constraints and invariants (for example, “Always use
zodfor validation” or “Never importinternal/across packages”). Write a skill for multi-step workflows (for example, “How to run database migrations”)." antigravity.google (checked on 2026-11-01) ↩︎Antigravity official docs, "Slash commands overview". "The agent proposes changes in a
learning_proposal.mdartifact and writes files only after you approve." antigravity.google (checked on 2026-11-01) ↩︎