@thanh01.pmt/curriculum-kit 1.4.37 → 1.4.39
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/dist/ai/index.cjs +194 -2
- package/dist/ai/index.cjs.map +1 -1
- package/dist/ai/index.d.cts +39 -2
- package/dist/ai/index.d.ts +39 -2
- package/dist/ai/index.mjs +191 -3
- package/dist/ai/index.mjs.map +1 -1
- package/dist/index.cjs +598 -29
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +229 -5
- package/dist/index.d.ts +229 -5
- package/dist/index.mjs +577 -30
- package/dist/index.mjs.map +1 -1
- package/dist/pipeline/index.cjs +43 -2
- package/dist/pipeline/index.cjs.map +1 -1
- package/dist/pipeline/index.mjs +43 -2
- package/dist/pipeline/index.mjs.map +1 -1
- package/dist/schemas/index.cjs +47 -2
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.cts +473 -44
- package/dist/schemas/index.d.ts +473 -44
- package/dist/schemas/index.mjs +44 -3
- package/dist/schemas/index.mjs.map +1 -1
- package/dist/workflow/index.cjs +63 -2
- package/dist/workflow/index.cjs.map +1 -1
- package/dist/workflow/index.mjs +63 -2
- package/dist/workflow/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1520,6 +1520,8 @@ function parseLessonFlow(lessonMarkdown) {
|
|
|
1520
1520
|
purpose: cells[4] || "",
|
|
1521
1521
|
studentAction: cells[5] || "",
|
|
1522
1522
|
teacherMove: cells[6] || "",
|
|
1523
|
+
outputEvidence: cells[7] || "",
|
|
1524
|
+
lo: (cells[8] || "").replace(/\*/g, "").split(/[,;/\s]+/).map((s) => s.trim()).filter(Boolean),
|
|
1523
1525
|
time: cells[9] || cells[cells.length - 2] || "",
|
|
1524
1526
|
artifactContract: cells[cells.length - 1] || ""
|
|
1525
1527
|
});
|
|
@@ -2827,11 +2829,51 @@ var ExtensionSchema = z.object({
|
|
|
2827
2829
|
});
|
|
2828
2830
|
var QualityAuditVerdictSchema = z.enum(["PASS", "NEEDS_REVISION", "FAIL"]);
|
|
2829
2831
|
var JudgeCriterionSchema = z.object({
|
|
2830
|
-
name: z.string().describe("Criterion name, e.g. Bloom Alignment, Code Validity, Word Count Gate, Language Adherence"),
|
|
2832
|
+
name: z.string().describe("Criterion name, e.g. Bloom Alignment, Code Validity, Word Count Gate, Language Adherence, Step Incrementality"),
|
|
2831
2833
|
passed: z.boolean(),
|
|
2832
2834
|
score: z.number().min(0).max(100).describe("Score out of 100"),
|
|
2833
2835
|
feedback: z.string().describe("Constructive feedback or citation of issues")
|
|
2834
2836
|
});
|
|
2837
|
+
var ActionableRepairActionSchema = z.enum([
|
|
2838
|
+
"SPLIT_STEP",
|
|
2839
|
+
"REVISE_PROVISIONING",
|
|
2840
|
+
"INSERT_RECAP",
|
|
2841
|
+
"ADJUST_TIME_BUDGET",
|
|
2842
|
+
"SUBSTITUTE_FALLBACK",
|
|
2843
|
+
"REVISE_EXIT_EVIDENCE"
|
|
2844
|
+
]);
|
|
2845
|
+
var ActionableRepairPromptSchema = z.object({
|
|
2846
|
+
action: ActionableRepairActionSchema,
|
|
2847
|
+
targetId: z.string().describe("ID of the session, feature, or step requiring repair, e.g. U01_M01_L02 or F1-S3"),
|
|
2848
|
+
severity: z.enum(["CRITICAL", "WARNING", "INFO"]).default("WARNING"),
|
|
2849
|
+
rationale: z.string().describe("Pedagogical or technical rationale for why this repair is mandated"),
|
|
2850
|
+
instruction: z.string().describe("Exact, actionable text instruction for the planner/generator in the next turn")
|
|
2851
|
+
});
|
|
2852
|
+
var ProjectGraphAuditSchema = z.object({
|
|
2853
|
+
schema_version: z.number().default(1),
|
|
2854
|
+
projectId: z.string(),
|
|
2855
|
+
overallVerdict: QualityAuditVerdictSchema,
|
|
2856
|
+
totalScore: z.number().min(0).max(100),
|
|
2857
|
+
toolchainFeasibility: JudgeCriterionSchema.describe("Installation friction, admin rights, IDE/compiler matrix"),
|
|
2858
|
+
provisioningStrategy: JudgeCriterionSchema.describe("Clear model for heavy runtimes: Pre-installed lab, Cloud instance, or Dedicated setup"),
|
|
2859
|
+
hardwareRuntimeEnvelope: JudgeCriterionSchema.describe("Memory/Flash limits, pinout conflicts, hardware platform alignment"),
|
|
2860
|
+
timeToHelloWorld: JudgeCriterionSchema.describe("Student time to achieve first working feedback loop (target <= 15 mins)"),
|
|
2861
|
+
actionableRepairs: z.array(ActionableRepairPromptSchema).default([])
|
|
2862
|
+
});
|
|
2863
|
+
var MacroPedagogyPlanAuditSchema = z.object({
|
|
2864
|
+
schema_version: z.number().default(1),
|
|
2865
|
+
planHash: z.string(),
|
|
2866
|
+
overallVerdict: QualityAuditVerdictSchema,
|
|
2867
|
+
totalScore: z.number().min(0).max(100),
|
|
2868
|
+
autoApproved: z.boolean().default(false).describe("True if totalScore >= 85 and overallVerdict is PASS"),
|
|
2869
|
+
stepIncrementality: JudgeCriterionSchema.describe("Single leap principle: <= 1 new syntax or 1 new algorithm per step"),
|
|
2870
|
+
zpdSaturation: JudgeCriterionSchema.describe("Vygotsky ZPD: <= 2 new concepts per session (K-12) / 3 (Adults), with prior anchor"),
|
|
2871
|
+
frictionAdjustedBudget: JudgeCriterionSchema.describe("Student time multiplier (2.5x): total content <= 85% session minutes"),
|
|
2872
|
+
epitomeViability: JudgeCriterionSchema.describe("Reigeluth Walking Skeleton: Unit 1 produces an end-to-end runnable MVP"),
|
|
2873
|
+
exitEvidenceSpecificity: JudgeCriterionSchema.describe("Tangible, measurable student deliverable for every session"),
|
|
2874
|
+
actionableRepairs: z.array(ActionableRepairPromptSchema).default([]),
|
|
2875
|
+
summary: z.string().describe("High-level executive evaluation summary")
|
|
2876
|
+
});
|
|
2835
2877
|
var CurriculumQualityReportSchema = z.object({
|
|
2836
2878
|
targetArtifactType: z.string().describe("Type of artifact audited, e.g. LESSON, ACT, CODE, WKS, SLIDE"),
|
|
2837
2879
|
lessonId: z.string(),
|
|
@@ -2839,7 +2881,8 @@ var CurriculumQualityReportSchema = z.object({
|
|
|
2839
2881
|
totalScore: z.number().min(0).max(100),
|
|
2840
2882
|
languageAdherencePassed: z.boolean().describe("True if content strictly matches the requested target language"),
|
|
2841
2883
|
criteria: z.array(JudgeCriterionSchema).min(3),
|
|
2842
|
-
actionableRepairPrompts: z.array(z.string()).default([]).describe("Concrete instruction prompts to fix detected issues in the next repair turn")
|
|
2884
|
+
actionableRepairPrompts: z.array(z.string()).default([]).describe("Concrete instruction prompts to fix detected issues in the next repair turn"),
|
|
2885
|
+
structuredRepairs: z.array(ActionableRepairPromptSchema).optional()
|
|
2843
2886
|
});
|
|
2844
2887
|
var ProjectProfileSchema = z.object({
|
|
2845
2888
|
id: z.string().optional(),
|
|
@@ -6723,6 +6766,111 @@ Please return a single JSON object matching these exact keys:
|
|
|
6723
6766
|
- "actionableRepairPrompts": string[]
|
|
6724
6767
|
`.trim();
|
|
6725
6768
|
}
|
|
6769
|
+
function buildCurriculumPlanJudgePrompt(input) {
|
|
6770
|
+
const { planJson, briefingContext, expectedLanguage = "Vietnamese", linterFindings = [] } = input;
|
|
6771
|
+
return `
|
|
6772
|
+
# System Methodology: Principal Curriculum SME & Macro-Pedagogical Quality Judge (@sme_judge)
|
|
6773
|
+
|
|
6774
|
+
You are the **Lead Curriculum Architect & Classroom Practicum SME**. Your role is to rigorously evaluate a candidate \`CURRICULUM_PLAN\` (Schema v3) against empirical pedagogical science, cognitive load capacity, and real classroom delivery constraints.
|
|
6775
|
+
|
|
6776
|
+
## COURSE BRIEFING & TARGET CONSTRAINTS
|
|
6777
|
+
${briefingContext}
|
|
6778
|
+
|
|
6779
|
+
${linterFindings.length > 0 ? `## DETERMINISTIC PRE-LINT FINDINGS (0-TOKEN LINTER)
|
|
6780
|
+
The deterministic structural linter detected the following issues in advance:
|
|
6781
|
+
${linterFindings.map((f) => `- [${f.severity}] ${f.id}: ${f.title} \u2014 ${f.description}`).join("\n")}
|
|
6782
|
+
Consider these deterministic findings when scoring and issuing actionable repair prescriptions.` : ""}
|
|
6783
|
+
|
|
6784
|
+
## CANDIDATE CURRICULUM PLAN JSON
|
|
6785
|
+
\`\`\`json
|
|
6786
|
+
${planJson}
|
|
6787
|
+
\`\`\`
|
|
6788
|
+
|
|
6789
|
+
## EVALUATION RUBRICS & 5 CRITICAL DIMENSIONS (TOTAL 100 POINTS)
|
|
6790
|
+
|
|
6791
|
+
1. **Step Incrementality & Single Leap Principle (20 pts):**
|
|
6792
|
+
- 20 pts: Every session introduces at most ONE new syntax or algorithmic concept. No massive cognitive leaps (e.g. going from basic variables directly to asynchronous networking).
|
|
6793
|
+
- 10 pts: Minor leap detected in 1 session that can be mitigated with starter code.
|
|
6794
|
+
- 0 pts: Severe cognitive gap (e.g. multiple compound paradigms combined in one session).
|
|
6795
|
+
|
|
6796
|
+
2. **Vygotsky ZPD Saturation & Cognitive Capacity (20 pts):**
|
|
6797
|
+
- 20 pts: New concept count <= 2 per session (K-12) / 3 (Adults), with explicit prior concept anchor or recap slot.
|
|
6798
|
+
- 10 pts: Session introduces 3 concepts without adequate bridge.
|
|
6799
|
+
- 0 pts: Severe overload (>3 new concepts in a single session) or unanchored concepts.
|
|
6800
|
+
|
|
6801
|
+
3. **Classroom Friction-Adjusted Time Budget (20 pts):**
|
|
6802
|
+
- 20 pts: Incorporates 2.5x student friction multiplier. Total content minutes <= 85% of session duration (15% overhead reserved). No step > 76 minutes.
|
|
6803
|
+
- 10 pts: Content is slightly packed, leaving < 10% buffer time.
|
|
6804
|
+
- 0 pts: Overpacked content that will cause students to run out of time in a standard classroom.
|
|
6805
|
+
|
|
6806
|
+
4. **Reigeluth Walking Skeleton & Milestone Agency (20 pts):**
|
|
6807
|
+
- 20 pts: Unit 1 culminates in an end-to-end runnable MVP (Epitome). Subsequent units provide modular elaborations.
|
|
6808
|
+
- 10 pts: Walking skeleton present but delayed to Unit 2.
|
|
6809
|
+
- 0 pts: Pure theoretical silo teaching where no working product appears until the end of the course.
|
|
6810
|
+
|
|
6811
|
+
5. **Exit Evidence Specificity (20 pts):**
|
|
6812
|
+
- 20 pts: Every session produces an explicit, tangible, user-visible deliverable (e.g. running UI screen, passing test suite, physical LED sequence).
|
|
6813
|
+
- 10 pts: Some sessions have generic deliverables ("completed practice exercise").
|
|
6814
|
+
- 0 pts: Vague or absent deliverables ("student understands topic").
|
|
6815
|
+
|
|
6816
|
+
## DECISION RULES
|
|
6817
|
+
- **PASS & AUTO-APPROVE:** Total Score >= 85 AND overallVerdict is "PASS" AND no CRITICAL actionable repairs.
|
|
6818
|
+
- **NEEDS_REVISION:** Total Score between 70 and 84, or fixable flaws. Prescribe concrete structured \`actionableRepairs\` (\`SPLIT_STEP\`, \`INSERT_RECAP\`, \`ADJUST_TIME_BUDGET\`, \`REVISE_EXIT_EVIDENCE\`).
|
|
6819
|
+
- **FAIL:** Total Score < 70, structural collapse, or unbridgeable pedagogical gaps.
|
|
6820
|
+
|
|
6821
|
+
## OUTPUT FORMAT
|
|
6822
|
+
Return a valid JSON object matching the MacroPedagogyPlanAuditSchema.
|
|
6823
|
+
`.trim();
|
|
6824
|
+
}
|
|
6825
|
+
function buildProjectGraphJudgePrompt(input) {
|
|
6826
|
+
const { bundleJson, briefingContext, linterFindings = [] } = input;
|
|
6827
|
+
return `
|
|
6828
|
+
# System Methodology: Lead Systems Engineer & Lab Infrastructure Auditor (@infra_judge)
|
|
6829
|
+
|
|
6830
|
+
You are the **Lead Lab Systems Engineer**. Your role is to rigorously evaluate a candidate \`PROJECT_GRAPH\` and its associated \`technology_scope\` against real-world lab environment feasibility, toolchain friction, and hardware constraints.
|
|
6831
|
+
|
|
6832
|
+
## COURSE BRIEFING & INFRASTRUCTURE CONSTRAINTS
|
|
6833
|
+
${briefingContext}
|
|
6834
|
+
|
|
6835
|
+
${linterFindings.length > 0 ? `## DETERMINISTIC PRE-LINT FINDINGS
|
|
6836
|
+
${linterFindings.map((f) => `- [${f.severity}] ${f.id}: ${f.title} \u2014 ${f.description}`).join("\n")}` : ""}
|
|
6837
|
+
|
|
6838
|
+
## CANDIDATE PROJECT GRAPH BUNDLE JSON
|
|
6839
|
+
\`\`\`json
|
|
6840
|
+
${bundleJson}
|
|
6841
|
+
\`\`\`
|
|
6842
|
+
|
|
6843
|
+
## EVALUATION RUBRICS & 4 DIMENSIONS (TOTAL 100 POINTS)
|
|
6844
|
+
|
|
6845
|
+
1. **Toolchain & Installation Feasibility (25 pts):**
|
|
6846
|
+
- 25 pts: Toolchain installs cleanly without complex admin rights, OS friction, or fragile build scripts.
|
|
6847
|
+
- 10 pts: Toolchain requires moderate admin setup, suitable for guided lab but risky for BYOD.
|
|
6848
|
+
- 0 pts: High-friction setup that frequently breaks in student environments.
|
|
6849
|
+
|
|
6850
|
+
2. **Environment Provisioning Strategy (25 pts):**
|
|
6851
|
+
- 25 pts: Heavy technologies (PostgreSQL, Docker, ROS2, etc.) declare an explicit, realistic provisioning model (\`PRE_INSTALLED_LAB\`, \`CLOUD_MANAGED\`, or \`DEDICATED_SETUP\`). Core course topics are NEVER downgraded; instead, proper infrastructure is specified.
|
|
6852
|
+
- 10 pts: Heavy tech used with ambiguous provisioning plan.
|
|
6853
|
+
- 0 pts: Heavy tech dumped on students with no provisioning strategy, causing setup collapse.
|
|
6854
|
+
|
|
6855
|
+
3. **Hardware & Runtime Envelope (25 pts):**
|
|
6856
|
+
- 25 pts: Code, libraries, and algorithms fit comfortably within target device RAM, Flash, and pinout budget (<= 75% envelope).
|
|
6857
|
+
- 10 pts: Memory or resource limits are tight.
|
|
6858
|
+
- 0 pts: Guaranteed hardware crash or pinout conflict.
|
|
6859
|
+
|
|
6860
|
+
4. **Time to Hello World (25 pts):**
|
|
6861
|
+
- 25 pts: First working runnable milestone achieved in <= 15 minutes of student effort.
|
|
6862
|
+
- 10 pts: First milestone takes 20-30 minutes.
|
|
6863
|
+
- 0 pts: Student spends the entire first session on environment configuration without seeing running code.
|
|
6864
|
+
|
|
6865
|
+
## DECISION RULES
|
|
6866
|
+
- **PASS:** Score >= 85 AND overallVerdict is "PASS".
|
|
6867
|
+
- **NEEDS_REVISION:** Score between 70 and 84. Prescribe structured actionable repairs.
|
|
6868
|
+
- **FAIL:** Score < 70 or critical environment blocker.
|
|
6869
|
+
|
|
6870
|
+
## OUTPUT FORMAT
|
|
6871
|
+
Return a valid JSON object matching ProjectGraphAuditSchema.
|
|
6872
|
+
`.trim();
|
|
6873
|
+
}
|
|
6726
6874
|
|
|
6727
6875
|
// src/ai/prompts/projectInstructionPrompt.ts
|
|
6728
6876
|
function buildProjectInstructionPrompt(input) {
|
|
@@ -7164,6 +7312,23 @@ async function generateExtensionFlow(input) {
|
|
|
7164
7312
|
|
|
7165
7313
|
// src/ai/flows/auditCurriculumQualityFlow.ts
|
|
7166
7314
|
init_provider_factory();
|
|
7315
|
+
|
|
7316
|
+
// src/constants/pedagogy.ts
|
|
7317
|
+
var STUDENT_FRICTION_MULTIPLIER = 2.5;
|
|
7318
|
+
var MAX_NEW_CONCEPTS_PER_SESSION_K12 = 2;
|
|
7319
|
+
var MAX_NEW_CONCEPTS_PER_SESSION_ADULT = 3;
|
|
7320
|
+
var DEFAULT_OVERHEAD_RATIO = 0.15;
|
|
7321
|
+
var MAX_IN_SESSION_SETUP_MINUTES = 15;
|
|
7322
|
+
var ENVIRONMENT_PROVISIONING_MODELS = [
|
|
7323
|
+
"PRE_INSTALLED_LAB",
|
|
7324
|
+
"CLOUD_MANAGED",
|
|
7325
|
+
"DEDICATED_SETUP"
|
|
7326
|
+
];
|
|
7327
|
+
var JUDGE_AUTO_APPROVE_THRESHOLD = 85;
|
|
7328
|
+
var JUDGE_ESCALATE_THRESHOLD = 70;
|
|
7329
|
+
var MAX_AUTONOMOUS_REPAIR_TURNS = 3;
|
|
7330
|
+
|
|
7331
|
+
// src/ai/flows/auditCurriculumQualityFlow.ts
|
|
7167
7332
|
async function auditCurriculumQualityFlow(input) {
|
|
7168
7333
|
const model = getAIModel(input.modelOptions);
|
|
7169
7334
|
const prompt = buildJudgePrompt({
|
|
@@ -7179,6 +7344,43 @@ async function auditCurriculumQualityFlow(input) {
|
|
|
7179
7344
|
schema: CurriculumQualityReportSchema,
|
|
7180
7345
|
prompt: `${prompt}
|
|
7181
7346
|
|
|
7347
|
+
Respond with a valid JSON object matching the schema.`
|
|
7348
|
+
});
|
|
7349
|
+
return object;
|
|
7350
|
+
}
|
|
7351
|
+
async function auditCurriculumPlanFlow(input) {
|
|
7352
|
+
const model = getAIModel(input.modelOptions);
|
|
7353
|
+
const prompt = buildCurriculumPlanJudgePrompt({
|
|
7354
|
+
planJson: input.planJson,
|
|
7355
|
+
briefingContext: input.briefingContext,
|
|
7356
|
+
expectedLanguage: input.expectedLanguage,
|
|
7357
|
+
linterFindings: input.linterFindings
|
|
7358
|
+
});
|
|
7359
|
+
const { object } = await generateObject({
|
|
7360
|
+
model,
|
|
7361
|
+
schema: MacroPedagogyPlanAuditSchema,
|
|
7362
|
+
prompt: `${prompt}
|
|
7363
|
+
|
|
7364
|
+
Respond with a valid JSON object matching the schema.`
|
|
7365
|
+
});
|
|
7366
|
+
const autoApproved = object.totalScore >= JUDGE_AUTO_APPROVE_THRESHOLD && object.overallVerdict === "PASS";
|
|
7367
|
+
return {
|
|
7368
|
+
...object,
|
|
7369
|
+
autoApproved
|
|
7370
|
+
};
|
|
7371
|
+
}
|
|
7372
|
+
async function auditProjectGraphFlow(input) {
|
|
7373
|
+
const model = getAIModel(input.modelOptions);
|
|
7374
|
+
const prompt = buildProjectGraphJudgePrompt({
|
|
7375
|
+
bundleJson: input.bundleJson,
|
|
7376
|
+
briefingContext: input.briefingContext,
|
|
7377
|
+
linterFindings: input.linterFindings
|
|
7378
|
+
});
|
|
7379
|
+
const { object } = await generateObject({
|
|
7380
|
+
model,
|
|
7381
|
+
schema: ProjectGraphAuditSchema,
|
|
7382
|
+
prompt: `${prompt}
|
|
7383
|
+
|
|
7182
7384
|
Respond with a valid JSON object matching the schema.`
|
|
7183
7385
|
});
|
|
7184
7386
|
return object;
|
|
@@ -26436,6 +26638,195 @@ function extractStandardRefs(text) {
|
|
|
26436
26638
|
return Array.from(new Set(matches));
|
|
26437
26639
|
}
|
|
26438
26640
|
|
|
26641
|
+
// src/parsers/lessonEntity.ts
|
|
26642
|
+
init_lessonFlowParser();
|
|
26643
|
+
var LessonEntitySchema = z.object({
|
|
26644
|
+
lessonId: z.string(),
|
|
26645
|
+
title: z.string(),
|
|
26646
|
+
pedagogyModel: z.string().default("5e"),
|
|
26647
|
+
estimatedDuration: z.string().default(""),
|
|
26648
|
+
learningObjectives: z.array(LearningObjectiveRowSchema).default([]),
|
|
26649
|
+
activitySequence: z.array(ActivitySeqRowSchema).default([]),
|
|
26650
|
+
/** Header→cell rows straight from the A4 Assessment Map table (headers vary by template). */
|
|
26651
|
+
assessmentMap: z.array(z.record(z.string())).default([]),
|
|
26652
|
+
tieredScaffolding: z.object({ bronze: z.string().default(""), silver: z.string().default(""), gold: z.string().default("") }).default({ bronze: "", silver: "", gold: "" })
|
|
26653
|
+
});
|
|
26654
|
+
var stripMd = (s) => s.replace(/\*\*/g, "").replace(/`/g, "").trim();
|
|
26655
|
+
function splitRow(line) {
|
|
26656
|
+
return line.trim().replace(/^\|/, "").replace(/\|$/, "").split("|").map((c) => c.trim());
|
|
26657
|
+
}
|
|
26658
|
+
function toActivitySeqRows(md) {
|
|
26659
|
+
const flow = parseLessonFlow(md);
|
|
26660
|
+
const rows = [];
|
|
26661
|
+
for (const a of flow.activities) {
|
|
26662
|
+
const parsed = ActivitySeqRowSchema.safeParse({
|
|
26663
|
+
seq: a.seq,
|
|
26664
|
+
phase: a.phase,
|
|
26665
|
+
activityType: a.activityType,
|
|
26666
|
+
actor: a.actor,
|
|
26667
|
+
purpose: a.purpose,
|
|
26668
|
+
studentAction: a.studentAction,
|
|
26669
|
+
teacherMove: a.teacherMove,
|
|
26670
|
+
outputEvidence: a.outputEvidence,
|
|
26671
|
+
lo: a.lo,
|
|
26672
|
+
durationMinutes: parseInt((a.time || "").replace(/[^0-9]/g, ""), 10) || 10,
|
|
26673
|
+
artifactContract: a.artifactContract
|
|
26674
|
+
});
|
|
26675
|
+
if (parsed.success) rows.push(parsed.data);
|
|
26676
|
+
}
|
|
26677
|
+
return rows;
|
|
26678
|
+
}
|
|
26679
|
+
function parseLearningObjectives(md) {
|
|
26680
|
+
const rows = [];
|
|
26681
|
+
let inLO = false;
|
|
26682
|
+
let headerSeen = false;
|
|
26683
|
+
for (const line of md.split("\n")) {
|
|
26684
|
+
const h = line.match(/^#{2,4}\s+(.*)$/);
|
|
26685
|
+
if (h) {
|
|
26686
|
+
if (/learning\s+objectives/i.test(h[1] ?? "")) inLO = true;
|
|
26687
|
+
else if (inLO) break;
|
|
26688
|
+
continue;
|
|
26689
|
+
}
|
|
26690
|
+
if (!inLO) continue;
|
|
26691
|
+
const t = line.trim();
|
|
26692
|
+
if (!t.startsWith("|")) continue;
|
|
26693
|
+
if (/^[\s|:-]+$/.test(t)) continue;
|
|
26694
|
+
const cells = splitRow(t);
|
|
26695
|
+
if (cells.length < 4) continue;
|
|
26696
|
+
if (!headerSeen) {
|
|
26697
|
+
headerSeen = true;
|
|
26698
|
+
continue;
|
|
26699
|
+
}
|
|
26700
|
+
const parsed = LearningObjectiveRowSchema.safeParse({
|
|
26701
|
+
code: stripMd(cells[0] ?? ""),
|
|
26702
|
+
objective: stripMd(cells[1] ?? ""),
|
|
26703
|
+
evidence: stripMd(cells[2] ?? ""),
|
|
26704
|
+
successCriteria: stripMd(cells[3] ?? ""),
|
|
26705
|
+
standardRefs: cells[4] ?? "" ? cells[4].split(/[\s,;]+/).filter(Boolean) : [],
|
|
26706
|
+
conceptRefs: []
|
|
26707
|
+
});
|
|
26708
|
+
if (parsed.success) rows.push(parsed.data);
|
|
26709
|
+
}
|
|
26710
|
+
return rows;
|
|
26711
|
+
}
|
|
26712
|
+
function parseAssessmentMap(md) {
|
|
26713
|
+
const rows = [];
|
|
26714
|
+
let inMap = false;
|
|
26715
|
+
let headers = [];
|
|
26716
|
+
for (const line of md.split("\n")) {
|
|
26717
|
+
const h = line.match(/^#{2,4}\s+(.*)$/);
|
|
26718
|
+
if (h) {
|
|
26719
|
+
if (/assessment\s*map/i.test(h[1] ?? "")) inMap = true;
|
|
26720
|
+
else if (inMap) break;
|
|
26721
|
+
continue;
|
|
26722
|
+
}
|
|
26723
|
+
if (!inMap) continue;
|
|
26724
|
+
const t = line.trim();
|
|
26725
|
+
if (!t.startsWith("|")) continue;
|
|
26726
|
+
if (/^[\s|:-]+$/.test(t)) continue;
|
|
26727
|
+
const cells = splitRow(t);
|
|
26728
|
+
if (headers.length === 0) {
|
|
26729
|
+
headers = cells;
|
|
26730
|
+
continue;
|
|
26731
|
+
}
|
|
26732
|
+
const row = {};
|
|
26733
|
+
headers.forEach((hdr, i) => {
|
|
26734
|
+
row[hdr] = stripMd(cells[i] ?? "");
|
|
26735
|
+
});
|
|
26736
|
+
rows.push(row);
|
|
26737
|
+
}
|
|
26738
|
+
return rows;
|
|
26739
|
+
}
|
|
26740
|
+
function parseTieredScaffolding(md) {
|
|
26741
|
+
const lines = md.split("\n");
|
|
26742
|
+
let capture = null;
|
|
26743
|
+
for (const line of lines) {
|
|
26744
|
+
const h = line.match(/^#{2,4}\s+(.*)$/);
|
|
26745
|
+
if (h) {
|
|
26746
|
+
const isTier = /elaborate|tiered|scaffold/i.test(h[1] ?? "");
|
|
26747
|
+
if (capture && !isTier) break;
|
|
26748
|
+
if (isTier) capture = [];
|
|
26749
|
+
continue;
|
|
26750
|
+
}
|
|
26751
|
+
if (capture) capture.push(line);
|
|
26752
|
+
}
|
|
26753
|
+
const body = (capture ?? []).join("\n");
|
|
26754
|
+
const grab = (label) => {
|
|
26755
|
+
const m = body.match(new RegExp(`(?:\\ud83e\\udd49|\\ud83e\\udd48|\\ud83e\\udd47)?\\s*\\*\\*${label}:\\*\\*\\s*([^\\n]+)`, "i"));
|
|
26756
|
+
return m ? m[1].trim() : "";
|
|
26757
|
+
};
|
|
26758
|
+
return { bronze: grab("Bronze"), silver: grab("Silver"), gold: grab("Gold") };
|
|
26759
|
+
}
|
|
26760
|
+
function buildLessonEntityJson(lessonMarkdown) {
|
|
26761
|
+
const md = lessonMarkdown || "";
|
|
26762
|
+
if (!md.trim()) return null;
|
|
26763
|
+
const flow = parseLessonFlow(md);
|
|
26764
|
+
const fm = md.match(/^---\s*\n([\s\S]*?)\n---/)?.[1] ?? "";
|
|
26765
|
+
const activitySequence = toActivitySeqRows(md);
|
|
26766
|
+
const learningObjectives = parseLearningObjectives(md);
|
|
26767
|
+
if (activitySequence.length === 0 && learningObjectives.length === 0) return null;
|
|
26768
|
+
const parsed = LessonEntitySchema.safeParse({
|
|
26769
|
+
lessonId: flow.lessonId || (fm.match(/id:\s*["']?([^"'\n]+)["']?/i)?.[1]?.trim() ?? ""),
|
|
26770
|
+
title: flow.lessonTitle,
|
|
26771
|
+
pedagogyModel: flow.pedagogicalModel,
|
|
26772
|
+
estimatedDuration: flow.estimatedDuration,
|
|
26773
|
+
learningObjectives,
|
|
26774
|
+
activitySequence,
|
|
26775
|
+
assessmentMap: parseAssessmentMap(md),
|
|
26776
|
+
tieredScaffolding: parseTieredScaffolding(md)
|
|
26777
|
+
});
|
|
26778
|
+
return parsed.success ? parsed.data : null;
|
|
26779
|
+
}
|
|
26780
|
+
function renderEntitySlotsForType(entity, artifactType, maxChars = 8e3) {
|
|
26781
|
+
const type = (artifactType || "").toUpperCase().trim();
|
|
26782
|
+
const parts = [];
|
|
26783
|
+
const wantActivities = ["ACT", "GUIDE", "SLIDE", "WKS", "QUIZ"].includes(type);
|
|
26784
|
+
const wantObjectives = type !== "CODE";
|
|
26785
|
+
const wantAssessment = ["QUIZ", "WKS"].includes(type);
|
|
26786
|
+
const wantTiers = ["ACT", "CODE", "EXT", "WKS"].includes(type);
|
|
26787
|
+
if (wantObjectives && entity.learningObjectives.length > 0) {
|
|
26788
|
+
parts.push(
|
|
26789
|
+
"### Learning Objectives & Evidence\n" + entity.learningObjectives.map((o) => `- ${o.code}: ${o.objective} \u2192 Evidence: ${o.evidence} | Pass: ${o.successCriteria}`).join("\n")
|
|
26790
|
+
);
|
|
26791
|
+
}
|
|
26792
|
+
if (wantActivities && entity.activitySequence.length > 0) {
|
|
26793
|
+
const header = "| Seq | Phase | Activity | Actor | Student Action | Teacher Move | Output/Evidence | LO | Mins | Artifact Contract |";
|
|
26794
|
+
const rows = [];
|
|
26795
|
+
for (const a of entity.activitySequence) {
|
|
26796
|
+
const r = `| ${a.seq} | ${a.phase} | ${a.activityType} | ${a.actor} | ${a.studentAction} | ${a.teacherMove} | ${a.outputEvidence} | ${a.lo.join(",")} | ${a.durationMinutes} | ${a.artifactContract} |`;
|
|
26797
|
+
if (parts.join("\n\n").length + r.length > maxChars) break;
|
|
26798
|
+
rows.push(r);
|
|
26799
|
+
}
|
|
26800
|
+
if (rows.length > 0) {
|
|
26801
|
+
parts.push("### Activity Sequence\n" + [header, "|---|---|---|---|---|---|---|---|---|---|", ...rows].join("\n"));
|
|
26802
|
+
}
|
|
26803
|
+
}
|
|
26804
|
+
if (wantAssessment && entity.assessmentMap.length > 0) {
|
|
26805
|
+
const lines = entity.assessmentMap.map((r) => Object.entries(r).map(([k, v]) => `${k}: ${v}`).join(" | "));
|
|
26806
|
+
parts.push("### Assessment Map (assess exactly these)\n" + lines.join("\n"));
|
|
26807
|
+
}
|
|
26808
|
+
const t = entity.tieredScaffolding;
|
|
26809
|
+
if (wantTiers && (t.bronze || t.silver || t.gold)) {
|
|
26810
|
+
parts.push(
|
|
26811
|
+
"### Tiered task ladder\n" + [t.bronze && `- Bronze: ${t.bronze}`, t.silver && `- Silver: ${t.silver}`, t.gold && `- Gold: ${t.gold}`].filter(Boolean).join("\n")
|
|
26812
|
+
);
|
|
26813
|
+
}
|
|
26814
|
+
return parts.join("\n\n").slice(0, maxChars);
|
|
26815
|
+
}
|
|
26816
|
+
function entityRowAssignedTo(row, artifactType) {
|
|
26817
|
+
const norm2 = (s) => s.toLowerCase().replace(/[^a-z0-9]/g, "");
|
|
26818
|
+
const wanted = norm2(artifactType);
|
|
26819
|
+
return row.artifactContract.split(/[,;/]/).map((c) => norm2(c)).some((c) => c === wanted || c.length > 3 && (c.includes(wanted) || wanted.includes(c)));
|
|
26820
|
+
}
|
|
26821
|
+
function renderAssignedRowsTable(entity, artifactType, maxChars = 1500) {
|
|
26822
|
+
const rows = entity.activitySequence.filter((r) => entityRowAssignedTo(r, artifactType));
|
|
26823
|
+
if (rows.length === 0) return "";
|
|
26824
|
+
const header = "| Seq | Phase | Activity | Actor | Student Action | Teacher Move | Output/Evidence | LO | Mins | Artifact Contract |";
|
|
26825
|
+
const sep = "|---|---|---|---|---|---|---|---|---|---|";
|
|
26826
|
+
const body = rows.map((a) => `| ${a.seq} | ${a.phase} | ${a.activityType} | ${a.actor} | ${a.studentAction} | ${a.teacherMove} | ${a.outputEvidence} | ${a.lo.join(",")} | ${a.durationMinutes} | ${a.artifactContract} |`);
|
|
26827
|
+
return [header, sep, ...body].join("\n").slice(0, maxChars);
|
|
26828
|
+
}
|
|
26829
|
+
|
|
26439
26830
|
// src/services/contextSlots.ts
|
|
26440
26831
|
var LESSON_SLOT_BUDGETS = {
|
|
26441
26832
|
ACT: { budget: 8e3 },
|
|
@@ -26555,6 +26946,7 @@ function buildSatelliteContext(input) {
|
|
|
26555
26946
|
slcMarkdown,
|
|
26556
26947
|
symbolLedgerBlock,
|
|
26557
26948
|
pedagogyLabel,
|
|
26949
|
+
lessonEntity,
|
|
26558
26950
|
mode = "legacy"
|
|
26559
26951
|
} = input;
|
|
26560
26952
|
const type = (artifactType || "").toUpperCase().trim();
|
|
@@ -26599,30 +26991,57 @@ ${kxExcerpt.excerpt}`);
|
|
|
26599
26991
|
}
|
|
26600
26992
|
if (!KX_ONLY_TYPES.has(type)) {
|
|
26601
26993
|
const spec = LESSON_SLOT_BUDGETS[type] ?? { budget: 12e3 };
|
|
26602
|
-
|
|
26603
|
-
|
|
26604
|
-
|
|
26605
|
-
|
|
26606
|
-
|
|
26607
|
-
|
|
26608
|
-
|
|
26994
|
+
let usedEntity = false;
|
|
26995
|
+
if (lessonEntity) {
|
|
26996
|
+
const slots = renderEntitySlotsForType(lessonEntity, type, spec.budget);
|
|
26997
|
+
if (slots) {
|
|
26998
|
+
const slotBlock = `
|
|
26999
|
+
|
|
27000
|
+
[LESSON ENTITY SLOTS (structured JSON source \u2014 canonical)]:
|
|
27001
|
+
${slots}`;
|
|
27002
|
+
parts.push(slotBlock);
|
|
27003
|
+
excerptSlot = slotBlock;
|
|
27004
|
+
blocks.push(blockMeta("lessonEntity:" + type, "LESSON_JSON", slots, true));
|
|
27005
|
+
usedEntity = true;
|
|
27006
|
+
} else {
|
|
27007
|
+
issues.push(`lesson-entity:empty-slots:${type}`);
|
|
27008
|
+
}
|
|
27009
|
+
}
|
|
27010
|
+
if (!usedEntity) {
|
|
27011
|
+
const excerpt = buildSectionAwareExcerpt(lessonContent, {
|
|
27012
|
+
priorities: spec.priorities ?? ["Artifact Contract", "A. Lesson Design Plan", "B. Lesson Flow", "Learning Objectives & Evidence", "Activity Sequence"],
|
|
27013
|
+
budget: spec.budget,
|
|
27014
|
+
sectionLanguageContract: slcMarkdown,
|
|
27015
|
+
artifactType: "LESSON"
|
|
27016
|
+
});
|
|
27017
|
+
const excerptBlock = `
|
|
26609
27018
|
|
|
26610
27019
|
[CANONICAL LESSON PLAN (scoped for ${type})]:
|
|
26611
27020
|
${excerpt.excerpt}`;
|
|
26612
|
-
|
|
26613
|
-
|
|
26614
|
-
|
|
26615
|
-
|
|
26616
|
-
|
|
26617
|
-
|
|
26618
|
-
|
|
26619
|
-
|
|
27021
|
+
parts.push(excerptBlock);
|
|
27022
|
+
excerptSlot = excerptBlock;
|
|
27023
|
+
blocks.push(blockMeta("lessonExcerpt:" + type, "LESSON", excerpt.excerpt, excerpt.verified, excerpt.issues));
|
|
27024
|
+
if (!excerpt.verified) issues.push(...excerpt.issues.map((i) => `lesson:${i}`));
|
|
27025
|
+
if (type === "QUIZ" || type === "WKS") {
|
|
27026
|
+
if (lessonEntity && lessonEntity.assessmentMap.length > 0) {
|
|
27027
|
+
const amJson = lessonEntity.assessmentMap.map((r) => Object.entries(r).map(([k, v]) => `${k}: ${v}`).join(" | ")).join("\n");
|
|
27028
|
+
parts.push(`
|
|
27029
|
+
|
|
27030
|
+
[ASSESSMENT MAP (criteria anchor \u2014 assess exactly these)]:
|
|
27031
|
+
${amJson}`);
|
|
27032
|
+
blocks.push(blockMeta("assessmentMap:" + type, "LESSON_JSON", amJson, true));
|
|
27033
|
+
} else {
|
|
27034
|
+
const am = extractAssessmentMap(lessonContent, 1200);
|
|
27035
|
+
if (am) {
|
|
27036
|
+
parts.push(`
|
|
26620
27037
|
|
|
26621
27038
|
[ASSESSMENT MAP (criteria anchor \u2014 assess exactly these)]:
|
|
26622
27039
|
${am}`);
|
|
26623
|
-
|
|
26624
|
-
|
|
26625
|
-
|
|
27040
|
+
blocks.push(blockMeta("assessmentMap:" + type, "LESSON", am, true));
|
|
27041
|
+
} else {
|
|
27042
|
+
issues.push(`assessment-map:unresolved:${type}`);
|
|
27043
|
+
}
|
|
27044
|
+
}
|
|
26626
27045
|
}
|
|
26627
27046
|
}
|
|
26628
27047
|
if (symbolLedgerBlock) {
|
|
@@ -26630,14 +27049,27 @@ ${am}`);
|
|
|
26630
27049
|
blocks.push(blockMeta("symbolLedger", "LESSON", symbolLedgerBlock, true));
|
|
26631
27050
|
}
|
|
26632
27051
|
} else {
|
|
26633
|
-
const
|
|
26634
|
-
|
|
26635
|
-
|
|
26636
|
-
|
|
26637
|
-
${
|
|
26638
|
-
|
|
26639
|
-
|
|
26640
|
-
|
|
27052
|
+
const miniParts = [];
|
|
27053
|
+
if (lessonEntity) {
|
|
27054
|
+
const rowsTable = renderAssignedRowsTable(lessonEntity, type === "CODE" ? "CODE_LAB" : type, 1500);
|
|
27055
|
+
if (rowsTable) miniParts.push(`### Activity Sequence rows assigned to ${type} (canonical \u2014 do not invent a different task):
|
|
27056
|
+
${rowsTable}`);
|
|
27057
|
+
const t = lessonEntity.tieredScaffolding;
|
|
27058
|
+
if ((type === "CODE" || type === "EXT") && (t.bronze || t.silver || t.gold)) {
|
|
27059
|
+
miniParts.push(
|
|
27060
|
+
"### Tiered task ladder (from LESSON Elaborate phase):\n" + [t.bronze && `- Bronze: ${t.bronze}`, t.silver && `- Silver: ${t.silver}`, t.gold && `- Gold: ${t.gold}`].filter(Boolean).join("\n")
|
|
27061
|
+
);
|
|
27062
|
+
}
|
|
27063
|
+
}
|
|
27064
|
+
if (miniParts.length === 0) {
|
|
27065
|
+
const contractRows = extractActivityContractRows(lessonContent, type === "CODE" ? "CODE_LAB" : type, 1500);
|
|
27066
|
+
const tierBlock = type === "CODE" || type === "EXT" ? extractTieredScaffoldingBlock(lessonContent, 900) : "";
|
|
27067
|
+
if (contractRows) miniParts.push(`### Activity Sequence rows assigned to ${type} (canonical \u2014 do not invent a different task):
|
|
27068
|
+
${contractRows}`);
|
|
27069
|
+
if (tierBlock) miniParts.push(`### Tiered task ladder (from LESSON Elaborate phase):
|
|
27070
|
+
${tierBlock}`);
|
|
27071
|
+
}
|
|
27072
|
+
const mini = miniParts.join("\n\n");
|
|
26641
27073
|
if (mini) {
|
|
26642
27074
|
const miniBlock = `
|
|
26643
27075
|
|
|
@@ -27331,7 +27763,9 @@ ${sg}${standardsBlock}${glossaryBlock}${buildGroundTruthBlock(includeKx)}${sessi
|
|
|
27331
27763
|
});
|
|
27332
27764
|
const producedArtifacts = [];
|
|
27333
27765
|
const lessonRelPath = `_content/${unitCode}/LESSON_${lessonCode}.md`;
|
|
27766
|
+
const lessonEntityRelPath = `_content/${unitCode}/LESSON_${lessonCode}.json`;
|
|
27334
27767
|
const existingLessonContent = await storage.readArtifact(projectId, lessonRelPath);
|
|
27768
|
+
let lessonEntity = buildLessonEntityJson(existingLessonContent || "");
|
|
27335
27769
|
let lessonContent = existingLessonContent || "";
|
|
27336
27770
|
if (artifactScope.includes("LESSON") && (!existingLessonContent || force || isStaleVsPlan(existingLessonContent))) {
|
|
27337
27771
|
if (existingLessonContent && !force && isStaleVsPlan(existingLessonContent)) {
|
|
@@ -27407,7 +27841,12 @@ Fix ALL issues above and output the complete corrected document.` }],
|
|
|
27407
27841
|
} else {
|
|
27408
27842
|
lessonContent = lintReport.autoFixedContent || rawLesson;
|
|
27409
27843
|
}
|
|
27410
|
-
|
|
27844
|
+
const stampedLesson = stampPlanHash(lessonContent);
|
|
27845
|
+
await storage.saveArtifact(projectId, lessonRelPath, stampedLesson);
|
|
27846
|
+
lessonEntity = buildLessonEntityJson(stampedLesson);
|
|
27847
|
+
if (lessonEntity) {
|
|
27848
|
+
await storage.saveArtifact(projectId, lessonEntityRelPath, JSON.stringify({ planHash: currentPlanHash ?? null, entity: lessonEntity }, null, 2));
|
|
27849
|
+
}
|
|
27411
27850
|
producedArtifacts.push(`LESSON_${lessonCode}.md`);
|
|
27412
27851
|
}
|
|
27413
27852
|
const contentHash = lessonContent ? computeContentHash(lessonContent) : void 0;
|
|
@@ -27729,6 +28168,7 @@ ${currentContent}` }],
|
|
|
27729
28168
|
slcMarkdown,
|
|
27730
28169
|
symbolLedgerBlock,
|
|
27731
28170
|
pedagogyLabel,
|
|
28171
|
+
lessonEntity,
|
|
27732
28172
|
mode: routingMode
|
|
27733
28173
|
});
|
|
27734
28174
|
satelliteContexts[key] = built.context;
|
|
@@ -31533,6 +31973,113 @@ var DeterministicStructuralLinter = class {
|
|
|
31533
31973
|
} else if (plan.mastery_gates && plan.mastery_gates.length > 0) {
|
|
31534
31974
|
strengths.push(`${plan.mastery_gates.length} inter-unit Mastery Gates defined with remediation protocols.`);
|
|
31535
31975
|
}
|
|
31976
|
+
const maxContentMinutes = Math.floor(
|
|
31977
|
+
(plan.constraints?.session_duration_minutes || 90) * (1 - DEFAULT_OVERHEAD_RATIO)
|
|
31978
|
+
);
|
|
31979
|
+
for (const s of plan.sessions) {
|
|
31980
|
+
const contentMins = (s.knowledge_minutes || 0) + (s.practice_minutes || 0);
|
|
31981
|
+
if (contentMins > maxContentMinutes + 2) {
|
|
31982
|
+
score -= 5;
|
|
31983
|
+
findings.push({
|
|
31984
|
+
id: `PLAN_OVERSIZED_SESSION_${s.id}`,
|
|
31985
|
+
dimension: "CONSTRUCTIVE_ALIGNMENT",
|
|
31986
|
+
severity: "MINOR",
|
|
31987
|
+
title: `Content Minutes Exceeded in Session ${s.id}`,
|
|
31988
|
+
description: `Session planned for ${contentMins} content minutes exceeds the ${maxContentMinutes}m budget (15% overhead reserve).`,
|
|
31989
|
+
remediationAdvice: `Reduce knowledge or practice minutes to fit within ${maxContentMinutes} minutes.`,
|
|
31990
|
+
affectedElement: s.id
|
|
31991
|
+
});
|
|
31992
|
+
}
|
|
31993
|
+
if (!s.exit_evidence || s.exit_evidence.length === 0 || !s.exit_evidence[0] || s.exit_evidence[0].trim().length < 3) {
|
|
31994
|
+
score -= 5;
|
|
31995
|
+
findings.push({
|
|
31996
|
+
id: `PLAN_VAGUE_EXIT_EVIDENCE_${s.id}`,
|
|
31997
|
+
dimension: "CONSTRUCTIVE_ALIGNMENT",
|
|
31998
|
+
severity: "MINOR",
|
|
31999
|
+
title: `Vague or Missing Exit Evidence in Session ${s.id}`,
|
|
32000
|
+
description: `Session lacks a concrete, measurable user-visible deliverable.`,
|
|
32001
|
+
remediationAdvice: `Specify an explicit exit evidence deliverable (e.g. running UI screen, passing test, or hardware actuation).`,
|
|
32002
|
+
affectedElement: s.id
|
|
32003
|
+
});
|
|
32004
|
+
}
|
|
32005
|
+
}
|
|
32006
|
+
score = Math.max(0, Math.min(100, score));
|
|
32007
|
+
const passed = score >= 80 && !findings.some((f) => f.severity === "CRITICAL");
|
|
32008
|
+
return { passed, score, findings, strengths };
|
|
32009
|
+
}
|
|
32010
|
+
/**
|
|
32011
|
+
* Validates structural and environment feasibility invariants for a Project Graph bundle.
|
|
32012
|
+
*/
|
|
32013
|
+
static lintProjectGraph(bundle, expectedSessions = 12) {
|
|
32014
|
+
const findings = [];
|
|
32015
|
+
const strengths = [];
|
|
32016
|
+
let score = 100;
|
|
32017
|
+
const graph = bundle?.project_graph;
|
|
32018
|
+
const scope = bundle?.technology_scope;
|
|
32019
|
+
if (!graph || !Array.isArray(graph.features) || graph.features.length === 0) {
|
|
32020
|
+
score -= 40;
|
|
32021
|
+
findings.push({
|
|
32022
|
+
id: "GRAPH_MISSING_FEATURES",
|
|
32023
|
+
dimension: "CROSS_ARTIFACT_ZERO_DRIFT",
|
|
32024
|
+
severity: "CRITICAL",
|
|
32025
|
+
title: "Missing Features in Project Graph",
|
|
32026
|
+
description: "Project graph has no features array or empty features.",
|
|
32027
|
+
remediationAdvice: "Declare at least 3 progressive features with concrete steps."
|
|
32028
|
+
});
|
|
32029
|
+
return { passed: false, score: Math.max(0, score), findings, strengths };
|
|
32030
|
+
}
|
|
32031
|
+
const allSteps = graph.features.flatMap((f) => f.steps || []);
|
|
32032
|
+
if (allSteps.length === 0) {
|
|
32033
|
+
score -= 30;
|
|
32034
|
+
findings.push({
|
|
32035
|
+
id: "GRAPH_EMPTY_STEPS",
|
|
32036
|
+
dimension: "CROSS_ARTIFACT_ZERO_DRIFT",
|
|
32037
|
+
severity: "CRITICAL",
|
|
32038
|
+
title: "Empty Steps in Project Graph",
|
|
32039
|
+
description: "Features contain no executable steps.",
|
|
32040
|
+
remediationAdvice: "Add 2 to 4 concrete steps per feature."
|
|
32041
|
+
});
|
|
32042
|
+
}
|
|
32043
|
+
for (const step of allSteps) {
|
|
32044
|
+
const est = step.effort?.estimated_minutes || 0;
|
|
32045
|
+
if (est > 76) {
|
|
32046
|
+
score -= 10;
|
|
32047
|
+
findings.push({
|
|
32048
|
+
id: `GRAPH_OVERSIZED_STEP_${step.id || "step"}`,
|
|
32049
|
+
dimension: "CONSTRUCTIVE_ALIGNMENT",
|
|
32050
|
+
severity: "MAJOR",
|
|
32051
|
+
title: `Step ${step.id || step.name} Exceeds Content Budget`,
|
|
32052
|
+
description: `Step requires ${est} minutes, which exceeds the 76-minute single-session ceiling.`,
|
|
32053
|
+
remediationAdvice: `Split step into two sequential sub-steps to prevent artificial session fragmentation.`,
|
|
32054
|
+
affectedElement: step.id
|
|
32055
|
+
});
|
|
32056
|
+
}
|
|
32057
|
+
}
|
|
32058
|
+
const allTechStrings = [
|
|
32059
|
+
scope?.platform || "",
|
|
32060
|
+
...Array.isArray(scope?.libraries_and_apis) ? scope.libraries_and_apis : [],
|
|
32061
|
+
...Array.isArray(scope?.toolchain) ? scope.toolchain : [],
|
|
32062
|
+
JSON.stringify(graph.project?.tech_stack || {})
|
|
32063
|
+
].join(" ").toLowerCase();
|
|
32064
|
+
const heavyKeywords = ["postgres", "postgresql", "docker", "kubernetes", "ros2", "oracle", "sql server"];
|
|
32065
|
+
const hasHeavyTech = heavyKeywords.some((k) => allTechStrings.includes(k));
|
|
32066
|
+
if (hasHeavyTech) {
|
|
32067
|
+
const declaredStrategy = scope?.provisioning_strategy || scope?.provisioning_model || graph.project?.provisioning_strategy;
|
|
32068
|
+
const isValidStrategy = ENVIRONMENT_PROVISIONING_MODELS.includes(declaredStrategy);
|
|
32069
|
+
if (!isValidStrategy) {
|
|
32070
|
+
score -= 15;
|
|
32071
|
+
findings.push({
|
|
32072
|
+
id: "GRAPH_UNPROVISIONED_HEAVY_TECH",
|
|
32073
|
+
dimension: "CONSTRUCTIVE_ALIGNMENT",
|
|
32074
|
+
severity: "MAJOR",
|
|
32075
|
+
title: "Heavy Technology Without Declared Lab Provisioning Strategy",
|
|
32076
|
+
description: `Course uses heavy/server technology without declaring a valid provisioning strategy (PRE_INSTALLED_LAB, CLOUD_MANAGED, or DEDICATED_SETUP).`,
|
|
32077
|
+
remediationAdvice: `Specify provisioning_strategy as PRE_INSTALLED_LAB, CLOUD_MANAGED, or DEDICATED_SETUP to ensure classroom feasibility.`
|
|
32078
|
+
});
|
|
32079
|
+
} else {
|
|
32080
|
+
strengths.push(`Heavy technology stack backed by explicit provisioning model: ${declaredStrategy}`);
|
|
32081
|
+
}
|
|
32082
|
+
}
|
|
31536
32083
|
score = Math.max(0, Math.min(100, score));
|
|
31537
32084
|
const passed = score >= 80 && !findings.some((f) => f.severity === "CRITICAL");
|
|
31538
32085
|
return { passed, score, findings, strengths };
|
|
@@ -33171,6 +33718,6 @@ function renderMediaPlaceholder(entry) {
|
|
|
33171
33718
|
return `> \u{1F5BC}\uFE0F [\u1EA2nh \u0111ang ch\u1EDD: ${entry.name} \u2014 s\u1EBD \u0111\u01B0\u1EE3c t\u1EA1o sau khi duy\u1EC7t media]`;
|
|
33172
33719
|
}
|
|
33173
33720
|
|
|
33174
|
-
export { ACT_TEMPLATE, ARTIFACT_DEPENDENCY_ROUTING, ARTIFACT_EXECUTION_ORDER, AcademicAuditor, ActiveLearningWorkflowSchema, ActivityLabSchema, ActivitySeqRowSchema, ActivityStepSchema, ArtifactContractRowSchema, AssessmentMapRowSchema, AssessmentObjectiveSchema, BELL_RINGER_TEMPLATE, BLOOM_ACTION_VERBS, BOM_TEMPLATE, BUNDLED_STANDARDS_PACK_IDS, BellRingerDaySchema, BellRingerSchema, BloomHintSchema, BloomLevelSchema, BloomTaxonomyEvaluator, BronzeTierSchema, CERConclusionSchema, CHOICE_BOARD_TEMPLATE, CODE_LAB_TEMPLATE, CURRICULUM_SLASH_COMMANDS, CardTierEnum, ChoiceBoardRubricRowSchema, ChoiceBoardSchema, ChoiceRuleSchema, ChoiceSquareSchema, ClassificationSchema, CodeHardwareFeasibilityEvaluator, CodeLabSchema, CodeSnippetSchema, CompetencyRubricRowSchema, ComputationalThinkingSchema, ConceptPrerequisiteEdgeSchema, ConceptSpiralEncounterSchema, ConstructiveAlignmentEvaluator, CoreConceptSchema, CourseObjectiveSchema, CoverageReportSchema, CrossArtifactDriftEvaluator, CurriculumArtifactSchema, CurriculumError, CurriculumPlanSchema, CurriculumQualityReportSchema, DEFAULT_ARTIFACT_STREAM_IDLE_MS, DEFAULT_ARTIFACT_STREAM_TOTAL_MS, DEFAULT_ENABLED_PROVIDERS, DEFAULT_GATE_SETTINGS, DEFAULT_KX_PRIORITIES, DEFAULT_LESSON_PRIORITIES, DEFAULT_STREAM_IDLE_MS, DEFAULT_STREAM_TOTAL_MS, DEFAULT_VIETNAMESE_SECTION_HEADINGS, DependencyEdgeSchema, DepthAssignmentSchema, DepthLevelSchema, DeterministicPipelineRunner, DeterministicStructuralLinter, DiagnosticQuestionSchema, DiagnosticQuizSchema, EDPPhaseEnum, EXIT_TICKET_TEMPLATE, EXPOSITION_REL, EXT_TEMPLATE, EntryLevelSchema, ExitTicketBugHuntSchema, ExitTicketMetacognitionSchema, ExitTicketQuickItemSchema, ExitTicketRecallPromptSchema, ExitTicketSchema, ExperimentalDesignSchema, ExpositionApprovalError, ExtensionChallengeSchema, ExtensionSchema, FileSystemCurriculumAdapter, FiveEFlowPhaseSchema, FiveEInstructionalEvaluator, FiveEPhaseEnum, FrameworkMappingSchema, FrameworkPackManifestSchema, FrameworkPackSchema, FrameworkStatementSchema, GLOSSARY_TEMPLATE, GRAPHIC_ORGANIZER_TEMPLATE, GeneratedSlideArraySchema, GeneratedSlideSchema, GlossaryQuickRefRowSchema, GlossarySchema, GlossaryTermSchema, GoldTierSchema, GradeBandSchema, GraphicOrganizerItemSchema, GraphicOrganizerSchema, HANDOUT_TEMPLATE, HandoutSchema, HandoutSectionSchema, HybridBlueprintArraySchema, HybridBlueprintItemSchema, HybridDeckSlideArraySchema, HybridDeckSlideSchema, HybridPipelineError, InstructionSectionSchema, InstructionStepSchema, JudgeCriterionSchema, LAYER_IDLE_BUDGET_MS, LAYER_TOTAL_BUDGET_MS, LESSON_PLAN_TEMPLATE, LLMJudgeEngine, LabTierTaskSchema, LearningObjectiveInputSchema, LearningObjectiveRowSchema, LessonFlowPhaseSchema, LessonPlan5ESchema, LessonPlanEDPSchema, LessonPlanSchema, LessonSectionSchema, LocalWorkspaceManager, MappingKindSchema, MarpSlideSchema, MasteryGateSchema, MediaError, MediaLedger, MentorCheatsheetSchema, MilestoneInputSchema, MisconceptionEvaluator, MisconceptionSchema, ModelPolicyResolver, NVIDIA_MODELS, NodeKindSchema, OrganizerTypeEnum, PROJECT_INSTRUCTION_TEMPLATE, PhaseInputSchema, PlanConstraintsSchema, PlannerInputSchema, PlanningGraphSchema, PlanningNodeSchema, PrerequisiteDecisionEntrySchema, PrerequisiteDecisionSchema, ProductGoalSchema, ProgressiveHintsSchema, ProjectGraphSchema, ProjectInstructionSchema, ProjectProfileSchema, QUIZ_TEMPLATE, QualityAuditVerdictSchema, QuizOptionSchema, REVIEW_GAME_TEMPLATE, RUBRIC_TEMPLATE, RecordProvenanceSchema, ResourceMapRowSchema, ReviewGameExportRowSchema, ReviewGameQuestionSchema, ReviewGameSchema, RoadmapInputSchema, RotationStationSchema, RubricCriteriaSchema, RubricSchema, SATELLITE_LESSON_PRIORITIES, SCIENCE_LAB_TEMPLATE, SELF_LAB_TEMPLATE, SLIDE_CANONICAL_METHODOLOGY, SLIDE_LAYOUT_PRESETS, SLIDE_TEMPLATE, STANDARD_REF_REGEX, STANDARD_SOT_FILES, STATION_ROTATION_TEMPLATE, ScaffoldDecisionEntrySchema, ScaffoldDecisionSchema, ScienceLabSchema, ScoringRubricRowSchema, SelfLabSchema, SelfPacedBundleSchema, SelfPacedChallengeSchema, SessionPlanSchema, SessionZpdStatusSchema, SilverTierSchema, SlideBlueprintArraySchema, SlideBlueprintItemSchema, SlideDeckSchema, StandardizedTermRowSchema, StandardsRegistryAdapter, StationRecordRowSchema, StationRotationSchema, StationTypeEnum, SupabaseCurriculumAdapter, TASK_CARDS_TEMPLATE, TEACHER_GUIDE_TEMPLATE, TIERED_PRACTICE_TEMPLATE, TaskCardSchema, TaskCardsSchema, TeacherGuideSchema, TeachingScriptPhaseSchema, TierLevelEnum, TierObjectiveSchema, TieredPracticeSchema, TranslationPolicySchema, TroubleshootingEntrySchema, TroubleshootingRowSchema, UnitPlanSchema, UserJourneySchema, WORKSHEET_TEMPLATE, WalkingSkeletonSchema, WorksheetItemSchema, WorksheetItemTypeEnum, WorksheetPartSchema, WorksheetSchema, ZpdVerdictSchema, activityTools, analystTools, analyzeProjectCreationIntent, assertAcyclic, assessorTools, assignDepths, atomicWriteFileSync, auditCurriculumQualityFlow, auditQualityReport, buildActivityPrompt, buildCodeLabPrompt, buildConceptPrerequisites, buildCurriculumContext, buildCurriculumPlan, buildDeliveryPackages, buildDiagnosticQuizPrompt, buildDomainLexiconGuardrail, buildExpositionContext, buildExpositionExcerpt, buildExtensionPrompt, buildHandoutPrompt, buildHeadingDirective, buildHtmlDeckSlidePrompt, buildImagePrompt, buildJudgePrompt, buildLanguageDirective, buildLessonExcerpt, buildLessonMasterPrompt, buildMarpMarkdownSlidePrompt, buildMasteryGates, buildProjectInstructionPrompt, buildSatelliteContext, buildSectionAwareExcerpt, buildSelfLabPrompt, buildSessionSliceContext, buildSlidesPrompt, buildStandardStackMarkdown, buildStandardsContext, buildStandardsContextBlock, buildTeacherGuidePrompt, buildWalkingSkeleton, buildWorksheetPrompt, checkSessionZpd, closeTruncatedJson, computeConceptSpiralProgression, computeContentHash, computePackingSpec, conductPreliminaryResearch, contentTools, convertRoadmapToFoundationSot, createAiInferenceError, createContextMissingError, createCurriculumStorage, createIdleAbortController, createStreamAbortController, createStreamAbortSignal, createStreamChunkExtractor, curateMediaLedger, designerTools, detectProjectPedagogy, dropCyclicConceptEdges, emitUsage, ensureExpositionForLesson, ensureKnowledgeExposition, evaluateActivityAlignment, evaluateStandardsCoverage, executeCurriculumCommand, executeSlideProductionWorkflow, exportAllProjectQuizzes, expositionCacheKey, extractActivityContractRows, extractAssessmentMap, extractCurriculumHorizon, extractJsonArray, extractScopeSequenceRows, extractSectionHeadingsFromSLC, extractSessionSlice, extractStandardRefs, extractStreamChunk, extractSymbolLedger, extractThoughtAndContent, extractTieredScaffoldingBlock, findStandardStatement, formatQuizzesToCsv, fulfillMediaLedger, gateModeFor, generateActivityFlow, generateCodeLabFlow, generateDiagnosticQuizFlow, generateEducationalImage, generateExtensionFlow, generateHandoutFlow, generateLessonMasterFlow, generateMilestoneCurriculumBundle, generatePhase1SotArtifacts, generatePhase2SotArtifacts, generateProjectInstruction, generateProjectInstructionFlow, generateRoadmapCurriculum, generateSelfLabFlow, generateSelfPacedBundle, generateSingleArtifact, generateSlidesFlow, generateTeacherGuideFlow, generateWorksheetFlow, getAIModel, getArtifactMetadata, getDesignatedFallbackChain, getDesignatedFallbackConfig, getLessonMetadata, getProjectArtifactScope, getProjectStatusReport, getSlideLayoutPresetById, getSlideLayoutPresetsByCategory, getSmartResumeContext, glossaryTermsForSession, illustratorTools, importRoadmapToProject, ingestProjectGraphIntoProject, initializeProjectInStorage, injectMediaIntoMarkdown, isActivityAlignmentLogOnly, isExpositionFresh, isModelAllowed, isProviderEnabled, isTranslationDue, lintAndSanitizeArtifact, lintCurriculumFramework, lintFrameworkPack, loadCurriculumTemplate, loadSotTemplate, normalizePlanningGraph, normalizeSlcContract, packagerTools, parseAllSessions, parseGateSettings, parseQuizMarkdown, parseRoadmapJsonToProjectPayload, produceBatchLessons, produceSingleLesson, publishToGitHub, publishToSupabase, rankGenCandidates, renderFrameworkFromPlan, renderHorizonPromptBlock, renderMediaPlaceholder, researcherTools, resolveApiKey, resolveGateSettings, resolveStandardsPacks, resolveStreamBudget, resolveTargetLanguageCode, resolveTranslationTargets, reviewerTools, runCurriculumAIInference, safeParseJson, searchEducationalImages, searchEducationalVideos, selectStatementsForLesson, serializeActivityToMarkdown, serializeCodeLabToMarkdown, serializeDiagnosticQuizToMarkdown, serializeHandoutToMarkdown, serializeLessonToMarkdown, serializeProjectInstructionToMarkdown, serializeSelfLabToMarkdown, slugifyProjectName, streamCurriculumAIInference, streamCurriculumAIInferenceWithTools, streamDiagnosticQuizFlow, streamLLMWithFallback, streamLayerPrefillWithFallback, streamLessonMasterFlow, streamSelfLabFlow, stripLlmJsonWrappers, targetLanguageDisplayName, techSmeTools, topoSort, uploadAssetToBucket, validateArtifactDependencies, validateCurriculumPlan, validateFrameworkPack, validateHorizonCompliance, validateHybridDeckSlides, validateMarkdownTables, validateMermaidSyntax, withAutoRepair };
|
|
33721
|
+
export { ACT_TEMPLATE, ARTIFACT_DEPENDENCY_ROUTING, ARTIFACT_EXECUTION_ORDER, AcademicAuditor, ActionableRepairActionSchema, ActionableRepairPromptSchema, ActiveLearningWorkflowSchema, ActivityLabSchema, ActivitySeqRowSchema, ActivityStepSchema, ArtifactContractRowSchema, AssessmentMapRowSchema, AssessmentObjectiveSchema, BELL_RINGER_TEMPLATE, BLOOM_ACTION_VERBS, BOM_TEMPLATE, BUNDLED_STANDARDS_PACK_IDS, BellRingerDaySchema, BellRingerSchema, BloomHintSchema, BloomLevelSchema, BloomTaxonomyEvaluator, BronzeTierSchema, CERConclusionSchema, CHOICE_BOARD_TEMPLATE, CODE_LAB_TEMPLATE, CURRICULUM_SLASH_COMMANDS, CardTierEnum, ChoiceBoardRubricRowSchema, ChoiceBoardSchema, ChoiceRuleSchema, ChoiceSquareSchema, ClassificationSchema, CodeHardwareFeasibilityEvaluator, CodeLabSchema, CodeSnippetSchema, CompetencyRubricRowSchema, ComputationalThinkingSchema, ConceptPrerequisiteEdgeSchema, ConceptSpiralEncounterSchema, ConstructiveAlignmentEvaluator, CoreConceptSchema, CourseObjectiveSchema, CoverageReportSchema, CrossArtifactDriftEvaluator, CurriculumArtifactSchema, CurriculumError, CurriculumPlanSchema, CurriculumQualityReportSchema, DEFAULT_ARTIFACT_STREAM_IDLE_MS, DEFAULT_ARTIFACT_STREAM_TOTAL_MS, DEFAULT_ENABLED_PROVIDERS, DEFAULT_GATE_SETTINGS, DEFAULT_KX_PRIORITIES, DEFAULT_LESSON_PRIORITIES, DEFAULT_OVERHEAD_RATIO, DEFAULT_STREAM_IDLE_MS, DEFAULT_STREAM_TOTAL_MS, DEFAULT_VIETNAMESE_SECTION_HEADINGS, DependencyEdgeSchema, DepthAssignmentSchema, DepthLevelSchema, DeterministicPipelineRunner, DeterministicStructuralLinter, DiagnosticQuestionSchema, DiagnosticQuizSchema, EDPPhaseEnum, ENVIRONMENT_PROVISIONING_MODELS, EXIT_TICKET_TEMPLATE, EXPOSITION_REL, EXT_TEMPLATE, EntryLevelSchema, ExitTicketBugHuntSchema, ExitTicketMetacognitionSchema, ExitTicketQuickItemSchema, ExitTicketRecallPromptSchema, ExitTicketSchema, ExperimentalDesignSchema, ExpositionApprovalError, ExtensionChallengeSchema, ExtensionSchema, FileSystemCurriculumAdapter, FiveEFlowPhaseSchema, FiveEInstructionalEvaluator, FiveEPhaseEnum, FrameworkMappingSchema, FrameworkPackManifestSchema, FrameworkPackSchema, FrameworkStatementSchema, GLOSSARY_TEMPLATE, GRAPHIC_ORGANIZER_TEMPLATE, GeneratedSlideArraySchema, GeneratedSlideSchema, GlossaryQuickRefRowSchema, GlossarySchema, GlossaryTermSchema, GoldTierSchema, GradeBandSchema, GraphicOrganizerItemSchema, GraphicOrganizerSchema, HANDOUT_TEMPLATE, HandoutSchema, HandoutSectionSchema, HybridBlueprintArraySchema, HybridBlueprintItemSchema, HybridDeckSlideArraySchema, HybridDeckSlideSchema, HybridPipelineError, InstructionSectionSchema, InstructionStepSchema, JUDGE_AUTO_APPROVE_THRESHOLD, JUDGE_ESCALATE_THRESHOLD, JudgeCriterionSchema, LAYER_IDLE_BUDGET_MS, LAYER_TOTAL_BUDGET_MS, LESSON_PLAN_TEMPLATE, LLMJudgeEngine, LabTierTaskSchema, LearningObjectiveInputSchema, LearningObjectiveRowSchema, LessonEntitySchema, LessonFlowPhaseSchema, LessonPlan5ESchema, LessonPlanEDPSchema, LessonPlanSchema, LessonSectionSchema, LocalWorkspaceManager, MAX_AUTONOMOUS_REPAIR_TURNS, MAX_IN_SESSION_SETUP_MINUTES, MAX_NEW_CONCEPTS_PER_SESSION_ADULT, MAX_NEW_CONCEPTS_PER_SESSION_K12, MacroPedagogyPlanAuditSchema, MappingKindSchema, MarpSlideSchema, MasteryGateSchema, MediaError, MediaLedger, MentorCheatsheetSchema, MilestoneInputSchema, MisconceptionEvaluator, MisconceptionSchema, ModelPolicyResolver, NVIDIA_MODELS, NodeKindSchema, OrganizerTypeEnum, PROJECT_INSTRUCTION_TEMPLATE, PhaseInputSchema, PlanConstraintsSchema, PlannerInputSchema, PlanningGraphSchema, PlanningNodeSchema, PrerequisiteDecisionEntrySchema, PrerequisiteDecisionSchema, ProductGoalSchema, ProgressiveHintsSchema, ProjectGraphAuditSchema, ProjectGraphSchema, ProjectInstructionSchema, ProjectProfileSchema, QUIZ_TEMPLATE, QualityAuditVerdictSchema, QuizOptionSchema, REVIEW_GAME_TEMPLATE, RUBRIC_TEMPLATE, RecordProvenanceSchema, ResourceMapRowSchema, ReviewGameExportRowSchema, ReviewGameQuestionSchema, ReviewGameSchema, RoadmapInputSchema, RotationStationSchema, RubricCriteriaSchema, RubricSchema, SATELLITE_LESSON_PRIORITIES, SCIENCE_LAB_TEMPLATE, SELF_LAB_TEMPLATE, SLIDE_CANONICAL_METHODOLOGY, SLIDE_LAYOUT_PRESETS, SLIDE_TEMPLATE, STANDARD_REF_REGEX, STANDARD_SOT_FILES, STATION_ROTATION_TEMPLATE, STUDENT_FRICTION_MULTIPLIER, ScaffoldDecisionEntrySchema, ScaffoldDecisionSchema, ScienceLabSchema, ScoringRubricRowSchema, SelfLabSchema, SelfPacedBundleSchema, SelfPacedChallengeSchema, SessionPlanSchema, SessionZpdStatusSchema, SilverTierSchema, SlideBlueprintArraySchema, SlideBlueprintItemSchema, SlideDeckSchema, StandardizedTermRowSchema, StandardsRegistryAdapter, StationRecordRowSchema, StationRotationSchema, StationTypeEnum, SupabaseCurriculumAdapter, TASK_CARDS_TEMPLATE, TEACHER_GUIDE_TEMPLATE, TIERED_PRACTICE_TEMPLATE, TaskCardSchema, TaskCardsSchema, TeacherGuideSchema, TeachingScriptPhaseSchema, TierLevelEnum, TierObjectiveSchema, TieredPracticeSchema, TranslationPolicySchema, TroubleshootingEntrySchema, TroubleshootingRowSchema, UnitPlanSchema, UserJourneySchema, WORKSHEET_TEMPLATE, WalkingSkeletonSchema, WorksheetItemSchema, WorksheetItemTypeEnum, WorksheetPartSchema, WorksheetSchema, ZpdVerdictSchema, activityTools, analystTools, analyzeProjectCreationIntent, assertAcyclic, assessorTools, assignDepths, atomicWriteFileSync, auditCurriculumPlanFlow, auditCurriculumQualityFlow, auditProjectGraphFlow, auditQualityReport, buildActivityPrompt, buildCodeLabPrompt, buildConceptPrerequisites, buildCurriculumContext, buildCurriculumPlan, buildCurriculumPlanJudgePrompt, buildDeliveryPackages, buildDiagnosticQuizPrompt, buildDomainLexiconGuardrail, buildExpositionContext, buildExpositionExcerpt, buildExtensionPrompt, buildHandoutPrompt, buildHeadingDirective, buildHtmlDeckSlidePrompt, buildImagePrompt, buildJudgePrompt, buildLanguageDirective, buildLessonEntityJson, buildLessonExcerpt, buildLessonMasterPrompt, buildMarpMarkdownSlidePrompt, buildMasteryGates, buildProjectGraphJudgePrompt, buildProjectInstructionPrompt, buildSatelliteContext, buildSectionAwareExcerpt, buildSelfLabPrompt, buildSessionSliceContext, buildSlidesPrompt, buildStandardStackMarkdown, buildStandardsContext, buildStandardsContextBlock, buildTeacherGuidePrompt, buildWalkingSkeleton, buildWorksheetPrompt, checkSessionZpd, closeTruncatedJson, computeConceptSpiralProgression, computeContentHash, computePackingSpec, conductPreliminaryResearch, contentTools, convertRoadmapToFoundationSot, createAiInferenceError, createContextMissingError, createCurriculumStorage, createIdleAbortController, createStreamAbortController, createStreamAbortSignal, createStreamChunkExtractor, curateMediaLedger, designerTools, detectProjectPedagogy, dropCyclicConceptEdges, emitUsage, ensureExpositionForLesson, ensureKnowledgeExposition, entityRowAssignedTo, evaluateActivityAlignment, evaluateStandardsCoverage, executeCurriculumCommand, executeSlideProductionWorkflow, exportAllProjectQuizzes, expositionCacheKey, extractActivityContractRows, extractAssessmentMap, extractCurriculumHorizon, extractJsonArray, extractScopeSequenceRows, extractSectionHeadingsFromSLC, extractSessionSlice, extractStandardRefs, extractStreamChunk, extractSymbolLedger, extractThoughtAndContent, extractTieredScaffoldingBlock, findStandardStatement, formatQuizzesToCsv, fulfillMediaLedger, gateModeFor, generateActivityFlow, generateCodeLabFlow, generateDiagnosticQuizFlow, generateEducationalImage, generateExtensionFlow, generateHandoutFlow, generateLessonMasterFlow, generateMilestoneCurriculumBundle, generatePhase1SotArtifacts, generatePhase2SotArtifacts, generateProjectInstruction, generateProjectInstructionFlow, generateRoadmapCurriculum, generateSelfLabFlow, generateSelfPacedBundle, generateSingleArtifact, generateSlidesFlow, generateTeacherGuideFlow, generateWorksheetFlow, getAIModel, getArtifactMetadata, getDesignatedFallbackChain, getDesignatedFallbackConfig, getLessonMetadata, getProjectArtifactScope, getProjectStatusReport, getSlideLayoutPresetById, getSlideLayoutPresetsByCategory, getSmartResumeContext, glossaryTermsForSession, illustratorTools, importRoadmapToProject, ingestProjectGraphIntoProject, initializeProjectInStorage, injectMediaIntoMarkdown, isActivityAlignmentLogOnly, isExpositionFresh, isModelAllowed, isProviderEnabled, isTranslationDue, lintAndSanitizeArtifact, lintCurriculumFramework, lintFrameworkPack, loadCurriculumTemplate, loadSotTemplate, normalizePlanningGraph, normalizeSlcContract, packagerTools, parseAllSessions, parseGateSettings, parseQuizMarkdown, parseRoadmapJsonToProjectPayload, produceBatchLessons, produceSingleLesson, publishToGitHub, publishToSupabase, rankGenCandidates, renderAssignedRowsTable, renderEntitySlotsForType, renderFrameworkFromPlan, renderHorizonPromptBlock, renderMediaPlaceholder, researcherTools, resolveApiKey, resolveGateSettings, resolveStandardsPacks, resolveStreamBudget, resolveTargetLanguageCode, resolveTranslationTargets, reviewerTools, runCurriculumAIInference, safeParseJson, searchEducationalImages, searchEducationalVideos, selectStatementsForLesson, serializeActivityToMarkdown, serializeCodeLabToMarkdown, serializeDiagnosticQuizToMarkdown, serializeHandoutToMarkdown, serializeLessonToMarkdown, serializeProjectInstructionToMarkdown, serializeSelfLabToMarkdown, slugifyProjectName, streamCurriculumAIInference, streamCurriculumAIInferenceWithTools, streamDiagnosticQuizFlow, streamLLMWithFallback, streamLayerPrefillWithFallback, streamLessonMasterFlow, streamSelfLabFlow, stripLlmJsonWrappers, targetLanguageDisplayName, techSmeTools, topoSort, uploadAssetToBucket, validateArtifactDependencies, validateCurriculumPlan, validateFrameworkPack, validateHorizonCompliance, validateHybridDeckSlides, validateMarkdownTables, validateMermaidSyntax, withAutoRepair };
|
|
33175
33722
|
//# sourceMappingURL=index.mjs.map
|
|
33176
33723
|
//# sourceMappingURL=index.mjs.map
|