返回 JoyAI-Echo
SKILL.md
1 ---
2 name: my
3 description: Check and set the agent's own runtime state (model, iterations, context window, token usage, web config). Use when diagnosing why something doesn't work ("why can't you search the web?", "why did you stop?"), checking resource limits before complex tasks, adapting configuration for long or simple tasks, or remembering user preferences across turns. Also use when the user asks what model you are running, how many tokens you've used, or what your settings are.
4 always: true
5 ---
6
7 # Self-Awareness
8
9 ## How to use
10
11 1. **Identify the situation** from the categories below
12 2. **Call the my tool** with the appropriate action
13 3. **If set**, warn the user before changing impactful settings (model, iterations)
14 4. **For detailed examples**, read [references/examples.md](references/examples.md)
15
16 ## When to check
17
18 <rule>
19 **Diagnose before explaining.** When something doesn't work, check your state first.
20 </rule>
21
22 <rule>
23 **Check budget before complex tasks.** Know your limits before committing.
24 </rule>
25
26 <rule>
27 **Recall across turns.** Store preferences in your scratchpad, read them back later.
28 </rule>
29
30 ## When to set
31
32 <rule>
33 **Only set when benefit is clear and user is informed.** Warn before changing model.
34 </rule>
35
36 | Situation | Command |
37 |-----------|---------|
38 | Large codebase analysis | `my(action="set", key="context_window_tokens", value=131072)` |
39 | Repetitive simple tasks | `my(action="set", key="model", value="<fast-model>")` |
40 | Long multi-step task | `my(action="set", key="max_iterations", value=80)` |
41
42 **Tradeoff:** Bias toward stability. Only set when defaults are genuinely insufficient.
43
44 ## Anti-patterns
45
46 <rule>
47 **Don't check every turn.** Costs a tool call. Use when you need information, not reflexively.
48 </rule>
49
50 <rule>
51 **Don't store sensitive data.** No API keys, passwords, or tokens in scratchpad.
52 </rule>
53
54 <rule>
55 **Don't set workspace.** Does not update file tool boundaries — won't work.
56 </rule>
57
58 ## Constraints
59
60 - All modifications in-memory only — restart resets everything
61 - Protected params have type/range validation: `max_iterations` (1–100), `context_window_tokens` (4096–1M), `model` (non-empty str)
62 - If `tools.my.allow_set` is false, check only
63
64 ## Related tools
65
66 | Need | Use | Persists? |
67 |------|-----|-----------|
68 | Per-session temp state | `my(action="set", key="...", value=...)` | No |
69 | Long-term facts | Memory skill (`MEMORY.md`, `USER.md`) | Yes |
70 | Permanent config change | Edit config file | Yes |
71
72 **Rule of thumb:** Tomorrow? Memory. This turn only? My.
73
73 lines MARKDOWN