@neikyun/ciel 6.1.0 → 6.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
# CIEL META-CRITIQUER: post-task reflection triggered on SubagentStop
|
|
3
3
|
# Records learnings and updates state
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
PROJECT_DIR="${CLAUDE_PROJECT_DIR:-$(pwd)}"
|
|
6
|
+
MEMO_DIR="$PROJECT_DIR/.ciel"
|
|
7
|
+
mkdir -p "$MEMO_DIR" 2>/dev/null || true
|
|
7
8
|
|
|
8
9
|
# Check if RELIRE is required
|
|
9
10
|
if [ -f "$MEMO_DIR/relire-required" ]; then
|
|
@@ -12,8 +13,19 @@ if [ -f "$MEMO_DIR/relire-required" ]; then
|
|
|
12
13
|
rm -f "$MEMO_DIR/relire-required"
|
|
13
14
|
fi
|
|
14
15
|
|
|
15
|
-
# Log subagent completion
|
|
16
|
+
# Log subagent completion — parse agent type from stdin JSON.
|
|
17
|
+
# $SUBAGENT_TYPE env var is not injected by Claude Code; stdin is the correct source.
|
|
18
|
+
INPUT=$(cat 2>/dev/null || echo "{}")
|
|
19
|
+
AGENT_TYPE=$(echo "$INPUT" | python3 -c "
|
|
20
|
+
import sys, json
|
|
21
|
+
try:
|
|
22
|
+
d = json.load(sys.stdin)
|
|
23
|
+
print(d.get('subagent_type', d.get('agent_type', 'unknown')))
|
|
24
|
+
except:
|
|
25
|
+
print('unknown')
|
|
26
|
+
" 2>/dev/null || echo "unknown")
|
|
27
|
+
|
|
16
28
|
TIMESTAMP=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
|
17
|
-
echo "- [$TIMESTAMP] Subagent completed:
|
|
29
|
+
echo "- [$TIMESTAMP] Subagent completed: \"$AGENT_TYPE\"" >> "$MEMO_DIR/subagent-log.md"
|
|
18
30
|
|
|
19
31
|
exit 0
|
|
@@ -60,6 +60,34 @@
|
|
|
60
60
|
"command": "echo \"[CIEL] Explorer started: $(date -u +%Y-%m-%dT%H:%M:%SZ)\" >> \"$CLAUDE_PROJECT_DIR/.ciel/exploration-log.md\""
|
|
61
61
|
}
|
|
62
62
|
]
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"matcher": "ciel-researcher",
|
|
66
|
+
"hooks": [
|
|
67
|
+
{
|
|
68
|
+
"type": "command",
|
|
69
|
+
"command": "echo \"[CIEL] Researcher started: $(date -u +%Y-%m-%dT%H:%M:%SZ)\" >> \"$CLAUDE_PROJECT_DIR/.ciel/subagent-log.md\""
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"matcher": "ciel-critic",
|
|
75
|
+
"hooks": [
|
|
76
|
+
{
|
|
77
|
+
"type": "command",
|
|
78
|
+
"command": "echo \"[CIEL] Critic started: $(date -u +%Y-%m-%dT%H:%M:%SZ)\" >> \"$CLAUDE_PROJECT_DIR/.ciel/subagent-log.md\""
|
|
79
|
+
}
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
],
|
|
83
|
+
"Stop": [
|
|
84
|
+
{
|
|
85
|
+
"hooks": [
|
|
86
|
+
{
|
|
87
|
+
"type": "command",
|
|
88
|
+
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/meta-critiquer.sh"
|
|
89
|
+
}
|
|
90
|
+
]
|
|
63
91
|
}
|
|
64
92
|
],
|
|
65
93
|
"SubagentStop": [
|
package/assets/CLAUDE.md
CHANGED
|
@@ -21,10 +21,11 @@ Classify depth in the FIRST line of EVERY response. No exceptions.
|
|
|
21
21
|
## MANDATORY: How to start every task
|
|
22
22
|
|
|
23
23
|
1. **Classify depth** using the Depth Gauge below
|
|
24
|
-
2. **Create TODO list** with `
|
|
24
|
+
2. **Create TODO list** with `TaskCreate` — one entry per pipeline step
|
|
25
25
|
3. **Mark current step `in_progress`** as you work
|
|
26
|
-
4. **
|
|
27
|
-
5. **
|
|
26
|
+
4. **Standard/Critical only: dispatch `ciel-researcher` + `ciel-explorer` in parallel BEFORE any Edit/Write** — this is a hard gate, not a suggestion
|
|
27
|
+
5. **Complete all steps** for the classified depth before declaring done
|
|
28
|
+
6. **End with META** — always, 10 items, non-negotiable
|
|
28
29
|
|
|
29
30
|
---
|
|
30
31
|
|
|
@@ -32,7 +33,7 @@ Classify depth in the FIRST line of EVERY response. No exceptions.
|
|
|
32
33
|
|
|
33
34
|
1. **Depth first** — every response starts with `[CIEL] Depth: <Trivial|Standard|Critical|Spike>`
|
|
34
35
|
2. **Pipeline** — follow the 16-step table below. Complete ALL steps for your depth. No shortcuts.
|
|
35
|
-
3. **TODO list** — use
|
|
36
|
+
3. **TODO list** — use `TaskCreate` at the start of each task (one task per pipeline step). Mark each step `in_progress` before starting it, `completed` when done.
|
|
36
37
|
4. **ASK** — use AskUserQuestion tool ONLY if ambiguous. If context is sufficient, DECIDE and move on.
|
|
37
38
|
5. **Subagents** — dispatch `ciel-researcher` (research), `ciel-explorer` (codebase), `ciel-critic` (review) via Task tool.
|
|
38
39
|
6. **TEST-FIRST (RED)** — write tests BEFORE source code. Never the reverse.
|
|
@@ -123,8 +124,9 @@ These are the most frequently skipped pipeline steps. Do NOT fall into these tra
|
|
|
123
124
|
| **No DOCS** | Starting a task without reading project state | Always read `.ciel/map.json` + `ciel-overlay.md` first |
|
|
124
125
|
| **No QUOI** | Coding without defining the goal + constraints | State "Goal (1 sentence) + NOT-X + DoD" before touching code |
|
|
125
126
|
| **No DIVERGE** | Using the first approach that comes to mind | Generate 2-3 alternatives before picking one |
|
|
126
|
-
| **No subagents** | Doing research/exploration inline instead of dispatching | Dispatch `ciel-researcher` + `ciel-explorer` in parallel |
|
|
127
|
+
| **No subagents** | Doing research/exploration inline instead of dispatching | Dispatch `ciel-researcher` + `ciel-explorer` in parallel — **before any Edit/Write on Standard/Critical** |
|
|
127
128
|
| **No RELIRE** | Merging without a hostile code review | Always dispatch `ciel-critic` MODE=RELIRE before merge |
|
|
129
|
+
| **RELIRE skipped on multi-file edit** | ≥2 Edit calls made without ciel-critic | Any session touching ≥2 files at Standard depth requires ciel-critic dispatch |
|
|
128
130
|
| **No PROUVER** | Claiming done without evidence | Show BEFORE/AFTER evidence (logs, curl, screenshot) |
|
|
129
131
|
| **No MEMOIRE** | Losing state between sessions | Save `.ciel/map.json` + `.ciel/memory.json` at task end |
|
|
130
132
|
| **No META** | Skipping reflection | Always run META (10 items) — it closes the feedback loop |
|
|
@@ -11,7 +11,7 @@ Principe : **"Understand before generating. Verify before claiming done."**
|
|
|
11
11
|
|
|
12
12
|
1. **Depth en 1ere ligne** — chaque reponse commence par `[CIEL Depth:X | Step:Y]`
|
|
13
13
|
2. **Pipeline** — suis les 16 etapes dans l'ordre
|
|
14
|
-
3. **TODO list** — cree une todo list au debut de chaque tache avec `todowrite` (OpenCode) ou
|
|
14
|
+
3. **TODO list** — cree une todo list au debut de chaque tache avec `todowrite` (OpenCode) ou `TaskCreate` (Claude Code). Marque chaque etape `in_progress` avant de commencer et `completed` a la fin.
|
|
15
15
|
4. **ASK** — utilise `question` tool SEULEMENT si ambigu. Si le contexte est suffisant, decide et avance sans demander.
|
|
16
16
|
5. **Subagents** — @ciel-researcher pour recherche, @ciel-explorer pour codebase, @ciel-critic pour relecture
|
|
17
17
|
6. **META** — reflexion post-tache (toujours, non-negociable)
|
|
@@ -46,6 +46,15 @@ Principe : **"Understand before generating. Verify before claiming done."**
|
|
|
46
46
|
| Trivial | Inline, pas de dispatch |
|
|
47
47
|
| Spike | @ciel-explorer si necessaire |
|
|
48
48
|
|
|
49
|
+
## GATES (non-negociables)
|
|
50
|
+
|
|
51
|
+
**GATE DISPATCH** — avant FAIRE sur toute tache Standard/Critical :
|
|
52
|
+
> Si aucun `Task(subagent_type="ciel-researcher")` et `Task(subagent_type="ciel-explorer")` n'a ete emis → STOP. Retourner a DIVERGE. Ne pas ecrire de code.
|
|
53
|
+
> Exception : taches Trivial ou si le resultat de la recherche est deja dans le contexte (ex. audit vient d'etre fait).
|
|
54
|
+
|
|
55
|
+
**GATE RELIRE** — avant de declarer une tache Standard/Critical terminee :
|
|
56
|
+
> Si aucun `Task(subagent_type="ciel-critic")` MODE=RELIRE n'a retourne ≥ 3 risques → dispatcher maintenant avant tout commit.
|
|
57
|
+
|
|
49
58
|
## References
|
|
50
59
|
|
|
51
60
|
- **Depth signals** → load `depth-classifier`
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@neikyun/ciel",
|
|
3
|
-
"version": "6.1
|
|
4
|
-
"description": "Ciel
|
|
3
|
+
"version": "6.2.1",
|
|
4
|
+
"description": "Ciel — Deep-reasoning pipeline for LLM-assisted development. OpenCode plugin + multi-platform CLI (OpenCode, Claude Code, more).",
|
|
5
5
|
"main": "./dist/plugin/index.js",
|
|
6
6
|
"types": "./dist/plugin/index.d.ts",
|
|
7
7
|
"bin": {
|
package/scripts/postinstall.cjs
CHANGED
|
@@ -150,6 +150,20 @@ async function main() {
|
|
|
150
150
|
// INIT_CWD = répertoire où l'utilisateur a lancé npm install
|
|
151
151
|
// (npm lance les lifecycle scripts dans node_modules/<pkg>/, pas dans le projet)
|
|
152
152
|
const targetDir = process.env.INIT_CWD || process.cwd();
|
|
153
|
+
|
|
154
|
+
// Skip si on installe dans le repo source Ciel lui-même (évite les doublons
|
|
155
|
+
// quand le développeur travaille dans le repo et que .claude/commands/ est déjà committé)
|
|
156
|
+
const selfPkgPath = join(targetDir, "packages/ciel/package.json");
|
|
157
|
+
if (existsSync(selfPkgPath)) {
|
|
158
|
+
try {
|
|
159
|
+
const selfPkg = JSON.parse(readFileSync(selfPkgPath, "utf-8"));
|
|
160
|
+
if (selfPkg.name === "@neikyun/ciel") {
|
|
161
|
+
console.error(` ${cyan("→")} Source repo détecté — installation ignorée (fichiers déjà dans .claude/).\n`);
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
164
|
+
} catch {}
|
|
165
|
+
}
|
|
166
|
+
|
|
153
167
|
const platforms = detectPlatforms(targetDir);
|
|
154
168
|
const assetsDir = resolveAssets();
|
|
155
169
|
|