| name | beeclaw-reflection-trigger |
| description | Beeclaw's trigger detection system. This skill runs automatically to detect when reflection should be invoked. Understanding these patterns helps you recognize when something needs improvement. Triggers include user corrections, frustration signals, skill failures, and repetitive patterns. |
| tags | ["beeclaw","evolution","triggers","detection"] |
| version | 1.0.0 |
Beeclaw Reflection Trigger Detection
This skill defines the patterns that signal reflection is needed. The system checks these automatically, but understanding them helps you recognize improvement opportunities.
Trigger Categories
1. User Correction (Medium Priority) โ ๏ธ
User indicates the AI made a mistake or misunderstood.
Chinese patterns:
"ไธๅฏน" / "้ไบ" / "ไธๆฏ่ฟๆ ท" / "้ๆฐๆฅ" / "ๅๆฅไธๆฌก"
"ไฝ ๆปๆฏ..." / "ๆฏๆฌก้ฝ..." / "ๆไนๅ..."
"ๆ่ฏด็ๆฏ..." / "ๆ็ๆๆๆฏ..." / "ๅ
ถๅฎๆๆฏๆณ..."
"ไฝ .*็่งฃ้" / "่ฏฏ่งฃไบ" / "่ฏฏไผ"
"ไธๅฅฝ" / "ไธๆปกๆ" / "ไธ่ก"
English patterns:
"No" / "Wrong" / "Incorrect" / "Not right" / "Try again"
"Let me clarify" / "What I meant" / "I said..."
"That's not what I asked" / "You misunderstood"
"I wanted X, not Y"
What to do: Analyze the misunderstanding. Was it ambiguous input? Missing context? Wrong assumption?
2. User Frustration (High Priority) ๐จ
User shows signs of frustration or considering giving up.
Chinese patterns:
"็ฆๆญป" / "ๅดฉๆบ" / "ๆ ่ฏญ" / "ๅไธไบ" / "ๅคไบ"
"ไธบไปไนๆปๆฏ..." / "ๆไนๅ..." / "็ฌฌ.*ๆฌกไบ"
"็ฎไบ" / "ไธ็จไบ" / "ๆ่ชๅทฑๆฅ" / "่ฟๆฏๆๆฅๅง"
English patterns:
"Frustrated" / "Annoying" / "So annoying" / "This is annoying"
"Forget it" / "Never mind" / "I'll do it myself"
"Ugh" / "Argh" / "OMG" / "Stop"
"This is hopeless" / "Giving up"
What to do: Immediately acknowledge the frustration. Identify root cause. Prioritize fixing the most painful issue first.
3. Skill Failure (High Priority) ๐จ
A skill execution failed repeatedly.
Detection rules:
- Same skill fails 2+ times consecutively
- Same skill fails 3+ times within 10 minutes
skill_record called with success=false
What to do: The skill may need significant improvement or complete redesign. Check if the skill's assumptions match reality.
4. Repetitive Pattern (Low Priority) ๐ก
Similar queries appear multiple times, suggesting a missing skill.
Detection rules:
- Similar user requests 3+ times within 30 minutes
- Pattern: same task type, different specifics
Example:
Request 1: "ๅธฎๆๅๅปบไธไธช็ฝ้กตๆๅๆ่ฝ"
Request 2: "ๅธฎๆๅๅปบไธไธชๆฐๆฎๅๆๆ่ฝ"
Request 3: "ๅธฎๆๅๅปบไธไธชๅพ่กจ็ๆๆ่ฝ"
โ Pattern: User repeatedly creates skills
โ Action: Maybe create a skill-creation-helper skill
What to do: Consider if this pattern deserves its own skill. Don't over-generalize too early.
5. Workaround Detected (Medium Priority) โ ๏ธ
User tries to do something themselves because AI failed.
Patterns:
"ๆ่ชๅทฑ..." / "ๆๆฅ..." / "่ฎฉๆ่ชๅทฑ..."
"ไธ็จไบ" / "ไธ้่ฆไบ" / "ๆ่ชๅทฑๆฅ"
"I'll do it myself" / "Never mind I'll handle it"
What to do: Identify what the AI failed to provide. This is valuable feedback - the user gave up on AI help.
Severity Levels
| Level | Icon | Meaning | Response |
|---|
| Low | ๐ก | Minor issue | Note for later improvement |
| Medium | โ ๏ธ | Should address | Propose fix soon |
| High | ๐จ | Critical | Address immediately, stop other work |
How Triggers Flow
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ User Message Received โ
โโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Check All Trigger Patterns โ
โ โ
โ 1. User correction phrases? โ Medium priority โ
โ 2. Frustration signals? โ High priority โ
โ 3. Skill just failed? โ High priority โ
โ 4. Similar query repeated 3+ times? โ Low priority โ
โ 5. Workaround language detected? โ Medium priority โ
โโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโดโโโโโโโโโโโ
โ โ
โผ โผ
No triggers Triggers found
โ โ
โผ โผ
Continue Generate context
conversation for reflection skill
โ
โผ
โโโโโโโโโโโโโโโโโโโ
โ Invoke โ
โ beeclaw- โ
โ reflection โ
โโโโโโโโโโโโโโโโโโโ
Configuration
Default thresholds (adjustable via config):
| Setting | Default | Description |
|---|
consecutiveFailureThreshold | 2 | Same skill fails N times in a row |
failureCountThreshold | 3 | Same skill fails N times in window |
failureTimeWindowMs | 600000 | 10 minute window for counting failures |
repetitiveQueryThreshold | 3 | Similar query appears N times |
repetitiveQueryTimeWindowMs | 1800000 | 30 minute window for counting queries |
When You Detect a Trigger
- Read the context carefully - It tells you what type of issue was detected
- Don't ignore or dismiss - Even if you think it's fine, the user doesn't
- Invoke beeclaw-reflection - Follow its structured analysis process
- Search for similar past issues - Use
memory_grep to find patterns
- Propose specific fixes - Not vague improvements
- Always confirm with user - Before modifying any skills
Adding New Trigger Patterns
If you notice a new pattern that should trigger reflection:
## Proposed New Trigger Pattern
**Pattern type:** [correction/frustration/failure/repetitive/workaround]
**Phrases to detect:**
- Chinese: [...]
- English: [...]
**Severity:** [low/medium/high]
**Why this matters:**
[Explain what this pattern indicates]
**Suggested action:**
[What should happen when detected]
Examples
Example 1: User Correction
User: "ไธๅฏน๏ผๆ่ฆ็ๆฏ TypeScript๏ผไธๆฏ JavaScript"
Detected: User correction pattern
Severity: Medium
Action: Invoke reflection to analyze why wrong language was used
Example 2: Frustration
User: "ๆไนๅๆฏ่ฟๆ ท๏ผ็ฌฌไธๆฌกไบ๏ผ็ฎไบๆ่ชๅทฑๅ"
Detected: Frustration + Workaround
Severity: High
Action: Immediately address the recurring issue
Example 3: Skill Failure
System: skill_record(skill="web-scraper", success=false)
System: skill_record(skill="web-scraper", success=false)
Detected: Consecutive skill failure
Severity: High
Action: Analyze web-scraper skill for fundamental issues
Remember
- Triggers are signals, not commands - use judgment
- High severity triggers should pause other work
- Multiple triggers in one message = higher overall priority
- The goal is continuous improvement, not blame
- Every trigger is a learning opportunity