@automovie/evidence 0.1.0 → 0.3.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 +14 -10
- package/lib/IAutoMovieDevelopmentProps.d.ts +11 -10
- package/lib/IAutoMovieEvidenceConfigProps.d.ts +9 -8
- package/lib/IAutoMovieNarrativeProps.d.ts +0 -3
- package/lib/IAutoMovieNoNarrativeProps.d.ts +16 -0
- package/lib/{narrative/IProductionLayerStages.js → IAutoMovieNoNarrativeProps.js} +1 -1
- package/lib/IAutoMovieNoNarrativeProps.js.map +1 -0
- package/lib/createDevelopmentContractClaims.d.ts +26 -14
- package/lib/createDevelopmentContractClaims.js +35 -21
- package/lib/createDevelopmentContractClaims.js.map +1 -1
- package/lib/createEvidenceConfig.d.ts +3 -3
- package/lib/createEvidenceConfig.js +19 -12
- package/lib/createEvidenceConfig.js.map +1 -1
- package/lib/index.d.ts +7 -8
- package/lib/index.js +1 -8
- package/lib/index.js.map +1 -1
- package/lib/internal/index.d.ts +5 -0
- package/lib/internal/index.js +7 -0
- package/lib/internal/index.js.map +1 -1
- package/lib/internal/resolveSkillsDirectory.d.ts +8 -9
- package/lib/internal/resolveSkillsDirectory.js +9 -12
- package/lib/internal/resolveSkillsDirectory.js.map +1 -1
- package/lib/narrative/IPackageChecklistClaimProps.d.ts +5 -10
- package/lib/narrative/IPackageContractProps.d.ts +0 -8
- package/lib/narrative/IPackagePopulationContractProps.d.ts +1 -9
- package/lib/narrative/IProductionConfigProps.d.ts +1 -10
- package/lib/narrative/createBriefFiles.d.ts +2 -2
- package/lib/narrative/createBriefFiles.js +2 -2
- package/lib/narrative/createNarrativeUnitFiles.d.ts +19 -12
- package/lib/narrative/createNarrativeUnitFiles.js +22 -17
- package/lib/narrative/createNarrativeUnitFiles.js.map +1 -1
- package/lib/narrative/createPackageChecklistClaim.js +5 -10
- package/lib/narrative/createPackageChecklistClaim.js.map +1 -1
- package/lib/narrative/createPackageContract.d.ts +3 -3
- package/lib/narrative/createPackageContract.js +3 -8
- package/lib/narrative/createPackageContract.js.map +1 -1
- package/lib/narrative/createPackagePopulationContract.d.ts +7 -7
- package/lib/narrative/createPackagePopulationContract.js +10 -18
- package/lib/narrative/createPackagePopulationContract.js.map +1 -1
- package/lib/narrative/index.d.ts +0 -4
- package/lib/narrative/index.js +0 -4
- package/lib/narrative/index.js.map +1 -1
- package/lib/narrative/internal/REALIZED_LAYERS.d.ts +1 -1
- package/lib/narrative/internal/REALIZED_LAYERS.js +1 -1
- package/lib/narrative/internal/claims/createDiscoveryClaim.d.ts +11 -3
- package/lib/narrative/internal/claims/createDiscoveryClaim.js +17 -5
- package/lib/narrative/internal/claims/createDiscoveryClaim.js.map +1 -1
- package/lib/narrative/internal/claims/createExpressionObligationClaims.d.ts +9 -8
- package/lib/narrative/internal/claims/createExpressionObligationClaims.js +15 -22
- package/lib/narrative/internal/claims/createExpressionObligationClaims.js.map +1 -1
- package/lib/narrative/internal/claims/createInstructionCoverageClaim.d.ts +6 -4
- package/lib/narrative/internal/claims/createInstructionCoverageClaim.js +7 -5
- package/lib/narrative/internal/claims/createInstructionCoverageClaim.js.map +1 -1
- package/lib/narrative/internal/claims/createLayerClaims.d.ts +9 -9
- package/lib/narrative/internal/claims/createLayerClaims.js +45 -65
- package/lib/narrative/internal/claims/createLayerClaims.js.map +1 -1
- package/lib/narrative/internal/claims/createOutlineClaims.js +8 -8
- package/lib/narrative/internal/claims/createOutlineClaims.js.map +1 -1
- package/lib/narrative/internal/claims/createPopulationObligationClaims.d.ts +3 -3
- package/lib/narrative/internal/claims/createPopulationObligationClaims.js +5 -5
- package/lib/narrative/internal/claims/createPopulationObligationClaims.js.map +1 -1
- package/lib/narrative/internal/claims/createReviewClaims.d.ts +8 -8
- package/lib/narrative/internal/claims/createReviewClaims.js +64 -77
- package/lib/narrative/internal/claims/createReviewClaims.js.map +1 -1
- package/lib/narrative/internal/claims/createSettingCoverageClaim.d.ts +1 -1
- package/lib/narrative/internal/claims/createSettingCoverageClaim.js +6 -7
- package/lib/narrative/internal/claims/createSettingCoverageClaim.js.map +1 -1
- package/lib/narrative/internal/collectProductionClaims.js +5 -2
- package/lib/narrative/internal/collectProductionClaims.js.map +1 -1
- package/lib/narrative/internal/index.d.ts +0 -1
- package/lib/narrative/internal/index.js +0 -1
- package/lib/narrative/internal/index.js.map +1 -1
- package/lib/narrative/internal/readSettingsFiles.d.ts +6 -5
- package/lib/narrative/internal/readSettingsFiles.js +12 -9
- package/lib/narrative/internal/readSettingsFiles.js.map +1 -1
- package/lib/narrative/internal/references/createCoverageReference.d.ts +1 -2
- package/lib/narrative/internal/references/createCoverageReference.js +2 -2
- package/lib/narrative/internal/references/createCoverageReference.js.map +1 -1
- package/lib/narrative/internal/references/createDiscoveryReferences.d.ts +2 -2
- package/lib/narrative/internal/references/createDiscoveryReferences.js +2 -2
- package/lib/narrative/internal/references/createLanguagePrincipleReferences.d.ts +7 -6
- package/lib/narrative/internal/references/createLanguagePrincipleReferences.js +7 -7
- package/lib/narrative/internal/references/createLanguagePrincipleReferences.js.map +1 -1
- package/lib/narrative/internal/references/createLineageReference.d.ts +7 -8
- package/lib/narrative/internal/references/createLineageReference.js +8 -8
- package/lib/narrative/internal/references/createLineageReference.js.map +1 -1
- package/lib/narrative/internal/references/createPrincipleReferences.d.ts +9 -8
- package/lib/narrative/internal/references/createPrincipleReferences.js +12 -12
- package/lib/narrative/internal/references/createPrincipleReferences.js.map +1 -1
- package/lib/narrative/internal/references/createSettingReferences.d.ts +3 -4
- package/lib/narrative/internal/references/createSettingReferences.js +6 -6
- package/lib/narrative/internal/references/createSettingReferences.js.map +1 -1
- package/lib/narrative/internal/references/layerFiles.d.ts +5 -5
- package/lib/narrative/internal/references/layerFiles.js +5 -5
- package/lib/narrative/internal/topology/createTopologyFiles.d.ts +1 -1
- package/lib/narrative/internal/topology/createTopologyFiles.js +1 -1
- package/lib/narrative/internal/utilities/BODY_ROOT.d.ts +15 -0
- package/lib/narrative/internal/utilities/BODY_ROOT.js +20 -0
- package/lib/narrative/internal/utilities/BODY_ROOT.js.map +1 -0
- package/lib/narrative/internal/utilities/PACKAGE_DOCS_ROOT.d.ts +6 -6
- package/lib/narrative/internal/utilities/PACKAGE_DOCS_ROOT.js +6 -6
- package/lib/narrative/internal/utilities/assertProductionEvidenceSources.js +6 -19
- package/lib/narrative/internal/utilities/assertProductionEvidenceSources.js.map +1 -1
- package/lib/narrative/internal/utilities/createUnitFiles.d.ts +4 -6
- package/lib/narrative/internal/utilities/createUnitFiles.js +5 -7
- package/lib/narrative/internal/utilities/createUnitFiles.js.map +1 -1
- package/lib/narrative/internal/utilities/index.d.ts +1 -1
- package/lib/narrative/internal/utilities/index.js +1 -1
- package/lib/narrative/internal/utilities/index.js.map +1 -1
- package/lib/narrative/internal/utilities/referenceLocation.d.ts +6 -9
- package/lib/narrative/internal/utilities/referenceLocation.js +9 -14
- package/lib/narrative/internal/utilities/referenceLocation.js.map +1 -1
- package/package.json +8 -4
- package/src/IAutoMovieDevelopmentProps.ts +11 -10
- package/src/IAutoMovieEvidenceConfigProps.ts +9 -8
- package/src/IAutoMovieNarrativeProps.ts +0 -4
- package/src/IAutoMovieNoNarrativeProps.ts +18 -0
- package/src/createDevelopmentContractClaims.ts +43 -22
- package/src/createEvidenceConfig.ts +23 -13
- package/src/index.ts +8 -8
- package/src/internal/index.ts +7 -0
- package/src/internal/resolveSkillsDirectory.ts +9 -12
- package/src/narrative/IPackageChecklistClaimProps.ts +5 -11
- package/src/narrative/IPackageContractProps.ts +0 -9
- package/src/narrative/IPackagePopulationContractProps.ts +1 -10
- package/src/narrative/IProductionConfigProps.ts +1 -11
- package/src/narrative/createBriefFiles.ts +2 -2
- package/src/narrative/createNarrativeUnitFiles.ts +28 -20
- package/src/narrative/createPackageChecklistClaim.ts +5 -10
- package/src/narrative/createPackageContract.ts +3 -15
- package/src/narrative/createPackagePopulationContract.ts +11 -26
- package/src/narrative/index.ts +0 -4
- package/src/narrative/internal/REALIZED_LAYERS.ts +1 -1
- package/src/narrative/internal/claims/createDiscoveryClaim.ts +20 -6
- package/src/narrative/internal/claims/createExpressionObligationClaims.ts +15 -24
- package/src/narrative/internal/claims/createInstructionCoverageClaim.ts +8 -6
- package/src/narrative/internal/claims/createLayerClaims.ts +48 -78
- package/src/narrative/internal/claims/createOutlineClaims.ts +8 -8
- package/src/narrative/internal/claims/createPopulationObligationClaims.ts +5 -5
- package/src/narrative/internal/claims/createReviewClaims.ts +69 -91
- package/src/narrative/internal/claims/createSettingCoverageClaim.ts +5 -7
- package/src/narrative/internal/collectProductionClaims.ts +7 -5
- package/src/narrative/internal/index.ts +0 -1
- package/src/narrative/internal/readSettingsFiles.ts +14 -9
- package/src/narrative/internal/references/createCoverageReference.ts +1 -3
- package/src/narrative/internal/references/createDiscoveryReferences.ts +2 -2
- package/src/narrative/internal/references/createLanguagePrincipleReferences.ts +8 -9
- package/src/narrative/internal/references/createLineageReference.ts +7 -9
- package/src/narrative/internal/references/createPrincipleReferences.ts +13 -14
- package/src/narrative/internal/references/createSettingReferences.ts +5 -8
- package/src/narrative/internal/references/layerFiles.ts +5 -5
- package/src/narrative/internal/topology/createTopologyFiles.ts +1 -1
- package/src/narrative/internal/utilities/BODY_ROOT.ts +17 -0
- package/src/narrative/internal/utilities/PACKAGE_DOCS_ROOT.ts +6 -6
- package/src/narrative/internal/utilities/assertProductionEvidenceSources.ts +6 -25
- package/src/narrative/internal/utilities/createUnitFiles.ts +5 -7
- package/src/narrative/internal/utilities/index.ts +1 -1
- package/src/narrative/internal/utilities/referenceLocation.ts +8 -18
- package/lib/narrative/AuthoredPass.d.ts +0 -16
- package/lib/narrative/AuthoredPass.js +0 -3
- package/lib/narrative/AuthoredPass.js.map +0 -1
- package/lib/narrative/IProductionLayerStages.d.ts +0 -15
- package/lib/narrative/IProductionLayerStages.js.map +0 -1
- package/lib/narrative/internal/hasNaturalness.d.ts +0 -14
- package/lib/narrative/internal/hasNaturalness.js +0 -19
- package/lib/narrative/internal/hasNaturalness.js.map +0 -1
- package/lib/narrative/internal/utilities/passRoot.d.ts +0 -16
- package/lib/narrative/internal/utilities/passRoot.js +0 -22
- package/lib/narrative/internal/utilities/passRoot.js.map +0 -1
- package/lib/narrative/stripNaturalnessComments.d.ts +0 -12
- package/lib/narrative/stripNaturalnessComments.js +0 -34
- package/lib/narrative/stripNaturalnessComments.js.map +0 -1
- package/src/narrative/AuthoredPass.ts +0 -16
- package/src/narrative/IProductionLayerStages.ts +0 -16
- package/src/narrative/internal/hasNaturalness.ts +0 -17
- package/src/narrative/internal/utilities/passRoot.ts +0 -20
- package/src/narrative/stripNaturalnessComments.ts +0 -31
|
@@ -8,34 +8,32 @@ import path from "node:path";
|
|
|
8
8
|
import type { IContractLocation } from "../../../internal/IContractLocation";
|
|
9
9
|
import type { AuthoredLayer } from "../../AuthoredLayer";
|
|
10
10
|
import type { IProductionConfigProps } from "../../IProductionConfigProps";
|
|
11
|
-
import type { ProductionStage } from "../../ProductionStage";
|
|
12
|
-
import { REALIZED_LAYERS } from "../REALIZED_LAYERS";
|
|
13
11
|
import { constructionStage } from "../constructionStage";
|
|
14
|
-
import { hasNaturalness } from "../hasNaturalness";
|
|
15
12
|
import { createLocalContractReference } from "../references/createLocalContractReference";
|
|
16
13
|
import { createSharedReference } from "../references/createSharedReference";
|
|
17
14
|
import { layerFiles } from "../references/layerFiles";
|
|
15
|
+
import { BODY_ROOT } from "../utilities/BODY_ROOT";
|
|
18
16
|
import { createContractDirectory } from "../utilities/createContractDirectory";
|
|
19
17
|
import { createUnitFiles } from "../utilities/createUnitFiles";
|
|
20
|
-
import { passRoot } from "../utilities/passRoot";
|
|
21
18
|
|
|
22
19
|
/**
|
|
23
|
-
* Creates population expression claims
|
|
20
|
+
* Creates the scripts population expression claims.
|
|
24
21
|
*
|
|
25
22
|
* A population question about expression, such as which sentence frames recur
|
|
26
23
|
* or how endings converge, is about the language of the finished layer.
|
|
27
|
-
* Scripts
|
|
28
|
-
*
|
|
29
|
-
*
|
|
24
|
+
* Scripts settle that language in construction, so the script population
|
|
25
|
+
* answers once at file level under the scripts construction stage. The
|
|
26
|
+
* screenplay settles its speech in construction too, under its realized-speech
|
|
27
|
+
* principles, and owes no separate expression family.
|
|
30
28
|
*
|
|
31
29
|
* The contract files sit under `naturalness/obligations`, a folder the unit
|
|
32
30
|
* checklists never select, so a population duty cannot leak into a per-unit
|
|
33
31
|
* checklist. A package whose contract predates the folder has no such claim.
|
|
34
32
|
*
|
|
35
|
-
* @evidence contracts/development/implementation.md#principled-implementation Only
|
|
36
|
-
* @evidence contracts/development/implementation.md#clear-and-simple-structure Expression population questions have their own file-level family
|
|
37
|
-
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts An absent optional obligation document produces no claim under the supported older-contract layout;
|
|
38
|
-
* @evidence contracts/development/common.md#meaningful-documentation The prose identifies
|
|
33
|
+
* @evidence contracts/development/implementation.md#principled-implementation Only scripts receive file-level expression obligation claims, under their construction stage; installed shared and language files are selected separately, each requiring exactly one respondent for every population item; createContractDirectory probes shared documents in the shared skills tree and language documents in the production's own `docs/contracts`.
|
|
34
|
+
* @evidence contracts/development/implementation.md#clear-and-simple-structure Expression population questions have their own file-level family under scripts construction without leaking whole-population duties into unit checklists.
|
|
35
|
+
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts An absent optional obligation document produces no claim under the supported older-contract layout; every other layer finishes its language in its own construction questions.
|
|
36
|
+
* @evidence contracts/development/common.md#meaningful-documentation The prose identifies the scripts respondents, file-level population semantics, construction activation and optional older contract families.
|
|
39
37
|
* @evidence contracts/development/implementation.md#efficient-algorithms layerFiles supplies at most four candidate documents per scope; a bounded number of synchronous existence probes and path constructions dominate, and returned claims/references are fixed in count.
|
|
40
38
|
* @evidence contracts/development/implementation.md#reuse-equivalent-work Both scopes reuse layerFiles and shared reference constructors; existence is refreshed for each config build because installed contract files can change between builds.
|
|
41
39
|
* @evidence contracts/development/implementation.md#bound-retention-and-release-resources Only bounded claim arrays and reference objects survive under caller ownership; fs.existsSync calls retain no exposed descriptor and there is no process-wide family cache.
|
|
@@ -44,12 +42,8 @@ export function createExpressionObligationClaims(
|
|
|
44
42
|
props: IProductionConfigProps,
|
|
45
43
|
layer: AuthoredLayer,
|
|
46
44
|
): IEvidenceClaim[] {
|
|
47
|
-
if (
|
|
48
|
-
const
|
|
49
|
-
const stage: ProductionStage = revised
|
|
50
|
-
? props.naturalness.screenplay
|
|
51
|
-
: constructionStage(props, layer);
|
|
52
|
-
const disabled: boolean = stage === "disabled";
|
|
45
|
+
if (layer !== "scripts") return [];
|
|
46
|
+
const disabled: boolean = constructionStage(props, layer) === "disabled";
|
|
53
47
|
const directory: string = "naturalness/obligations";
|
|
54
48
|
|
|
55
49
|
const shared: IEvidenceClaim[] = layerFiles(layer)
|
|
@@ -60,7 +54,6 @@ export function createExpressionObligationClaims(
|
|
|
60
54
|
(file: string): IEvidenceClaim =>
|
|
61
55
|
claim({
|
|
62
56
|
disabled,
|
|
63
|
-
revised,
|
|
64
57
|
layer,
|
|
65
58
|
scope: props.narrativeScope,
|
|
66
59
|
reference: createSharedReference({
|
|
@@ -87,7 +80,6 @@ export function createExpressionObligationClaims(
|
|
|
87
80
|
: [
|
|
88
81
|
claim({
|
|
89
82
|
disabled,
|
|
90
|
-
revised,
|
|
91
83
|
layer,
|
|
92
84
|
scope: props.narrativeScope,
|
|
93
85
|
reference,
|
|
@@ -99,18 +91,17 @@ export function createExpressionObligationClaims(
|
|
|
99
91
|
return [...shared, ...language];
|
|
100
92
|
}
|
|
101
93
|
|
|
102
|
-
/** Creates one claim whose
|
|
94
|
+
/** Creates one claim whose layer documents answer each item exactly once. */
|
|
103
95
|
function claim(props: {
|
|
104
96
|
disabled: boolean;
|
|
105
|
-
revised: boolean;
|
|
106
97
|
layer: AuthoredLayer;
|
|
107
98
|
reference: IEvidenceMarkdownReference;
|
|
108
99
|
scope: IProductionConfigProps["narrativeScope"];
|
|
109
100
|
}): IEvidenceClaim {
|
|
110
101
|
return {
|
|
111
|
-
name: `${props.layer}
|
|
102
|
+
name: `${props.layer} documents answer each ${props.reference.files[0]} item once`,
|
|
112
103
|
type: "markdown",
|
|
113
|
-
root:
|
|
104
|
+
root: BODY_ROOT,
|
|
114
105
|
files: createUnitFiles(props.layer, props.scope),
|
|
115
106
|
symbol: "file",
|
|
116
107
|
disabled: props.disabled,
|
|
@@ -5,18 +5,20 @@ import path from "node:path";
|
|
|
5
5
|
import type { IProductionConfigProps } from "../../IProductionConfigProps";
|
|
6
6
|
import type { ProductionStage } from "../../ProductionStage";
|
|
7
7
|
import { constructionStage } from "../constructionStage";
|
|
8
|
+
import { BODY_ROOT } from "../utilities/BODY_ROOT";
|
|
8
9
|
import { PACKAGE_DOCS_ROOT } from "../utilities/PACKAGE_DOCS_ROOT";
|
|
9
10
|
import { createUnitFiles } from "../utilities/createUnitFiles";
|
|
10
|
-
import { passRoot } from "../utilities/passRoot";
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
-
* Tracks instruction adoption in
|
|
13
|
+
* Tracks instruction adoption in long work's settings, and realization in treatments or a short's screenplay.
|
|
14
14
|
* Each layer covers the targets independently through its own construction
|
|
15
15
|
* hosts and stage. Settings accounts for every adopted requirement; treatments
|
|
16
|
-
* can exclude requirements outside its selected narrative population.
|
|
16
|
+
* can exclude requirements outside its selected narrative population. A
|
|
17
|
+
* short's brief holds only what the commission leaves open, so it owes no
|
|
18
|
+
* instruction citation and its screenplay realizes every requirement.
|
|
17
19
|
* Instructions remain targets only. No instructions folder means no claim.
|
|
18
20
|
*
|
|
19
|
-
* @evidence contracts/development/implementation.md#principled-implementation When docs/instructions exists, selected
|
|
21
|
+
* @evidence contracts/development/implementation.md#principled-implementation When docs/instructions exists, selected body H2 hosts independently cover every instruction H2; treatments may exclude out-of-population requirements while settings or short screenplay may not.
|
|
20
22
|
* @evidence contracts/development/implementation.md#clear-and-simple-structure The optional instruction input stays a reference population rather than becoming another authored host tree.
|
|
21
23
|
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts The treatments exclusion difference follows narrative-population scope; an absent instruction directory returns undefined rather than manufacturing an input requirement.
|
|
22
24
|
* @evidence contracts/development/common.md#meaningful-documentation The prose states adoption versus realization, independent stage ownership, target-only instructions and the absent-directory result.
|
|
@@ -26,7 +28,7 @@ import { passRoot } from "../utilities/passRoot";
|
|
|
26
28
|
*/
|
|
27
29
|
export function createInstructionCoverageClaim(
|
|
28
30
|
props: IProductionConfigProps,
|
|
29
|
-
layer: "settings" | "
|
|
31
|
+
layer: "settings" | "treatments" | "screenplay",
|
|
30
32
|
): IEvidenceClaim | undefined {
|
|
31
33
|
const stage: ProductionStage = constructionStage(props, layer);
|
|
32
34
|
const directory: string = path.join(
|
|
@@ -38,7 +40,7 @@ export function createInstructionCoverageClaim(
|
|
|
38
40
|
return {
|
|
39
41
|
name: `the ${layer} canon realizes every user instruction`,
|
|
40
42
|
type: "markdown",
|
|
41
|
-
root:
|
|
43
|
+
root: BODY_ROOT,
|
|
42
44
|
files: createUnitFiles(layer, props.narrativeScope),
|
|
43
45
|
symbol: "h2",
|
|
44
46
|
disabled: stage === "disabled",
|
|
@@ -5,7 +5,6 @@ import type { IProductionConfigProps } from "../../IProductionConfigProps";
|
|
|
5
5
|
import type { ProductionStage } from "../../ProductionStage";
|
|
6
6
|
import { createNarrativeUnitFiles } from "../../createNarrativeUnitFiles";
|
|
7
7
|
import { constructionStage } from "../constructionStage";
|
|
8
|
-
import { hasNaturalness } from "../hasNaturalness";
|
|
9
8
|
import { isCanonLayer } from "../isCanonLayer";
|
|
10
9
|
import { createCoverageReference } from "../references/createCoverageReference";
|
|
11
10
|
import { createLanguagePrincipleReferences } from "../references/createLanguagePrincipleReferences";
|
|
@@ -13,8 +12,8 @@ import { createLineageReference } from "../references/createLineageReference";
|
|
|
13
12
|
import { createPrincipleReferences } from "../references/createPrincipleReferences";
|
|
14
13
|
import { createUpstreamReference } from "../references/createUpstreamReference";
|
|
15
14
|
import { createTopologyFiles } from "../topology/createTopologyFiles";
|
|
15
|
+
import { BODY_ROOT } from "../utilities/BODY_ROOT";
|
|
16
16
|
import { createUnitFiles } from "../utilities/createUnitFiles";
|
|
17
|
-
import { passRoot } from "../utilities/passRoot";
|
|
18
17
|
import { createSettingCoverageClaim } from "./createSettingCoverageClaim";
|
|
19
18
|
|
|
20
19
|
/**
|
|
@@ -28,18 +27,18 @@ import { createSettingCoverageClaim } from "./createSettingCoverageClaim";
|
|
|
28
27
|
* What differs between layers is which parents exist. Canon, settings or a
|
|
29
28
|
* short's brief, inherits nothing, so it has no construction file claim.
|
|
30
29
|
* Treatments account for settings, and a short's screenplay for its brief.
|
|
31
|
-
* Scripts realize the treatments they divide
|
|
32
|
-
*
|
|
30
|
+
* Scripts realize the treatments they divide. A long screenplay keeps the
|
|
31
|
+
* script partition: each screenplay scene file realizes exactly one script
|
|
32
|
+
* scene H2, so a script episode file becomes the screenplay episode folder of
|
|
33
|
+
* its scene files.
|
|
33
34
|
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
* because a frozen content-preserving revision cannot repair content-shaped
|
|
37
|
-
* speech defects where those questions find them.
|
|
35
|
+
* Script construction also answers the expression questions, because scripts
|
|
36
|
+
* settle their own language and no later pass revises it.
|
|
38
37
|
*
|
|
39
|
-
* @evidence contracts/development/implementation.md#principled-implementation Construction H2 claims
|
|
38
|
+
* @evidence contracts/development/implementation.md#principled-implementation Construction H2 claims and file inheritance use native reference flags for per-unit checklists, treatment coverage and exact script-scene lineage, where each screenplay scene file cites the one script scene H2 it realizes; scripts construction also selects its expression family.
|
|
40
39
|
* @evidence contracts/development/implementation.md#clear-and-simple-structure One layer factory centralizes stage/root/parent choices, while population obligations, discovery and review remain separate factories with their distinct respondents.
|
|
41
|
-
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts Short screenplay cites its actual brief
|
|
42
|
-
* @evidence contracts/development/common.md#meaningful-documentation The prose distinguishes unit/population duties, layer-specific parents
|
|
40
|
+
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts Short screenplay cites its actual brief without invented treatment or script parents; canon has no inherited file claim, and only scripts construction selects the expression questions.
|
|
41
|
+
* @evidence contracts/development/common.md#meaningful-documentation The prose distinguishes unit/population duties, layer-specific parents, the scene-file lineage and scripts expression; nearby comments explain topology capture.
|
|
43
42
|
* @evidence contracts/development/implementation.md#efficient-algorithms A fixed number of claims and reference families are constructed per layer; helper existence probes dominate most layers, while treatments and short screenplay also enumerate canon files for coverage, whose scans and sorting scale with the installed canon.
|
|
44
43
|
* @evidence contracts/development/implementation.md#reuse-equivalent-work Unit/topology selectors, parent-reference builders and scalar stages are reused within the construction; each build refreshes filesystem-dependent contract/canon observations instead of retaining stale config results.
|
|
45
44
|
* @evidence contracts/development/implementation.md#bound-retention-and-release-resources The returned native claims own their layer-family objects and any canon-derived references; synchronous discovery leaves no filesystem handle or background task open.
|
|
@@ -53,19 +52,18 @@ export function createLayerClaims(
|
|
|
53
52
|
const files: string[] = createUnitFiles(layer, props.narrativeScope);
|
|
54
53
|
|
|
55
54
|
// Indexes and invalid paths must enter the same snapshot as the authored H2s.
|
|
56
|
-
const topology: string[] =
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
: createTopologyFiles(layer, props.narrativeScope);
|
|
55
|
+
const topology: string[] = isCanonLayer(layer)
|
|
56
|
+
? files
|
|
57
|
+
: createTopologyFiles(layer, props.narrativeScope);
|
|
60
58
|
|
|
61
|
-
const treatments: string[] = createNarrativeUnitFiles(
|
|
62
|
-
"treatments",
|
|
63
|
-
props.narrativeScope,
|
|
64
|
-
);
|
|
65
|
-
const scripts: string[] = createNarrativeUnitFiles(
|
|
66
|
-
"scripts",
|
|
67
|
-
props.narrativeScope,
|
|
68
|
-
);
|
|
59
|
+
const treatments: string[] = createNarrativeUnitFiles({
|
|
60
|
+
layer: "treatments",
|
|
61
|
+
scope: props.narrativeScope,
|
|
62
|
+
});
|
|
63
|
+
const scripts: string[] = createNarrativeUnitFiles({
|
|
64
|
+
layer: "scripts",
|
|
65
|
+
scope: props.narrativeScope,
|
|
66
|
+
});
|
|
69
67
|
|
|
70
68
|
const parents: (symbol: "file" | "h2") => IEvidenceReference[] = (
|
|
71
69
|
symbol: "file" | "h2",
|
|
@@ -73,37 +71,40 @@ export function createLayerClaims(
|
|
|
73
71
|
props.mode !== "long"
|
|
74
72
|
? []
|
|
75
73
|
: [
|
|
76
|
-
|
|
77
|
-
|
|
74
|
+
// A screenplay scene file realizes one script scene, an H2 of its
|
|
75
|
+
// episode file; its sections have no one-to-one script parent.
|
|
76
|
+
...(layer === "screenplay" && symbol === "file"
|
|
77
|
+
? [createLineageReference(scripts, "h2")]
|
|
78
78
|
: []),
|
|
79
79
|
...(layer === "scripts" || layer === "screenplay"
|
|
80
|
-
? [createCoverageReference(treatments, symbol
|
|
80
|
+
? [createCoverageReference(treatments, symbol)]
|
|
81
81
|
: []),
|
|
82
82
|
];
|
|
83
83
|
|
|
84
|
-
const naturalness: IEvidenceReference[] = [
|
|
85
|
-
...createPrincipleReferences({
|
|
86
|
-
contracts: props,
|
|
87
|
-
layer,
|
|
88
|
-
gate: "naturalness",
|
|
89
|
-
}),
|
|
90
|
-
...createLanguagePrincipleReferences({
|
|
91
|
-
location: props.location,
|
|
92
|
-
layer,
|
|
93
|
-
gate: "naturalness",
|
|
94
|
-
}),
|
|
95
|
-
];
|
|
96
|
-
|
|
97
84
|
// Script expression must remain repairable in the same construction body.
|
|
98
85
|
const expression: IEvidenceReference[] =
|
|
99
|
-
layer === "scripts"
|
|
86
|
+
layer === "scripts"
|
|
87
|
+
? [
|
|
88
|
+
...createPrincipleReferences({
|
|
89
|
+
contracts: props,
|
|
90
|
+
layer,
|
|
91
|
+
family: "naturalness",
|
|
92
|
+
}),
|
|
93
|
+
...createLanguagePrincipleReferences({
|
|
94
|
+
location: props.location,
|
|
95
|
+
layer,
|
|
96
|
+
family: "naturalness",
|
|
97
|
+
}),
|
|
98
|
+
]
|
|
99
|
+
: [];
|
|
100
100
|
|
|
101
|
-
const inherits: string =
|
|
102
|
-
|
|
101
|
+
const inherits: string = isCanonLayer(layer)
|
|
102
|
+
? ""
|
|
103
|
+
: ", and account for the layers they inherit";
|
|
103
104
|
const unit: IEvidenceClaim = {
|
|
104
105
|
name: `${layer} H2 units answer their principle checklists${inherits}`,
|
|
105
106
|
type: "markdown",
|
|
106
|
-
root:
|
|
107
|
+
root: BODY_ROOT,
|
|
107
108
|
files: topology,
|
|
108
109
|
symbol: "h2",
|
|
109
110
|
disabled,
|
|
@@ -111,49 +112,19 @@ export function createLayerClaims(
|
|
|
111
112
|
...createPrincipleReferences({
|
|
112
113
|
contracts: props,
|
|
113
114
|
layer,
|
|
114
|
-
|
|
115
|
+
family: "principles",
|
|
115
116
|
}),
|
|
116
117
|
...createLanguagePrincipleReferences({
|
|
117
118
|
location: props.location,
|
|
118
119
|
layer,
|
|
119
|
-
|
|
120
|
+
family: "principles",
|
|
120
121
|
}),
|
|
121
122
|
...(isCanonLayer(layer) ? [] : [createUpstreamReference(props, layer)]),
|
|
122
123
|
...expression,
|
|
123
124
|
...parents("h2"),
|
|
124
125
|
],
|
|
125
126
|
};
|
|
126
|
-
|
|
127
|
-
// The revision snapshot is a reference, not another authored edition.
|
|
128
|
-
const second: ProductionStage = hasNaturalness(layer)
|
|
129
|
-
? props.naturalness.screenplay
|
|
130
|
-
: "disabled";
|
|
131
|
-
const surface: IEvidenceClaim[] = hasNaturalness(layer)
|
|
132
|
-
? [
|
|
133
|
-
{
|
|
134
|
-
name: `${layer} final files preserve their draft lineage for naturalness`,
|
|
135
|
-
type: "markdown",
|
|
136
|
-
root: passRoot("final"),
|
|
137
|
-
files,
|
|
138
|
-
symbol: "file",
|
|
139
|
-
disabled: second === "disabled",
|
|
140
|
-
reference: [createLineageReference(files, "file", "revision")],
|
|
141
|
-
},
|
|
142
|
-
{
|
|
143
|
-
name: `${layer} final H2 units answer their naturalness checklists`,
|
|
144
|
-
type: "markdown",
|
|
145
|
-
root: passRoot("final"),
|
|
146
|
-
files: topology,
|
|
147
|
-
symbol: "h2",
|
|
148
|
-
disabled: second === "disabled",
|
|
149
|
-
reference: [
|
|
150
|
-
createLineageReference(topology, "h2", "revision"),
|
|
151
|
-
...naturalness,
|
|
152
|
-
],
|
|
153
|
-
},
|
|
154
|
-
]
|
|
155
|
-
: [];
|
|
156
|
-
if (isCanonLayer(layer)) return [unit, ...surface];
|
|
127
|
+
if (isCanonLayer(layer)) return [unit];
|
|
157
128
|
|
|
158
129
|
const coverage: IEvidenceClaim | undefined =
|
|
159
130
|
layer === "treatments"
|
|
@@ -165,14 +136,13 @@ export function createLayerClaims(
|
|
|
165
136
|
{
|
|
166
137
|
name: `${layer} unit files account for the layers they inherit`,
|
|
167
138
|
type: "markdown",
|
|
168
|
-
root:
|
|
139
|
+
root: BODY_ROOT,
|
|
169
140
|
files,
|
|
170
141
|
symbol: "file",
|
|
171
142
|
disabled,
|
|
172
143
|
reference: parents("file"),
|
|
173
144
|
},
|
|
174
145
|
unit,
|
|
175
|
-
...surface,
|
|
176
146
|
...(coverage === undefined ? [] : [coverage]),
|
|
177
147
|
];
|
|
178
148
|
}
|
|
@@ -4,9 +4,9 @@ import path from "node:path";
|
|
|
4
4
|
|
|
5
5
|
import type { IProductionConfigProps } from "../../IProductionConfigProps";
|
|
6
6
|
import { createSharedReference } from "../references/createSharedReference";
|
|
7
|
+
import { BODY_ROOT } from "../utilities/BODY_ROOT";
|
|
7
8
|
import { createContractDirectory } from "../utilities/createContractDirectory";
|
|
8
9
|
import { createUnitFiles } from "../utilities/createUnitFiles";
|
|
9
|
-
import { passRoot } from "../utilities/passRoot";
|
|
10
10
|
import { validateSettingsOutline } from "../validateSettingsOutline";
|
|
11
11
|
|
|
12
12
|
/**
|
|
@@ -56,18 +56,18 @@ export function createOutlineClaims(
|
|
|
56
56
|
throw new Error("Settings outline contracts must be installed as a pair.");
|
|
57
57
|
|
|
58
58
|
if (principle === false) {
|
|
59
|
-
if (!fs.existsSync(path.join(props.location,
|
|
59
|
+
if (!fs.existsSync(path.join(props.location, BODY_ROOT, outline)))
|
|
60
60
|
return [];
|
|
61
61
|
return [
|
|
62
62
|
{
|
|
63
63
|
name: "each settings file belongs to exactly one part of the outline",
|
|
64
64
|
type: "markdown",
|
|
65
|
-
root:
|
|
65
|
+
root: BODY_ROOT,
|
|
66
66
|
files: createUnitFiles("settings", props.narrativeScope),
|
|
67
67
|
symbol: "file",
|
|
68
68
|
reference: {
|
|
69
69
|
type: "markdown",
|
|
70
|
-
root:
|
|
70
|
+
root: BODY_ROOT,
|
|
71
71
|
files: [outline],
|
|
72
72
|
symbol: "h2",
|
|
73
73
|
singleEvidencePerSymbol: true,
|
|
@@ -89,7 +89,7 @@ export function createOutlineClaims(
|
|
|
89
89
|
{
|
|
90
90
|
name: "settings outline parts answer their own principle checklist",
|
|
91
91
|
type: "markdown",
|
|
92
|
-
root:
|
|
92
|
+
root: BODY_ROOT,
|
|
93
93
|
files: [outline],
|
|
94
94
|
symbol: "h2",
|
|
95
95
|
disabled: outlineDisabled,
|
|
@@ -103,7 +103,7 @@ export function createOutlineClaims(
|
|
|
103
103
|
{
|
|
104
104
|
name: "settings outline answers each arrangement obligation once",
|
|
105
105
|
type: "markdown",
|
|
106
|
-
root:
|
|
106
|
+
root: BODY_ROOT,
|
|
107
107
|
files: [outline],
|
|
108
108
|
symbol: "file",
|
|
109
109
|
disabled: outlineDisabled,
|
|
@@ -120,13 +120,13 @@ export function createOutlineClaims(
|
|
|
120
120
|
{
|
|
121
121
|
name: "each settings file corresponds to exactly one outline entry",
|
|
122
122
|
type: "markdown",
|
|
123
|
-
root:
|
|
123
|
+
root: BODY_ROOT,
|
|
124
124
|
files: createUnitFiles("settings", props.narrativeScope),
|
|
125
125
|
symbol: "file",
|
|
126
126
|
disabled,
|
|
127
127
|
reference: {
|
|
128
128
|
type: "markdown",
|
|
129
|
-
root:
|
|
129
|
+
root: BODY_ROOT,
|
|
130
130
|
files: [outline],
|
|
131
131
|
symbol: "h3",
|
|
132
132
|
singleEvidencePerSymbol: true,
|
|
@@ -14,9 +14,9 @@ import { constructionStage } from "../constructionStage";
|
|
|
14
14
|
import { createLocalContractReference } from "../references/createLocalContractReference";
|
|
15
15
|
import { createSharedReference } from "../references/createSharedReference";
|
|
16
16
|
import { layerFiles } from "../references/layerFiles";
|
|
17
|
+
import { BODY_ROOT } from "../utilities/BODY_ROOT";
|
|
17
18
|
import { createContractDirectory } from "../utilities/createContractDirectory";
|
|
18
19
|
import { createUnitFiles } from "../utilities/createUnitFiles";
|
|
19
|
-
import { passRoot } from "../utilities/passRoot";
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* Creates the population obligation claims for a complete layer.
|
|
@@ -28,13 +28,13 @@ import { passRoot } from "../utilities/passRoot";
|
|
|
28
28
|
* repeating a population question on every unit turns one comparison into a
|
|
29
29
|
* restatement per unit.
|
|
30
30
|
*
|
|
31
|
-
* Unit duties use checklists.
|
|
32
|
-
* expression obligation claims rather than repeating their question per unit.
|
|
31
|
+
* Unit duties use checklists. Script expression population comparisons have
|
|
32
|
+
* separate expression obligation claims rather than repeating their question per unit.
|
|
33
33
|
*
|
|
34
34
|
* @evidence contracts/development/implementation.md#principled-implementation Construction stage controls whole-layer file-level obligation coverage, with one answering document per shared/language population item and no per-H2 repetition of the same comparison; createContractDirectory probes shared documents in the shared skills tree and language documents in the production's own `docs/contracts`.
|
|
35
35
|
* @evidence contracts/development/implementation.md#clear-and-simple-structure The exported factory delegates one family build while keeping population scope distinct from principle checklists and expression obligations.
|
|
36
36
|
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts Required shared common/narrative files stay selected even when missing so the compiler reports a broken tree; only realized and layer-specific optional documents are conditionally selected.
|
|
37
|
-
* @evidence contracts/development/common.md#meaningful-documentation The prose explains whole-layer respondents, unique evidence and the boundary with per-unit and
|
|
37
|
+
* @evidence contracts/development/common.md#meaningful-documentation The prose explains whole-layer respondents, unique evidence and the boundary with per-unit and script expression families; the helper comment identifies optional-file compatibility.
|
|
38
38
|
* @evidence contracts/development/implementation.md#efficient-algorithms At most four candidates per scope are filtered and mapped, with a bounded number of synchronous existence probes and selector constructions; this factory never scans the manuscript population.
|
|
39
39
|
* @evidence contracts/development/implementation.md#reuse-equivalent-work Shared/language selection reuses layerFiles and reference builders; optional installed files are observed per config build, so changes in the contract tree invalidate naturally without a retained cache.
|
|
40
40
|
* @evidence contracts/development/implementation.md#bound-retention-and-release-resources Intermediate and returned arrays have a fixed family bound; returned claim/reference objects belong to the config owner and existence probes retain no exposed handles.
|
|
@@ -110,7 +110,7 @@ function claim(props: {
|
|
|
110
110
|
return {
|
|
111
111
|
name: `${props.layer} documents answer each ${props.reference.files[0]} item once`,
|
|
112
112
|
type: "markdown",
|
|
113
|
-
root:
|
|
113
|
+
root: BODY_ROOT,
|
|
114
114
|
files: createUnitFiles(props.layer, props.scope),
|
|
115
115
|
symbol: "file",
|
|
116
116
|
disabled: props.disabled,
|