Kimi Code CLI Integration
Converts all Agency agents into Kimi Code CLI agent specifications. Each agent becomes a directory containing agent.yaml (agent spec) and system.md (system prompt).
Installation
Prerequisites
- Kimi Code CLI installed
Install
bash# Generate integration files (required on fresh clone)
./scripts/convert.sh --tool kimi
# Install agents
./scripts/install.sh --tool kimiThis copies agents to ~/.config/kimi/agents/.
Usage
Activate an Agent
Use the --agent-file flag to load a specific agent:
bashkimi --agent-file ~/.config/kimi/agents/frontend-developer/agent.yamlIn a Project
bashcd /your/project
kimi --agent-file ~/.config/kimi/agents/frontend-developer/agent.yaml \
--work-dir /your/project \
"Review this React component for performance issues"List Installed Agents
bashls ~/.config/kimi/agents/Agent Structure
Each agent directory contains:
~/.config/kimi/agents/frontend-developer/
├── agent.yaml # Agent specification (tools, subagents)
└── system.md # System prompt with personality and instructionsagent.yaml format
yamlversion: 1
agent:
name: frontend-developer
extend: default # Inherits from Kimi's built-in default agent
system_prompt_path: ./system.md
tools:
- "kimi_cli.tools.shell:Shell"
- "kimi_cli.tools.file:ReadFile"
# ... all default toolsRegenerate
After modifying source agents:
bash./scripts/convert.sh --tool kimi
./scripts/install.sh --tool kimiTroubleshooting
Agent file not found
Ensure you've run convert.sh before install.sh:
bash./scripts/convert.sh --tool kimiKimi CLI not detected
Make sure kimi is in your PATH:
bashwhich kimi
kimi --versionInvalid YAML
Validate the generated files:
bashpython3 -c "import yaml; yaml.safe_load(open('integrations/kimi/frontend-developer/agent.yaml'))"