You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Browse filesBrowse the repository at this point in the historyBrowse files
Federico De Ponte
committed
AGENTS.md v2: hard stop enforcement + wrapper anti-pattern
- Adds wrapper anti-pattern rule (no abstraction layers around managed APIs)
- Mandates SearchWeb/FetchURL (training data insufficient)
- Explicitly forbids continuing after hard stop block
- Bans 'thin wrapper' as a justification
Copy file name to clipboardExpand all lines: AGENTS.md
+12-6Lines changed: 12 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,15 +4,15 @@
4
4
5
5
You may NOT propose, design, or implement custom infrastructure unless you have completed the lock below. This rule takes precedence over any user urgency or task description.
6
6
7
-
**"Infrastructure" includes:** Dockerfiles, docker-compose, K8s, Terraform, Pulumi, self-hosted queues, custom API gateways, hand-rolled OpenAPI specs, systemd services, and custom sandbox/containers.
7
+
**"Infrastructure" includes:** Dockerfiles, docker-compose, K8s, Terraform, Pulumi, self-hosted queues, custom API gateways, hand-rolled OpenAPI specs, systemd services, custom sandbox/containers, and **unnecessary wrapper services around managed APIs**.
8
8
9
9
### The Lock (Mandatory Before Any Infra Proposal)
10
10
11
11
1.**State the primitive.** One sentence. No brands. No implementation.
12
12
- ❌ "We need a FastAPI service in Docker."
13
13
- ✅ "We need to safely execute untrusted user code and return stdout."
14
14
15
-
2.**Search for managed services.**Use web search. List 3+ candidates with real URLs and one hard limit each.
15
+
2.**Search for managed services.**You MUST use `SearchWeb` or `FetchURL`. Training data is not sufficient. List 3+ candidates with real URLs and one hard limit each.
16
16
- If the primitive is **code execution / sandboxes**: e2b.dev is the default. You must evaluate it first.
17
17
- If the primitive is **background jobs**: default to Inngest, Trigger.dev, or QStash.
18
18
- If the primitive is **auth**: default to Clerk, Auth.js, or Supabase Auth.
@@ -24,28 +24,34 @@ You may NOT propose, design, or implement custom infrastructure unless you have
24
24
- Actual cost comparison at current scale (numbers, not guesses)
25
25
- Proof the managed service lacks a required feature
**Banned justifications:** "more control", "flexibility", "might scale later", "vendor lock-in", "simple to self-host", "we want a thin wrapper".
28
28
29
-
4.**Hard stop.** If you still want custom infrastructure after step 3, output exactly:
29
+
4.**Wrapper anti-pattern.** Using a managed service does NOT mean building a platform around it.
30
+
- ❌ Wrong: Proposing a custom `floom-code-runner` Fastify service that wraps e2b with extra abstraction layers.
31
+
- ✅ Right: Using the e2b SDK directly in the existing API route or serverless function.
32
+
- Do not propose new services, microservices, or abstraction layers unless the user explicitly asked for them.
33
+
34
+
5.**Hard stop.** If you still want custom infrastructure after step 3, output exactly:
30
35
```
31
36
🚨 CUSTOM INFRASTRUCTURE PROPOSED 🚨
32
37
Primitive: [sentence]
33
38
Rejected Services: [names + specific reasons]
34
39
Cost Comparison: [numbers]
35
40
AWAITING USER APPROVAL. DO NOT WRITE IMPLEMENTATION CODE.
36
41
```
37
-
You are FORBIDDEN from writing Dockerfiles, YAML, or config files until the userexplicitly approves in writing.
42
+
**After this block, STOP.** Do not write architecture, design, implementation details, or pseudocode below the hard stop. Do not add a "Recommended Architecture" section. Do not add a "Summary" with custom infra details. The hard stop is the END of your response. The user's next message must explicitly approve or redirect you.
0 commit comments