@wukonglabs/wukong
v0.2.2
Published
AI Coding Agent — CLI and TUI interface with CI automation support (ReAct loop + built-in tools + skill system)
Maintainers
Readme
@wukonglabs/wukong
CI-First AI Agent CLI — a minimal yet full-featured AI coding assistant
Wukong is a CLI AI coding agent with a ReAct reasoning loop, built-in tools, a skill system, and session persistence. Powered by @wukonglabs/wukong-agent-sdk.
Install
npm install -g @wukonglabs/wukong@latestRequires Node.js >= 22. Pure JS/TS, no native addons — install and run, no C++ toolchain needed.
First Run (Interactive Setup)
Run wukong directly. If no model provider is configured, an interactive wizard starts:
🔧 No model config detected — starting interactive setup
Choose a provider type:
1) OpenAI (Official)
2) Anthropic (Claude Official)
3) OpenAI-Compatible (custom baseUrl, e.g. DeepSeek / vLLM)
Enter choice [1]: 3
API Key: sk-xxx
Base URL (required, e.g. https://api.deepseek.com/v1): https://api.deepseek.com/v1
Model name: deepseek-chat
✅ Config saved to /Users/you/.wukong/wukong.jsonConfig is written to ~/.wukong/wukong.json (permissions 0600). You can also manually configure as described below.
Non-interactive environments (pipes / CI) skip the wizard; use env vars or a config file instead.
Usage
# Interactive mode
wukong
# Single-shot
wukong agent --message "Check my package.json"
# JSON output (for programmatic use)
wukong agent --json --message "List files in current directory"
# Reuse session (multi-turn)
wukong agent --message "Continue the last task" --session-id "my_session"
# Custom system prompt
wukong agent --message "Review this PR" --system-prompt "You are a code reviewer"
# Image recognition (requires vision config)
wukong agent --message "Describe this image" --images https://example.com/shot.pngCLI Options
| Option | Short | Description |
| ----------------- | ----- | ---------------------------------------- |
| agent | - | Subcommand: single-shot mode |
| --message | -m | Message content |
| --session-id | -s | Session ID (default: cli:local) |
| --system-prompt | - | Injected system prompt |
| --images | - | Image URLs (multiple allowed) |
| --json | - | JSON output |
| --test | - | Test mode: send test message then exit |
Configuration
Priority: CLI args > env vars (.env) > config file (wukong.json) > defaults
Config file lookup order: $WUKONG_CONFIG_PATH → ./wukong.json → ~/.wukong/wukong.json
Minimal Config File
Place at ~/.wukong/wukong.json (global) or ./wukong.json (project):
{
"agent": {
"defaultModel": "deepseek-chat"
},
"llm": {
"providers": {
"deepseek": {
"type": "openai-compatible",
"apiKey": "${DEEPSEEK_API_KEY}",
"baseUrl": "https://api.deepseek.com/v1"
}
},
"models": {
"deepseek-chat": {
"provider": "deepseek",
"id": "deepseek-chat"
}
}
}
}Use --model <alias> at startup. In TUI, /model lists models and /model <alias> switches between turns.
Environment Variables (Recommended)
OPENAI_API_KEY=sk-xxx # → llm.providers.openai.apiKey (if declared)
LLM_BASE_URL=https://api.xxx/v1 # → llm.providers.openai.baseUrl
LLM_MODEL=openai-default # → agent.defaultModel (declared alias)
ANTHROPIC_API_KEY=sk-ant-xxx # → llm.providers.anthropic.apiKey (if declared)Config file string values support ${VAR_NAME} templates referencing env vars.
Full config options (multi-provider, Vision, Skills) → root README.
Skills
Inject domain knowledge and custom tools via SKILL.md files — no source changes needed. Skills auto-load from <install-dir>/skills/bundled/, ~/.wukong/skills/, <project>/skills/, and configured directories (later paths override earlier ones by name). See root README for details.
License
MIT
