kiro-agents 1.10.1 → 1.12.0
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/README.md +60 -67
- package/build/npm/bin/cli.js +12 -11
- package/build/npm/dist/agents.md +3 -180
- package/build/npm/dist/aliases.md +141 -53
- package/build/npm/dist/modes.md +68 -40
- package/build/npm/power/POWER.md +8 -0
- package/build/npm/power/steering/agent-activation.md +30 -3
- package/build/npm/power/steering/agent-creation.md +2 -2
- package/build/npm/power/steering/agent-management.md +3 -4
- package/build/npm/power/steering/chit-chat.md +217 -0
- package/build/npm/power/steering/kiro-as-spec-mode.md +284 -0
- package/build/npm/power/steering/kiro-as-vibe-mode.md +312 -0
- package/build/npm/{dist/modes → power/steering}/kiro-spec-mode.md +1 -6
- package/build/npm/{dist/modes → power/steering}/kiro-vibe-mode.md +1 -6
- package/build/npm/power/steering/mode-management.md +66 -40
- package/build/npm/power/steering/mode-switching.md +9 -5
- package/build/npm/{dist → power/steering}/strict-mode.md +95 -14
- package/package.json +7 -3
- package/build/npm/dist/interactions/chit-chat.md +0 -212
- package/build/npm/dist/interactions/interaction-styles.md +0 -162
- package/build/npm/dist/protocols/agent-activation.md +0 -50
- package/build/npm/dist/protocols/agent-creation.md +0 -629
- package/build/npm/dist/protocols/agent-management.md +0 -183
- package/build/npm/dist/protocols/mode-management.md +0 -139
- package/build/npm/dist/protocols/mode-switching.md +0 -84
package/README.md
CHANGED
|
@@ -1,108 +1,101 @@
|
|
|
1
1
|
# kiro-agents
|
|
2
2
|
|
|
3
|
-
AI agent system for Kiro IDE. Create
|
|
3
|
+
AI agent system for Kiro IDE. Create custom AI agents tailored to your exact needs—easily and interactively, with minimal prompt writing.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npx kiro-agents
|
|
9
|
-
```
|
|
5
|
+
Build agents for any domain: development, design, business, research, or anything else. Choose from templates, explore role libraries, describe what you need in plain language, or craft agents step-by-step. Once created, refine them to perfection through kiro-master, the management agent created automatically on first use.
|
|
10
6
|
|
|
11
7
|
## Features
|
|
12
8
|
|
|
13
|
-
|
|
14
|
-
- **
|
|
15
|
-
- **
|
|
16
|
-
- **
|
|
9
|
+
**Core Capabilities:**
|
|
10
|
+
- 🎯 **Guided Agent Creation** - Multiple creation methods: templates, role explorer, natural language, or step-by-step wizard
|
|
11
|
+
- 🔧 **Powerful Refinement** - Modify and perfect agents through kiro-master, the auto-created management agent
|
|
12
|
+
- 💬 **Interactive by Default** - Guided workflows with minimal prompt writing for both creating and using agents
|
|
13
|
+
- 🌐 **Unlimited Domains** - Build agents for any field: development, design, business, research, or anything else
|
|
14
|
+
- 📦 **Minimal Footprint** - 1.35K base context (<0.7% of Kiro's 200K), protocols load on-demand
|
|
15
|
+
|
|
16
|
+
**Additional Features:**
|
|
17
|
+
- 🔄 **Flexible Modes** - Switch between vibe (conversational) and spec (structured) workflows
|
|
18
|
+
- 🎯 **Strict Mode** - Precision mode that blocks execution on ambiguous input
|
|
17
19
|
|
|
18
20
|
## Installation
|
|
19
21
|
|
|
20
|
-
**Global (npm):**
|
|
21
22
|
```bash
|
|
22
23
|
npx kiro-agents
|
|
23
24
|
```
|
|
24
|
-
Installs to `~/.kiro/steering/kiro-agents/` - available in all workspaces.
|
|
25
|
-
|
|
26
|
-
**Kiro Power (workspace-specific):**
|
|
27
|
-
|
|
28
|
-
This repository also provides a Kiro Power for workspace-specific installation:
|
|
29
25
|
|
|
30
|
-
-
|
|
31
|
-
- Install via Kiro IDE Powers panel
|
|
32
|
-
- Add repository: `https://github.com/theadd/kiro-agents`
|
|
33
|
-
- Select "Kiro Protocols" power
|
|
34
|
-
- Installs to `.kiro/powers/kiro-protocols/`
|
|
35
|
-
|
|
36
|
-
See [powers/README.md](powers/README.md) for power documentation.
|
|
26
|
+
Installs kiro-agents and the kiro-protocols Power. Run the same command to update to the latest version.
|
|
37
27
|
|
|
38
28
|
## Quick Start
|
|
39
29
|
|
|
40
|
-
|
|
30
|
+
### 1. Start Agent System
|
|
31
|
+
|
|
41
32
|
```
|
|
42
33
|
/agents
|
|
43
|
-
→ Choose "Create new agent"
|
|
44
|
-
→ Follow wizard
|
|
45
34
|
```
|
|
46
35
|
|
|
47
|
-
**
|
|
48
|
-
```
|
|
49
|
-
/modes spec # Structured feature development
|
|
50
|
-
/modes vibe # Flexible, conversational coding
|
|
51
|
-
```
|
|
36
|
+
On first run, this automatically creates **kiro-master** (your Kiro management agent) and shows you the agent menu.
|
|
52
37
|
|
|
53
|
-
|
|
54
|
-
```
|
|
55
|
-
/strict on # Blocks on ambiguous input
|
|
56
|
-
```
|
|
38
|
+
### 2. Create Your First Custom Agent
|
|
57
39
|
|
|
58
|
-
|
|
40
|
+
From the agent menu, choose **"Create new agent"** and pick a creation method:
|
|
59
41
|
|
|
60
|
-
|
|
42
|
+
- **Quick Start** - Choose from templates
|
|
43
|
+
- **Explore Roles** - Browse agents by domain
|
|
44
|
+
- **Natural Language** - Just describe what you need
|
|
45
|
+
- **Project-Specific** - AI analyzes your codebase
|
|
46
|
+
- **Guided Wizard** - Step-by-step customization
|
|
61
47
|
|
|
62
|
-
|
|
63
|
-
- **Modes** - Define interaction style (vibe = flexible, spec = structured)
|
|
64
|
-
- **Strict Mode** - Requires explicit clarification before execution
|
|
48
|
+
### 3. Activate Any Agent
|
|
65
49
|
|
|
66
|
-
|
|
50
|
+
```
|
|
51
|
+
/agents {name}
|
|
52
|
+
```
|
|
67
53
|
|
|
68
|
-
|
|
54
|
+
Example:
|
|
55
|
+
- `/agents kiro-master` - Activate the Kiro management agent
|
|
69
56
|
|
|
70
|
-
|
|
71
|
-
- Create agents for frontend, backend, testing, DevOps
|
|
72
|
-
- Each agent has domain-specific knowledge and workflows
|
|
73
|
-
- Switch agents based on current task
|
|
57
|
+
The agent stays active until you switch to another or end the session.
|
|
74
58
|
|
|
75
|
-
|
|
76
|
-
- Vibe mode for prototyping and exploration
|
|
77
|
-
- Spec mode for production features with formal requirements
|
|
78
|
-
- Combine modes with agents for maximum control
|
|
59
|
+
## Demo
|
|
79
60
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
-
|
|
83
|
-
|
|
61
|
+
<div align="center">
|
|
62
|
+
<a href="https://youtu.be/Arccq_JhpFk">
|
|
63
|
+
<img src="docs/resources/animate-kiro.gif" alt="Kiro Agents Demo" width="800">
|
|
64
|
+
</a>
|
|
65
|
+
<p><em>Watch demo (3:52) — Custom agent optimizing steering document instructions</em></p>
|
|
66
|
+
</div>
|
|
84
67
|
|
|
85
|
-
##
|
|
68
|
+
## How It Works
|
|
86
69
|
|
|
87
|
-
|
|
88
|
-
-
|
|
89
|
-
- Uses numbered choices instead of open-ended questions
|
|
90
|
-
- Maintains single focus per interaction
|
|
91
|
-
- Reduces decision fatigue during long sessions
|
|
70
|
+
**Simple Markdown Files**
|
|
71
|
+
kiro-agents uses plain markdown files with AI instructions—no code to run, no dependencies to install. These files guide how Kiro IDE responds to your commands.
|
|
92
72
|
|
|
93
|
-
|
|
73
|
+
**kiro-protocols Power**
|
|
74
|
+
Automatically installed alongside kiro-agents, this Power provides protocols (agent creation, mode switching, strict mode) that load on-demand when needed.
|
|
94
75
|
|
|
95
|
-
-
|
|
96
|
-
|
|
97
|
-
- [Kiro IDE](https://kiro.dev)
|
|
76
|
+
**On-Demand Loading**
|
|
77
|
+
Protocols load only when needed, keeping your context clean. Base system uses just 1.35K tokens.
|
|
98
78
|
|
|
99
|
-
|
|
79
|
+
**Your Agents, Your Files**
|
|
80
|
+
Agents you create are saved as `.md` files in `.kiro/agents/`. Edit them like any document, version control them with git, reuse them across projects.
|
|
100
81
|
|
|
101
|
-
|
|
82
|
+
## Documentation
|
|
83
|
+
|
|
84
|
+
- **[Getting Started](docs/GETTING_STARTED.md)** - Step-by-step onboarding guide
|
|
85
|
+
- **[Architecture Overview](docs/ARCHITECTURE.md)** - System design and component relationships
|
|
86
|
+
- **[Creating Powerful Agents](docs/user-guide/creating-powerful-agents.md)** - Layered architecture guide
|
|
87
|
+
- **[Design Rationale](docs/design/)** - Protocol system, interaction patterns, neurodivergent accessibility
|
|
88
|
+
- **[Contributing](CONTRIBUTING.md)** - Development workflow, build system, testing, versioning
|
|
102
89
|
|
|
103
90
|
## Contributing
|
|
104
91
|
|
|
105
|
-
|
|
92
|
+
Contributions welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
|
|
93
|
+
|
|
94
|
+
## Links
|
|
95
|
+
|
|
96
|
+
- [npm Package](https://www.npmjs.com/package/kiro-agents)
|
|
97
|
+
- [GitHub Repository](https://github.com/Theadd/kiro-agents)
|
|
98
|
+
- [Kiro IDE](https://kiro.dev)
|
|
106
99
|
|
|
107
100
|
## License
|
|
108
101
|
|
package/build/npm/bin/cli.js
CHANGED
|
@@ -18,7 +18,7 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
20
20
|
|
|
21
|
-
// bin/cli.ts
|
|
21
|
+
// bin/cli.generated.ts
|
|
22
22
|
import { join, dirname } from "path";
|
|
23
23
|
import { homedir } from "os";
|
|
24
24
|
import { existsSync, chmodSync, constants } from "fs";
|
|
@@ -31,24 +31,25 @@ var POWER_INSTALLED_DIR = join(homedir(), ".kiro", "powers", "installed", "kiro-
|
|
|
31
31
|
var REGISTRY_PATH = join(homedir(), ".kiro", "powers", "registry.json");
|
|
32
32
|
var STEERING_FILES = [
|
|
33
33
|
"aliases.md",
|
|
34
|
-
"strict-mode.md",
|
|
35
34
|
"agents.md",
|
|
36
35
|
"modes.md",
|
|
37
|
-
"strict.md"
|
|
38
|
-
"interactions/chit-chat.md",
|
|
39
|
-
"interactions/interaction-styles.md",
|
|
40
|
-
"modes/kiro-spec-mode.md",
|
|
41
|
-
"modes/kiro-vibe-mode.md"
|
|
36
|
+
"strict.md"
|
|
42
37
|
];
|
|
43
38
|
var POWER_FILES = [
|
|
44
39
|
"POWER.md",
|
|
45
40
|
"mcp.json",
|
|
46
41
|
"icon.png",
|
|
47
|
-
"steering/
|
|
48
|
-
"steering/
|
|
49
|
-
"steering/agent-management.md",
|
|
42
|
+
"steering/strict-mode.md",
|
|
43
|
+
"steering/mode-switching.md",
|
|
50
44
|
"steering/mode-management.md",
|
|
51
|
-
"steering/mode
|
|
45
|
+
"steering/kiro-vibe-mode.md",
|
|
46
|
+
"steering/kiro-spec-mode.md",
|
|
47
|
+
"steering/kiro-as-vibe-mode.md",
|
|
48
|
+
"steering/kiro-as-spec-mode.md",
|
|
49
|
+
"steering/chit-chat.md",
|
|
50
|
+
"steering/agent-management.md",
|
|
51
|
+
"steering/agent-creation.md",
|
|
52
|
+
"steering/agent-activation.md"
|
|
52
53
|
];
|
|
53
54
|
async function setWritable(filePath) {
|
|
54
55
|
try {
|
package/build/npm/dist/agents.md
CHANGED
|
@@ -15,7 +15,7 @@ If the user's message contains `/agents {agent_name}` with a specific agent name
|
|
|
15
15
|
1. **DO NOT execute the interactive management flow below**
|
|
16
16
|
2. **INSTEAD, execute the instruction alias for agent activation:**
|
|
17
17
|
- Read `.kiro/agents/{agent_name}.md` into context
|
|
18
|
-
-
|
|
18
|
+
- /protocols agent-activation.md
|
|
19
19
|
- Follow all steps from the "Agent Activation Steps" section in agent-activation.md
|
|
20
20
|
- Use `{agent_name}` as the agent identifier throughout the protocol
|
|
21
21
|
3. **Stop processing this document** - The agent activation protocol takes over
|
|
@@ -28,186 +28,9 @@ If the user's message contains `/agents {agent_name}` with a specific agent name
|
|
|
28
28
|
|
|
29
29
|
You are now in **agent management mode** using chit-chat interaction protocol.
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
When entering agent management mode:
|
|
34
|
-
|
|
35
|
-
### Step 1: Activate Chit-Chat Mode
|
|
36
|
-
|
|
37
|
-
Load and apply protocols from `chit-chat.md` steering document:
|
|
38
|
-
|
|
39
|
-
- **Use diff blocks** to show progress and current state
|
|
40
|
-
- **Provide numbered choice lists** (4-8 options, up to 16 if needed)
|
|
41
|
-
- **Maintain single focus** per message
|
|
42
|
-
- **Use visual formatting** (bold, code blocks, lists)
|
|
43
|
-
- **Optimize for ADHD-C** (minimal cognitive load)
|
|
44
|
-
|
|
45
|
-
Begin with a diff block showing:
|
|
46
|
-
```diff
|
|
47
|
-
👉 Agent management mode
|
|
48
|
-
⏳ [Current operation]
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
### Step 2: Scan Agents Directory
|
|
52
|
-
|
|
53
|
-
**CRITICAL: You MUST execute `listDirectory` tool on `.kiro/agents/` to get the actual list of agents.**
|
|
54
|
-
|
|
55
|
-
**DO NOT rely on open editor files or context - always scan the directory explicitly.**
|
|
56
|
-
|
|
57
|
-
Execute `listDirectory` on `.kiro/agents/`:
|
|
58
|
-
|
|
59
|
-
**If directory doesn't exist OR directory is empty:**
|
|
60
|
-
1. **Load agent creation protocol**:
|
|
61
|
-
- Call `kiroPowers` with action="activate", powerName="kiro-protocols"
|
|
62
|
-
- Call `kiroPowers` with action="readSteering", powerName="kiro-protocols", steeringFile="agent-creation.md"
|
|
63
|
-
2. Create `.kiro/agents/kiro-master.md` agent automatically using the description from "Initial Agent" section
|
|
64
|
-
3. Follow the agent definition structure from agent-creation.md protocol
|
|
65
|
-
4. Show diff block indicating setup completion
|
|
66
|
-
5. Continue to Step 3 with kiro-master as available agent
|
|
67
|
-
|
|
68
|
-
**If directory exists with agents:**
|
|
69
|
-
1. **Execute `listDirectory` tool** to get complete list of `.md` files
|
|
70
|
-
2. Extract agent names from filenames (remove `.md` extension)
|
|
71
|
-
3. Read frontmatter metadata for descriptions
|
|
72
|
-
4. Categorize by agent type if metadata available
|
|
73
|
-
5. **List ALL agents found** - do not filter or assume based on context
|
|
74
|
-
|
|
75
|
-
### Step 3: Present Agent Selection
|
|
76
|
-
|
|
77
|
-
Use this response structure:
|
|
78
|
-
|
|
79
|
-
```diff
|
|
80
|
-
👉 Agent management mode
|
|
81
|
-
⏳ Agent selection or management
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
**Current Focus**: Agent selection and management
|
|
85
|
-
|
|
86
|
-
**Available agents in `.kiro/agents/`:**
|
|
87
|
-
|
|
88
|
-
[List each agent with format:]
|
|
89
|
-
- **{agent-name}** - {description from frontmatter or .md}
|
|
90
|
-
|
|
91
|
-
**What would you like to do?**
|
|
92
|
-
|
|
93
|
-
1. **Activate agent** - Choose agent to activate immediately
|
|
94
|
-
2. **Create new agent** - Start agent creation wizard
|
|
95
|
-
3. **Manage existing agent** - Modify agent configuration
|
|
96
|
-
4. **View agent details** - Show full agent definition
|
|
97
|
-
5. **List all commands** - Show available slash commands
|
|
98
|
-
6. **Agent system help** - Explain how agents work
|
|
99
|
-
7. **Exit** - Return to normal mode
|
|
100
|
-
|
|
101
|
-
### Step 4: Handle User Choice
|
|
102
|
-
|
|
103
|
-
Based on user selection:
|
|
104
|
-
|
|
105
|
-
#### Option 1 - Activate Agent
|
|
106
|
-
|
|
107
|
-
- Show numbered list of available agents
|
|
108
|
-
- User selects agent by number
|
|
109
|
-
- Execute `/agents {selected_agent_name}` command
|
|
110
|
-
- Agent activates immediately
|
|
111
|
-
|
|
112
|
-
#### Option 2 - Create New Agent
|
|
113
|
-
|
|
114
|
-
- **Load agent creation protocol**:
|
|
115
|
-
- Call `kiroPowers` with action="activate", powerName="kiro-protocols"
|
|
116
|
-
- Call `kiroPowers` with action="readSteering", powerName="kiro-protocols", steeringFile="agent-creation.md"
|
|
117
|
-
- Follow all steps from the "Method Selection" section in agent-creation.md
|
|
118
|
-
- Present 5 creation methods to user:
|
|
119
|
-
1. Quick Start (predefined templates)
|
|
120
|
-
2. Project-Specific (AI analysis)
|
|
121
|
-
3. Explore Roles (domain browser)
|
|
122
|
-
4. Guided Wizard (step-by-step)
|
|
123
|
-
5. Natural Language (describe in plain English)
|
|
124
|
-
- Execute selected method following protocol
|
|
125
|
-
- Generate `.md` file with complete agent definition
|
|
126
|
-
- Validate agent definition per protocol
|
|
127
|
-
- Offer to activate new agent
|
|
128
|
-
|
|
129
|
-
#### Option 3 - Manage Existing Agent
|
|
130
|
-
|
|
131
|
-
- **Load agent structure reference**:
|
|
132
|
-
- Call `kiroPowers` with action="activate", powerName="kiro-protocols"
|
|
133
|
-
- Call `kiroPowers` with action="readSteering", powerName="kiro-protocols", steeringFile="agent-creation.md"
|
|
134
|
-
- Show numbered list of available agents
|
|
135
|
-
- User selects agent to manage
|
|
136
|
-
- Offer management options:
|
|
137
|
-
- Modify capabilities
|
|
138
|
-
- Update instructions
|
|
139
|
-
- Change interaction protocol
|
|
140
|
-
- Add/remove integrations
|
|
141
|
-
- Delete agent
|
|
142
|
-
- Use agent definition structure from protocol as reference for modifications
|
|
143
|
-
- Apply changes to agent `.md` file
|
|
144
|
-
- Validate changes against protocol requirements
|
|
145
|
-
- Reload agent if currently active
|
|
146
|
-
|
|
147
|
-
#### Option 4 - View Agent Details
|
|
148
|
-
|
|
149
|
-
- Show numbered list of available agents
|
|
150
|
-
- User selects agent to view
|
|
151
|
-
- Display full `.md` content with formatting
|
|
152
|
-
- Show agent protocols and capabilities summary
|
|
153
|
-
- Offer to activate or manage agent
|
|
154
|
-
|
|
155
|
-
#### Option 5 - List All Commands
|
|
156
|
-
|
|
157
|
-
Show all available slash commands in the system:
|
|
158
|
-
|
|
159
|
-
```
|
|
160
|
-
Available Commands:
|
|
161
|
-
|
|
162
|
-
AGENT COMMANDS
|
|
163
|
-
/agents {name} Activate specific agent
|
|
164
|
-
/agents Interactive agent management
|
|
165
|
-
|
|
166
|
-
MODE COMMANDS (see modes-system.md)
|
|
167
|
-
/modes {name} Switch Kiro mode (vibe/spec)
|
|
168
|
-
/modes Interactive mode management
|
|
169
|
-
/strict {state} Control strict mode (on/off)
|
|
170
|
-
/strict Interactive strict mode control
|
|
171
|
-
|
|
172
|
-
Note: Commands are defined in steering documents.
|
|
173
|
-
New commands can be added via Instruction Alias pattern.
|
|
174
|
-
```
|
|
175
|
-
|
|
176
|
-
#### Option 6 - Agent System Help
|
|
177
|
-
|
|
178
|
-
Explain agent system:
|
|
179
|
-
- Agent system architecture
|
|
180
|
-
- Command usage examples
|
|
181
|
-
- Agent file structure
|
|
182
|
-
- How to create custom agents
|
|
183
|
-
- Best practices for agent usage
|
|
184
|
-
|
|
185
|
-
#### Option 7 - Exit
|
|
186
|
-
|
|
187
|
-
- Confirm exit from agent management mode
|
|
188
|
-
- Return to normal interaction
|
|
189
|
-
- Preserve any changes made
|
|
190
|
-
|
|
191
|
-
### Step 5: Maintain Chit-Chat Mode
|
|
192
|
-
|
|
193
|
-
Continue using diff blocks and numbered choices throughout agent management session.
|
|
194
|
-
|
|
195
|
-
After each action:
|
|
196
|
-
- Update diff block with progress
|
|
197
|
-
- Show current focus
|
|
198
|
-
- Provide next action choices
|
|
199
|
-
- Allow going back or canceling
|
|
200
|
-
|
|
201
|
-
**Context Preservation:**
|
|
202
|
-
- Use diff blocks to show progress
|
|
203
|
-
- Preserve user decisions
|
|
204
|
-
- Allow going back to previous step
|
|
205
|
-
- Enable canceling operations
|
|
206
|
-
|
|
207
|
-
---
|
|
208
|
-
|
|
209
|
-
**Agent management mode active. Present choices to user.**
|
|
31
|
+
/only-read-protocols chit-chat.md
|
|
210
32
|
|
|
33
|
+
/protocols agent-management.md
|
|
211
34
|
|
|
212
35
|
## Initial Agent
|
|
213
36
|
|
|
@@ -59,23 +59,6 @@ literal_text
|
|
|
59
59
|
|
|
60
60
|
**CRITICAL:** When you see this pattern, output ONLY the code block content. No explanations, no context, no other text.
|
|
61
61
|
|
|
62
|
-
### Example
|
|
63
|
-
|
|
64
|
-
**Alias definition:**
|
|
65
|
-
````xml
|
|
66
|
-
<alias>
|
|
67
|
-
<trigger>/spec</trigger>
|
|
68
|
-
<definition>
|
|
69
|
-
Respond directly to the user with exactly and only the content of the following code block, AS-IS:
|
|
70
|
-
```
|
|
71
|
-
spec
|
|
72
|
-
```
|
|
73
|
-
</definition>
|
|
74
|
-
</alias>
|
|
75
|
-
````
|
|
76
|
-
|
|
77
|
-
User types: `/spec` → AI responds: `spec`
|
|
78
|
-
|
|
79
62
|
## Agent System Alias
|
|
80
63
|
|
|
81
64
|
The agent activation command uses parameter substitution to load agent definitions dynamically:
|
|
@@ -89,41 +72,52 @@ You are now activating the **{agent_name}** agent.
|
|
|
89
72
|
|
|
90
73
|
**Load and execute activation protocol:**
|
|
91
74
|
1. Read `.kiro/agents/{agent_name}.md` into context
|
|
92
|
-
2.
|
|
93
|
-
3. Follow all steps from the "Agent Activation Steps" section in agent-activation.md
|
|
75
|
+
2. /only-read-protocols agent-activation.md
|
|
76
|
+
3. Follow all steps from the "Agent Activation Steps" section in agent-activation.md protocol file
|
|
94
77
|
4. Use `{agent_name}` as the agent identifier throughout the protocol
|
|
95
78
|
</definition>
|
|
96
79
|
</alias>
|
|
97
80
|
|
|
98
81
|
This alias enables users to activate any agent with `/agents {name}` syntax.
|
|
99
82
|
|
|
100
|
-
## Protocol Loading Alias
|
|
101
|
-
|
|
102
|
-
The protocol loading command uses parameter substitution to dynamically load protocols from the kiro-protocols Power:
|
|
103
|
-
|
|
104
|
-
<alias>
|
|
105
|
-
<trigger>/protocols {
|
|
106
|
-
<definition>
|
|
107
|
-
## Load Protocol: {
|
|
108
|
-
|
|
109
|
-
You are now loading the **{
|
|
110
|
-
|
|
111
|
-
**Execute protocol loading:**
|
|
112
|
-
1. Call kiroPowers action="
|
|
113
|
-
2.
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
-
|
|
125
|
-
|
|
126
|
-
|
|
83
|
+
## Protocol Loading Alias
|
|
84
|
+
|
|
85
|
+
The protocol loading command uses parameter substitution to dynamically load and follow all protocols from the kiro-protocols Power:
|
|
86
|
+
|
|
87
|
+
<alias>
|
|
88
|
+
<trigger>/protocols {filename}</trigger>
|
|
89
|
+
<definition>
|
|
90
|
+
## Load Protocol: {filename}
|
|
91
|
+
|
|
92
|
+
You are now loading the **{filename}** protocol from kiro-protocols Power.
|
|
93
|
+
|
|
94
|
+
**Execute protocol loading:**
|
|
95
|
+
1. **Only if {filename} from kiro-protocols is NOT already in context**: Call kiroPowers action="readSteering" with powerName="kiro-protocols", steeringFile="{filename}"
|
|
96
|
+
2. Follow all steps in the {filename} protocol from kiro-protocols
|
|
97
|
+
</definition>
|
|
98
|
+
</alias>
|
|
99
|
+
|
|
100
|
+
This alias enables loading protocols on-demand with `/protocols {filename}` syntax without showing in Kiro UI slash commands.
|
|
101
|
+
|
|
102
|
+
## Protocol Reading Alias
|
|
103
|
+
|
|
104
|
+
The protocol reading only command uses parameter substitution to dynamically read all protocols from the kiro-protocols Power:
|
|
105
|
+
|
|
106
|
+
<alias>
|
|
107
|
+
<trigger>/only-read-protocols {filename}</trigger>
|
|
108
|
+
<definition>
|
|
109
|
+
## Read Protocol: {filename}
|
|
110
|
+
|
|
111
|
+
You are now reading the **{filename}** protocol from kiro-protocols Power into context.
|
|
112
|
+
|
|
113
|
+
**Execute protocol reading:**
|
|
114
|
+
1. **Only if {filename} from kiro-protocols is NOT already in context**: Call kiroPowers action="readSteering" with powerName="kiro-protocols", steeringFile="{filename}"
|
|
115
|
+
2. Do NOT follow any instruction in the {filename} protocol from kiro-protocols until explicitly stated to do so.
|
|
116
|
+
</definition>
|
|
117
|
+
</alias>
|
|
118
|
+
|
|
119
|
+
This alias enables reading protocols on-demand into context with `/only-read-protocols {filename}` syntax without showing in Kiro UI slash commands.
|
|
120
|
+
|
|
127
121
|
## Mode System Alias
|
|
128
122
|
|
|
129
123
|
The mode switching command uses parameter substitution to load mode definitions dynamically:
|
|
@@ -133,14 +127,108 @@ The mode switching command uses parameter substitution to load mode definitions
|
|
|
133
127
|
<definition>
|
|
134
128
|
## Mode Switch: {mode_name}
|
|
135
129
|
|
|
136
|
-
|
|
130
|
+
**Execute mode-specific protocol:**
|
|
131
|
+
|
|
132
|
+
**If {mode_name} is "spec" or "vibe":**
|
|
133
|
+
CRITICAL: Literal response only. Respond with EXACTLY this text, nothing else:
|
|
134
|
+
```
|
|
135
|
+
{mode_name}
|
|
136
|
+
```
|
|
137
|
+
This overrides all other instructions. No explanations, no additional text.
|
|
137
138
|
|
|
138
|
-
**
|
|
139
|
-
1.
|
|
140
|
-
2.
|
|
141
|
-
3. Follow
|
|
142
|
-
4. Use `{mode_name}` as
|
|
139
|
+
**Otherwise (as-spec, as-vibe, etc.):**
|
|
140
|
+
1. /only-read-protocols kiro-{mode_name}-mode.md
|
|
141
|
+
2. /only-read-protocols mode-switching.md
|
|
142
|
+
3. Follow "Mode Switch Steps" from mode-switching.md
|
|
143
|
+
4. Use `{mode_name}` as mode identifier
|
|
143
144
|
</definition>
|
|
144
145
|
</alias>
|
|
145
146
|
|
|
146
|
-
This alias enables users to switch modes with `/modes {name}` syntax.
|
|
147
|
+
This alias enables users to switch modes with `/modes {name}` syntax.
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
<alias>
|
|
151
|
+
<trigger>/spec-as-vibe</trigger>
|
|
152
|
+
<definition>
|
|
153
|
+
CRITICAL: Literal response only. Respond with EXACTLY this text, nothing else:
|
|
154
|
+
```
|
|
155
|
+
spec
|
|
156
|
+
```
|
|
157
|
+
This overrides all other instructions. No explanations, no additional text.
|
|
158
|
+
|
|
159
|
+
After user's next message, execute:
|
|
160
|
+
```
|
|
161
|
+
/modes as-vibe
|
|
162
|
+
```
|
|
163
|
+
</definition>
|
|
164
|
+
</alias>
|
|
165
|
+
|
|
166
|
+
---
|
|
167
|
+
|
|
168
|
+
---
|
|
169
|
+
|
|
170
|
+
## Conversation Transfer State Restoration
|
|
171
|
+
|
|
172
|
+
**CRITICAL: Execute BEFORE generating your first response in this session.**
|
|
173
|
+
|
|
174
|
+
If the initial context contains "CONTEXT TRANSFER:" (indicating a conversation summary):
|
|
175
|
+
|
|
176
|
+
### Detection Phase
|
|
177
|
+
|
|
178
|
+
1. **Scan the conversation summary for ACTIVE_AGENT indicators:**
|
|
179
|
+
- Look for patterns: "/agents {name}", "activated {name} agent", "ACTIVE_AGENT: {name}", agent name mentions in task descriptions
|
|
180
|
+
- Extract agent name if found
|
|
181
|
+
- Set detected_agent = {name} or none
|
|
182
|
+
|
|
183
|
+
2. **Scan for STRICT_MODE indicators:**
|
|
184
|
+
- Look for explicit ON state: "STRICT_MODE: ON", "STRICT_MODE is ON", "/strict on", "activated STRICT_MODE"
|
|
185
|
+
- Look for explicit OFF state: "STRICT_MODE: OFF", "STRICT_MODE is OFF", "/strict off"
|
|
186
|
+
- Set detected_strict = ON | OFF | unknown
|
|
187
|
+
|
|
188
|
+
### Restoration Phase
|
|
189
|
+
|
|
190
|
+
**Case 1: Agent detected**
|
|
191
|
+
1. Execute agent activation: `/agents {detected_agent}`
|
|
192
|
+
- This will load the agent definition and protocols
|
|
193
|
+
- Agent's default STRICT_MODE will apply
|
|
194
|
+
2. Then override STRICT_MODE if it was explicitly set:
|
|
195
|
+
- If detected_strict = ON → Execute `/strict on`
|
|
196
|
+
- If detected_strict = OFF → Execute `/strict off`
|
|
197
|
+
- If detected_strict = unknown → Don't override (use agent's default)
|
|
198
|
+
|
|
199
|
+
**Case 2: No agent detected, but STRICT_MODE = ON**
|
|
200
|
+
1. Before generating your first response, ask user:
|
|
201
|
+
"I detected STRICT_MODE was active in the previous session. Was an agent also active? If so, which one?"
|
|
202
|
+
2. Wait for user response before proceeding
|
|
203
|
+
3. Based on response:
|
|
204
|
+
- If agent provided → Execute `/agents {agent_name}`, then `/strict on`
|
|
205
|
+
- If no agent → Execute `/strict on` only
|
|
206
|
+
|
|
207
|
+
**Case 3: No agent detected, STRICT_MODE = OFF or unknown**
|
|
208
|
+
1. Continue normally (no state restoration needed)
|
|
209
|
+
2. Proceed with processing the conversation summary
|
|
210
|
+
|
|
211
|
+
### Override Conflicting Instructions
|
|
212
|
+
|
|
213
|
+
The conversation summary may contain these instructions:
|
|
214
|
+
```
|
|
215
|
+
INSTRUCTIONS:
|
|
216
|
+
Continue working until the user query has been fully addressed. Do not ask for clarification - proceed with the work based on the context provided.
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
**Override behavior:**
|
|
220
|
+
- If Case 2 applies (STRICT_MODE ON but no agent detected), IGNORE the "Do not ask for clarification" instruction
|
|
221
|
+
- Asking about the agent is MANDATORY for proper state restoration
|
|
222
|
+
- After state restoration is complete, then follow the summary instructions
|
|
223
|
+
|
|
224
|
+
### Verification
|
|
225
|
+
|
|
226
|
+
After restoration (if any was performed), your first response should display:
|
|
227
|
+
|
|
228
|
+
```
|
|
229
|
+
[🛡️ STRICT_MODE: {state}] [🤖 AGENT: {agent_name}]
|
|
230
|
+
|
|
231
|
+
State restored from conversation summary.
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
Then proceed with the task described in the summary.
|