feat: project-scoped instinct isolation

* feat: add project-scoped instinct isolation

* fix(continuous-learning-v2): harden instinct loading and promotion safety; sync v2.1 command docs

* fix(ci): make copilot-setup-steps a valid GitHub Actions workflow

* fix(hooks): stabilize docs warning inline JS regex parsing
This commit is contained in:
Harry Kwok
2026-03-02 04:07:13 +08:00
committed by GitHub
parent 2d3be88bb5
commit 5818e8adc7
26 changed files with 2476 additions and 713 deletions

View File

@@ -1,75 +1,29 @@
---
description: View learned instincts with confidence scores
description: Show learned instincts (project + global) with confidence
agent: build
---
# Instinct Status Command
Display learned instincts and their confidence scores: $ARGUMENTS
Show instinct status from continuous-learning-v2: $ARGUMENTS
## Your Task
Read and display instincts from the continuous-learning-v2 system.
Run:
## Instinct Location
Global: `~/.claude/instincts/`
Project: `.claude/instincts/`
## Status Display
### Instinct Summary
| Category | Count | Avg Confidence |
|----------|-------|----------------|
| Coding | X | 0.XX |
| Testing | X | 0.XX |
| Security | X | 0.XX |
| Git | X | 0.XX |
### High Confidence Instincts (>0.8)
```
[trigger] → [action] (confidence: 0.XX)
```bash
python3 "${CLAUDE_PLUGIN_ROOT}/skills/continuous-learning-v2/scripts/instinct-cli.py" status
```
### Learning Progress
If `CLAUDE_PLUGIN_ROOT` is unavailable, use:
- Total instincts: X
- This session: X
- Promoted to skills: X
### Recent Instincts
Last 5 instincts learned:
1. **[timestamp]** - [trigger] → [action]
2. **[timestamp]** - [trigger] → [action]
...
## Instinct Structure
```json
{
"id": "instinct-123",
"trigger": "When I see a try-catch without specific error type",
"action": "Suggest using specific error types for better handling",
"confidence": 0.75,
"applications": 5,
"successes": 4,
"source": "session-observation",
"timestamp": "2025-01-15T10:30:00Z"
}
```bash
python3 ~/.claude/skills/continuous-learning-v2/scripts/instinct-cli.py status
```
## Confidence Calculation
## Behavior Notes
```
confidence = (successes + 1) / (applications + 2)
```
Bayesian smoothing ensures new instincts don't have extreme confidence.
---
**TIP**: Use `/evolve` to cluster related instincts into skills when confidence is high.
- Output includes both project-scoped and global instincts.
- Project instincts override global instincts when IDs conflict.
- Output is grouped by domain with confidence bars.
- This command does not support extra filters in v2.1.