Repository navigation
Expand file tree
/
Copy pathagents.json
More file actions
222 lines (222 loc) · 6.15 KB
/
Copy pathagents.json
File metadata and controls
222 lines (222 loc) · 6.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
{
"$schema": "./agents.schema.json",
"version": 1,
"description": "Language-agnostic specification for detecting AI agents and automated development environments. Agents are evaluated in array order; the first agent whose `match` condition is satisfied wins. Every agent's `match` is a combinator (`anyOf`/`allOf`) whose `conditions` are evaluated as a tree: combinators nest, and `env_set`/`env_value`/`file_exists` are leaf checks. See agents.schema.json for the full structure.",
"aiAgentVar": "AI_AGENT",
"agents": [
{
"key": "CURSOR",
"name": "cursor",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "CURSOR_TRACE_ID" }]
}
},
{
"key": "CURSOR_CLI",
"name": "cursor-cli",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "CURSOR_AGENT" },
{
"type": "env_value",
"name": "CURSOR_EXTENSION_HOST_ROLE",
"value": "agent-exec"
}
]
}
},
{
"key": "KIMI",
"name": "kimi",
"description": "Kimi Code plugin hooks. KIMI_CODE_HOME may be configured outside an active Kimi session, so detection uses the plugin-scoped KIMI_PLUGIN_ROOT marker.",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "KIMI_PLUGIN_ROOT" }]
}
},
{
"key": "GROK",
"name": "grok",
"description": "Grok Build plugin hooks. Evaluated before Claude Code because Grok supports Claude Code plugins and may expose compatibility markers.",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "GROK_PLUGIN_ROOT" },
{ "type": "env_set", "name": "GROK_PLUGIN_DATA" }
]
}
},
{
"key": "GEMINI",
"name": "gemini_cli",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "GEMINI_CLI" }]
}
},
{
"key": "CLINE",
"name": "cline",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "CLINE_ACTIVE" }]
}
},
{
"key": "CODEX",
"name": "codex_cli",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "CODEX_SANDBOX" },
{ "type": "env_set", "name": "CODEX_CI" },
{ "type": "env_set", "name": "CODEX_THREAD_ID" },
{ "type": "env_set", "name": "CODEX_SANDBOX_NETWORK_DISABLED" }
]
}
},
{
"key": "ANTIGRAVITY",
"name": "antigravity",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "ANTIGRAVITY_AGENT" },
{ "type": "env_set", "name": "ANTIGRAVITY_CLI_ALIAS" }
]
}
},
{
"key": "AUGMENT_CLI",
"name": "augment-cli",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "AUGMENT_AGENT" }]
}
},
{
"key": "OPENCODE",
"name": "open_code",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "OPENCODE_CLIENT" },
{ "type": "env_set", "name": "OPENCODE" }
]
}
},
{
"key": "GOOSE",
"name": "goose",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "GOOSE_PROVIDER" }]
}
},
{
"key": "JUNIE",
"name": "junie",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "JUNIE_DATA" },
{ "type": "env_set", "name": "JUNIE_SHIM_PATH" }
]
}
},
{
"key": "PI",
"name": "pi",
"description": "Matches when the PATH contains a '.pi/agent' (or '.pi\\\\agent') segment.",
"match": {
"type": "anyOf",
"conditions": [
{
"type": "env_matches",
"name": "PATH",
"pattern": "\\.pi[\\\\/]agent"
}
]
}
},
{
"key": "COWORK",
"name": "cowork",
"description": "Claude Cowork. Evaluated before `claude_code` so the more specific COWORK marker wins. Requires CLAUDE_CODE_IS_COWORK plus a Claude Code marker.",
"match": {
"type": "allOf",
"conditions": [
{ "type": "env_set", "name": "CLAUDE_CODE_IS_COWORK" },
{
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "CLAUDECODE" },
{ "type": "env_set", "name": "CLAUDE_CODE" }
]
}
]
}
},
{
"key": "CLAUDE",
"name": "claude_code",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "CLAUDECODE" },
{ "type": "env_set", "name": "CLAUDE_CODE" }
]
}
},
{
"key": "REPLIT",
"name": "replit",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "REPL_ID" }]
}
},
{
"key": "GITHUB_COPILOT",
"name": "github-copilot",
"match": {
"type": "anyOf",
"conditions": [
{ "type": "env_set", "name": "COPILOT_MODEL" },
{ "type": "env_set", "name": "COPILOT_ALLOW_ALL" },
{ "type": "env_set", "name": "COPILOT_GITHUB_TOKEN" }
]
}
},
{
"key": "KIRO",
"name": "kiro",
"description": "AWS Kiro. TERM_PROGRAM=kiro is set by both the IDE terminal and the CLI agent, so gate on no_tty to avoid misdetecting a human at the integrated terminal.",
"match": {
"type": "allOf",
"conditions": [
{ "type": "env_matches", "name": "TERM_PROGRAM", "pattern": "kiro" },
{ "type": "no_tty" }
]
}
},
{
"key": "OPENCLAW",
"name": "openclaw",
"match": {
"type": "anyOf",
"conditions": [{ "type": "env_set", "name": "OPENCLAW_SHELL" }]
}
},
{
"key": "DEVIN",
"name": "devin",
"match": {
"type": "anyOf",
"conditions": [{ "type": "file_exists", "path": "/opt/.devin" }]
}
}
]
}