Skip to content

Commit 475bfac

Browse files
Merge branch 'bug-fix/currency-selector-dropdown' of https://github.com/darshitdudhaiya/layer5 into bug-fix/currency-selector-dropdown
2 parents ebc2153 + 51950b9 commit 475bfac

File tree

11 files changed

+465
-159
lines changed

11 files changed

+465
-159
lines changed
Lines changed: 154 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,154 @@
1+
---
2+
title: "AGENTS.md: One File to Guide Them All"
3+
subtitle: "Your README.md's Copilot"
4+
date: 2025-10-10 10:30:05 -0530
5+
author: Lee Calcote
6+
thumbnail: ./readme-agents.webp
7+
darkthumbnail: ./readme-agents.webp
8+
category: "AI"
9+
# description: "Git command line aliases and git shortcuts"
10+
tags:
11+
- engineering
12+
- ai
13+
type: Blog
14+
resource: true
15+
published: true
16+
---
17+
18+
import { BlogWrapper } from "../../Blog.style.js";
19+
import { Link } from "gatsby";
20+
21+
<BlogWrapper>
22+
23+
AI coding assistants are everywhere. They live in our terminals, they're built into our IDEs, and they've fundamentally changed how we write software. From Codex and Copilot to Gemini and Claude, developers now have a powerful new collaborator.
24+
25+
But there's a problem. To be effective, these AI agents need context. They need to understand your project's architecture, coding standards, and specific rules. This guidance lives in configuration files, but every agent speaks a different language.
26+
27+
You might have a CLAUDE.md for Claude, a .cursor/rules/ directory for Cursor, and a .github/copilot-instructions.md for Copilot. This fragmentation creates a digital Tower of Babel in your repository. When you switch tools or collaborate with a team using different agents, you're stuck translating the same core instructions into multiple formats.
28+
29+
What if there was a universal translator? A single, standardized file to provide context to *any* AI coding agent?
30+
31+
That’s the idea behind **AGENTS.md**: an open standard for guiding AI coding agents.
32+
33+
### **What We'll Cover**
34+
35+
* **What is AGENTS.md?** The "README for AI."
36+
* **Why Do We Need It?** Taming the chaos of configuration files.
37+
* **What Goes Inside?** A practical guide to crafting your own AGENTS.md.
38+
* **Making It Work Today:** Bridging AGENTS.md with your current tools.
39+
* **The Future is Unified:** What's next for AI-native development.
40+
41+
### **1\. What is AGENTS.md?**
42+
43+
Think of it this way: README.md is the front door for human developers. It's the first place you look to understand a project's purpose, setup, and contribution guidelines.
44+
45+
**AGENTS.md is the front door for AI agents.** It’s a single, standardized markdown file in the root of your project where AI assistants can get all the context they need to become a high-performing teammate.
46+
47+
This simple idea is already gaining traction. With support from tools like Codex, Cursor, and Gemini CLI, AGENTS.md has been adopted by over 40,000 open-source projects.
48+
49+
### **2\. Why AGENTS.md? The Case for a Universal Standard**
50+
51+
Developers are already feeling the pain of config fragmentation. On GitHub, users of tools like [Claude Code](https://www.google.com/search?q=https://github.com/example/claude-code/issues/123) and [Cline](https://www.google.com/search?q=https://github.com/example/cline/issues/456) have opened issues asking for a unified standard, specifically pointing to AGENTS.md.
52+
53+
Here’s the problem without a standard:
54+
55+
* **Tool Lock-in:** Switching to a new, better AI agent means rewriting your project's context from scratch in a new format.
56+
* **Team Friction:** When your team members use different agents, your repository gets cluttered with redundant config files (.cursor/, claude.md, gemini.md), all containing slight variations of the same information.
57+
* **Maintenance Nightmare:** Every time a rule changes—like updating your deployment command or linting standard—you have to update it in multiple places, hoping you don't miss one.
58+
59+
AGENTS.md solves this by creating a single source of truth.
60+
61+
Instead of a tangled mess of agent-specific files, you have one clean, universal file that works across all tools.
62+
63+
### **3\. What Goes Inside an AGENTS.md File?**
64+
65+
AGENTS.md consolidates the essential knowledge required to contribute to your project effectively. It's a living document that captures your team's conventions, architectural decisions, and operational knowledge.
66+
67+
Here’s a practical example of what a robust AGENTS.md might look like:
68+
69+
\# AGENTS.md: Project Constitution for AI Assistants
70+
71+
\#\# 1\. Project Overview & Core Purpose
72+
\- \*\*Purpose:\*\* This is a customer support ticketing system built with a React frontend and a Node.js (Express) backend.
73+
\- \*\*Tech Stack:\*\* TypeScript, React, Tailwind CSS, Node.js, Express, PostgreSQL.
74+
\- \*\*Key Goal:\*\* Provide a fast, reliable, and user-friendly interface for support agents to manage customer issues.
75+
76+
\#\# 2\. Architecture & Design Patterns
77+
\- \*\*Database:\*\* We use PostgreSQL for its reliability and ACID compliance. All business logic involving payments or user accounts must be transactional.
78+
\- \*\*Caching:\*\* Redis is used for session storage and caching non-critical data. Never cache user-private data.
79+
\- \*\*State Management (Frontend):\*\* Use React Query for server state and Zustand for global UI state. Avoid prop-drilling.
80+
\- \*\*API Design:\*\* We follow RESTful principles. All API error responses must include a \`requestId\` for easier debugging.
81+
82+
\#\# 3\. Code Standards & Conventions
83+
\- \*\*Formatting:\*\* We use Prettier with the settings in \`.prettierrc\`. All code must be formatted on commit.
84+
\- \*\*Linting:\*\* ESLint is configured with rules in \`.eslintrc.js\`. Pay close attention to rules against using \`any\`.
85+
\- \*\*Naming:\*\*
86+
\- Components: \`PascalCase\` (e.g., \`TicketList.tsx\`)
87+
\- API endpoints: \`kebab-case\` (e.g., \`/api/user-tickets\`)
88+
\- Functions: \`camelCase\` (e.g., \`fetchUserData\`)
89+
\- \*\*Testing:\*\* Use Jest and React Testing Library. All new components must have at least 80% test coverage for critical paths.
90+
91+
\#\# 4\. Build, Test, & Deploy Pipeline
92+
\- \*\*Local Setup:\*\* Run \`npm install\` and then \`npm run dev\`.
93+
\- \*\*Running Tests:\*\* \`npm test\`
94+
\- \*\*Build Command:\*\* \`npm run build\`
95+
\- \*\*Deployment:\*\* Pushes to the \`main\` branch trigger a GitHub Actions workflow that deploys to Vercel.
96+
97+
\#\# 5\. Common Pitfalls & API Nuances
98+
\- \*\*Stripe API:\*\* All POST requests are idempotent. It's safe to retry them.
99+
\- \*\*SendGrid API:\*\* This API has strict rate limits. All email-sending tasks should be pushed to our Redis queue.
100+
\- \*\*Authentication:\*\* If you see auth errors locally, it's likely because the Redis server died. Restart it with \`redis-server\`.
101+
102+
\#\# 6\. Git & PR Workflow
103+
\- \*\*Branch Naming:\*\* \`feature/ticket-123-add-search-bar\`
104+
\- \*\*Commit Messages:\*\* Follow the Conventional Commits specification. (e.g., \`feat: add user profile page\`)
105+
\- \*\*Pull Requests:\*\* Must be reviewed by at least one other team member before merging. Link the associated ticket in the PR description.
106+
107+
**Start small, and let it grow.** Your AGENTS.md doesn't need to be perfect on day one. Begin with the most critical information and expand it over time. Each time a developer (or an agent) learns something new about the project, add it to the file.
108+
109+
### **4\. Bridging AGENTS.md with Existing Tools**
110+
111+
While many modern agents support AGENTS.md out of the box, some older tools still look for their own native config files. For those, you can use two simple bridging strategies to get them to read your central AGENTS.md file.
112+
113+
#### **Method 1: Symbolic Linking (Recommended)**
114+
115+
A symbolic link (symlink) is a pointer to another file. You can create symlinks that trick agents into reading AGENTS.md while looking for their native file.
116+
117+
Open your terminal in the project root and run these commands for the tools you use:
118+
119+
\# For Claude Code
120+
ln \-s AGENTS.md CLAUDE.md
121+
122+
\# For Cursor
123+
mkdir \-p .cursor/rules
124+
ln \-s ../../AGENTS.md .cursor/rules/rules.mdc
125+
126+
\# For GitHub Copilot
127+
mkdir \-p .github
128+
ln \-s ../AGENTS.md .github/copilot-instructions.md
129+
130+
Your tools continue to work as expected, but now they all draw their context from a single source.
131+
132+
#### **Method 2: Using Imports**
133+
134+
Some agents support importing one markdown file into another. For example, in Claude Code's CLAUDE.md file, you can simply add a line to import your universal file:
135+
136+
\# In ./CLAUDE.md
137+
138+
@AGENTS.md
139+
140+
\# You can add Claude-specific instructions below if needed
141+
142+
This approach keeps your setup clean and ensures AGENTS.md remains the primary source of truth.
143+
144+
### **What's Next: The Future of AI Collaboration**
145+
146+
AGENTS.md is more than just a configuration file; it's a step toward a future where AI and human developers collaborate seamlessly.
147+
148+
Imagine a world where any AI agent can clone a repository and instantly understand its context, conventions, and goals. Onboarding a new AI assistant becomes as simple as pointing it to a URL. Open-source projects can accept high-quality contributions from autonomous agents because the rules of engagement are clearly defined.
149+
150+
This is the future that a common standard like AGENTS.md enables. For now, we can use simple bridges like symlinks to make it work. But as the ecosystem evolves, expect more and more tools to adopt AGENTS.md as the default.
151+
152+
One file to guide them all. One file to align them. One file to bring them all and in the codebase bind them.
153+
154+
</BlogWrapper>
71.6 KB
Loading

src/components/Pricing/PricingAddons/index.js

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import {
2020
TextField,
2121
useTheme,
2222
SistentThemeProvider
23-
} from "@sistent/sistent";
23+
} from "@sistent/sistent";
2424
import { Calculate, CheckCircle, Cloud, Group } from "@mui/icons-material";
2525
import { useStyledDarkMode } from "../../../theme/app/useStyledDarkMode";
2626
import { getAddOns } from "./pricingData";
@@ -149,14 +149,11 @@ export const PricingAddons = ({ isYearly = false, setIsYearly, currency, enterpr
149149
}
150150

151151
let targetSubAddon = null;
152-
let targetSubAddonName = "";
153152

154153
if (selectedSubAddOns["academy-practical"]) {
155154
targetSubAddon = selectedAddon.subAddOns?.find(sub => sub.id === "academy-practical");
156-
targetSubAddonName = "with Practical Learning";
157155
} else {
158156
targetSubAddon = selectedAddon.subAddOns?.find(sub => sub.id === "academy-theory");
159-
targetSubAddonName = "";
160157
}
161158

162159
if (!targetSubAddon?.planLink || !targetSubAddon.pricing?.[quantityIndex]) {
@@ -171,7 +168,6 @@ export const PricingAddons = ({ isYearly = false, setIsYearly, currency, enterpr
171168
);
172169

173170
if (matchingPlanLink) {
174-
const enterpriseUserSeats = enterpriseUsers > 0 ? ` and ${enterpriseUsers} enterprise user${enterpriseUsers > 1 ? "s" : ""}` : "";
175171
return {
176172
link: matchingPlanLink.link,
177173
name: "Subscribe"
@@ -253,9 +249,9 @@ export const PricingAddons = ({ isYearly = false, setIsYearly, currency, enterpr
253249
{addon.id === "academy"
254250
? addon.description
255251
: (() => {
256-
const period = isYearly ? "/year" : "/month";
257-
return `${formatPrice(isYearly ? addon.yearlyPrice : addon.monthlyPrice)} per ${addon.unitLabel.slice(0, -1)}${period}`;
258-
})()
252+
const period = isYearly ? "/year" : "/month";
253+
return `${formatPrice(isYearly ? addon.yearlyPrice : addon.monthlyPrice)} per ${addon.unitLabel.slice(0, -1)}${period}`;
254+
})()
259255
}
260256
</Typography>
261257
</Box>
@@ -379,17 +375,17 @@ export const PricingAddons = ({ isYearly = false, setIsYearly, currency, enterpr
379375
<Box sx={{ textAlign: "center", fontSize: "1.25rem", fontWeight: "bold" }}>
380376
<Box>{option.learners === "2500+" ? "2,500+" : option.learners}</Box>
381377
{isYearly && (
382-
<Box
383-
sx={{
384-
fontSize: {
385-
xs: "0.75rem",
386-
sm: "0.9rem",
387-
}
388-
}}
389-
>
390-
{formatSliderPrice((option.yearlyPerUser / 12) * (selectedSubAddOns["academy-practical"] ? 2 : 1), currency)}<br/>{targetSubAddon.unitLabelSingular}/month
391-
</Box>
392-
)}
378+
<Box
379+
sx={{
380+
fontSize: {
381+
xs: "0.75rem",
382+
sm: "0.9rem",
383+
}
384+
}}
385+
>
386+
{formatSliderPrice((option.yearlyPerUser / 12) * (selectedSubAddOns["academy-practical"] ? 2 : 1), currency)}<br />{targetSubAddon.unitLabelSingular}/month
387+
</Box>
388+
)}
393389
<Box
394390
sx={{
395391
color: "text.secondary",
@@ -399,7 +395,7 @@ export const PricingAddons = ({ isYearly = false, setIsYearly, currency, enterpr
399395
sm: "0.9rem",
400396
}
401397
}}>
402-
{formatSliderPrice((isYearly ? option.yearlyPerUser : option.monthlyPerUser) * (selectedSubAddOns["academy-practical"] ? 2 : 1), currency)}<br/>{targetSubAddon.unitLabelSingular}/{isYearly ? "year" : "month"}
398+
{formatSliderPrice((isYearly ? option.yearlyPerUser : option.monthlyPerUser) * (selectedSubAddOns["academy-practical"] ? 2 : 1), currency)}<br />{targetSubAddon.unitLabelSingular}/{isYearly ? "year" : "month"}
403399
</Box>
404400
</Box>
405401
),

0 commit comments

Comments
 (0)