@thanh01.pmt/domain-kit 0.2.1 → 0.4.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/README.md +42 -11
- package/dist/{chunk-CRN6D4HG.mjs → chunk-HILSUZOF.mjs} +32 -8
- package/dist/chunk-HILSUZOF.mjs.map +1 -0
- package/dist/{chunk-23TQPTHG.mjs → chunk-LZQLLAYP.mjs} +5 -5
- package/dist/{chunk-23TQPTHG.mjs.map → chunk-LZQLLAYP.mjs.map} +1 -1
- package/dist/{chunk-HH4UX65C.mjs → chunk-PKUEOSZ3.mjs} +42 -4
- package/dist/chunk-PKUEOSZ3.mjs.map +1 -0
- package/dist/{chunk-HUDFN4IX.mjs → chunk-QJF4QCBJ.mjs} +99 -4
- package/dist/chunk-QJF4QCBJ.mjs.map +1 -0
- package/dist/{chunk-WHBAGJWN.mjs → chunk-VCPIWJ7R.mjs} +4 -4
- package/dist/chunk-VCPIWJ7R.mjs.map +1 -0
- package/dist/curriculumFeedEmitter-6IK6PFDH.mjs +4 -0
- package/dist/{curriculumFeedEmitter-E5DAJYUZ.mjs.map → curriculumFeedEmitter-6IK6PFDH.mjs.map} +1 -1
- package/dist/{curriculumFeedSchema-TEeQg2bY.d.ts → curriculumFeedSchema-B66H3gEV.d.cts} +148 -8
- package/dist/{curriculumFeedSchema-TEeQg2bY.d.cts → curriculumFeedSchema-B66H3gEV.d.ts} +148 -8
- package/dist/feed/index.cjs +136 -3
- package/dist/feed/index.cjs.map +1 -1
- package/dist/feed/index.d.cts +1 -1
- package/dist/feed/index.d.ts +1 -1
- package/dist/feed/index.mjs +2 -2
- package/dist/graph/index.cjs +30 -5
- package/dist/graph/index.cjs.map +1 -1
- package/dist/graph/index.d.cts +2 -2
- package/dist/graph/index.d.ts +2 -2
- package/dist/graph/index.mjs +1 -1
- package/dist/{hybridGraphPipeline-DVZYLCAQ.d.ts → hybridGraphPipeline-DXQDbBEj.d.ts} +14 -2
- package/dist/{hybridGraphPipeline-DmWRKYXf.d.cts → hybridGraphPipeline-dT-bio-3.d.cts} +14 -2
- package/dist/{hybridGraphSchema-BCgXicgA.d.ts → hybridGraphSchema-nrUeSwpU.d.cts} +15 -15
- package/dist/{hybridGraphSchema-BCgXicgA.d.cts → hybridGraphSchema-nrUeSwpU.d.ts} +15 -15
- package/dist/index.cjs +168 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.mjs +5 -5
- package/dist/pipeline/index.cjs +165 -8
- package/dist/pipeline/index.cjs.map +1 -1
- package/dist/pipeline/index.d.cts +3 -3
- package/dist/pipeline/index.d.ts +3 -3
- package/dist/pipeline/index.mjs +4 -4
- package/dist/schemas/index.cjs +42 -4
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.cts +2 -2
- package/dist/schemas/index.d.ts +2 -2
- package/dist/schemas/index.mjs +2 -2
- package/package.json +10 -9
- package/LICENSE +0 -21
- package/dist/chunk-CRN6D4HG.mjs.map +0 -1
- package/dist/chunk-HH4UX65C.mjs.map +0 -1
- package/dist/chunk-HUDFN4IX.mjs.map +0 -1
- package/dist/chunk-WHBAGJWN.mjs.map +0 -1
- package/dist/curriculumFeedEmitter-E5DAJYUZ.mjs +0 -4
package/dist/index.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export { i as ArchEdgeSchema, A as ArchNodeSchema, x as ArchitectureDetail, j as ArchitectureDetailSchema, w as Capability, C as CapabilitySchema, z as DataIntegration, m as DataIntegrationSchema, G as Decomposition, s as DecompositionSchema, D as DevelopmentStageSchema, y as Experience, E as ExperienceComponentSchema, l as ExperienceSchema, d as Feature, F as FeatureSchema, B as Implementation, I as ImplementationSchema, e as JourneySchema, J as JourneyStepSchema, r as MilestoneDecompositionSchema, M as MissingGapSchema, N as NavigationSchema, v as Product, P as ProductGoalSchema, g as ProductSchema, f as ProductUserSchema, u as ProjectGraph, t as ProjectGraphSchema, h as ProjectInfoSchema, R as RequirementSchema, k as ScreenSchema, c as Step, S as StepEffortSchema, a as StepOutcomeSchema, b as StepSchema, n as TaskEffortSchema, o as TaskOutcomeSchema, p as TaskSchema, q as TechDebtSchema, T as TechStackSchema, U as UiStateSchema } from './projectGraphSchema-DnD7orZV.cjs';
|
|
2
|
-
export { b as Concept, d as ConceptCategory, c as ConceptCategorySchema, m as ConceptIntroduction, i as ConceptIntroductionSchema, C as ConceptSchema, l as DevelopmentPhase, D as DevelopmentPhaseSchema, j as HybridGraph, H as HybridGraphSchema, g as KnowledgeGraph, K as KnowledgeGraphSchema, f as LearningPathStep, L as LearningPathStepSchema, a as ProblemType, P as ProblemTypeSchema, k as ProjectConceptLink, h as ProjectConceptLinkSchema, e as SubjectInfo, S as SubjectInfoSchema } from './hybridGraphSchema-
|
|
2
|
+
export { b as Concept, d as ConceptCategory, c as ConceptCategorySchema, m as ConceptIntroduction, i as ConceptIntroductionSchema, C as ConceptSchema, l as DevelopmentPhase, D as DevelopmentPhaseSchema, j as HybridGraph, H as HybridGraphSchema, g as KnowledgeGraph, K as KnowledgeGraphSchema, f as LearningPathStep, L as LearningPathStepSchema, a as ProblemType, P as ProblemTypeSchema, k as ProjectConceptLink, h as ProjectConceptLinkSchema, e as SubjectInfo, S as SubjectInfoSchema } from './hybridGraphSchema-nrUeSwpU.cjs';
|
|
3
3
|
export { ExperimentProcedureSchema, GrammarRuleSchema, HardwareFeatureExtensionSchema, HardwareStepSchema, HardwareTaskExtensionSchema, HardwareTechStackExtensionSchema, LanguageConceptExtension, LanguageConceptExtensionSchema, MathConceptExtension, MathConceptExtensionSchema, MathTheoremSchema, ScienceConceptExtension, ScienceConceptExtensionSchema, ShapeSchema, ThreeDesignFeatureExtensionSchema, ThreeDesignTaskExtensionSchema, ThreeDesignTechStackExtensionSchema, WiringSchema } from './schemas/index.cjs';
|
|
4
4
|
export { a as DetectionConfidenceSchema, e as DomainCategory, D as DomainCategorySchema, c as DomainProfile, b as DomainProfileSchema, g as GraphType, G as GraphTypeSchema, d as InputType, I as InputTypeSchema, f as LearningMode, L as LearningModeSchema } from './domainProfileSchema-CwT3Ffsw.cjs';
|
|
5
|
-
export { g as CurriculumFeed, C as CurriculumFeedSchema, i as FeedEdge, c as FeedEdgeSchema, j as FeedGrouping, d as FeedGroupingSchema, F as FeedKeywordsSchema, h as FeedNode, b as FeedNodeSchema, f as FeedPhase, e as FeedPhaseSchema, a as FeedScaffoldCandidateSchema, v as validateCurriculumFeed } from './curriculumFeedSchema-
|
|
5
|
+
export { g as CurriculumFeed, C as CurriculumFeedSchema, i as FeedEdge, c as FeedEdgeSchema, j as FeedGrouping, d as FeedGroupingSchema, F as FeedKeywordsSchema, h as FeedNode, b as FeedNodeSchema, f as FeedPhase, e as FeedPhaseSchema, a as FeedScaffoldCandidateSchema, v as validateCurriculumFeed } from './curriculumFeedSchema-B66H3gEV.cjs';
|
|
6
6
|
export { C as CppParseResult, P as PythonParseResult, S as SwiftParseResult, T as TsParseResult, f as mergeCppResults, d as mergePythonResults, m as mergeSwiftResults, b as mergeTsResults, e as parseCppFile, c as parsePythonFile, p as parseSwiftFile, a as parseTsFile } from './cpp-CZUPqJt9.cjs';
|
|
7
7
|
export { P as ParsedSyllabus, a as SyllabusTopic, S as SyllabusUnit, p as parseSyllabus } from './syllabusParser-MSX1fEzW.cjs';
|
|
8
8
|
export { K as Keyword, S as SourceContext, e as extractKeywords } from './keywordExtractor-BxlGRMHC.cjs';
|
|
@@ -10,7 +10,7 @@ export { FileRelevanceScore, scoreByContent, scoreByPath, scoreFiles, selectRele
|
|
|
10
10
|
export { DetectDomainOptions, DetectInputTypeOptions, DetectLearningModeOptions, DomainDetectionResult, InputTypeDetectionResult, LearningModeDetectionResult, detectDomain, detectInputType, detectLearningMode } from './detector/index.cjs';
|
|
11
11
|
export { D as DetectDomainProfileOptions, d as detectDomainProfile } from './domainProfileDetector-bzugdQmS.cjs';
|
|
12
12
|
export { CIO_CODE_RE, CONCEPT_CODE_RE, DepthLayerAudit, ExtractOverviewOptions, ExtractScaffoldOptions, ExtractStepsOptions, LEARNER_CLAUSE, SIO_CODE_RE, ULO_CODE_RE, assignConceptCodes, auditDepthLayers, cioActionSlug, cioCode, conceptCodeFromName, extractFeatureSteps, extractFeatureStepsBatched, extractProjectOverview, extractScaffold, sioCode, standardStatement, techTagFor, uloCode } from './graph/index.cjs';
|
|
13
|
-
export { H as Hallucination,
|
|
13
|
+
export { H as Hallucination, j as HybridGraphPipelineOptions, k as HybridGraphPipelineResult, K as KnowledgeGraphPipelineOptions, a as KnowledgeGraphPipelineResult, f as KnowledgeGraphVerificationReport, V as VerifyOptions, i as auditPhasePlan, e as auditSyllabusCoverage, c as breakPrerequisiteCycles, d as detectPrerequisiteCycles, h as generateHybridGraph, g as generateKnowledgeGraph, b as verifyKnowledgeGraph, v as verifyProjectGraph } from './hybridGraphPipeline-dT-bio-3.cjs';
|
|
14
14
|
export { C as ConceptMapping, E as EscalateOptions, e as escalateAndMapConcepts } from './conceptEscalator-ltRLtPhf.cjs';
|
|
15
15
|
export { ConceptMatch, ProposedConcept, ResolveConceptsOptions, ResolveConceptsResult, ResolvedConcept, resolveConcepts } from './concepts/index.cjs';
|
|
16
16
|
export { AssembleOptions, AssembledMilestone, AssembledPhase, AssembledRoadmap, assembleRoadmap } from './assembly/index.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export { i as ArchEdgeSchema, A as ArchNodeSchema, x as ArchitectureDetail, j as ArchitectureDetailSchema, w as Capability, C as CapabilitySchema, z as DataIntegration, m as DataIntegrationSchema, G as Decomposition, s as DecompositionSchema, D as DevelopmentStageSchema, y as Experience, E as ExperienceComponentSchema, l as ExperienceSchema, d as Feature, F as FeatureSchema, B as Implementation, I as ImplementationSchema, e as JourneySchema, J as JourneyStepSchema, r as MilestoneDecompositionSchema, M as MissingGapSchema, N as NavigationSchema, v as Product, P as ProductGoalSchema, g as ProductSchema, f as ProductUserSchema, u as ProjectGraph, t as ProjectGraphSchema, h as ProjectInfoSchema, R as RequirementSchema, k as ScreenSchema, c as Step, S as StepEffortSchema, a as StepOutcomeSchema, b as StepSchema, n as TaskEffortSchema, o as TaskOutcomeSchema, p as TaskSchema, q as TechDebtSchema, T as TechStackSchema, U as UiStateSchema } from './projectGraphSchema-DnD7orZV.js';
|
|
2
|
-
export { b as Concept, d as ConceptCategory, c as ConceptCategorySchema, m as ConceptIntroduction, i as ConceptIntroductionSchema, C as ConceptSchema, l as DevelopmentPhase, D as DevelopmentPhaseSchema, j as HybridGraph, H as HybridGraphSchema, g as KnowledgeGraph, K as KnowledgeGraphSchema, f as LearningPathStep, L as LearningPathStepSchema, a as ProblemType, P as ProblemTypeSchema, k as ProjectConceptLink, h as ProjectConceptLinkSchema, e as SubjectInfo, S as SubjectInfoSchema } from './hybridGraphSchema-
|
|
2
|
+
export { b as Concept, d as ConceptCategory, c as ConceptCategorySchema, m as ConceptIntroduction, i as ConceptIntroductionSchema, C as ConceptSchema, l as DevelopmentPhase, D as DevelopmentPhaseSchema, j as HybridGraph, H as HybridGraphSchema, g as KnowledgeGraph, K as KnowledgeGraphSchema, f as LearningPathStep, L as LearningPathStepSchema, a as ProblemType, P as ProblemTypeSchema, k as ProjectConceptLink, h as ProjectConceptLinkSchema, e as SubjectInfo, S as SubjectInfoSchema } from './hybridGraphSchema-nrUeSwpU.js';
|
|
3
3
|
export { ExperimentProcedureSchema, GrammarRuleSchema, HardwareFeatureExtensionSchema, HardwareStepSchema, HardwareTaskExtensionSchema, HardwareTechStackExtensionSchema, LanguageConceptExtension, LanguageConceptExtensionSchema, MathConceptExtension, MathConceptExtensionSchema, MathTheoremSchema, ScienceConceptExtension, ScienceConceptExtensionSchema, ShapeSchema, ThreeDesignFeatureExtensionSchema, ThreeDesignTaskExtensionSchema, ThreeDesignTechStackExtensionSchema, WiringSchema } from './schemas/index.js';
|
|
4
4
|
export { a as DetectionConfidenceSchema, e as DomainCategory, D as DomainCategorySchema, c as DomainProfile, b as DomainProfileSchema, g as GraphType, G as GraphTypeSchema, d as InputType, I as InputTypeSchema, f as LearningMode, L as LearningModeSchema } from './domainProfileSchema-CwT3Ffsw.js';
|
|
5
|
-
export { g as CurriculumFeed, C as CurriculumFeedSchema, i as FeedEdge, c as FeedEdgeSchema, j as FeedGrouping, d as FeedGroupingSchema, F as FeedKeywordsSchema, h as FeedNode, b as FeedNodeSchema, f as FeedPhase, e as FeedPhaseSchema, a as FeedScaffoldCandidateSchema, v as validateCurriculumFeed } from './curriculumFeedSchema-
|
|
5
|
+
export { g as CurriculumFeed, C as CurriculumFeedSchema, i as FeedEdge, c as FeedEdgeSchema, j as FeedGrouping, d as FeedGroupingSchema, F as FeedKeywordsSchema, h as FeedNode, b as FeedNodeSchema, f as FeedPhase, e as FeedPhaseSchema, a as FeedScaffoldCandidateSchema, v as validateCurriculumFeed } from './curriculumFeedSchema-B66H3gEV.js';
|
|
6
6
|
export { C as CppParseResult, P as PythonParseResult, S as SwiftParseResult, T as TsParseResult, f as mergeCppResults, d as mergePythonResults, m as mergeSwiftResults, b as mergeTsResults, e as parseCppFile, c as parsePythonFile, p as parseSwiftFile, a as parseTsFile } from './cpp-CZUPqJt9.js';
|
|
7
7
|
export { P as ParsedSyllabus, a as SyllabusTopic, S as SyllabusUnit, p as parseSyllabus } from './syllabusParser-MSX1fEzW.js';
|
|
8
8
|
export { K as Keyword, S as SourceContext, e as extractKeywords } from './keywordExtractor-DU5XRN8-.js';
|
|
@@ -10,7 +10,7 @@ export { FileRelevanceScore, scoreByContent, scoreByPath, scoreFiles, selectRele
|
|
|
10
10
|
export { DetectDomainOptions, DetectInputTypeOptions, DetectLearningModeOptions, DomainDetectionResult, InputTypeDetectionResult, LearningModeDetectionResult, detectDomain, detectInputType, detectLearningMode } from './detector/index.js';
|
|
11
11
|
export { D as DetectDomainProfileOptions, d as detectDomainProfile } from './domainProfileDetector-DHb1T0zB.js';
|
|
12
12
|
export { CIO_CODE_RE, CONCEPT_CODE_RE, DepthLayerAudit, ExtractOverviewOptions, ExtractScaffoldOptions, ExtractStepsOptions, LEARNER_CLAUSE, SIO_CODE_RE, ULO_CODE_RE, assignConceptCodes, auditDepthLayers, cioActionSlug, cioCode, conceptCodeFromName, extractFeatureSteps, extractFeatureStepsBatched, extractProjectOverview, extractScaffold, sioCode, standardStatement, techTagFor, uloCode } from './graph/index.js';
|
|
13
|
-
export { H as Hallucination,
|
|
13
|
+
export { H as Hallucination, j as HybridGraphPipelineOptions, k as HybridGraphPipelineResult, K as KnowledgeGraphPipelineOptions, a as KnowledgeGraphPipelineResult, f as KnowledgeGraphVerificationReport, V as VerifyOptions, i as auditPhasePlan, e as auditSyllabusCoverage, c as breakPrerequisiteCycles, d as detectPrerequisiteCycles, h as generateHybridGraph, g as generateKnowledgeGraph, b as verifyKnowledgeGraph, v as verifyProjectGraph } from './hybridGraphPipeline-DXQDbBEj.js';
|
|
14
14
|
export { C as ConceptMapping, E as EscalateOptions, e as escalateAndMapConcepts } from './conceptEscalator-YfMKIKCZ.js';
|
|
15
15
|
export { ConceptMatch, ProposedConcept, ResolveConceptsOptions, ResolveConceptsResult, ResolvedConcept, resolveConcepts } from './concepts/index.js';
|
|
16
16
|
export { AssembleOptions, AssembledMilestone, AssembledPhase, AssembledRoadmap, assembleRoadmap } from './assembly/index.js';
|
package/dist/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import './chunk-R57WTNXW.mjs';
|
|
2
|
-
export { runDomainPipeline, runHybridGraphPipeline, runKnowledgeGraphPipeline, runProjectGraphPipeline } from './chunk-
|
|
3
|
-
export { emitCurriculumFeed } from './chunk-
|
|
4
|
-
export { ArchEdgeSchema, ArchNodeSchema, ArchitectureDetailSchema, CapabilitySchema, ConceptCategorySchema, ConceptIntroductionSchema, ConceptSchema, DataIntegrationSchema, DecompositionSchema, DetectionConfidenceSchema, DevelopmentPhaseSchema, DevelopmentStageSchema, DomainCategorySchema, DomainProfileSchema, ExperienceComponentSchema, ExperienceSchema, ExperimentProcedureSchema, FeatureSchema, GrammarRuleSchema, GraphTypeSchema, HardwareFeatureExtensionSchema, HardwareStepSchema, HardwareTaskExtensionSchema, HardwareTechStackExtensionSchema, HybridGraphSchema, ImplementationSchema, InputTypeSchema, JourneySchema, JourneyStepSchema, KnowledgeGraphSchema, LanguageConceptExtensionSchema, LearningModeSchema, LearningPathStepSchema, MathConceptExtensionSchema, MathTheoremSchema, MilestoneDecompositionSchema, MissingGapSchema, NavigationSchema, ProblemTypeSchema, ProductGoalSchema, ProductSchema, ProductUserSchema, ProjectConceptLinkSchema, ProjectGraphSchema, ProjectInfoSchema, RequirementSchema, ScienceConceptExtensionSchema, ScreenSchema, ShapeSchema, StepEffortSchema, StepOutcomeSchema, StepSchema, SubjectInfoSchema, TaskEffortSchema, TaskOutcomeSchema, TaskSchema, TechDebtSchema, TechStackSchema, ThreeDesignFeatureExtensionSchema, ThreeDesignTaskExtensionSchema, ThreeDesignTechStackExtensionSchema, UiStateSchema, WiringSchema } from './chunk-
|
|
5
|
-
export { CurriculumFeedSchema, FeedEdgeSchema, FeedGroupingSchema, FeedKeywordsSchema, FeedNodeSchema, FeedPhaseSchema, FeedScaffoldCandidateSchema, validateCurriculumFeed } from './chunk-
|
|
2
|
+
export { runDomainPipeline, runHybridGraphPipeline, runKnowledgeGraphPipeline, runProjectGraphPipeline } from './chunk-LZQLLAYP.mjs';
|
|
3
|
+
export { emitCurriculumFeed } from './chunk-QJF4QCBJ.mjs';
|
|
4
|
+
export { ArchEdgeSchema, ArchNodeSchema, ArchitectureDetailSchema, CapabilitySchema, ConceptCategorySchema, ConceptIntroductionSchema, ConceptSchema, DataIntegrationSchema, DecompositionSchema, DetectionConfidenceSchema, DevelopmentPhaseSchema, DevelopmentStageSchema, DomainCategorySchema, DomainProfileSchema, ExperienceComponentSchema, ExperienceSchema, ExperimentProcedureSchema, FeatureSchema, GrammarRuleSchema, GraphTypeSchema, HardwareFeatureExtensionSchema, HardwareStepSchema, HardwareTaskExtensionSchema, HardwareTechStackExtensionSchema, HybridGraphSchema, ImplementationSchema, InputTypeSchema, JourneySchema, JourneyStepSchema, KnowledgeGraphSchema, LanguageConceptExtensionSchema, LearningModeSchema, LearningPathStepSchema, MathConceptExtensionSchema, MathTheoremSchema, MilestoneDecompositionSchema, MissingGapSchema, NavigationSchema, ProblemTypeSchema, ProductGoalSchema, ProductSchema, ProductUserSchema, ProjectConceptLinkSchema, ProjectGraphSchema, ProjectInfoSchema, RequirementSchema, ScienceConceptExtensionSchema, ScreenSchema, ShapeSchema, StepEffortSchema, StepOutcomeSchema, StepSchema, SubjectInfoSchema, TaskEffortSchema, TaskOutcomeSchema, TaskSchema, TechDebtSchema, TechStackSchema, ThreeDesignFeatureExtensionSchema, ThreeDesignTaskExtensionSchema, ThreeDesignTechStackExtensionSchema, UiStateSchema, WiringSchema } from './chunk-VCPIWJ7R.mjs';
|
|
5
|
+
export { CurriculumFeedSchema, FeedEdgeSchema, FeedGroupingSchema, FeedKeywordsSchema, FeedNodeSchema, FeedPhaseSchema, FeedScaffoldCandidateSchema, validateCurriculumFeed } from './chunk-PKUEOSZ3.mjs';
|
|
6
6
|
import './chunk-IJZUV7N3.mjs';
|
|
7
7
|
export { mergeCppResults, mergePythonResults, mergeSwiftResults, mergeTsResults, parseCppFile, parsePythonFile, parseSwiftFile, parseTsFile } from './chunk-DRVOV5ZD.mjs';
|
|
8
8
|
export { scoreByContent, scoreByPath, scoreFiles, selectRelevantFiles } from './chunk-RKRNOVKO.mjs';
|
|
@@ -10,7 +10,7 @@ export { extractKeywords } from './chunk-XMHKWHVK.mjs';
|
|
|
10
10
|
import './chunk-7XGWW6CB.mjs';
|
|
11
11
|
export { detectDomain, detectDomainProfile, detectInputType, detectLearningMode } from './chunk-BL5NBKPH.mjs';
|
|
12
12
|
import './chunk-ZKLT27T4.mjs';
|
|
13
|
-
export { CIO_CODE_RE, CONCEPT_CODE_RE, LEARNER_CLAUSE, SIO_CODE_RE, ULO_CODE_RE, assignConceptCodes, auditDepthLayers, auditSyllabusCoverage, breakPrerequisiteCycles, cioActionSlug, cioCode, conceptCodeFromName, detectPrerequisiteCycles, escalateAndMapConcepts, extractFeatureSteps, extractFeatureStepsBatched, extractProjectOverview, extractScaffold, generateHybridGraph, generateKnowledgeGraph, sioCode, standardStatement, techTagFor, uloCode, verifyKnowledgeGraph, verifyProjectGraph } from './chunk-
|
|
13
|
+
export { CIO_CODE_RE, CONCEPT_CODE_RE, LEARNER_CLAUSE, SIO_CODE_RE, ULO_CODE_RE, assignConceptCodes, auditDepthLayers, auditPhasePlan, auditSyllabusCoverage, breakPrerequisiteCycles, cioActionSlug, cioCode, conceptCodeFromName, detectPrerequisiteCycles, escalateAndMapConcepts, extractFeatureSteps, extractFeatureStepsBatched, extractProjectOverview, extractScaffold, generateHybridGraph, generateKnowledgeGraph, sioCode, standardStatement, techTagFor, uloCode, verifyKnowledgeGraph, verifyProjectGraph } from './chunk-HILSUZOF.mjs';
|
|
14
14
|
export { parseSyllabus } from './chunk-T4Y2DE2W.mjs';
|
|
15
15
|
import './chunk-KMYENICQ.mjs';
|
|
16
16
|
export { resolveConcepts } from './chunk-KNDBODUQ.mjs';
|
package/dist/pipeline/index.cjs
CHANGED
|
@@ -39,6 +39,22 @@ function validateCurriculumFeed(feed) {
|
|
|
39
39
|
}
|
|
40
40
|
const phaseIds = parsed.phases.map((p) => p.id);
|
|
41
41
|
if (new Set(phaseIds).size !== phaseIds.length) throw new Error("curriculum feed contains duplicate phase ids");
|
|
42
|
+
if (parsed.phases.length > 0) {
|
|
43
|
+
const phaseIndexOf = /* @__PURE__ */ new Map();
|
|
44
|
+
parsed.phases.forEach((p, i) => {
|
|
45
|
+
for (const id of p.node_ids) phaseIndexOf.set(id, i);
|
|
46
|
+
});
|
|
47
|
+
for (const e of parsed.dependency_edges) {
|
|
48
|
+
const fromIdx = phaseIndexOf.get(e.from);
|
|
49
|
+
const toIdx = phaseIndexOf.get(e.to);
|
|
50
|
+
if (fromIdx === void 0 || toIdx === void 0) continue;
|
|
51
|
+
if (fromIdx > toIdx) {
|
|
52
|
+
throw new Error(
|
|
53
|
+
"curriculum feed teaching-order violation: prerequisite " + e.from + " (phase " + (fromIdx + 1) + ") is scheduled AFTER its consumer " + e.to + " (phase " + (toIdx + 1) + ")"
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
42
58
|
return parsed;
|
|
43
59
|
}
|
|
44
60
|
var FeedKeywordsSchema, FeedScaffoldCandidateSchema, FeedNodeSchema, FeedEdgeSchema, FeedGroupingSchema, FeedPhaseSchema, CurriculumFeedSchema;
|
|
@@ -72,11 +88,33 @@ var init_curriculumFeedSchema = __esm({
|
|
|
72
88
|
references: zod.z.array(zod.z.object({ file: zod.z.string().min(1), evidence: zod.z.string().default("") })).default([]),
|
|
73
89
|
feature_id: zod.z.string().nullable().default(null),
|
|
74
90
|
concept_ref: zod.z.string().nullable().default(null),
|
|
91
|
+
// P52/T2.1: outcome.user_visible projected from the ProjectGraph step — the
|
|
92
|
+
// tangible checkpoint the session-cutting planner aims for (empty when the
|
|
93
|
+
// step declares no user-visible result). Concepts carry '' by default.
|
|
94
|
+
user_visible_deliverable: zod.z.string().default(""),
|
|
95
|
+
// P52/T3.1 — depth-reconcile inputs (optional/defaulted so old feeds
|
|
96
|
+
// validate unchanged):
|
|
97
|
+
// • depth_variants: minutes to teach this node at each depth level.
|
|
98
|
+
// ULO (know-it-exists) ≤ CIO (mechanism) ≤ SIO (implementation). All 3
|
|
99
|
+
// required so a downgrade never turns an anchor teach into a zero.
|
|
100
|
+
// • depth_scaffold_candidates: parallel to scaffold_candidates but
|
|
101
|
+
// acts on DEPTH (e.g. SIO→CIO) instead of lesson time.
|
|
102
|
+
// • is_core: concept is a Master-Tree core concept — reconciler must
|
|
103
|
+
// never downgrade it; escalate instead.
|
|
104
|
+
depth_variants: zod.z.object({ ulo: zod.z.number().int().nonnegative(), cio: zod.z.number().int().nonnegative(), sio: zod.z.number().int().nonnegative() }).optional(),
|
|
105
|
+
depth_scaffold_candidates: zod.z.array(zod.z.object({
|
|
106
|
+
from_depth: zod.z.enum(["ulo", "cio", "sio"]),
|
|
107
|
+
to_depth: zod.z.enum(["ulo", "cio", "sio"]),
|
|
108
|
+
minutes_saved: zod.z.number().int().nonnegative(),
|
|
109
|
+
reason: zod.z.string().default("")
|
|
110
|
+
})).optional(),
|
|
111
|
+
is_core: zod.z.boolean().default(false),
|
|
75
112
|
// Progressive-completion bookkeeping (feed v2, additive):
|
|
76
113
|
// phase_id = development phase that introduces/uses this node;
|
|
77
|
-
// introduce_aspect = how the phase teaches a concept node (first intro
|
|
114
|
+
// introduce_aspect = how the phase teaches a concept node (first intro, advanced
|
|
115
|
+
// revisit, or preview — a light ULO awareness pass that is NOT the introduction).
|
|
78
116
|
phase_id: zod.z.string().default(""),
|
|
79
|
-
introduce_aspect: zod.z.enum(["new", "advanced"]).nullable().default(null)
|
|
117
|
+
introduce_aspect: zod.z.enum(["new", "advanced", "preview"]).nullable().default(null)
|
|
80
118
|
});
|
|
81
119
|
FeedEdgeSchema = zod.z.object({
|
|
82
120
|
from: zod.z.string().min(1),
|
|
@@ -123,6 +161,9 @@ function stepMinutes(step) {
|
|
|
123
161
|
const effort = step.effort ?? {};
|
|
124
162
|
return Math.max(0, Math.round(num(effort.estimated_minutes, num(step.estimated_minutes, 45))));
|
|
125
163
|
}
|
|
164
|
+
function pushWarning(opts, message) {
|
|
165
|
+
(opts.warnings ?? (opts.warnings = [])).push(message);
|
|
166
|
+
}
|
|
126
167
|
function newKeywordsInOrder(nodes) {
|
|
127
168
|
const seen = /* @__PURE__ */ new Set();
|
|
128
169
|
for (const n of nodes) {
|
|
@@ -152,6 +193,10 @@ function feedNodeFromStep(step, featureId) {
|
|
|
152
193
|
references: arr(step.files).map((f) => ({ file: str(f), evidence: "step file" })).filter((f) => f.file),
|
|
153
194
|
feature_id: featureId,
|
|
154
195
|
concept_ref: null,
|
|
196
|
+
// P52/T2.1: carry the step's tangible outcome so the planner can cut
|
|
197
|
+
// sessions at user-visible checkpoints instead of raw minute counts.
|
|
198
|
+
user_visible_deliverable: str(step.outcome?.user_visible),
|
|
199
|
+
is_core: false,
|
|
155
200
|
phase_id: "",
|
|
156
201
|
introduce_aspect: null
|
|
157
202
|
};
|
|
@@ -170,6 +215,20 @@ function deriveConceptDepthHint(concept) {
|
|
|
170
215
|
if (str(concept.cio) || prereqs.length >= 1) return "cio";
|
|
171
216
|
return "ulo";
|
|
172
217
|
}
|
|
218
|
+
function deriveDepthInputs(minutes, depth) {
|
|
219
|
+
const ulo = Math.max(5, Math.round(minutes * 0.35));
|
|
220
|
+
const cio = Math.max(ulo + 5, Math.round(minutes * 0.65));
|
|
221
|
+
const sio = Math.max(cio + 5, minutes);
|
|
222
|
+
const variants = { ulo, cio, sio };
|
|
223
|
+
const candidates = [];
|
|
224
|
+
if (depth === "sio") {
|
|
225
|
+
candidates.push({ from_depth: "sio", to_depth: "cio", minutes_saved: sio - cio, reason: "SIO implementation practice deferred \u2014 CIO mechanism suffices for downstream consumers" });
|
|
226
|
+
}
|
|
227
|
+
if (depth === "cio" || depth === "sio") {
|
|
228
|
+
candidates.push({ from_depth: depth, to_depth: "ulo", minutes_saved: (depth === "sio" ? sio : cio) - ulo, reason: "Mechanism deferred \u2014 ULO awareness suffices (know-it-exists); never below the ULO floor" });
|
|
229
|
+
}
|
|
230
|
+
return { depth_variants: variants, depth_scaffold_candidates: candidates };
|
|
231
|
+
}
|
|
173
232
|
function feedNodeFromConcept(concept) {
|
|
174
233
|
const id = str(concept.id);
|
|
175
234
|
const pts = arr(concept.problem_types).map((p) => str(p.bloom_level, "Understand")).filter((b) => b in BLOOM_RANK).sort((a, b) => BLOOM_RANK[a] - BLOOM_RANK[b]);
|
|
@@ -199,6 +258,10 @@ function feedNodeFromConcept(concept) {
|
|
|
199
258
|
references,
|
|
200
259
|
feature_id: null,
|
|
201
260
|
concept_ref: id,
|
|
261
|
+
user_visible_deliverable: "",
|
|
262
|
+
// concepts are taught, not shipped — checkpoints live on product steps
|
|
263
|
+
...deriveDepthInputs(Math.max(0, Math.round(num(concept.estimated_minutes, 15))), deriveConceptDepthHint(concept)),
|
|
264
|
+
is_core: false,
|
|
202
265
|
phase_id: "",
|
|
203
266
|
introduce_aspect: null
|
|
204
267
|
};
|
|
@@ -259,6 +322,7 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
259
322
|
}
|
|
260
323
|
const emitCtx = [];
|
|
261
324
|
const emittedConcepts = /* @__PURE__ */ new Set();
|
|
325
|
+
const previewsEmitted = /* @__PURE__ */ new Set();
|
|
262
326
|
const linkList = arr(hybrid.links);
|
|
263
327
|
for (const rp of rawPhases) {
|
|
264
328
|
const pid = str(rp.id);
|
|
@@ -267,7 +331,8 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
267
331
|
const intros = arr(rp.introduces);
|
|
268
332
|
const news = intros.filter((i) => str(i.aspect, "new") === "new");
|
|
269
333
|
const advanced = intros.filter((i) => str(i.aspect) === "advanced");
|
|
270
|
-
|
|
334
|
+
const previews = intros.filter((i) => str(i.aspect) === "preview");
|
|
335
|
+
for (const intro of [...news, ...advanced, ...previews]) {
|
|
271
336
|
const cid = str(intro.concept_id);
|
|
272
337
|
const c = conceptById.get(cid);
|
|
273
338
|
if (!c) {
|
|
@@ -276,6 +341,39 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
276
341
|
if (str(intro.aspect, "new") === "advanced" && !emittedConcepts.has(cid)) {
|
|
277
342
|
throw new Error("Phase " + pid + " advanced-revisits concept " + cid + " that was never emitted - fail-closed");
|
|
278
343
|
}
|
|
344
|
+
if (str(intro.aspect, "new") === "preview") {
|
|
345
|
+
if (emittedConcepts.has(cid)) {
|
|
346
|
+
throw new Error("Phase " + pid + " previews concept " + cid + " that was already introduced - preview must precede the anchor teach - fail-closed");
|
|
347
|
+
}
|
|
348
|
+
if (previewsEmitted.has(cid)) {
|
|
349
|
+
throw new Error("Phase " + pid + " duplicate preview of concept " + cid + " - fail-closed");
|
|
350
|
+
}
|
|
351
|
+
const pidIdx = rawPhases.findIndex((rp2) => str(rp2.id) === pid);
|
|
352
|
+
const anchorIdx = rawPhases.findIndex((rp2) => arr(rp2.introduces).some((i2) => str(i2.concept_id) === cid && str(i2.aspect, "new") !== "preview"));
|
|
353
|
+
if (anchorIdx < 0) {
|
|
354
|
+
throw new Error("Phase " + pid + " previews concept " + cid + " that is never fully introduced in any phase - fail-closed");
|
|
355
|
+
}
|
|
356
|
+
if (pidIdx >= anchorIdx) {
|
|
357
|
+
throw new Error("Phase " + pid + " previews concept " + cid + " whose anchor introduction is not in a LATER phase - fail-closed");
|
|
358
|
+
}
|
|
359
|
+
previewsEmitted.add(cid);
|
|
360
|
+
const prevNode = feedNodeFromConcept(c);
|
|
361
|
+
prevNode.id = cid + "__PREV" + pad22(order);
|
|
362
|
+
prevNode.name = str(c.name, cid) + " (preview)";
|
|
363
|
+
prevNode.phase_id = pid;
|
|
364
|
+
prevNode.introduce_aspect = "preview";
|
|
365
|
+
prevNode.estimated_minutes = Math.max(5, Math.round(prevNode.estimated_minutes * 0.25));
|
|
366
|
+
prevNode.depth_hint = "ulo";
|
|
367
|
+
prevNode.bloom_hint = "Understand";
|
|
368
|
+
prevNode.concept_codes = [str(c.code) || cid];
|
|
369
|
+
prevNode.keywords = { all: strs(c.keywords), new: [], prerequisite: [] };
|
|
370
|
+
prevNode.scaffolding = { scaffold_candidates: [], core_value_minutes: 0 };
|
|
371
|
+
prevNode.depth_variants = { ulo: prevNode.estimated_minutes, cio: prevNode.estimated_minutes, sio: prevNode.estimated_minutes };
|
|
372
|
+
prevNode.depth_scaffold_candidates = [];
|
|
373
|
+
nodes.push(prevNode);
|
|
374
|
+
conceptOrder.push(prevNode.id);
|
|
375
|
+
continue;
|
|
376
|
+
}
|
|
279
377
|
if (!emittedConcepts.has(cid)) {
|
|
280
378
|
const node = feedNodeFromConcept(c);
|
|
281
379
|
node.phase_id = pid;
|
|
@@ -296,6 +394,7 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
296
394
|
node.name = str(c.name, cid) + " (advanced)";
|
|
297
395
|
node.phase_id = pid;
|
|
298
396
|
node.introduce_aspect = "advanced";
|
|
397
|
+
node.depth_scaffold_candidates = [{ from_depth: "sio", to_depth: "cio", minutes_saved: Math.round(node.estimated_minutes * 0.3), reason: "advanced revisit may drop to CIO recap without breaking first-teach chain" }];
|
|
299
398
|
node.estimated_minutes = Math.max(15, Math.round(node.estimated_minutes * 0.5));
|
|
300
399
|
node.concept_codes = [str(c.code) || cid];
|
|
301
400
|
edges.push({ from: cid, to: revisitId, kind: "knowledge", reason: "advanced revisit of " + cid + " at phase " + pid });
|
|
@@ -331,6 +430,17 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
331
430
|
}
|
|
332
431
|
phaseNodeIds.push(ids);
|
|
333
432
|
}
|
|
433
|
+
const placed = new Set(phaseNodeIds.flat());
|
|
434
|
+
const orderedNodes = [];
|
|
435
|
+
for (const ids of phaseNodeIds) {
|
|
436
|
+
for (const id of ids) {
|
|
437
|
+
const n = nodes.find((x) => x.id === id);
|
|
438
|
+
if (n) orderedNodes.push(n);
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
for (const n of nodes) if (!placed.has(n.id)) orderedNodes.push(n);
|
|
442
|
+
nodes.length = 0;
|
|
443
|
+
nodes.push(...orderedNodes);
|
|
334
444
|
const edgeSeen = new Set(edges.map((e) => e.from + ">" + e.to));
|
|
335
445
|
const pushEdge = (from, to, reason) => {
|
|
336
446
|
const key = from + ">" + to;
|
|
@@ -345,6 +455,14 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
345
455
|
const firstStep = (stepIdsByFeature.get(fid) || [])[0];
|
|
346
456
|
if (!firstStep) continue;
|
|
347
457
|
const depth = str(l.depth, "cio");
|
|
458
|
+
const anchorNode = nodes.find((n2) => n2.kind === "concept" && n2.concept_ref === cid && n2.introduce_aspect === "new");
|
|
459
|
+
const stepNode = nodes.find((n2) => n2.id === firstStep);
|
|
460
|
+
const anchorPhaseIdx = anchorNode ? emitCtx.findIndex((c2) => c2.id === anchorNode.phase_id) : -1;
|
|
461
|
+
const stepPhaseIdx = stepNode ? emitCtx.findIndex((c2) => c2.id === stepNode.phase_id) : -1;
|
|
462
|
+
if (emitCtx.length > 0 && anchorPhaseIdx > stepPhaseIdx) {
|
|
463
|
+
pushWarning(opts, "hybrid link drift: concept " + cid + " is fully taught in a later phase than consumer " + firstStep + " (a preview covers the dependency)");
|
|
464
|
+
continue;
|
|
465
|
+
}
|
|
348
466
|
pushEdge(cid, firstStep, str(l.relationship, "hybrid link") + " [" + depth + "]");
|
|
349
467
|
for (const n of nodes) {
|
|
350
468
|
if (n.kind === "concept" && n.concept_ref === cid && n.introduce_aspect === "advanced" && n.phase_id === str(l.phase_id)) {
|
|
@@ -363,6 +481,21 @@ function emitFromHybrid(hybrid, opts) {
|
|
|
363
481
|
for (const k of n.keywords?.prerequisite ?? []) {
|
|
364
482
|
const src = introducer.get(k.toLowerCase());
|
|
365
483
|
if (!src || src === n.id) continue;
|
|
484
|
+
const srcNode = nodes.find((x) => x.id === src);
|
|
485
|
+
const phaseOf = (id) => {
|
|
486
|
+
const n2 = nodes.find((x) => x.id === id);
|
|
487
|
+
return n2 ? emitCtx.findIndex((c) => c.id === n2.phase_id) : -1;
|
|
488
|
+
};
|
|
489
|
+
const conceptOvertaken = n.kind === "concept" && srcNode?.kind === "product_step";
|
|
490
|
+
const fromPhase = phaseOf(src);
|
|
491
|
+
const toPhase = phaseOf(n.id);
|
|
492
|
+
if (conceptOvertaken || emitCtx.length > 0 && fromPhase > toPhase) {
|
|
493
|
+
pushWarning(
|
|
494
|
+
opts,
|
|
495
|
+
"keyword-order drift: introducer " + src + " sits in a later phase than consumer " + n.id + ' (keyword "' + k + '") \u2014 host should move the introducer earlier'
|
|
496
|
+
);
|
|
497
|
+
continue;
|
|
498
|
+
}
|
|
366
499
|
if (feedOrder.get(src) < feedOrder.get(n.id)) pushEdge(src, n.id, "keyword prerequisite [" + k + "]");
|
|
367
500
|
}
|
|
368
501
|
}
|
|
@@ -4136,6 +4269,8 @@ function auditPhasePlan(plan, features, concepts, links, warnings, log) {
|
|
|
4136
4269
|
const phases = [];
|
|
4137
4270
|
const featurePhase = /* @__PURE__ */ new Map();
|
|
4138
4271
|
const newIntroPhase = /* @__PURE__ */ new Map();
|
|
4272
|
+
const previewsSeen = /* @__PURE__ */ new Set();
|
|
4273
|
+
const previewPhase = /* @__PURE__ */ new Map();
|
|
4139
4274
|
const errors = [];
|
|
4140
4275
|
plan.forEach((rp, idx) => {
|
|
4141
4276
|
const id = String(rp.id || "PH" + (idx + 1));
|
|
@@ -4167,7 +4302,22 @@ function auditPhasePlan(plan, features, concepts, links, warnings, log) {
|
|
|
4167
4302
|
errors.push("Phase " + id + ": introduces unknown concept " + cid);
|
|
4168
4303
|
continue;
|
|
4169
4304
|
}
|
|
4170
|
-
const
|
|
4305
|
+
const rawAspect = String(ri.aspect || "new");
|
|
4306
|
+
const aspect = rawAspect === "advanced" || rawAspect === "preview" ? rawAspect : "new";
|
|
4307
|
+
if (aspect === "preview") {
|
|
4308
|
+
if (newIntroPhase.has(cid)) {
|
|
4309
|
+
errors.push("Phase " + id + ": preview of " + cid + " after its new introduction in phase " + newIntroPhase.get(cid) + " - preview must precede the anchor teach");
|
|
4310
|
+
continue;
|
|
4311
|
+
}
|
|
4312
|
+
if (previewsSeen.has(cid)) {
|
|
4313
|
+
errors.push("Phase " + id + ": duplicate preview of " + cid);
|
|
4314
|
+
continue;
|
|
4315
|
+
}
|
|
4316
|
+
previewsSeen.add(cid);
|
|
4317
|
+
previewPhase.set(cid, order);
|
|
4318
|
+
introductions.push({ concept_id: cid, aspect, note: String(ri.note || "") });
|
|
4319
|
+
continue;
|
|
4320
|
+
}
|
|
4171
4321
|
if (aspect === "advanced") {
|
|
4172
4322
|
const first = newIntroPhase.get(cid);
|
|
4173
4323
|
if (first === void 0) {
|
|
@@ -4215,10 +4365,17 @@ function auditPhasePlan(plan, features, concepts, links, warnings, log) {
|
|
|
4215
4365
|
}
|
|
4216
4366
|
for (const [cid, consumerOrder] of firstConsumerPhase) {
|
|
4217
4367
|
const intro = newIntroPhase.get(cid);
|
|
4218
|
-
|
|
4368
|
+
const prev = previewPhase.get(cid);
|
|
4369
|
+
if (intro === void 0 && prev === void 0) {
|
|
4219
4370
|
errors.push("Concept " + cid + " is consumed from phase " + consumerOrder + " but never introduced in any phase");
|
|
4220
|
-
} else if (intro > consumerOrder) {
|
|
4221
|
-
errors.push("Concept " + cid + " introduced in phase " + intro + " but first consumed in phase " + consumerOrder + " - introduction must come no later than first consumption");
|
|
4371
|
+
} else if (intro !== void 0 && intro > consumerOrder && (prev === void 0 || prev > consumerOrder)) {
|
|
4372
|
+
errors.push("Concept " + cid + " introduced in phase " + intro + " but first consumed in phase " + consumerOrder + " - introduction must come no later than first consumption (or a preview must cover the dependency)");
|
|
4373
|
+
}
|
|
4374
|
+
}
|
|
4375
|
+
for (const [cid, pOrder] of previewPhase) {
|
|
4376
|
+
const anchor = newIntroPhase.get(cid);
|
|
4377
|
+
if (anchor !== void 0 && anchor <= pOrder) {
|
|
4378
|
+
errors.push("Concept " + cid + " previewed in phase " + pOrder + " but fully introduced in phase " + anchor + " - preview must precede the anchor introduction");
|
|
4222
4379
|
}
|
|
4223
4380
|
}
|
|
4224
4381
|
return { phases, errors };
|
|
@@ -4234,7 +4391,7 @@ async function decomposePhases(args) {
|
|
|
4234
4391
|
const linkList = links.map(
|
|
4235
4392
|
(l) => "- " + l.feature_id + " -> " + l.concept_id + " (" + l.depth + ")"
|
|
4236
4393
|
).join("\n") || "(none)";
|
|
4237
|
-
const systemPrompt =
|
|
4394
|
+
const systemPrompt = 'You decompose a software project build into PROGRESSIVE COMPLETION PHASES for learning purposes.\n\nA phase is NOT a feature and NOT a milestone list: it is a cross-feature slice of the\nproduct whose completion yields a DEMONSTRABLY more complete product. Build up gradually:\nthe product grows feature by feature across phases, and each phase adds its features to\nwhat previous phases already built.\n\nRULES:\n1. Every feature must be assigned to EXACTLY ONE phase (no feature reused, none skipped).\n2. Phases are ordered; later phases depend on earlier ones and yield a more complete product.\n3. product_completion describes concretely what the product can DO once the phase is done.\n4. introduces lists which concepts the phase must teach BEFORE its feature work starts:\n - aspect new: first time the concept appears in the course\n - aspect advanced: a concept introduced in an EARLIER phase, revisited here at a\n higher depth (an advanced aspect of the same concept, e.g. validation rules on top\n of basic data modeling). Use the note field to say which aspect.\n - aspect preview: a light awareness pass ("know it exists", ULO depth only, ~5 min)\n placed in an EARLIER phase when its feature work needs the vocabulary before the\n full teach. The anchor phase still owns the full new introduction.\n5. A concept MUST be introduced (new) no later than the first phase that consumes it.\n6. A concept must not be introduced before its own prerequisites are introduced.\n7. Typically 3-6 phases for a small project; keep phases balanced.\n8. Phase 1 usually covers project setup/foundation features plus the first minimal slice.\n9. Return JSON only.';
|
|
4238
4395
|
const baseUserPrompt = "FEATURES:\n" + featureList + "\n\nCONCEPTS:\n" + conceptList + "\n\nFEATURE-CONCEPT LINKS:\n" + linkList + "\n\nReturn JSON with a phases array. Each phase: { id: PH1, name, product_completion, feature_ids: [F0, F1], introduces: [{ concept_id: C1, aspect: new or advanced, note }] }.\n";
|
|
4239
4396
|
const MAX_DECOMPOSE_ATTEMPTS = 3;
|
|
4240
4397
|
let auditErrors = [];
|