@creator-notes/cnotes 0.84.0 → 0.86.0
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.
- package/.claude-plugin/plugin.json +1 -1
- package/dist/commands/notes.d.ts.map +1 -1
- package/dist/commands/notes.js +10 -5
- package/dist/commands/notes.js.map +1 -1
- package/dist/commands/quality.d.ts +9 -4
- package/dist/commands/quality.d.ts.map +1 -1
- package/dist/commands/quality.js +160 -66
- package/dist/commands/quality.js.map +1 -1
- package/dist/lib/agent-grade.d.ts +24 -0
- package/dist/lib/agent-grade.d.ts.map +1 -0
- package/dist/lib/agent-grade.js +31 -0
- package/dist/lib/agent-grade.js.map +1 -0
- package/dist/lib/draft-view.d.ts +40 -2
- package/dist/lib/draft-view.d.ts.map +1 -1
- package/dist/lib/draft-view.js +42 -2
- package/dist/lib/draft-view.js.map +1 -1
- package/dist/lib/quality.d.ts +84 -6
- package/dist/lib/quality.d.ts.map +1 -1
- package/dist/lib/quality.js +183 -12
- package/dist/lib/quality.js.map +1 -1
- package/dist/lib/rubric-sections.d.ts +29 -0
- package/dist/lib/rubric-sections.d.ts.map +1 -0
- package/dist/lib/rubric-sections.js +77 -0
- package/dist/lib/rubric-sections.js.map +1 -0
- package/package.json +1 -1
- package/skills/cnotes/SKILL.md +37 -12
package/dist/lib/quality.js
CHANGED
|
@@ -1,32 +1,70 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Note quality checks for `cnotes quality`.
|
|
3
3
|
*
|
|
4
|
-
* Two kinds of check,
|
|
4
|
+
* Two kinds of check, both free:
|
|
5
5
|
*
|
|
6
6
|
* - STRUCTURAL (this module, pure): things a reader trips on regardless of
|
|
7
7
|
* type: no title, a body too thin to say anything, a type the workspace
|
|
8
|
-
* doesn't define, a type with no rubric
|
|
9
|
-
*
|
|
8
|
+
* doesn't define, a type with no rubric, a note that has already been
|
|
9
|
+
* superseded, and a missing heading the rubric declared under
|
|
10
|
+
* "Required sections:". Bare display IDs are structural too, but need a
|
|
10
11
|
* workspace lookup, so the command runs them through mention-lint.
|
|
11
|
-
* - RUBRIC
|
|
12
|
-
*
|
|
13
|
-
*
|
|
12
|
+
* - RUBRIC: the calling agent grades. This module builds the
|
|
13
|
+
* "grade this against the rubric" payload (rubric + note content + the
|
|
14
|
+
* instruction) and reads a grade the agent already recorded. Nothing here
|
|
15
|
+
* spends credits. The ladder is the same one the editor banner uses.
|
|
14
16
|
*
|
|
15
17
|
* Output is shaped for an agent that writes, checks and revises in one run:
|
|
16
18
|
* every issue carries a stable `code` to branch on and a sentence to act on.
|
|
17
19
|
*/
|
|
20
|
+
import { AGENT_GRADE_INSTRUCTION } from "./agent-grade.js";
|
|
21
|
+
import { missingRequiredSections } from "./rubric-sections.js";
|
|
18
22
|
import { readSupersededBy } from "./superseded-by.js";
|
|
19
|
-
/** Same floor the grader
|
|
20
|
-
* the server skips grading as "still drafting", so flag it here instead. */
|
|
23
|
+
/** Same floor the old server grader used. Below it there is nothing to judge. */
|
|
21
24
|
export const MIN_BODY_CHARS = 50;
|
|
22
25
|
/** Top rung of the quality ladder (1 Fragment … 4 Strong). */
|
|
23
26
|
export const LADDER_TOP = 4;
|
|
27
|
+
/** Grading spends nothing. Kept on the report so a reader can see the cost. */
|
|
28
|
+
export const QUALITY_CREDIT_COST = 0;
|
|
24
29
|
export const LADDER_LABELS = {
|
|
25
30
|
1: "Fragment",
|
|
26
31
|
2: "Taking shape",
|
|
27
32
|
3: "One move from strong",
|
|
28
33
|
4: "Strong",
|
|
29
34
|
};
|
|
35
|
+
function readCriteria(value) {
|
|
36
|
+
if (!Array.isArray(value))
|
|
37
|
+
return [];
|
|
38
|
+
const out = [];
|
|
39
|
+
for (const item of value) {
|
|
40
|
+
if (!item || typeof item !== "object")
|
|
41
|
+
continue;
|
|
42
|
+
const rec = item;
|
|
43
|
+
const criterion = typeof rec.criterion === "string" ? rec.criterion : "";
|
|
44
|
+
const reason = typeof rec.reason === "string" ? rec.reason : "";
|
|
45
|
+
if (!criterion || !reason)
|
|
46
|
+
continue;
|
|
47
|
+
out.push({ criterion, reason });
|
|
48
|
+
}
|
|
49
|
+
return out;
|
|
50
|
+
}
|
|
51
|
+
/** A grade previously recorded on the note, or null when this version has none. */
|
|
52
|
+
export function readStoredGrade(row) {
|
|
53
|
+
const raw = row.qualityGrade;
|
|
54
|
+
if (!raw || typeof raw !== "object")
|
|
55
|
+
return null;
|
|
56
|
+
const grade = raw;
|
|
57
|
+
if (typeof grade.level !== "number")
|
|
58
|
+
return null;
|
|
59
|
+
return {
|
|
60
|
+
level: grade.level,
|
|
61
|
+
feedback: typeof grade.feedback === "string" ? grade.feedback : "",
|
|
62
|
+
nextStep: typeof grade.nextStep === "string" ? grade.nextStep : "",
|
|
63
|
+
suggestions: Array.isArray(grade.suggestions) ? grade.suggestions.map(String) : [],
|
|
64
|
+
criteria: readCriteria(grade.criteria),
|
|
65
|
+
gradedBy: typeof grade.gradedBy === "string" ? grade.gradedBy : null,
|
|
66
|
+
};
|
|
67
|
+
}
|
|
30
68
|
/** Normalise a `/api/notes` row (markdown format) into what the checks read. */
|
|
31
69
|
export function toQualityNote(row) {
|
|
32
70
|
const latest = row.latestVersion;
|
|
@@ -37,13 +75,18 @@ export function toQualityNote(row) {
|
|
|
37
75
|
title: typeof row.title === "string" ? row.title : "",
|
|
38
76
|
type: typeof row.type === "string" ? row.type : "",
|
|
39
77
|
markdown: typeof body === "string" ? body : "",
|
|
78
|
+
versionNumber: typeof row.latestVersionNumber === "number" && row.latestVersionNumber > 0
|
|
79
|
+
? row.latestVersionNumber
|
|
80
|
+
: null,
|
|
40
81
|
raw: row,
|
|
82
|
+
storedGrade: readStoredGrade(row),
|
|
41
83
|
};
|
|
42
84
|
}
|
|
43
85
|
/** Build the type catalog from a `/api/supertags` response. */
|
|
44
86
|
export function typeCatalogFrom(supertags) {
|
|
45
87
|
const known = new Set();
|
|
46
88
|
const withRubric = new Set();
|
|
89
|
+
const rubrics = new Map();
|
|
47
90
|
for (const s of Array.isArray(supertags) ? supertags : []) {
|
|
48
91
|
const name = String(s.name ?? "").toLowerCase();
|
|
49
92
|
if (!name)
|
|
@@ -51,9 +94,10 @@ export function typeCatalogFrom(supertags) {
|
|
|
51
94
|
known.add(name);
|
|
52
95
|
if (typeof s.validationPrompt === "string" && s.validationPrompt.trim()) {
|
|
53
96
|
withRubric.add(name);
|
|
97
|
+
rubrics.set(name, s.validationPrompt);
|
|
54
98
|
}
|
|
55
99
|
}
|
|
56
|
-
return { known, withRubric };
|
|
100
|
+
return { known, withRubric, rubrics };
|
|
57
101
|
}
|
|
58
102
|
/** Every structural issue on one note that needs no further lookup. */
|
|
59
103
|
export function structuralIssues(note, types) {
|
|
@@ -71,7 +115,7 @@ export function structuralIssues(note, types) {
|
|
|
71
115
|
code: "empty_body",
|
|
72
116
|
message: bodyChars === 0
|
|
73
117
|
? "Empty body. The note says nothing beyond its title."
|
|
74
|
-
: `Body is ${bodyChars} characters, under the ${MIN_BODY_CHARS}
|
|
118
|
+
: `Body is ${bodyChars} characters, under the ${MIN_BODY_CHARS} a grade needs to judge it.`,
|
|
75
119
|
});
|
|
76
120
|
}
|
|
77
121
|
const typeKey = note.type.toLowerCase();
|
|
@@ -89,6 +133,15 @@ export function structuralIssues(note, types) {
|
|
|
89
133
|
message: `Type "${note.type}" has no rubric, so it cannot be graded. Add one with \`cnotes types update ${note.type} --validation-prompt "…"\`.`,
|
|
90
134
|
});
|
|
91
135
|
}
|
|
136
|
+
else {
|
|
137
|
+
const rubric = types.rubrics.get(typeKey) ?? "";
|
|
138
|
+
for (const section of missingRequiredSections(note.markdown, rubric)) {
|
|
139
|
+
issues.push({
|
|
140
|
+
code: "missing_section",
|
|
141
|
+
message: `Missing required section "## ${section}". The ${note.type} rubric requires it as a heading.`,
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
}
|
|
92
145
|
const supersededBy = readSupersededBy(note.raw);
|
|
93
146
|
if (supersededBy && supersededBy.length > 0) {
|
|
94
147
|
const by = supersededBy.map((r) => r.displayId).filter(Boolean).join(", ");
|
|
@@ -99,6 +152,23 @@ export function structuralIssues(note, types) {
|
|
|
99
152
|
}
|
|
100
153
|
return issues;
|
|
101
154
|
}
|
|
155
|
+
export function gradeFromStored(note) {
|
|
156
|
+
const stored = note.storedGrade;
|
|
157
|
+
if (!stored)
|
|
158
|
+
return null;
|
|
159
|
+
return {
|
|
160
|
+
outcome: "graded",
|
|
161
|
+
level: stored.level,
|
|
162
|
+
label: LADDER_LABELS[stored.level] ?? `Level ${stored.level}`,
|
|
163
|
+
isTopRung: stored.level >= LADDER_TOP,
|
|
164
|
+
feedback: stored.feedback,
|
|
165
|
+
nextStep: stored.nextStep,
|
|
166
|
+
suggestions: stored.suggestions,
|
|
167
|
+
criteria: stored.criteria,
|
|
168
|
+
gradedBy: stored.gradedBy,
|
|
169
|
+
};
|
|
170
|
+
}
|
|
171
|
+
/** @deprecated Server Check quality responses. Kept so a stored body still maps. */
|
|
102
172
|
export function gradeFromResponse(body) {
|
|
103
173
|
if (body.outcome === "graded" && typeof body.level === "number") {
|
|
104
174
|
return {
|
|
@@ -109,23 +179,124 @@ export function gradeFromResponse(body) {
|
|
|
109
179
|
feedback: String(body.feedback ?? ""),
|
|
110
180
|
nextStep: String(body.nextStep ?? ""),
|
|
111
181
|
suggestions: Array.isArray(body.suggestions) ? body.suggestions.map(String) : [],
|
|
182
|
+
criteria: readCriteria(body.criteria),
|
|
183
|
+
gradedBy: typeof body.gradedBy === "string" ? body.gradedBy : null,
|
|
112
184
|
};
|
|
113
185
|
}
|
|
186
|
+
if (body.outcome === "needs_agent") {
|
|
187
|
+
return { outcome: "needs_agent", reason: String(body.reason ?? AGENT_GRADE_INSTRUCTION) };
|
|
188
|
+
}
|
|
114
189
|
return {
|
|
115
190
|
outcome: "skipped",
|
|
116
191
|
reason: String(body.reason ?? body.skipReason ?? "not graded"),
|
|
117
192
|
};
|
|
118
193
|
}
|
|
194
|
+
/** The payload handed to the calling agent: rubric, note, and how to record. */
|
|
195
|
+
export function gradeRequestFor(note, rubric) {
|
|
196
|
+
const criteriaExample = JSON.stringify([{ criterion: "<name>", reason: "<why>" }]);
|
|
197
|
+
const versionFlag = note.versionNumber ? ` --graded-version ${note.versionNumber}` : "";
|
|
198
|
+
return {
|
|
199
|
+
task: "grade_against_rubric",
|
|
200
|
+
instruction: AGENT_GRADE_INSTRUCTION,
|
|
201
|
+
displayId: note.displayId,
|
|
202
|
+
type: note.type,
|
|
203
|
+
title: note.title,
|
|
204
|
+
rubric,
|
|
205
|
+
content: note.markdown,
|
|
206
|
+
versionNumber: note.versionNumber,
|
|
207
|
+
ladder: [1, 2, 3, 4].map((level) => ({ level, label: LADDER_LABELS[level] })),
|
|
208
|
+
submit: {
|
|
209
|
+
command: `cnotes quality record ${note.displayId}${versionFlag} --level <1-4> --criteria '${criteriaExample}'` +
|
|
210
|
+
` --feedback "<where it sits>" --next-step "<one move, empty at 4>"`,
|
|
211
|
+
method: "POST",
|
|
212
|
+
path: `/api/notes/${encodeURIComponent(note.displayId)}/grade`,
|
|
213
|
+
},
|
|
214
|
+
};
|
|
215
|
+
}
|
|
119
216
|
/**
|
|
120
217
|
* Whether a report item should fail a `--fail-below <level>` gate: a graded
|
|
121
|
-
* note under the bar,
|
|
122
|
-
* the workspace's gap, not the note's
|
|
218
|
+
* note under the bar, a note the agent has not graded yet, or any structural
|
|
219
|
+
* issue except `no_rubric` (that one is the workspace's gap, not the note's).
|
|
123
220
|
*/
|
|
124
221
|
export function itemFails(item, failBelow) {
|
|
125
222
|
if (failBelow === undefined)
|
|
126
223
|
return false;
|
|
127
224
|
if (item.grade.outcome === "graded" && item.grade.level < failBelow)
|
|
128
225
|
return true;
|
|
226
|
+
if (item.grade.outcome === "needs_agent")
|
|
227
|
+
return true;
|
|
129
228
|
return item.issues.some((i) => i.code !== "no_rubric");
|
|
130
229
|
}
|
|
230
|
+
/**
|
|
231
|
+
* Parse `cnotes quality record` flags into the body the free record endpoint
|
|
232
|
+
* accepts. Returns a message instead of throwing so the command owns the exit.
|
|
233
|
+
*/
|
|
234
|
+
export function parseGradeSubmission(input) {
|
|
235
|
+
const level = Number(input.level);
|
|
236
|
+
if (!Number.isInteger(level) || level < 1 || level > LADDER_TOP) {
|
|
237
|
+
return { ok: false, message: `--level must be a rung from 1 to ${LADDER_TOP}.` };
|
|
238
|
+
}
|
|
239
|
+
const rung = level;
|
|
240
|
+
let parsed;
|
|
241
|
+
try {
|
|
242
|
+
parsed = JSON.parse(input.criteria);
|
|
243
|
+
}
|
|
244
|
+
catch {
|
|
245
|
+
return {
|
|
246
|
+
ok: false,
|
|
247
|
+
message: `--criteria must be a JSON array of {"criterion","reason"} objects.`,
|
|
248
|
+
};
|
|
249
|
+
}
|
|
250
|
+
if (!Array.isArray(parsed) || parsed.length === 0) {
|
|
251
|
+
return { ok: false, message: "--criteria needs at least one {criterion, reason}." };
|
|
252
|
+
}
|
|
253
|
+
if (parsed.length > 12) {
|
|
254
|
+
return { ok: false, message: "--criteria accepts at most 12 criteria." };
|
|
255
|
+
}
|
|
256
|
+
const criteria = [];
|
|
257
|
+
for (let i = 0; i < parsed.length; i++) {
|
|
258
|
+
const item = parsed[i];
|
|
259
|
+
if (!item || typeof item !== "object") {
|
|
260
|
+
return { ok: false, message: `criteria[${i}] must be an object with criterion and reason.` };
|
|
261
|
+
}
|
|
262
|
+
const rec = item;
|
|
263
|
+
const criterion = String(rec.criterion ?? rec.name ?? "").trim();
|
|
264
|
+
const reason = String(rec.reason ?? "").trim();
|
|
265
|
+
if (!criterion || !reason) {
|
|
266
|
+
return { ok: false, message: `criteria[${i}] needs both criterion and reason.` };
|
|
267
|
+
}
|
|
268
|
+
if (criterion.length > 200 || reason.length > 2000) {
|
|
269
|
+
return { ok: false, message: `criteria[${i}] is too long (criterion ≤ 200, reason ≤ 2000).` };
|
|
270
|
+
}
|
|
271
|
+
criteria.push({ criterion, reason });
|
|
272
|
+
}
|
|
273
|
+
const nextStep = (input.nextStep ?? "").trim();
|
|
274
|
+
if (rung < LADDER_TOP && !nextStep) {
|
|
275
|
+
return {
|
|
276
|
+
ok: false,
|
|
277
|
+
message: "A grade below 4 needs --next-step: the single most valuable change.",
|
|
278
|
+
};
|
|
279
|
+
}
|
|
280
|
+
let versionNumber;
|
|
281
|
+
if (input.version !== undefined) {
|
|
282
|
+
versionNumber = Number(input.version);
|
|
283
|
+
if (!Number.isInteger(versionNumber) || versionNumber < 1) {
|
|
284
|
+
return { ok: false, message: "--graded-version must be the version number you graded (a positive integer)." };
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
const feedback = input.feedback?.trim();
|
|
288
|
+
const gradedBy = input.gradedBy?.trim();
|
|
289
|
+
return {
|
|
290
|
+
ok: true,
|
|
291
|
+
value: {
|
|
292
|
+
level: rung,
|
|
293
|
+
criteria,
|
|
294
|
+
...(feedback ? { feedback } : {}),
|
|
295
|
+
nextStep: rung >= LADDER_TOP ? "" : nextStep,
|
|
296
|
+
suggestions: (input.suggestions ?? []).map((s) => s.trim()).filter(Boolean),
|
|
297
|
+
...(gradedBy ? { gradedBy } : {}),
|
|
298
|
+
...(versionNumber !== undefined ? { versionNumber } : {}),
|
|
299
|
+
},
|
|
300
|
+
};
|
|
301
|
+
}
|
|
131
302
|
//# sourceMappingURL=quality.js.map
|
package/dist/lib/quality.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"quality.js","sourceRoot":"","sources":["../../src/lib/quality.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD;6EAC6E;AAC7E,MAAM,CAAC,MAAM,cAAc,GAAG,EAAE,CAAC;AAEjC,8DAA8D;AAC9D,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,CAAC;AAE5B,MAAM,CAAC,MAAM,aAAa,GAA2B;IACnD,CAAC,EAAE,UAAU;IACb,CAAC,EAAE,cAAc;IACjB,CAAC,EA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;AACJ,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Which sections a rubric requires, and whether a note's headings include them.
|
|
3
|
+
*
|
|
4
|
+
* Deterministic on purpose: no model, no credits. A rubric requires a section
|
|
5
|
+
* only when it says so, in either of these forms (the label is case-insensitive):
|
|
6
|
+
*
|
|
7
|
+
* Required sections: Problem; Options; Rationale
|
|
8
|
+
* Required sections:
|
|
9
|
+
* - Problem
|
|
10
|
+
* - Options
|
|
11
|
+
*
|
|
12
|
+
* Names are separated by semicolons so a name may contain commas. A period ends
|
|
13
|
+
* a name, so an explanation can follow the list on the same line. A rubric that
|
|
14
|
+
* never declares sections requires none: the check stays quiet instead of
|
|
15
|
+
* inventing headings from prose.
|
|
16
|
+
*
|
|
17
|
+
* Copied to cli/src/lib/rubric-sections.ts. Keep the two files byte-identical;
|
|
18
|
+
* __tests__/agent-grade.test.ts fails when they drift.
|
|
19
|
+
*/
|
|
20
|
+
/** Section names a rubric declares, in declaration order, without duplicates. */
|
|
21
|
+
export declare function requiredSections(rubric: string): string[];
|
|
22
|
+
/** ATX heading texts (`#` through `######`), in order. */
|
|
23
|
+
export declare function headingTexts(markdown: string): string[];
|
|
24
|
+
/**
|
|
25
|
+
* Declared section names that do not appear as a heading in `markdown`.
|
|
26
|
+
* Comparison is case-insensitive. An undeclared rubric returns an empty list.
|
|
27
|
+
*/
|
|
28
|
+
export declare function missingRequiredSections(markdown: string, rubric: string): string[];
|
|
29
|
+
//# sourceMappingURL=rubric-sections.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rubric-sections.d.ts","sourceRoot":"","sources":["../../src/lib/rubric-sections.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,iFAAiF;AACjF,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CA6BzD;AAED,0DAA0D;AAC1D,wBAAgB,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,EAAE,CAMvD;AAMD;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAKlF"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Which sections a rubric requires, and whether a note's headings include them.
|
|
3
|
+
*
|
|
4
|
+
* Deterministic on purpose: no model, no credits. A rubric requires a section
|
|
5
|
+
* only when it says so, in either of these forms (the label is case-insensitive):
|
|
6
|
+
*
|
|
7
|
+
* Required sections: Problem; Options; Rationale
|
|
8
|
+
* Required sections:
|
|
9
|
+
* - Problem
|
|
10
|
+
* - Options
|
|
11
|
+
*
|
|
12
|
+
* Names are separated by semicolons so a name may contain commas. A period ends
|
|
13
|
+
* a name, so an explanation can follow the list on the same line. A rubric that
|
|
14
|
+
* never declares sections requires none: the check stays quiet instead of
|
|
15
|
+
* inventing headings from prose.
|
|
16
|
+
*
|
|
17
|
+
* Copied to cli/src/lib/rubric-sections.ts. Keep the two files byte-identical;
|
|
18
|
+
* __tests__/agent-grade.test.ts fails when they drift.
|
|
19
|
+
*/
|
|
20
|
+
/** Section names a rubric declares, in declaration order, without duplicates. */
|
|
21
|
+
export function requiredSections(rubric) {
|
|
22
|
+
const names = [];
|
|
23
|
+
const seen = new Set();
|
|
24
|
+
const add = (raw) => {
|
|
25
|
+
const name = raw.split(".")[0]?.trim().replace(/^#+\s*/, "").trim() ?? "";
|
|
26
|
+
if (!name)
|
|
27
|
+
return;
|
|
28
|
+
const key = name.toLowerCase();
|
|
29
|
+
if (seen.has(key))
|
|
30
|
+
return;
|
|
31
|
+
seen.add(key);
|
|
32
|
+
names.push(name);
|
|
33
|
+
};
|
|
34
|
+
const lines = rubric.split(/\r?\n/);
|
|
35
|
+
for (let i = 0; i < lines.length; i++) {
|
|
36
|
+
const match = lines[i].match(/required sections\s*:\s*(.*)$/i);
|
|
37
|
+
if (!match)
|
|
38
|
+
continue;
|
|
39
|
+
const rest = match[1].trim();
|
|
40
|
+
if (rest) {
|
|
41
|
+
for (const part of rest.split(/\s*;\s*/))
|
|
42
|
+
add(part);
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
for (let j = i + 1; j < lines.length; j++) {
|
|
46
|
+
const bullet = lines[j].match(/^\s*[-*]\s+(.+)$/);
|
|
47
|
+
if (!bullet)
|
|
48
|
+
break;
|
|
49
|
+
add(bullet[1]);
|
|
50
|
+
i = j;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
return names;
|
|
54
|
+
}
|
|
55
|
+
/** ATX heading texts (`#` through `######`), in order. */
|
|
56
|
+
export function headingTexts(markdown) {
|
|
57
|
+
const out = [];
|
|
58
|
+
for (const match of markdown.matchAll(/^#{1,6}[ \t]+(.+?)[ \t]*$/gm)) {
|
|
59
|
+
out.push(match[1].trim());
|
|
60
|
+
}
|
|
61
|
+
return out;
|
|
62
|
+
}
|
|
63
|
+
function norm(value) {
|
|
64
|
+
return value.trim().toLowerCase().replace(/\s+/g, " ").replace(/[.:]+$/, "");
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Declared section names that do not appear as a heading in `markdown`.
|
|
68
|
+
* Comparison is case-insensitive. An undeclared rubric returns an empty list.
|
|
69
|
+
*/
|
|
70
|
+
export function missingRequiredSections(markdown, rubric) {
|
|
71
|
+
const required = requiredSections(rubric);
|
|
72
|
+
if (required.length === 0)
|
|
73
|
+
return [];
|
|
74
|
+
const headings = new Set(headingTexts(markdown).map(norm));
|
|
75
|
+
return required.filter((name) => !headings.has(norm(name)));
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=rubric-sections.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rubric-sections.js","sourceRoot":"","sources":["../../src/lib/rubric-sections.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,iFAAiF;AACjF,MAAM,U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ANGED
package/skills/cnotes/SKILL.md
CHANGED
|
@@ -251,13 +251,23 @@ cnotes notes create --notes '[
|
|
|
251
251
|
# (and `details.items` in --json mode), so you can fix the whole batch in one shot.
|
|
252
252
|
# Each .results[] item carries .type + .rubric — keep them when filtering JSON.
|
|
253
253
|
|
|
254
|
-
# THEN: grade what you just wrote and revise before ending the run.
|
|
255
|
-
#
|
|
256
|
-
#
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
#
|
|
254
|
+
# THEN: grade what you just wrote and revise before ending the run.
|
|
255
|
+
# You are the grader. Grading spends no credits. `cnotes quality` does not
|
|
256
|
+
# call a server model. It returns a gradeRequest on each ungraded note:
|
|
257
|
+
# task "grade_against_rubric", the type rubric, the note content, and the
|
|
258
|
+
# instruction "Grade this against the rubric". The create response's
|
|
259
|
+
# .selfCheck is this command. Read .items[].gradeRequest (it also sits on
|
|
260
|
+
# .gradeRequests). Do not drop it when you keep only the display id.
|
|
261
|
+
cnotes quality INSIGHT-12 PAINPOINT-4 --fail-below 4 --json
|
|
262
|
+
# Exit 3 until you record a grade. Then:
|
|
263
|
+
cnotes quality record INSIGHT-12 --graded-version 4 --level 3 --criteria '[{"criterion":"Evidence","reason":"Grounded in two tickets."}]' --feedback "The pattern is named." --next-step "Say what would falsify it."
|
|
264
|
+
cnotes quality --canvas CANVAS-60 --json
|
|
265
|
+
cnotes quality --all --limit 200 --no-grade
|
|
266
|
+
# Structural codes (free, no credits): missing_title, empty_body, bare_id,
|
|
267
|
+
# unknown_type, no_rubric, superseded, missing_section.
|
|
268
|
+
# missing_section fires only for headings named in a rubric line
|
|
269
|
+
# "Required sections: Problem; Options". A rubric without that line
|
|
270
|
+
# requires no headings.
|
|
261
271
|
|
|
262
272
|
# Update metadata only (not content — use versions for that)
|
|
263
273
|
# NOTE: --title is NOT available. Title is read-only, derived from the # h1 heading in version content.
|
|
@@ -678,8 +688,15 @@ cnotes draft dismiss # close it; nothing reaches the shared
|
|
|
678
688
|
```
|
|
679
689
|
|
|
680
690
|
The loop:
|
|
681
|
-
1. **Build inside the draft.** New notes and canvases land
|
|
682
|
-
copy takes your canvas edits.
|
|
691
|
+
1. **Build inside the draft, one run per change.** New notes and canvases land
|
|
692
|
+
in it, and a branch copy takes your canvas edits. The person reviews your
|
|
693
|
+
version run by run, each under the intent you began it with (`cnotes
|
|
694
|
+
operations begin --prompt "Resolve the sign-in ticket with its Decision"`),
|
|
695
|
+
the way a pull request is read commit by commit. So bracket one intention
|
|
696
|
+
per run, named as the change, and never a run whose prompt lists three
|
|
697
|
+
things with "and". Reflowing cards inside a frame is folded away as layout;
|
|
698
|
+
moving a card into another frame, adding, removing, relinking and
|
|
699
|
+
rewording are what the person reads. Link to shared notes normally:
|
|
683
700
|
`[DECISION-12: Title](relationship:builds-on)` resolves to the shared note
|
|
684
701
|
and stays a working link once the draft lands.
|
|
685
702
|
2. **Change a shared note by proposing it, never live.** Read it (`cnotes
|
|
@@ -1069,7 +1086,7 @@ For any canvas you only *added to* (you already hold its id, so you didn't re-`g
|
|
|
1069
1086
|
|
|
1070
1087
|
### Note Types
|
|
1071
1088
|
- The `--type` parameter must reference an **existing supertag** in the workspace. Free-text type strings are rejected.
|
|
1072
|
-
- **Pick the type, then read its rubric, then write to it — in that order.** Each type carries a `validationPrompt` (its quality rubric: what a good instance contains). Once you know the type, run `cnotes types show <Type>` (or read `typeRubrics` from `cnotes operations begin --json` / `validationPrompt` from `cnotes types list --json`) and author to that rubric so the note lands well-formed
|
|
1089
|
+
- **Pick the type, then read its rubric, then write to it — in that order.** Each type carries a `validationPrompt` (its quality rubric: what a good instance contains). Once you know the type, run `cnotes types show <Type>` (or read `typeRubrics` from `cnotes operations begin --json` / `validationPrompt` from `cnotes types list --json`) and author to that rubric so the note lands well-formed. Example: a Decision needs the alternatives weighed, the rationale, and a revisit trigger, and it cites the cards it depends on (see [Decisions](#decisions)). `cnotes notes create --json` also puts the rubric on **each** `.results[]` item (`type` + `rubric`) and as a top-level `rubrics` array. Do not cut the output down to only `displayId` until you have checked `.results[].rubric`. After the write, you grade: `cnotes quality` hands back `gradeRequest` (rubric + content + "Grade this against the rubric") and spends no credits. Record the grade with `cnotes quality record`. A Decision rubric that declares `Required sections:` fails the free structural check until those `##` headings are present.
|
|
1073
1090
|
- If the type you need doesn't exist, create it first: `cnotes types create "MyType" --display-name "My Type"`
|
|
1074
1091
|
- Type names are **case-sensitive** and use PascalCase (e.g., `Update`, `PainPoint`, `Meeting`).
|
|
1075
1092
|
- The display ID prefix is **auto-derived** from the display name: spaces become hyphens, all uppercase (e.g., display name "Pain Point" → prefix `PAIN-POINT`, display name "Idea" → prefix `IDEA`).
|
|
@@ -1270,8 +1287,16 @@ cnotes canvas add-text <canvasId> --content '# Q1' --x 0 --y 0
|
|
|
1270
1287
|
cnotes canvas place <canvasId> --spec /tmp/q1.json
|
|
1271
1288
|
cnotes canvas add-edge <canvasId> --source <a> --target <b> --label "depends on"
|
|
1272
1289
|
|
|
1273
|
-
# 3. Self-check the notes you wrote
|
|
1274
|
-
cnotes quality
|
|
1290
|
+
# 3. Self-check the notes you wrote. You grade them. This spends no credits.
|
|
1291
|
+
# `cnotes quality --json` returns gradeRequest on each ungraded item:
|
|
1292
|
+
# the rubric, the note content, and "Grade this against the rubric".
|
|
1293
|
+
# Place the note on the ladder (1 Fragment, 2 Taking shape, 3 One move
|
|
1294
|
+
# from strong, 4 Strong). Write a reason for every criterion. Record it.
|
|
1295
|
+
# gradedBy becomes the open run id (this operation), or your agent name
|
|
1296
|
+
# when no run is open. Then run quality again. Exit 3 means revise with
|
|
1297
|
+
# versions create, record a new grade, and check once more.
|
|
1298
|
+
cnotes quality INSIGHT-12 --fail-below 4 --json
|
|
1299
|
+
cnotes quality record INSIGHT-12 --graded-version 4 --level 3 --criteria '[{"criterion":"Evidence","reason":"Grounded in two tickets."}]' --feedback "The pattern is named." --next-step "Say what would falsify it."
|
|
1275
1300
|
|
|
1276
1301
|
# 4. Close the run when done.
|
|
1277
1302
|
cnotes operations end
|