feat(kugetsu): add status, delegate, doctor commands; inject PM context at init
This commit implements Phase 3b/3c architectural improvements: ### New kugetsu CLI commands: - `kugetsu status` - Check initialization status (replaces kugetsu-helper check-status) - `kugetsu delegate <msg>` - Send message to PM agent (new command) - `kugetsu doctor [--fix]` - Diagnose and fix kugetsu issues ### PM Context Injection: - kugetsu init now reads ~/.kugetsu/pm-agent.md (if exists) and injects it into the PM agent session at creation time - PM context is loaded ONCE at init, not on every delegation - This improves efficiency - kugetsu-pm content read once, not 10 times ### kugetsu-chat updated: - Now uses `kugetsu delegate` instead of kugetsu-helper - Now uses `kugetsu status` instead of kugetsu-helper check-status - Simplified - no longer depends on kugetsu-helpers ### kugetsu continue: - Removed strict issue-ref format validation - Now accepts any session name that is tracked in index.json["issues"] - Issue-ref format is a guideline, not a hard requirement ### Documentation updated: - phase3a-setup.md - Updated to reflect new kugetsu commands - kugetsu-install.sh - Simplified Phase 3a setup instructions ### Breaking changes: - kugetsu-helpers is no longer required for Phase 3a Chat Agent - kugetsu-chat skill v3.0 now requires kugetsu CLI with new commands
This commit is contained in:
@@ -5,7 +5,7 @@ license: MIT
|
||||
compatibility: Requires Hermes agent with Telegram configured, kugetsu CLI, opencode sessions.
|
||||
metadata:
|
||||
author: shoko
|
||||
version: "2.0"
|
||||
version: "3.0"
|
||||
---
|
||||
|
||||
# kugetsu-chat - REQUIRED SKILL FOR KUGETSU ROUTING
|
||||
@@ -37,12 +37,12 @@ When you MUST use this skill:
|
||||
|
||||
### Step 2: Check if kugetsu is initialized
|
||||
```
|
||||
terminal(command="~/.local/bin/kugetsu-helper check-status", timeout=10)
|
||||
terminal(command="kugetsu status", timeout=10)
|
||||
```
|
||||
|
||||
### Step 3: If initialized, DELEGATE immediately
|
||||
```
|
||||
terminal(command="~/.local/bin/kugetsu-helper delegate-to-pm '<entire user message>'", timeout=120)
|
||||
terminal(command="kugetsu delegate '<entire user message>'", timeout=120)
|
||||
```
|
||||
|
||||
### Step 4: Relay the response to the user
|
||||
@@ -52,12 +52,12 @@ terminal(command="~/.local/bin/kugetsu-helper delegate-to-pm '<entire user messa
|
||||
The ONLY command you should use for delegation:
|
||||
|
||||
```bash
|
||||
~/.local/bin/kugetsu-helper delegate-to-pm '<user message>'
|
||||
kugetsu delegate '<user message>'
|
||||
```
|
||||
|
||||
Example:
|
||||
```
|
||||
terminal(command="~/.local/bin/kugetsu-helper delegate-to-pm 'fix issue #5 in github.com/shoko/kugetsu'", timeout=120)
|
||||
terminal(command="kugetsu delegate 'fix issue #5 in github.com/shoko/kugetsu'", timeout=120)
|
||||
```
|
||||
|
||||
## Error Handling
|
||||
@@ -67,26 +67,28 @@ terminal(command="~/.local/bin/kugetsu-helper delegate-to-pm 'fix issue #5 in gi
|
||||
| `ok` | kugetsu is ready | Proceed with delegation |
|
||||
| `kugetsu_not_initialized` | Not set up | Tell user to run `kugetsu init` |
|
||||
| `pm_agent_missing` | PM not created | Tell user to run `kugetsu init` |
|
||||
| `pm_agent_expired` | PM session expired | Tell user to run `kugetsu doctor --fix` |
|
||||
|
||||
## Quick Reference
|
||||
|
||||
**DELEGATION COMMAND:**
|
||||
```
|
||||
terminal(command="~/.local/bin/kugetsu-helper delegate-to-pm '<message>'", timeout=120)
|
||||
terminal(command="kugetsu delegate '<message>'", timeout=120)
|
||||
```
|
||||
|
||||
**CHECK STATUS:**
|
||||
```
|
||||
terminal(command="~/.local/bin/kugetsu-helper check-status", timeout=10)
|
||||
terminal(command="kugetsu status", timeout=10)
|
||||
```
|
||||
|
||||
## Required Files
|
||||
## Required Dependencies
|
||||
|
||||
- `~/.local/bin/kugetsu-helper` - The delegation helper script
|
||||
- `kugetsu` CLI installed and in PATH
|
||||
- kugetsu initialized via `kugetsu init`
|
||||
|
||||
## Notes
|
||||
|
||||
- ALWAYS use the full path `~/.local/bin/kugetsu-helper`
|
||||
- ALWAYS use `delegate-to-pm` subcommand
|
||||
- ALWAYS use `kugetsu delegate` command (not kugetsu-helper)
|
||||
- ALWAYS wrap user message in single quotes inside the command
|
||||
- ALWAYS use timeout of at least 120 seconds for delegation
|
||||
- ALWAYS use timeout of at least 120 seconds for delegation
|
||||
- kugetsu delegates to the persistent PM agent session created during init
|
||||
|
||||
Reference in New Issue
Block a user