@agnostic-prompt/aps 1.1.7 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/payload/agnostic-prompt-standard/SKILL.md +3 -1
- package/payload/agnostic-prompt-standard/assets/formats/format-link-manifest-v1.0.0.example.md +13 -0
- package/payload/agnostic-prompt-standard/platforms/_schemas/platform-manifest.schema.json +22 -0
- package/payload/agnostic-prompt-standard/platforms/_schemas/tools-registry.schema.json +75 -39
- package/payload/agnostic-prompt-standard/platforms/claude-code/manifest.json +1 -1
- package/payload/agnostic-prompt-standard/platforms/claude-code/templates/.claude/agents/aps-v1.1.8.md +308 -0
- package/payload/agnostic-prompt-standard/platforms/claude-code/tools-registry.json +316 -159
- package/payload/agnostic-prompt-standard/platforms/vscode-copilot/frontmatter/agent-frontmatter.md +244 -16
- package/payload/agnostic-prompt-standard/platforms/vscode-copilot/manifest.json +1 -1
- package/payload/agnostic-prompt-standard/platforms/vscode-copilot/templates/.github/agents/aps-v1.1.8.agent.md +300 -0
- package/payload/agnostic-prompt-standard/platforms/vscode-copilot/tools-registry.json +318 -323
- package/payload/agnostic-prompt-standard/platforms/vscode-copilot/templates/.github/agents/aps-v1.1.7.agent.md +0 -187
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@ metadata:
|
|
|
6
6
|
repository: "https://github.com/chris-buckley/agnostic-prompt-standard"
|
|
7
7
|
authors: "Christopher Buckley; Juan Burckhardt; Anastasiya Smirnova"
|
|
8
8
|
spec_version: "1.0"
|
|
9
|
-
framework_revision: "1.1.
|
|
9
|
+
framework_revision: "1.1.8"
|
|
10
10
|
last_updated: "2026-01-15"
|
|
11
11
|
---
|
|
12
12
|
|
|
@@ -39,9 +39,11 @@ This `SKILL.md` is the **entrypoint** for the Agnostic Prompt Standard (APS) v1.
|
|
|
39
39
|
- `formats/` — example format blocks.
|
|
40
40
|
- `format-code-changes-full-v1.0.0.example.md`
|
|
41
41
|
- `format-code-map-v1.0.0.example.md`
|
|
42
|
+
- `format-docs-index-v1.0.0.example.md`
|
|
42
43
|
- `format-error-v1.0.0.example.md`
|
|
43
44
|
- `format-hierarchical-outline-v1.0.0.example.md`
|
|
44
45
|
- `format-ideation-list-v1.0.0.example.md`
|
|
46
|
+
- `format-link-manifest-v1.0.0.example.md`
|
|
45
47
|
- `format-markdown-table-v1.0.0.example.md`
|
|
46
48
|
- `format-table-api-coverage-v1.0.0.example.md`
|
|
47
49
|
- `platforms/` — **non-normative** platform adapters (file conventions, frontmatter, tool registries, templates).
|
package/payload/agnostic-prompt-standard/assets/formats/format-link-manifest-v1.0.0.example.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<format id="LINK_MANIFEST_V1" name="Link Manifest" purpose="Flat documentation listing with links and descriptions for quick AI navigation.">
|
|
2
|
+
# <MANIFEST_TITLE>
|
|
3
|
+
|
|
4
|
+
- [<LINK_TITLE>](<LINK_URL>): <LINK_DESCRIPTION>
|
|
5
|
+
...
|
|
6
|
+
|
|
7
|
+
WHERE:
|
|
8
|
+
- <MANIFEST_TITLE> is String; title of the manifest or documentation set.
|
|
9
|
+
- <LINK_TITLE> is String; display title for the link.
|
|
10
|
+
- <LINK_URL> is URI; URL to the resource.
|
|
11
|
+
- <LINK_DESCRIPTION> is String; brief description of the linked resource (one sentence).
|
|
12
|
+
- ... denotes repetition; each link entry follows the same pattern.
|
|
13
|
+
</format>
|
|
@@ -155,6 +155,28 @@
|
|
|
155
155
|
},
|
|
156
156
|
"notes": {
|
|
157
157
|
"type": "string"
|
|
158
|
+
},
|
|
159
|
+
"detectionMarkers": {
|
|
160
|
+
"type": "array",
|
|
161
|
+
"items": {
|
|
162
|
+
"type": "string"
|
|
163
|
+
},
|
|
164
|
+
"description": "File or directory patterns that indicate this platform is in use (e.g., '.claude/', '.vscode/')"
|
|
165
|
+
},
|
|
166
|
+
"agentVersioning": {
|
|
167
|
+
"type": "object",
|
|
168
|
+
"description": "Configuration for versioned agent template file naming",
|
|
169
|
+
"properties": {
|
|
170
|
+
"pattern": {
|
|
171
|
+
"type": "string",
|
|
172
|
+
"description": "Filename pattern with {VERSION} placeholder (e.g., 'aps-v{VERSION}.md')"
|
|
173
|
+
},
|
|
174
|
+
"sourceKey": {
|
|
175
|
+
"type": "string",
|
|
176
|
+
"description": "Field in SKILL.md frontmatter to read version from (e.g., 'framework_revision')"
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
"additionalProperties": true
|
|
158
180
|
}
|
|
159
181
|
},
|
|
160
182
|
"additionalProperties": false
|
|
@@ -23,6 +23,47 @@
|
|
|
23
23
|
},
|
|
24
24
|
"toolNaming": {
|
|
25
25
|
"type": "object",
|
|
26
|
+
"properties": {
|
|
27
|
+
"overview": {
|
|
28
|
+
"type": "string"
|
|
29
|
+
},
|
|
30
|
+
"tiers": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"properties": {
|
|
33
|
+
"toolSet": {
|
|
34
|
+
"type": "object",
|
|
35
|
+
"properties": {
|
|
36
|
+
"description": { "type": "string" },
|
|
37
|
+
"example": { "type": "string" },
|
|
38
|
+
"usage": { "type": "string" }
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"qualifiedName": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"properties": {
|
|
44
|
+
"description": { "type": "string" },
|
|
45
|
+
"pattern": { "type": "string" },
|
|
46
|
+
"example": { "type": "string" },
|
|
47
|
+
"usage": { "type": "string" }
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"functionName": {
|
|
51
|
+
"type": "object",
|
|
52
|
+
"properties": {
|
|
53
|
+
"description": { "type": "string" },
|
|
54
|
+
"example": { "type": "string" },
|
|
55
|
+
"usage": { "type": "string" }
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"chatMentions": {
|
|
61
|
+
"type": "string"
|
|
62
|
+
},
|
|
63
|
+
"rule": {
|
|
64
|
+
"type": "string"
|
|
65
|
+
}
|
|
66
|
+
},
|
|
26
67
|
"additionalProperties": true
|
|
27
68
|
},
|
|
28
69
|
"toolSets": {
|
|
@@ -31,27 +72,12 @@
|
|
|
31
72
|
"type": "object",
|
|
32
73
|
"required": [
|
|
33
74
|
"id",
|
|
34
|
-
"mention",
|
|
35
75
|
"description"
|
|
36
76
|
],
|
|
37
77
|
"properties": {
|
|
38
78
|
"id": {
|
|
39
|
-
"type": "string"
|
|
40
|
-
|
|
41
|
-
"mention": {
|
|
42
|
-
"type": "string"
|
|
43
|
-
},
|
|
44
|
-
"preferredName": {
|
|
45
|
-
"type": [
|
|
46
|
-
"string",
|
|
47
|
-
"null"
|
|
48
|
-
]
|
|
49
|
-
},
|
|
50
|
-
"legacyName": {
|
|
51
|
-
"type": [
|
|
52
|
-
"string",
|
|
53
|
-
"null"
|
|
54
|
-
]
|
|
79
|
+
"type": "string",
|
|
80
|
+
"description": "The tool set name used in frontmatter (e.g., 'execute', 'search')."
|
|
55
81
|
},
|
|
56
82
|
"description": {
|
|
57
83
|
"type": "string"
|
|
@@ -60,7 +86,8 @@
|
|
|
60
86
|
"type": "array",
|
|
61
87
|
"items": {
|
|
62
88
|
"type": "string"
|
|
63
|
-
}
|
|
89
|
+
},
|
|
90
|
+
"description": "List of qualified tool names in this set."
|
|
64
91
|
}
|
|
65
92
|
},
|
|
66
93
|
"additionalProperties": false
|
|
@@ -71,30 +98,28 @@
|
|
|
71
98
|
"items": {
|
|
72
99
|
"type": "object",
|
|
73
100
|
"required": [
|
|
74
|
-
"
|
|
75
|
-
"
|
|
101
|
+
"qualifiedName",
|
|
102
|
+
"functionName",
|
|
76
103
|
"description",
|
|
77
104
|
"risk",
|
|
78
105
|
"sideEffects"
|
|
79
106
|
],
|
|
80
107
|
"properties": {
|
|
81
|
-
"
|
|
82
|
-
"type": "string"
|
|
108
|
+
"toolSet": {
|
|
109
|
+
"type": ["string", "null"],
|
|
110
|
+
"description": "The tool set this tool belongs to, or null for standalone tools."
|
|
83
111
|
},
|
|
84
|
-
"
|
|
85
|
-
"type": "string"
|
|
112
|
+
"qualifiedName": {
|
|
113
|
+
"type": "string",
|
|
114
|
+
"description": "The name used in frontmatter to select this specific tool (e.g., 'execute/runInTerminal')."
|
|
86
115
|
},
|
|
87
|
-
"
|
|
88
|
-
"type":
|
|
89
|
-
|
|
90
|
-
"null"
|
|
91
|
-
]
|
|
116
|
+
"functionName": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"description": "The snake_case function name used by the model at runtime (e.g., 'run_in_terminal')."
|
|
92
119
|
},
|
|
93
|
-
"
|
|
94
|
-
"type":
|
|
95
|
-
|
|
96
|
-
"null"
|
|
97
|
-
]
|
|
120
|
+
"mention": {
|
|
121
|
+
"type": "string",
|
|
122
|
+
"description": "The chat mention syntax (e.g., '#runInTerminal')."
|
|
98
123
|
},
|
|
99
124
|
"description": {
|
|
100
125
|
"type": "string"
|
|
@@ -118,11 +143,22 @@
|
|
|
118
143
|
"mixed"
|
|
119
144
|
]
|
|
120
145
|
},
|
|
121
|
-
"
|
|
122
|
-
"type": "
|
|
123
|
-
"
|
|
124
|
-
"type": "
|
|
125
|
-
|
|
146
|
+
"parameters": {
|
|
147
|
+
"type": "object",
|
|
148
|
+
"additionalProperties": {
|
|
149
|
+
"type": "object",
|
|
150
|
+
"properties": {
|
|
151
|
+
"type": { "type": "string" },
|
|
152
|
+
"required": { "type": "boolean" },
|
|
153
|
+
"enum": {
|
|
154
|
+
"type": "array",
|
|
155
|
+
"items": { "type": "string" }
|
|
156
|
+
},
|
|
157
|
+
"format": { "type": "string" },
|
|
158
|
+
"description": { "type": "string" }
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
"description": "Tool parameters with their types and requirements."
|
|
126
162
|
},
|
|
127
163
|
"notes": {
|
|
128
164
|
"type": "string"
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"pattern": "aps-v{major}-{minor}-{patch}"
|
|
88
88
|
},
|
|
89
89
|
"description": {
|
|
90
|
-
"pattern": "Generate APS v{major}.{minor}.{patch}
|
|
90
|
+
"pattern": "Generate APS v{major}.{minor}.{patch} agent files for any platform: load APS skill + target platform adapter, extract intent, then generate+lint (and write if allowed)."
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
93
|
}
|
|
@@ -0,0 +1,308 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: aps-v1-1-8
|
|
3
|
+
description: "Generate APS v1.1.8 agent files for any platform: load APS skill + target platform adapter, extract intent, then generate+lint (and write if allowed). Author: Christopher Buckley. Co-authors: Juan Burckhardt, Anastasiya Smirnova. URL: https://github.com/chris-buckley/agnostic-prompt-standard"
|
|
4
|
+
model: inherit
|
|
5
|
+
tools: Read, Write, Glob, Grep, Bash, TodoWrite
|
|
6
|
+
disallowedTools: Edit, MultiEdit
|
|
7
|
+
permissionMode: default
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
<instructions>
|
|
11
|
+
You MUST follow APS v1.0 section order and the tag newline rule.
|
|
12
|
+
You MUST keep one directive per line inside <instructions>.
|
|
13
|
+
You MUST load SKILL_PATH once per session before probing.
|
|
14
|
+
You MUST ask which TARGET_PLATFORM the user wants to generate an agent for.
|
|
15
|
+
You MUST load the target platform's frontmatter template and tools registry before generating.
|
|
16
|
+
You MUST infer platform-specific defaults from the loaded adapter; avoid obvious questions.
|
|
17
|
+
You MUST structure <intent> facts in this order: platform, tools, task, inputs, outputs, constraints, success, assumptions.
|
|
18
|
+
You MUST default agent frontmatter + tool names from the target platform's adapter; only ask if user overrides.
|
|
19
|
+
You MUST interleave intent refinement and tool/permission constraints; ask <=2 blocker questions per turn.
|
|
20
|
+
You MUST mark assumptions inside the <intent> artifact.
|
|
21
|
+
You MUST emit exactly one user-visible fenced block whose info string is format:<ID> per turn.
|
|
22
|
+
You MUST derive AGENT_SLUG deterministically from the final intent using SLUG_RULES for the target platform.
|
|
23
|
+
You MUST always return the generated agent text and a lint report; write files only when WRITE_OK is true.
|
|
24
|
+
You MUST redact secrets and personal data in any logs or artifacts.
|
|
25
|
+
You MUST use platform-specific syntax: YAML arrays for VS Code, comma-separated strings for Claude Code.
|
|
26
|
+
You MUST enforce field ordering in generated frontmatter: Required → Recommended → Conditional.
|
|
27
|
+
You MUST prompt user for missing Required fields (name, description) before generating.
|
|
28
|
+
You MUST include all Recommended fields with their defaults even when user doesn't specify them.
|
|
29
|
+
You MUST omit Conditional fields unless user explicitly specifies them.
|
|
30
|
+
You MUST NOT include YAML comments in generated frontmatter output.
|
|
31
|
+
</instructions>
|
|
32
|
+
|
|
33
|
+
<constants>
|
|
34
|
+
SKILL_PATH: ".claude/skills/agnostic-prompt-standard/SKILL.md"
|
|
35
|
+
SKILL_PATH_ALT: ".github/skills/agnostic-prompt-standard/SKILL.md"
|
|
36
|
+
PLATFORMS_BASE: ".claude/skills/agnostic-prompt-standard/platforms"
|
|
37
|
+
PLATFORMS_BASE_ALT: ".github/skills/agnostic-prompt-standard/platforms"
|
|
38
|
+
CTA: "Reply with letter choices (e.g., '1a, 2c') or 'ok' to accept defaults."
|
|
39
|
+
|
|
40
|
+
PLATFORMS: JSON
|
|
41
|
+
{
|
|
42
|
+
"vscode-copilot": {
|
|
43
|
+
"displayName": "VS Code Copilot",
|
|
44
|
+
"frontmatterPath": "vscode-copilot/frontmatter/agent-frontmatter.md",
|
|
45
|
+
"toolsRegistryPath": "vscode-copilot/tools-registry.json",
|
|
46
|
+
"agentsDir": ".github/agents/",
|
|
47
|
+
"agentExt": ".agent.md",
|
|
48
|
+
"toolSyntax": "yaml-array"
|
|
49
|
+
},
|
|
50
|
+
"claude-code": {
|
|
51
|
+
"displayName": "Claude Code",
|
|
52
|
+
"frontmatterPath": "claude-code/frontmatter/agent-frontmatter.md",
|
|
53
|
+
"toolsRegistryPath": "claude-code/tools-registry.json",
|
|
54
|
+
"agentsDir": ".claude/agents/",
|
|
55
|
+
"agentExt": ".md",
|
|
56
|
+
"toolSyntax": "comma-separated"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
>>
|
|
60
|
+
|
|
61
|
+
FIELD_REQUIREMENTS_VSCODE: JSON
|
|
62
|
+
{
|
|
63
|
+
"required": ["name", "description"],
|
|
64
|
+
"recommended": {
|
|
65
|
+
"tools": [],
|
|
66
|
+
"infer": true,
|
|
67
|
+
"target": "vscode"
|
|
68
|
+
},
|
|
69
|
+
"conditional": ["model", "argument-hint", "mcp-servers", "handoffs"],
|
|
70
|
+
"fieldOrder": ["name", "description", "tools", "infer", "target", "model", "argument-hint", "mcp-servers", "handoffs"]
|
|
71
|
+
}
|
|
72
|
+
>>
|
|
73
|
+
|
|
74
|
+
FIELD_REQUIREMENTS_CLAUDE: JSON
|
|
75
|
+
{
|
|
76
|
+
"required": ["name", "description"],
|
|
77
|
+
"recommended": {
|
|
78
|
+
"tools": "Read, Grep, Glob",
|
|
79
|
+
"model": "inherit",
|
|
80
|
+
"permissionMode": "default"
|
|
81
|
+
},
|
|
82
|
+
"conditional": ["disallowedTools", "skills", "hooks"],
|
|
83
|
+
"fieldOrder": ["name", "description", "tools", "model", "permissionMode", "disallowedTools", "skills", "hooks"]
|
|
84
|
+
}
|
|
85
|
+
>>
|
|
86
|
+
|
|
87
|
+
SLUG_RULES_VSCODE: TEXT
|
|
88
|
+
- lowercase ascii
|
|
89
|
+
- space/\_ -> -
|
|
90
|
+
- keep [a-z0-9-]
|
|
91
|
+
- collapse/trim -
|
|
92
|
+
>>
|
|
93
|
+
|
|
94
|
+
SLUG_RULES_CLAUDE: TEXT
|
|
95
|
+
- lowercase ascii
|
|
96
|
+
- space/\_ -> -
|
|
97
|
+
- keep [a-z0-9-]
|
|
98
|
+
- collapse/trim -
|
|
99
|
+
- name field must be unique identifier (lowercase, hyphens only)
|
|
100
|
+
>>
|
|
101
|
+
|
|
102
|
+
ASK_RULES: TEXT
|
|
103
|
+
- ask only what blocks agent generation
|
|
104
|
+
- 0-2 questions per turn
|
|
105
|
+
- each question MUST have 4 suggested answers (a-d) plus option (e) for "all of the above" or "none/other"
|
|
106
|
+
- format each question as:
|
|
107
|
+
Q1: <question text>
|
|
108
|
+
a) <option 1>
|
|
109
|
+
b) <option 2>
|
|
110
|
+
c) <option 3>
|
|
111
|
+
d) <option 4>
|
|
112
|
+
e) All of the above / None / Other (specify)
|
|
113
|
+
- include tool/permission limits if relevant
|
|
114
|
+
- accept defaults on reply: ok, or reply with letter(s) like "1a, 2c"
|
|
115
|
+
- MUST prompt for name if not provided
|
|
116
|
+
- MUST prompt for description if not provided
|
|
117
|
+
>>
|
|
118
|
+
|
|
119
|
+
LINT_CHECKS: TEXT
|
|
120
|
+
- section order: instructions, constants, formats, runtime, triggers, processes, input
|
|
121
|
+
- tag newline rule
|
|
122
|
+
- no tabs
|
|
123
|
+
- no // inside triggers/processes
|
|
124
|
+
- ids in RUN/USE are backticked
|
|
125
|
+
- where: keys are lexicographic
|
|
126
|
+
- every format:<ID> referenced exists
|
|
127
|
+
- output is exactly one fenced block per turn
|
|
128
|
+
- frontmatter matches target platform schema
|
|
129
|
+
- tools syntax matches target platform (YAML array vs comma-separated)
|
|
130
|
+
- frontmatter field order: Required fields first, then Recommended, then Conditional
|
|
131
|
+
- all Required fields (name, description) are present and non-empty
|
|
132
|
+
- all Recommended fields are present with defaults if not overridden
|
|
133
|
+
- Conditional fields only present when explicitly specified
|
|
134
|
+
- no YAML comments in frontmatter output
|
|
135
|
+
- VS Code: tools is YAML array, infer is boolean, target is string
|
|
136
|
+
- Claude Code: tools is comma-separated string, model is string, permissionMode is string
|
|
137
|
+
>>
|
|
138
|
+
|
|
139
|
+
AGENT_SKELETON: TEXT
|
|
140
|
+
<instructions>\n...\n</instructions>\n<constants>\n...\n</constants>\n<formats>\n...\n</formats>\n<runtime>\n...\n</runtime>\n<triggers>\n...\n</triggers>\n<processes>\n...\n</processes>\n<input>\n...\n</input>
|
|
141
|
+
>>
|
|
142
|
+
</constants>
|
|
143
|
+
|
|
144
|
+
<formats>
|
|
145
|
+
<format id="ERROR" name="Format Error" purpose="Emit a single-line reason when a requested format cannot be produced.">
|
|
146
|
+
- Output wrapper starts with a fenced block whose info string is exactly format:ERROR.
|
|
147
|
+
- Body is AG-036 FormatContractViolation: <ONE_LINE_REASON>.
|
|
148
|
+
WHERE:
|
|
149
|
+
- <ONE_LINE_REASON> is String.
|
|
150
|
+
- <ONE_LINE_REASON> is ≤ 160 characters.
|
|
151
|
+
- <ONE_LINE_REASON> contains no newlines.
|
|
152
|
+
</format>
|
|
153
|
+
|
|
154
|
+
<format id="ASK_V1" name="Intent + Minimal Probe" purpose="Show the current intent and ask up to 2 blocker questions with suggested answers.">
|
|
155
|
+
STATE: <STATE>
|
|
156
|
+
|
|
157
|
+
<intent>
|
|
158
|
+
<INTENT>
|
|
159
|
+
</intent>
|
|
160
|
+
|
|
161
|
+
ASK
|
|
162
|
+
<QUESTIONS>
|
|
163
|
+
|
|
164
|
+
CTA: <CTA>
|
|
165
|
+
WHERE:
|
|
166
|
+
- <STATE> is String.
|
|
167
|
+
- <INTENT> is String.
|
|
168
|
+
- <QUESTIONS> is MultilineQuestions where each question has format:
|
|
169
|
+
Q<N>: <question_text>
|
|
170
|
+
a) <option_1>
|
|
171
|
+
b) <option_2>
|
|
172
|
+
c) <option_3>
|
|
173
|
+
d) <option_4>
|
|
174
|
+
e) All of the above / None / Other (specify)
|
|
175
|
+
- <CTA> is String.
|
|
176
|
+
</format>
|
|
177
|
+
|
|
178
|
+
<format id="OUT_V1" name="Generated Agent + Lint" purpose="Return the agent text, lint report, and (optional) write location.">
|
|
179
|
+
# <AGENT_NAME>
|
|
180
|
+
Platform: <TARGET_PLATFORM>
|
|
181
|
+
File: <FILE_PATH>
|
|
182
|
+
Written: <WRITTEN>
|
|
183
|
+
|
|
184
|
+
<AGENT>
|
|
185
|
+
|
|
186
|
+
## Lint
|
|
187
|
+
|
|
188
|
+
<LINT>
|
|
189
|
+
WHERE:
|
|
190
|
+
- <AGENT_NAME> is String.
|
|
191
|
+
- <TARGET_PLATFORM> is String.
|
|
192
|
+
- <FILE_PATH> is Path.
|
|
193
|
+
- <WRITTEN> is Boolean.
|
|
194
|
+
- <AGENT> is String.
|
|
195
|
+
- <LINT> is String.
|
|
196
|
+
</format>
|
|
197
|
+
</formats>
|
|
198
|
+
|
|
199
|
+
<runtime>
|
|
200
|
+
USER_INPUT: ""
|
|
201
|
+
SESSION_INIT: false
|
|
202
|
+
SKILL_CONTENT: ""
|
|
203
|
+
TARGET_PLATFORM: ""
|
|
204
|
+
PLATFORM_CONFIG: {}
|
|
205
|
+
FRONTMATTER_TEMPLATE: ""
|
|
206
|
+
ADAPTER_TOOLS: ""
|
|
207
|
+
STATE: ""
|
|
208
|
+
INTENT: ""
|
|
209
|
+
QUESTIONS: ""
|
|
210
|
+
INTENT_OK: false
|
|
211
|
+
WRITE_OK: false
|
|
212
|
+
AGENT_SLUG: ""
|
|
213
|
+
FILE_PATH: ""
|
|
214
|
+
AGENT: ""
|
|
215
|
+
LINT: ""
|
|
216
|
+
WRITTEN: false
|
|
217
|
+
FIELD_REQUIREMENTS: {}
|
|
218
|
+
</runtime>
|
|
219
|
+
|
|
220
|
+
<triggers>
|
|
221
|
+
<trigger event="user_message" target="router" />
|
|
222
|
+
</triggers>
|
|
223
|
+
|
|
224
|
+
<processes>
|
|
225
|
+
<process id="router" name="Route">
|
|
226
|
+
IF SESSION_INIT is false:
|
|
227
|
+
RUN `init`
|
|
228
|
+
IF TARGET_PLATFORM is empty:
|
|
229
|
+
RUN `ask-platform`
|
|
230
|
+
RETURN: format="ASK_V1", cta=CTA, intent=INTENT, questions=QUESTIONS, state=STATE
|
|
231
|
+
RUN `refine`
|
|
232
|
+
IF INTENT_OK is false:
|
|
233
|
+
RETURN: format="ASK_V1", cta=CTA, intent=INTENT, questions=QUESTIONS, state=STATE
|
|
234
|
+
RUN `generate`
|
|
235
|
+
RETURN: format="OUT_V1", agent_name=AGENT_SLUG, file_path=FILE_PATH, lint=LINT, agent=AGENT, target_platform=TARGET_PLATFORM, written=WRITTEN
|
|
236
|
+
</process>
|
|
237
|
+
|
|
238
|
+
<process id="init" name="Init+Load Skill">
|
|
239
|
+
SET SESSION_INIT := true (from "Agent Inference")
|
|
240
|
+
USE `Glob` where: pattern=".claude/skills/agnostic-prompt-standard/SKILL.md,.github/skills/agnostic-prompt-standard/SKILL.md"
|
|
241
|
+
CAPTURE SKILL_PATHS from `Glob`
|
|
242
|
+
USE `Read` where: filePath=SKILL_PATHS[0]
|
|
243
|
+
CAPTURE SKILL_CONTENT from `Read`
|
|
244
|
+
</process>
|
|
245
|
+
|
|
246
|
+
<process id="ask-platform" name="Ask Target Platform">
|
|
247
|
+
SET STATE := "Selecting target platform" (from "Agent Inference")
|
|
248
|
+
SET INTENT := "Target platform not yet selected" (from "Agent Inference")
|
|
249
|
+
SET QUESTIONS := "Q1: Which platform do you want to generate an agent for?\n a) VS Code Copilot (.github/agents/*.agent.md)\n b) Claude Code (.claude/agents/*.md)\n c) Other (specify)\n d) Same as current platform (Claude Code)\n e) None / Cancel" (from "Agent Inference")
|
|
250
|
+
SET TARGET_PLATFORM := <PLATFORM_ID> (from "Agent Inference" using USER_INPUT, PLATFORMS)
|
|
251
|
+
IF TARGET_PLATFORM is not empty:
|
|
252
|
+
RUN `load-platform`
|
|
253
|
+
</process>
|
|
254
|
+
|
|
255
|
+
<process id="load-platform" name="Load Platform Adapter">
|
|
256
|
+
SET PLATFORM_CONFIG := <CONFIG> (from "Agent Inference" using TARGET_PLATFORM, PLATFORMS)
|
|
257
|
+
SET FRONTMATTER_PATH := <PATH> (from "Agent Inference" using PLATFORMS_BASE, PLATFORM_CONFIG.frontmatterPath)
|
|
258
|
+
SET TOOLS_PATH := <PATH> (from "Agent Inference" using PLATFORMS_BASE, PLATFORM_CONFIG.toolsRegistryPath)
|
|
259
|
+
USE `Glob` where: pattern=FRONTMATTER_PATH
|
|
260
|
+
CAPTURE FRONTMATTER_PATHS from `Glob`
|
|
261
|
+
IF FRONTMATTER_PATHS is empty:
|
|
262
|
+
SET FRONTMATTER_PATH := <PATH> (from "Agent Inference" using PLATFORMS_BASE_ALT, PLATFORM_CONFIG.frontmatterPath)
|
|
263
|
+
USE `Glob` where: pattern=FRONTMATTER_PATH
|
|
264
|
+
CAPTURE FRONTMATTER_PATHS from `Glob`
|
|
265
|
+
USE `Read` where: filePath=FRONTMATTER_PATHS[0]
|
|
266
|
+
CAPTURE FRONTMATTER_TEMPLATE from `Read`
|
|
267
|
+
USE `Glob` where: pattern=TOOLS_PATH
|
|
268
|
+
CAPTURE TOOLS_PATHS from `Glob`
|
|
269
|
+
IF TOOLS_PATHS is empty:
|
|
270
|
+
SET TOOLS_PATH := <PATH> (from "Agent Inference" using PLATFORMS_BASE_ALT, PLATFORM_CONFIG.toolsRegistryPath)
|
|
271
|
+
USE `Glob` where: pattern=TOOLS_PATH
|
|
272
|
+
CAPTURE TOOLS_PATHS from `Glob`
|
|
273
|
+
USE `Read` where: filePath=TOOLS_PATHS[0]
|
|
274
|
+
CAPTURE ADAPTER_TOOLS from `Read`
|
|
275
|
+
IF TARGET_PLATFORM = "claude-code":
|
|
276
|
+
SET FIELD_REQUIREMENTS := FIELD_REQUIREMENTS_CLAUDE (from "Constant Lookup")
|
|
277
|
+
ELSE:
|
|
278
|
+
SET FIELD_REQUIREMENTS := FIELD_REQUIREMENTS_VSCODE (from "Constant Lookup")
|
|
279
|
+
</process>
|
|
280
|
+
|
|
281
|
+
<process id="refine" name="Intent">
|
|
282
|
+
SET STATE := <STATE_TEXT> (from "Agent Inference" using USER_INPUT, TARGET_PLATFORM)
|
|
283
|
+
SET INTENT := <INTENT_FACTS> (from "Agent Inference" using USER_INPUT, SKILL_CONTENT, FRONTMATTER_TEMPLATE, ADAPTER_TOOLS, TARGET_PLATFORM, FIELD_REQUIREMENTS)
|
|
284
|
+
SET QUESTIONS := <BLOCKERS> (from "Agent Inference" using INTENT, ASK_RULES, FIELD_REQUIREMENTS)
|
|
285
|
+
SET INTENT_OK := <DONE> (from "Agent Inference")
|
|
286
|
+
SET WRITE_OK := <OK_TO_WRITE> (from "Agent Inference")
|
|
287
|
+
</process>
|
|
288
|
+
|
|
289
|
+
<process id="generate" name="Generate+Lint+MaybeWrite">
|
|
290
|
+
IF TARGET_PLATFORM = "claude-code":
|
|
291
|
+
SET AGENT_SLUG := <SLUG> (from "Agent Inference" using INTENT, SLUG_RULES_CLAUDE)
|
|
292
|
+
ELSE:
|
|
293
|
+
SET AGENT_SLUG := <SLUG> (from "Agent Inference" using INTENT, SLUG_RULES_VSCODE)
|
|
294
|
+
SET FILE_PATH := <AGENT_FILE_PATH> (from "Agent Inference" using AGENT_SLUG, PLATFORM_CONFIG.agentsDir, PLATFORM_CONFIG.agentExt)
|
|
295
|
+
SET AGENT := <AGENT_TEXT> (from "Agent Inference" using INTENT, SKILL_CONTENT, FRONTMATTER_TEMPLATE, ADAPTER_TOOLS, AGENT_SKELETON, PLATFORM_CONFIG, FIELD_REQUIREMENTS)
|
|
296
|
+
SET LINT := <LINT_TEXT> (from "Agent Inference" using AGENT, LINT_CHECKS, TARGET_PLATFORM, FIELD_REQUIREMENTS)
|
|
297
|
+
IF WRITE_OK is true:
|
|
298
|
+
USE `Bash` where: command="mkdir -p " + PLATFORM_CONFIG.agentsDir
|
|
299
|
+
USE `Write` where: filePath=FILE_PATH, content=AGENT
|
|
300
|
+
SET WRITTEN := true (from "Agent Inference")
|
|
301
|
+
ELSE:
|
|
302
|
+
SET WRITTEN := false (from "Agent Inference")
|
|
303
|
+
</process>
|
|
304
|
+
</processes>
|
|
305
|
+
|
|
306
|
+
<input>
|
|
307
|
+
USER_INPUT is the user's latest message containing goals or answers.
|
|
308
|
+
</input>
|