Before starting, verify you have:
# 1. Check Node.js version
node --version # Should be v24.13.0 or higher
# 2. Check Git
git --version
# 3. Check current directory
pwd # Should be in ~/projects/terab or navigate there
cd ~/projects/terab
# 4. Verify terab is a git repository
git status # Should show repo status, not "not a git repository"cd ~/codeswarm
git pull origin main
npm install # Install any new dependencies (boxen)which mehaisi
# Should show: /usr/local/bin/codeswarm or similar
codeswarm --version
# Should show version numbercd ~/projects/terab
# If already initialized, remove old config to test fresh
rm -rf .mehaisi
# Initialize with Ollama Cloud model
codeswarm init --model kimi-k2.5:cloudExpected Output:
π INITIALIZING MEHAISI
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Initialization complete
Configuration
β’ 19 agents configured
β’ Workflows & pipelines ready
β’ Model: kimi-k2.5:cloud
β’ Provider: ollama-cloud
π― Get Started
1. codeswarm credentials Β· Setup API keys
2. codeswarm agents --list Β· View available agents
3. codeswarm pipeline cautious Β· Run full pipeline
What to Check:
- β Clean, modern formatting
- β No emoji overload
- β Point-based lists with bullets
- β Proper spacing (no gaps)
- β Shows correct model and provider
cd ~/projects/terab
# Run credential setup (the new interactive feature!)
codeswarm credentialsExpected Prompt:
π SETTING UP CREDENTIALS
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Provider: ollama-cloud
β Ollama Cloud API key not found
βΉ Get your API key from: https://ollama.com
? Enter your Ollama Cloud API key: [type here]
When Prompted:
- Enter your API key:
59064537a0604b5fa23d0f2c9a4cd0a2.OS7nVy9sUJAYhlLOwpOBWgM6 - When asked "Save to config?": Choose
Yes
Expected Result:
β API key saved to config
β Credential setup complete
What to Check:
- β Modern header with divider
- β Clean warning/info messages
- β Password is hidden as you type
- β Confirms save to config
- β No ugly gaps or spacing issues
cat .mehaisi/config.json | grep api_keyExpected Output:
"api_key": "59064537a0604b5fa23d0f2c9a4cd0a2.OS7nVy9sUJAYhlLOwpOBWgM6",
codeswarm statusExpected Output:
β SYSTEM STATUS
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Configuration
Model: kimi-k2.5:cloud
Provider: ollama-cloud
Safety Mode: Manual approval
Agents: 19
Sessions: 0
What to Check:
- β Professional header
- β Key-value pairs properly aligned
- β Clean divider line
- β No extra newlines or gaps
codeswarm agents --listExpected Output:
β AVAILABLE AGENTS
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
INVESTIGATOR
βββββββββββββββββββββββββ¬βββββββ¬βββββββββββββββββββββββββββββ
β Agent β Risk β Capabilities β
βββββββββββββββββββββββββΌβββββββΌβββββββββββββββββββββββββββββ€
β Accessibility Auditor β low β accessibility, a11y-c... β
β API Detective β low β api-integration, endpo... β
...
βββββββββββββββββββββββββ΄βββββββ΄βββββββββββββββββββββββββββββ
FIXER
...
ββββββββββββββββββββββββββββββββ
Total: 19 agents configured
What to Check:
- β Beautiful Unicode box-drawing (βββ not ugly ASCII)
- β Color-coded risk levels (green for low, yellow for medium, red for high)
- β Grouped by agent type
- β Clean table formatting
- β Professional appearance
cat .mehaisi/config.json | head -30What to Check:
- β
"model": "kimi-k2.5:cloud"at the top - β
"default_provider": "ollama-cloud" - β Provider configs have the model set correctly
# This tests that your global model overrides agent defaults
codeswarm run api-detective --dry-run 2>&1 | grep -i modelExpected Behavior:
- Should use
kimi-k2.5:cloud(your global model) - NOT
qwen3-coder(the old agent default)
cd ~/projects/terab
# Run the cautious pipeline (safest, read-only investigations)
codeswarm pipeline cautiousExpected Output:
π INITIALIZING MEHAISI SESSION
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Pre-flight checks passed
β Session ID: [uuid]
π PIPELINE: CAUTIOUS
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Investigation
Workflow: investigate
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β’ API Analysis
βΆ API Detective
β’ Executing...
β Agent completed
β’ UI Analysis
βΆ UI Inspector
β’ Executing...
β Agent completed
...
What to Check:
- β Clean headers with icons
- β Phase banners with inverse background
- β Point-based workflow steps
- β Agent execution shows progress
- β No credential prompts (already saved!)
- β Professional, modern output throughout
- β No ugly gaps or formatting issues
This Will:
- Scan your terab codebase
- Find API issues, UI problems, security vulnerabilities
- Create a session report
- NOT modify any code (cautious pipeline is read-only)
# View the most recent session report
codeswarm report --lastExpected Output:
- Session summary with findings
- List of issues discovered
- Agent performance metrics
cd ~/projects/terab
# Run another command - should NOT ask for credentials
codeswarm run security-scannerExpected Behavior:
- β Runs immediately without prompting
- β Uses saved credentials from config
- β Smooth, uninterrupted execution
# Remove saved credentials
cat .mehaisi/config.json | grep -v "api_key" > /tmp/config-temp.json
mv /tmp/config-temp.json .mehaisi/config.json
# Run again - should prompt this time
codeswarm run api-detectiveExpected Behavior:
- β Detects missing credentials
- β Prompts you interactively
- β Gives you option to save again
After Testing:
# Save credentials again when prompted
# Or restore manually:
codeswarm credentials# Temporarily set wrong API key
export OLLAMA_CLOUD_API_KEY="invalid-key-12345"
codeswarm run api-detectiveExpected Output:
- β Clear error message about authentication failure
- β Suggests checking your API key
- β Doesn't crash or hang
Clean up:
unset OLLAMA_CLOUD_API_KEY# This tests graceful failure
# Temporarily block network or disconnect
codeswarm run api-detectiveExpected Behavior:
- β Times out gracefully
- β Shows clear error message
- β Doesn't hang indefinitely
After completing all tests, you should have:
β Clean Installation
- Fresh
.mehaisidirectory in terab project - Config file with
kimi-k2.5:cloudmodel - Ollama Cloud provider selected
β Working Credentials
- API key saved in config
- Never prompted multiple times
- Smooth execution without manual exports
β Modern UX
- Beautiful Unicode tables
- Clean headers with dividers
- Point-based lists
- No formatting gaps
- Color-coded output
- Professional appearance
β Functional Pipeline
- Runs investigations on terab codebase
- Agents execute successfully
- Session reports generated
- No crashes or hangs
β Smart Model Selection
- Your chosen model used everywhere
- Agent defaults overridden correctly
- Provider auto-selected based on model
cd ~/codeswarm
sudo npm linkcd ~/codeswarm
npm install boxen --save# Check file permissions
ls -la .mehaisi/config.json
# Should be writable
# Manually verify save
cat .mehaisi/config.json | grep api_key# Check your model is set correctly
cat .mehaisi/config.json | grep model
# Verify provider
cat .mehaisi/config.json | grep default_provider# Make sure you have latest code
cd ~/codeswarm
git pull origin main
npm install
sudo npm linkIf you just want to quickly verify everything works:
# 1. Navigate to terab
cd ~/projects/terab
# 2. Initialize
rm -rf .codeswarm && codeswarm init --model kimi-k2.5:cloud
# 3. Setup credentials
codeswarm credentials
# Enter: 59064537a0604b5fa23d0f2c9a4cd0a2.OS7nVy9sUJAYhlLOwpOBWgM6
# Choose: Yes (save to config)
# 4. Check status
codeswarm status
# 5. List agents
codeswarm agents --list
# 6. Run one agent
codeswarm run api-detective
# Done! If these all work with clean output, you're good!Use this to track your testing progress:
- Pulled latest code from GitHub
- Installed dependencies (boxen)
- Initialized terab project
- Tested interactive credential prompt
- Verified credentials saved to config
- Checked status command (modern UI)
- Checked agents list (Unicode tables)
- Verified model selection (global overrides)
- Ran full cautious pipeline
- Verified no re-prompting for credentials
- Tested credential removal and re-prompt
- All output is clean, modern, professional
If you encounter any issues:
- Check
~/.mehaisi/temp/for error logs - Run with verbose mode:
MEHAISI_VERBOSE=1 codeswarm [command] - Check the guides:
Good luck with your testing! π