@@ -1,4 +1,8 @@
1-# AGENTS.md
1+# Global Agent Instructions
2+
3+- Be concise and less verbose
4+- No performative apologies. Don't say "sorry", "I apologize", or explain why you "should have known better". Just state what happened and move forward.
5+- Use a casual non-enterprise tone.
26
37 ## Instruction fidelity
48
@@ -12,30 +16,38 @@ When the user asks for a specific change, do exactly that and nothing more.
1216
1317 This is the default behavior.
1418
15-## Web search with Exa HTTP API (via curl)
16-
17-Use the `EXA_API_KEY` environment variable and call Exa directly with `curl`.
19+## Web research with Exa
1820
19-### Basic search
21+An Exa API key is available in the `EXA_API_KEY` environment variable.
22+Use it via curl for web search and content extraction when research
23+is needed (e.g., gathering best practices, checking recent trends,
24+reading documentation).
2025
26+**Search:**
2127 ```bash
22-curl -sS https://api.exa.ai/search \
28+curl -s "https://api.exa.ai/search" \
2329 -H "x-api-key: $EXA_API_KEY" \
2430 -H "Content-Type: application/json" \
25- -d '{"query":"your query","numResults":5}'
31+ -d '{
32+ "query": "your search query",
33+ "numResults": 10,
34+ "type": "auto",
35+ "contents": {"text": {"maxCharacters": 3000}}
36+ }' | jq -r '.results[] | "## \(.title)\n\(.url)\n\(.text[:1500])\n---"'
2637 ```
2738
28-### Include page text in results
29-
39+**Fetch full content from a known URL:**
3040 ```bash
31-curl -sS https://api.exa.ai/search \
41+curl -s "https://api.exa.ai/contents" \
3242 -H "x-api-key: $EXA_API_KEY" \
3343 -H "Content-Type: application/json" \
34- -d '{"query":"your query","numResults":5,"contents":{"text":true}}'
44+ -d '{
45+ "ids": ["https://example.com/article"],
46+ "text": {"maxCharacters": 12000}
47+ }' | jq -r '.results[0].text'
3548 ```
3649
37-### Notes
50+Adjust `maxCharacters` and `numResults` based on how much context
51+you need. Use search for discovery, then fetch full content for
52+the most relevant results.
3853
39-- Use `-sS` for clean output with visible errors.
40-- Add `-w "\nHTTP_STATUS:%{http_code}\n"` when you want an explicit status code.
41-- The API key must be sent in the `x-api-key` header.