@techspokes/typescript-wsdl-client 1.1.5 → 1.2.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 +80 -68
- package/dist/app/generateApp.d.ts +0 -1
- package/dist/app/generateApp.js +1 -1
- package/dist/app/generateCheckedApp.d.ts +38 -0
- package/dist/app/generateCheckedApp.js +108 -0
- package/dist/checkedPipeline.d.ts +155 -0
- package/dist/checkedPipeline.js +448 -0
- package/dist/checkedPlanning.d.ts +123 -0
- package/dist/checkedPlanning.js +268 -0
- package/dist/cli.d.ts +0 -1
- package/dist/cli.js +92 -2
- package/dist/client/checkedDirectRuntime.d.ts +40 -3
- package/dist/client/checkedDirectRuntime.js +28 -8
- package/dist/client/directClientRuntime.d.ts +27 -2
- package/dist/client/directClientRuntime.js +142 -89
- package/dist/client/directClientVersion.d.ts +3 -1
- package/dist/client/directClientVersion.js +3 -0
- package/dist/client/generateClient.d.ts +0 -1
- package/dist/client/generateClient.js +98 -28
- package/dist/client/generateDirectClient.d.ts +21 -3
- package/dist/client/generateDirectClient.js +138 -6
- package/dist/client/generateOperations.d.ts +0 -1
- package/dist/client/generateOperations.js +30 -11
- package/dist/client/generateTypes.d.ts +0 -1
- package/dist/client/generateUtils.d.ts +0 -1
- package/dist/client/generateUtils.js +7 -1
- package/dist/compiler/applicationGroups.d.ts +53 -0
- package/dist/compiler/applicationGroups.js +403 -0
- package/dist/compiler/buildCanonicalGraph.d.ts +0 -1
- package/dist/compiler/canonicalGraph.d.ts +4 -16
- package/dist/compiler/canonicalGraph.js +1 -8
- package/dist/compiler/catalogErrors.d.ts +0 -1
- package/dist/compiler/catalogProvenance.d.ts +0 -1
- package/dist/compiler/checkedAssessment.d.ts +0 -1
- package/dist/compiler/checkedAssessment.js +1 -1
- package/dist/compiler/checkedComponentSource.d.ts +16 -0
- package/dist/compiler/checkedComponentSource.js +31 -0
- package/dist/compiler/checkedSourcePreparation.d.ts +38 -1
- package/dist/compiler/checkedSourcePreparation.js +71 -0
- package/dist/compiler/complexTypeContent.d.ts +5 -6
- package/dist/compiler/complexTypeContent.js +2 -2
- package/dist/compiler/componentCorrespondence.d.ts +32 -0
- package/dist/compiler/componentCorrespondence.js +140 -0
- package/dist/compiler/componentRecordProjection.d.ts +112 -0
- package/dist/compiler/componentRecordProjection.js +329 -0
- package/dist/compiler/componentSoapPreparation.d.ts +20 -0
- package/dist/compiler/componentSoapPreparation.js +36 -0
- package/dist/compiler/composeCanonicalGraph.d.ts +0 -1
- package/dist/compiler/dataOwnership.d.ts +0 -1
- package/dist/compiler/dataOwnership.js +14 -4
- package/dist/compiler/datatypeValues.d.ts +0 -1
- package/dist/compiler/declarationIdentity.d.ts +22 -0
- package/dist/compiler/declarationIdentity.js +9 -0
- package/dist/compiler/directCodec.d.ts +79 -2
- package/dist/compiler/directCodec.js +310 -92
- package/dist/compiler/directExecutionPolicy.d.ts +0 -1
- package/dist/compiler/directOperation.d.ts +72 -8
- package/dist/compiler/directOperation.js +164 -19
- package/dist/compiler/directSoap.d.ts +29 -5
- package/dist/compiler/directSoap.js +154 -44
- package/dist/compiler/directSoapSource.d.ts +24 -1
- package/dist/compiler/directSoapSource.js +166 -19
- package/dist/compiler/directSourceCapsule.d.ts +74 -2
- package/dist/compiler/directSourceCapsule.js +484 -6
- package/dist/compiler/directStructure.d.ts +83 -6
- package/dist/compiler/directStructure.js +353 -58
- package/dist/compiler/directStructurePlan.d.ts +144 -2
- package/dist/compiler/directStructurePlan.js +615 -30
- package/dist/compiler/directValues.d.ts +76 -5
- package/dist/compiler/directValues.js +967 -117
- package/dist/compiler/finiteRe01Construction.d.ts +69 -0
- package/dist/compiler/finiteRe01Construction.js +422 -0
- package/dist/compiler/finiteRe01Verification.d.ts +81 -3
- package/dist/compiler/finiteRe01Verification.js +391 -4
- package/dist/compiler/generateCatalog.d.ts +0 -1
- package/dist/compiler/graphTraversal.d.ts +0 -1
- package/dist/compiler/hypotheticalScopedIdentity.d.ts +0 -1
- package/dist/compiler/legacyDeclarations.d.ts +26 -0
- package/dist/compiler/legacyDeclarations.js +144 -0
- package/dist/compiler/occurrenceAnalysis.d.ts +2 -1
- package/dist/compiler/occurrenceAnalysis.js +23 -7
- package/dist/compiler/originalSourceMembership.d.ts +0 -1
- package/dist/compiler/particleAttribution.d.ts +0 -1
- package/dist/compiler/particleAttribution.js +20 -0
- package/dist/compiler/particleDeclarationConsistency.d.ts +0 -1
- package/dist/compiler/particleDeclarationConsistency.js +9 -0
- package/dist/compiler/particleExtension.d.ts +0 -1
- package/dist/compiler/particleExtension.js +5 -1
- package/dist/compiler/particleLocalAssessment.d.ts +0 -1
- package/dist/compiler/particleRestriction.d.ts +0 -1
- package/dist/compiler/particleRestriction.js +6 -1
- package/dist/compiler/particleSemanticView.d.ts +2 -1
- package/dist/compiler/particleSemanticView.js +16 -3
- package/dist/compiler/particleWildcardRelation.d.ts +0 -1
- package/dist/compiler/projectionScalar.d.ts +49 -0
- package/dist/compiler/projectionScalar.js +218 -0
- package/dist/compiler/re01CandidateAssignments.d.ts +95 -0
- package/dist/compiler/re01CandidateAssignments.js +341 -0
- package/dist/compiler/re01CandidateCorrespondence.d.ts +22 -1
- package/dist/compiler/re01CandidateCorrespondence.js +167 -38
- package/dist/compiler/re01TypeProperties.d.ts +0 -1
- package/dist/compiler/re01TypePropertyValidation.d.ts +0 -1
- package/dist/compiler/resolveCanonicalGraph.d.ts +5 -2
- package/dist/compiler/resolveCanonicalGraph.js +77 -7
- package/dist/compiler/rpcStringValues.d.ts +30 -0
- package/dist/compiler/rpcStringValues.js +196 -0
- package/dist/compiler/rpcTypedValues.d.ts +48 -0
- package/dist/compiler/rpcTypedValues.js +190 -0
- package/dist/compiler/scalarSchemaAssessment.d.ts +0 -1
- package/dist/compiler/schemaAttributeGroupProperties.d.ts +0 -1
- package/dist/compiler/schemaAttributeProperties.d.ts +0 -1
- package/dist/compiler/schemaAttributeUses.d.ts +22 -2
- package/dist/compiler/schemaAttributeUses.js +86 -13
- package/dist/compiler/schemaBinaryWordReconstruction.d.ts +0 -1
- package/dist/compiler/schemaBuiltinFacets.d.ts +0 -1
- package/dist/compiler/schemaCalendarImages.d.ts +0 -1
- package/dist/compiler/schemaCalendarLanguage.d.ts +0 -1
- package/dist/compiler/schemaCompiler.d.ts +0 -1
- package/dist/compiler/schemaCompiler.js +44 -109
- package/dist/compiler/schemaComponentEquality.d.ts +0 -1
- package/dist/compiler/schemaConstructionAssessment.d.ts +34 -1
- package/dist/compiler/schemaConstructionAssessment.js +88 -6
- package/dist/compiler/schemaDatatypeValues.d.ts +0 -1
- package/dist/compiler/schemaDecimalLanguage.d.ts +0 -1
- package/dist/compiler/schemaDeclarationPrimitives.d.ts +7 -2
- package/dist/compiler/schemaDeclarationPrimitives.js +18 -1
- package/dist/compiler/schemaDocumentSyntax.d.ts +0 -1
- package/dist/compiler/schemaDurationLanguage.d.ts +0 -1
- package/dist/compiler/schemaElementInstance.d.ts +30 -0
- package/dist/compiler/schemaElementInstance.js +45 -0
- package/dist/compiler/schemaElementProperties.d.ts +0 -1
- package/dist/compiler/schemaEndpointWordCapacity.d.ts +0 -1
- package/dist/compiler/schemaExactCalendar.d.ts +0 -1
- package/dist/compiler/schemaFacetAnnotation.d.ts +0 -1
- package/dist/compiler/schemaGeneratedScalarShape.d.ts +0 -1
- package/dist/compiler/schemaGeneratedScalarShape.js +2 -0
- package/dist/compiler/schemaIdentityConstraints.d.ts +0 -1
- package/dist/compiler/schemaIeeeLanguage.d.ts +0 -1
- package/dist/compiler/schemaIntegerImages.d.ts +0 -1
- package/dist/compiler/schemaLexicalPredicates.d.ts +0 -1
- package/dist/compiler/schemaNotationProperties.d.ts +0 -1
- package/dist/compiler/schemaNumericImageConditions.d.ts +0 -1
- package/dist/compiler/schemaParticleWildcardProperties.d.ts +0 -1
- package/dist/compiler/schemaPattern.d.ts +0 -1
- package/dist/compiler/schemaRegularLanguage.d.ts +0 -1
- package/dist/compiler/schemaScalarContext.d.ts +5 -1
- package/dist/compiler/schemaScalarKernel.d.ts +0 -1
- package/dist/compiler/schemaScalarWitnesses.d.ts +0 -1
- package/dist/compiler/schemaSimpleTypeProperties.d.ts +0 -1
- package/dist/compiler/schemaSourceGrammar.d.ts +0 -1
- package/dist/compiler/schemaSourceLexical.d.ts +0 -1
- package/dist/compiler/schemaSourceValues.d.ts +0 -1
- package/dist/compiler/schemaSourceWildcards.d.ts +1 -2
- package/dist/compiler/schemaSourceWildcards.js +3 -1
- package/dist/compiler/schemaSymbolicSequences.d.ts +0 -1
- package/dist/compiler/schemaSymbolicValueSets.d.ts +0 -1
- package/dist/compiler/schemaSyntaxAssessment.d.ts +0 -1
- package/dist/compiler/schemaTemporalAliases.d.ts +0 -1
- package/dist/compiler/schemaTokenImages.d.ts +0 -1
- package/dist/compiler/schemaTypeIdentity.d.ts +0 -1
- package/dist/compiler/schemaTypeIdentity.js +2 -0
- package/dist/compiler/schemaTypeRelations.d.ts +0 -1
- package/dist/compiler/schemaUri.d.ts +0 -1
- package/dist/compiler/schemaValueContext.d.ts +0 -1
- package/dist/compiler/schemaValueImages.d.ts +0 -1
- package/dist/compiler/schemaValueSequences.d.ts +0 -1
- package/dist/compiler/semanticBudget.d.ts +18 -1
- package/dist/compiler/semanticBudget.js +17 -2
- package/dist/compiler/semanticCatalog.d.ts +2 -3
- package/dist/compiler/semanticContext.d.ts +12 -1
- package/dist/compiler/semanticContext.js +39 -0
- package/dist/compiler/semanticTypeDependencies.d.ts +0 -1
- package/dist/compiler/semanticTypeReference.d.ts +0 -1
- package/dist/compiler/shapeResolver.d.ts +0 -1
- package/dist/compiler/soapHeaders.d.ts +16 -0
- package/dist/compiler/soapHeaders.js +42 -0
- package/dist/compiler/sourceSchemaBinding.d.ts +0 -1
- package/dist/compiler/standardSchemaComponents.d.ts +71 -0
- package/dist/compiler/standardSchemaComponents.js +74 -0
- package/dist/compiler/standardSchemaConstruction.d.ts +20 -0
- package/dist/compiler/standardSchemaConstruction.js +34 -0
- package/dist/compiler/structuralCompanions.d.ts +0 -1
- package/dist/compiler/validateSemanticGraph.d.ts +0 -1
- package/dist/compiler/wildcardAlgebra.d.ts +0 -1
- package/dist/compiler/wsdlPolicyRequirements.d.ts +43 -0
- package/dist/compiler/wsdlPolicyRequirements.js +239 -0
- package/dist/config.d.ts +0 -1
- package/dist/gateway/generateCheckedGateway.d.ts +32 -0
- package/dist/gateway/generateCheckedGateway.js +293 -0
- package/dist/gateway/generateComposedGateway.d.ts +16 -0
- package/dist/gateway/generateComposedGateway.js +65 -0
- package/dist/gateway/generateGateway.d.ts +0 -1
- package/dist/gateway/generateGateway.js +1 -0
- package/dist/gateway/generators.d.ts +0 -1
- package/dist/gateway/generators.js +19 -4
- package/dist/gateway/helpers.d.ts +1 -1
- package/dist/gateway/helpers.js +15 -0
- package/dist/generation/componentShape.d.ts +14 -0
- package/dist/generation/componentShape.js +293 -0
- package/dist/generation/preamble.d.ts +0 -1
- package/dist/generation/sourceLayout.d.ts +13 -0
- package/dist/generation/sourceLayout.js +40 -0
- package/dist/generation/writeGeneratedSource.d.ts +0 -1
- package/dist/index.d.ts +11 -2
- package/dist/index.js +4 -1
- package/dist/loader/fetch.d.ts +0 -1
- package/dist/loader/orderedSyntax.d.ts +12 -1
- package/dist/loader/orderedSyntax.js +40 -6
- package/dist/loader/resolutionDepth.d.ts +0 -1
- package/dist/loader/schemaInput.d.ts +28 -1
- package/dist/loader/schemaInput.js +41 -4
- package/dist/loader/schemaResources.d.ts +2 -1
- package/dist/loader/schemaResources.js +45 -4
- package/dist/loader/wsdlLoader.d.ts +0 -1
- package/dist/multiServicePipeline.d.ts +41 -0
- package/dist/multiServicePipeline.js +287 -0
- package/dist/openapi/casing.d.ts +0 -1
- package/dist/openapi/composeOpenAPI.d.ts +29 -0
- package/dist/openapi/composeOpenAPI.js +322 -0
- package/dist/openapi/generateOpenAPI.d.ts +0 -1
- package/dist/openapi/generatePaths.d.ts +0 -1
- package/dist/openapi/generateSchemas.d.ts +0 -1
- package/dist/openapi/security.d.ts +0 -1
- package/dist/pipeline.d.ts +7 -3
- package/dist/pipeline.js +15 -0
- package/dist/test/generateCheckedTests.d.ts +17 -0
- package/dist/test/generateCheckedTests.js +60 -0
- package/dist/test/generateTests.d.ts +0 -1
- package/dist/test/generators.d.ts +0 -1
- package/dist/test/mockData.d.ts +0 -1
- package/dist/test/mockData.js +20 -14
- package/dist/util/attributeWildcards.d.ts +0 -1
- package/dist/util/builder.d.ts +0 -1
- package/dist/util/catalogMeta.d.ts +0 -1
- package/dist/util/checkedCliDiagnostics.d.ts +11 -0
- package/dist/util/checkedCliDiagnostics.js +22 -0
- package/dist/util/cli.d.ts +0 -1
- package/dist/util/errors.d.ts +0 -1
- package/dist/util/imports.d.ts +0 -1
- package/dist/util/runtimeSource.d.ts +0 -1
- package/dist/util/runtimeSource.js +3 -5
- package/dist/util/securityConfig.d.ts +0 -1
- package/dist/util/streamConfig.d.ts +0 -1
- package/dist/util/tools.d.ts +0 -1
- package/dist/util/xmlWhitespace.d.ts +0 -1
- package/dist/xsd/primitives.d.ts +0 -1
- package/docs/agent-skill.md +12 -1
- package/docs/api-reference.md +127 -9
- package/docs/checked-gateway.md +212 -0
- package/docs/checked-generation.md +167 -0
- package/docs/cli-reference.md +48 -6
- package/docs/concepts.md +139 -5
- package/docs/configuration.md +15 -4
- package/docs/corpus.md +33 -0
- package/docs/direct-values.md +13 -13
- package/docs/examples/checked-forecast.wsdl +19 -0
- package/docs/gateway-guide.md +104 -27
- package/docs/generated-code.md +22 -11
- package/docs/mapping-contract.md +114 -0
- package/docs/migration-playbook.md +5 -1
- package/docs/migration.md +124 -6
- package/docs/output-anatomy.md +21 -18
- package/docs/production.md +7 -5
- package/docs/start-here.md +19 -3
- package/docs/supported-patterns.md +24 -3
- package/docs/testing.md +119 -31
- package/docs/troubleshooting.md +3 -1
- package/llms.txt +16 -8
- package/package.json +64 -23
- package/src/runtime/checkedGatewayHost.tpl.txt +157 -0
- package/src/runtime/clientStreamMethods.tpl.txt +156 -148
- package/src/runtime/operationsStreamHelper.tpl.txt +6 -6
- package/src/runtime/streamXml.ts +49 -21
- package/dist/app/generateApp.d.ts.map +0 -1
- package/dist/cli.d.ts.map +0 -1
- package/dist/client/checkedDirectRuntime.d.ts.map +0 -1
- package/dist/client/directClientRuntime.d.ts.map +0 -1
- package/dist/client/directClientVersion.d.ts.map +0 -1
- package/dist/client/generateClient.d.ts.map +0 -1
- package/dist/client/generateDirectClient.d.ts.map +0 -1
- package/dist/client/generateOperations.d.ts.map +0 -1
- package/dist/client/generateTypes.d.ts.map +0 -1
- package/dist/client/generateUtils.d.ts.map +0 -1
- package/dist/compiler/buildCanonicalGraph.d.ts.map +0 -1
- package/dist/compiler/canonicalGraph.d.ts.map +0 -1
- package/dist/compiler/catalogErrors.d.ts.map +0 -1
- package/dist/compiler/catalogProvenance.d.ts.map +0 -1
- package/dist/compiler/checkedAssessment.d.ts.map +0 -1
- package/dist/compiler/checkedSourcePreparation.d.ts.map +0 -1
- package/dist/compiler/complexTypeContent.d.ts.map +0 -1
- package/dist/compiler/composeCanonicalGraph.d.ts.map +0 -1
- package/dist/compiler/dataOwnership.d.ts.map +0 -1
- package/dist/compiler/datatypeValues.d.ts.map +0 -1
- package/dist/compiler/directCodec.d.ts.map +0 -1
- package/dist/compiler/directExecutionPolicy.d.ts.map +0 -1
- package/dist/compiler/directOperation.d.ts.map +0 -1
- package/dist/compiler/directSoap.d.ts.map +0 -1
- package/dist/compiler/directSoapSource.d.ts.map +0 -1
- package/dist/compiler/directSourceCapsule.d.ts.map +0 -1
- package/dist/compiler/directStructure.d.ts.map +0 -1
- package/dist/compiler/directStructurePlan.d.ts.map +0 -1
- package/dist/compiler/directValues.d.ts.map +0 -1
- package/dist/compiler/finiteRe01Verification.d.ts.map +0 -1
- package/dist/compiler/generateCatalog.d.ts.map +0 -1
- package/dist/compiler/graphTraversal.d.ts.map +0 -1
- package/dist/compiler/hypotheticalScopedIdentity.d.ts.map +0 -1
- package/dist/compiler/occurrenceAnalysis.d.ts.map +0 -1
- package/dist/compiler/originalSourceMembership.d.ts.map +0 -1
- package/dist/compiler/particleAttribution.d.ts.map +0 -1
- package/dist/compiler/particleDeclarationConsistency.d.ts.map +0 -1
- package/dist/compiler/particleExtension.d.ts.map +0 -1
- package/dist/compiler/particleLocalAssessment.d.ts.map +0 -1
- package/dist/compiler/particleRestriction.d.ts.map +0 -1
- package/dist/compiler/particleSemanticView.d.ts.map +0 -1
- package/dist/compiler/particleWildcardRelation.d.ts.map +0 -1
- package/dist/compiler/re01CandidateCorrespondence.d.ts.map +0 -1
- package/dist/compiler/re01TypeProperties.d.ts.map +0 -1
- package/dist/compiler/re01TypePropertyValidation.d.ts.map +0 -1
- package/dist/compiler/resolveCanonicalGraph.d.ts.map +0 -1
- package/dist/compiler/scalarSchemaAssessment.d.ts.map +0 -1
- package/dist/compiler/schemaAttributeGroupProperties.d.ts.map +0 -1
- package/dist/compiler/schemaAttributeProperties.d.ts.map +0 -1
- package/dist/compiler/schemaAttributeUses.d.ts.map +0 -1
- package/dist/compiler/schemaBinaryWordReconstruction.d.ts.map +0 -1
- package/dist/compiler/schemaBuiltinFacets.d.ts.map +0 -1
- package/dist/compiler/schemaCalendarImages.d.ts.map +0 -1
- package/dist/compiler/schemaCalendarLanguage.d.ts.map +0 -1
- package/dist/compiler/schemaCompiler.d.ts.map +0 -1
- package/dist/compiler/schemaComponentEquality.d.ts.map +0 -1
- package/dist/compiler/schemaConstructionAssessment.d.ts.map +0 -1
- package/dist/compiler/schemaDatatypeValues.d.ts.map +0 -1
- package/dist/compiler/schemaDecimalLanguage.d.ts.map +0 -1
- package/dist/compiler/schemaDeclarationPrimitives.d.ts.map +0 -1
- package/dist/compiler/schemaDocumentSyntax.d.ts.map +0 -1
- package/dist/compiler/schemaDurationLanguage.d.ts.map +0 -1
- package/dist/compiler/schemaElementProperties.d.ts.map +0 -1
- package/dist/compiler/schemaEndpointWordCapacity.d.ts.map +0 -1
- package/dist/compiler/schemaExactCalendar.d.ts.map +0 -1
- package/dist/compiler/schemaFacetAnnotation.d.ts.map +0 -1
- package/dist/compiler/schemaGeneratedScalarShape.d.ts.map +0 -1
- package/dist/compiler/schemaIdentityConstraints.d.ts.map +0 -1
- package/dist/compiler/schemaIeeeLanguage.d.ts.map +0 -1
- package/dist/compiler/schemaIntegerImages.d.ts.map +0 -1
- package/dist/compiler/schemaLexicalPredicates.d.ts.map +0 -1
- package/dist/compiler/schemaNotationProperties.d.ts.map +0 -1
- package/dist/compiler/schemaNumericImageConditions.d.ts.map +0 -1
- package/dist/compiler/schemaParticleWildcardProperties.d.ts.map +0 -1
- package/dist/compiler/schemaPattern.d.ts.map +0 -1
- package/dist/compiler/schemaRegularLanguage.d.ts.map +0 -1
- package/dist/compiler/schemaScalarContext.d.ts.map +0 -1
- package/dist/compiler/schemaScalarKernel.d.ts.map +0 -1
- package/dist/compiler/schemaScalarWitnesses.d.ts.map +0 -1
- package/dist/compiler/schemaSimpleTypeProperties.d.ts.map +0 -1
- package/dist/compiler/schemaSourceGrammar.d.ts.map +0 -1
- package/dist/compiler/schemaSourceLexical.d.ts.map +0 -1
- package/dist/compiler/schemaSourceValues.d.ts.map +0 -1
- package/dist/compiler/schemaSourceWildcards.d.ts.map +0 -1
- package/dist/compiler/schemaSymbolicSequences.d.ts.map +0 -1
- package/dist/compiler/schemaSymbolicValueSets.d.ts.map +0 -1
- package/dist/compiler/schemaSyntaxAssessment.d.ts.map +0 -1
- package/dist/compiler/schemaTemporalAliases.d.ts.map +0 -1
- package/dist/compiler/schemaTokenImages.d.ts.map +0 -1
- package/dist/compiler/schemaTypeIdentity.d.ts.map +0 -1
- package/dist/compiler/schemaTypeRelations.d.ts.map +0 -1
- package/dist/compiler/schemaUri.d.ts.map +0 -1
- package/dist/compiler/schemaValueContext.d.ts.map +0 -1
- package/dist/compiler/schemaValueImages.d.ts.map +0 -1
- package/dist/compiler/schemaValueSequences.d.ts.map +0 -1
- package/dist/compiler/semanticBudget.d.ts.map +0 -1
- package/dist/compiler/semanticCatalog.d.ts.map +0 -1
- package/dist/compiler/semanticContext.d.ts.map +0 -1
- package/dist/compiler/semanticTypeDependencies.d.ts.map +0 -1
- package/dist/compiler/semanticTypeReference.d.ts.map +0 -1
- package/dist/compiler/shapeResolver.d.ts.map +0 -1
- package/dist/compiler/sourceSchemaBinding.d.ts.map +0 -1
- package/dist/compiler/structuralCompanions.d.ts.map +0 -1
- package/dist/compiler/validateSemanticGraph.d.ts.map +0 -1
- package/dist/compiler/wildcardAlgebra.d.ts.map +0 -1
- package/dist/config.d.ts.map +0 -1
- package/dist/gateway/generateGateway.d.ts.map +0 -1
- package/dist/gateway/generators.d.ts.map +0 -1
- package/dist/gateway/helpers.d.ts.map +0 -1
- package/dist/generation/preamble.d.ts.map +0 -1
- package/dist/generation/writeGeneratedSource.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/loader/fetch.d.ts.map +0 -1
- package/dist/loader/orderedSyntax.d.ts.map +0 -1
- package/dist/loader/resolutionDepth.d.ts.map +0 -1
- package/dist/loader/schemaInput.d.ts.map +0 -1
- package/dist/loader/schemaResources.d.ts.map +0 -1
- package/dist/loader/wsdlLoader.d.ts.map +0 -1
- package/dist/openapi/casing.d.ts.map +0 -1
- package/dist/openapi/generateOpenAPI.d.ts.map +0 -1
- package/dist/openapi/generatePaths.d.ts.map +0 -1
- package/dist/openapi/generateSchemas.d.ts.map +0 -1
- package/dist/openapi/security.d.ts.map +0 -1
- package/dist/pipeline.d.ts.map +0 -1
- package/dist/runtime/jsonArray.d.ts +0 -24
- package/dist/runtime/jsonArray.d.ts.map +0 -1
- package/dist/runtime/jsonArray.js +0 -52
- package/dist/runtime/ndjson.d.ts +0 -24
- package/dist/runtime/ndjson.d.ts.map +0 -1
- package/dist/runtime/ndjson.js +0 -30
- package/dist/runtime/streamXml.d.ts +0 -45
- package/dist/runtime/streamXml.d.ts.map +0 -1
- package/dist/runtime/streamXml.js +0 -212
- package/dist/test/generateTests.d.ts.map +0 -1
- package/dist/test/generators.d.ts.map +0 -1
- package/dist/test/mockData.d.ts.map +0 -1
- package/dist/util/attributeWildcards.d.ts.map +0 -1
- package/dist/util/builder.d.ts.map +0 -1
- package/dist/util/catalogMeta.d.ts.map +0 -1
- package/dist/util/cli.d.ts.map +0 -1
- package/dist/util/errors.d.ts.map +0 -1
- package/dist/util/imports.d.ts.map +0 -1
- package/dist/util/runtimeSource.d.ts.map +0 -1
- package/dist/util/securityConfig.d.ts.map +0 -1
- package/dist/util/streamConfig.d.ts.map +0 -1
- package/dist/util/tools.d.ts.map +0 -1
- package/dist/util/xmlWhitespace.d.ts.map +0 -1
- package/dist/xsd/primitives.d.ts.map +0 -1
- package/docs/AGENTS.md +0 -47
- package/docs/README.md +0 -69
- package/docs/architecture.md +0 -158
- package/docs/content-model-analysis.md +0 -92
- package/docs/content-model-baseline.md +0 -121
- package/docs/content-model-catalog.md +0 -116
- package/docs/content-model-companions.md +0 -90
- package/docs/content-model-composition.md +0 -103
- package/docs/content-model-decisions.md +0 -79
- package/docs/content-model-gateway-feasibility.md +0 -169
- package/docs/content-model-graph.md +0 -121
- package/docs/content-model-loading.md +0 -163
- package/docs/content-model-matching.md +0 -85
- package/docs/content-model-readiness.md +0 -144
- package/docs/content-model-resolution.md +0 -81
- package/docs/content-model-s02-handoff.md +0 -98
- package/docs/content-model-s06-au-01.md +0 -425
- package/docs/content-model-s06-dt-01.md +0 -386
- package/docs/content-model-s06-pw-01.md +0 -350
- package/docs/content-model-s06-re-01-resolver-implementation.md +0 -869
- package/docs/content-model-s06-re-01-resolver.md +0 -513
- package/docs/content-model-s06-re-01-scalar-witnesses.md +0 -1423
- package/docs/content-model-s06-re-01-support-reconstruction.md +0 -6337
- package/docs/content-model-s06-re-01.md +0 -7477
- package/docs/content-model-s06-research-handoff.md +0 -909
- package/docs/content-model-shipped-fix.md +0 -83
- package/docs/content-model-soap-feasibility.md +0 -165
- package/docs/decisions/001-test-generation.md +0 -36
- package/docs/decisions/002-streamable-responses.md +0 -332
- package/docs/decisions/003-content-model-contracts.md +0 -280
- package/docs/file-naming-and-path-organization.md +0 -213
- package/docs/reference-validation.md +0 -243
- package/docs/releases/README.md +0 -94
- package/docs/releases/v0.20.0.md +0 -22
- package/docs/releases/v0.21.0.md +0 -30
- package/docs/releases/v0.22.0.md +0 -30
- package/docs/releases/v0.23.0.md +0 -31
- package/docs/releases/v0.24.0.md +0 -38
- package/docs/releases/v0.25.0.md +0 -31
- package/docs/releases/v0.25.2.md +0 -32
- package/docs/releases/v0.26.0.md +0 -32
- package/docs/releases/v0.27.0.md +0 -31
- package/docs/releases/v0.28.0.md +0 -32
- package/docs/releases/v0.29.0.md +0 -32
- package/docs/releases/v0.30.0.md +0 -30
- package/docs/releases/v0.30.1.md +0 -31
- package/docs/releases/v0.30.2.md +0 -30
- package/docs/releases/v0.30.3.md +0 -33
- package/docs/releases/v0.31.0.md +0 -33
- package/docs/releases/v0.32.0.md +0 -33
- package/docs/releases/v0.33.0.md +0 -34
- package/docs/releases/v0.34.0.md +0 -30
- package/docs/releases/v0.35.0.md +0 -33
- package/docs/releases/v0.36.0.md +0 -32
- package/docs/releases/v0.37.0.md +0 -33
- package/docs/releases/v0.38.0.md +0 -35
- package/docs/releases/v0.39.0.md +0 -35
- package/docs/releases/v0.40.0.md +0 -45
- package/docs/releases/v0.40.1.md +0 -34
- package/docs/releases/v1.0.0.md +0 -42
- package/docs/releases/v1.0.1.md +0 -38
- package/docs/releases/v1.0.2.md +0 -51
- package/docs/releases/v1.0.3.md +0 -37
- package/docs/releases/v1.0.4.md +0 -45
- package/docs/releases/v1.0.5.md +0 -41
- package/docs/releases/v1.0.6.md +0 -35
- package/docs/releases/v1.0.7.md +0 -36
- package/docs/releases/v1.1.0.md +0 -42
- package/docs/releases/v1.1.1.md +0 -44
- package/docs/releases/v1.1.2.md +0 -42
- package/docs/releases/v1.1.3.md +0 -36
- package/docs/releases/v1.1.4.md +0 -36
- package/docs/releases/v1.1.5.md +0 -38
- package/docs/roadmap/README.md +0 -107
- package/docs/roadmap/v1.0-capability-conformance-framework.md +0 -582
- package/docs/roadmap/v1.0-choice-union-mode.md +0 -90
- package/docs/roadmap/v1.0-contract-audit.md +0 -75
- package/docs/roadmap/v1.0-json-array-streaming.md +0 -101
- package/docs/roadmap/v1.0-openapi-fastify-compatibility.md +0 -99
- package/docs/roadmap/v1.0-release-candidate-gates.md +0 -92
- package/docs/roadmap/v1.0-wsdl-coverage-matrix.md +0 -200
- package/docs/roadmap/v1.0-xs-anyattribute-wildcard-bag.md +0 -932
- package/src/runtime/jsonArray.ts +0 -55
- package/src/runtime/ndjson.ts +0 -32
|
@@ -1,513 +0,0 @@
|
|
|
1
|
-
# S06 RE01 Hypothetical Resolver Specification
|
|
2
|
-
|
|
3
|
-
One candidate's component resolution, comparison boundary and research implementation plan. See the root [README](../README.md).
|
|
4
|
-
|
|
5
|
-
## Purpose and boundaries
|
|
6
|
-
|
|
7
|
-
The [current RE01 addendum](https://github.com/TechSpokes/typescript-wsdl-client/issues/234#issuecomment-6110178846) supersedes this historical resolver's global replacement policy as a necessary characterization of every derivability witness.
|
|
8
|
-
The [derivability continuation](content-model-s06-re-01.md#derivability-and-affiliation-continuation) preserves immutable actual Γ and investigates the separate hypothetical judgment with justified predicate dependencies.
|
|
9
|
-
Historical D1/E2 and literal whole-schema tests retain their original scope; structural preparation does not certify either full model.
|
|
10
|
-
|
|
11
|
-
This is the authoritative specification and issue-ready task plan for [#256](https://github.com/TechSpokes/typescript-wsdl-client/issues/256), supporting [RE01/#234](content-model-s06-re-01.md) within [#232](content-model-s06-research-handoff.md). The caller is the subsequent RE01 research candidate checker. It supplies one explicit two-step construction; this resolver never generates or searches candidates.
|
|
12
|
-
|
|
13
|
-
The selected research model is abstract component construction plans with a separate hypothetical context, the RE01 record's D1/E2 recommendation. A context contains an explicit component schema over immutable actual inputs. Reused components keep their identities, while every reference query, including a query through an unchanged component, uses its caller's declared context.
|
|
14
|
-
|
|
15
|
-
Preparation certifies structural consistency and a closed reference universe only. Resolution certifies the target of one declared reference only. Endpoint correspondence certifies the supplied correspondence over its declared projection only; none of these successes certifies complete candidate legality, payload validity or existence of any other witness.
|
|
16
|
-
|
|
17
|
-
The input precondition is a finite, immutable, resolved actual graph with source-level operands retained. Actual schema assessment, normalized restriction views and complete semantic predicates are separate inputs, each with a named authority and scope. Missing semantic authority returns `unresolved` at the checking boundary, rather than a successful legality claim.
|
|
18
|
-
|
|
19
|
-
The production entry remains [`prepareResolvedCompilationInput`](../src/compiler/semanticCatalog.ts), not a new loader or catalog format. Research execution uses independently prepared records and must not import `src/` or the unaccepted #231 assessment modules. No public result, profile, catalog, legacy default, occurrence algorithm or scalar engine changes in this specification.
|
|
20
|
-
|
|
21
|
-
### Verified inputs and primary authority
|
|
22
|
-
|
|
23
|
-
The verified base is #255 head `60937e4cfd5617eb39fcf49247e2e5c417790064`, tree `6c7c0a66cbbe1bc2baf0992c723a5fbef9591758`. At entry, main is `f4e39e819f2d9aa264cfdd14d16154c6443c9bac`; #254 remains open at `ddd90663aa88670edcca4371f7a142d94a5d36da` and #255 remains draft/unmerged. The specification branch targets `codex/research-232-continuation`; parent delivery is a merge dependency, not a resolver blocker.
|
|
24
|
-
|
|
25
|
-
The [dated 28 October 2004 structures source](https://github.com/jacoelho/xsd/blob/142f25ee187e17f041af87b6bfcfc82385254520/docs/spec/xml/structures.xml) was read with deleted editorial text excluded. Its SHA-256 is `e496af408b14853e6169ac7c1fca09d55a81bd73771758ad6be020960e1317ba`. Component construction is permitted by [conformance](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#concepts-conformance), but [schema validity](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#conformance-schemaValidity) still requires all relevant component constraints recursively.
|
|
26
|
-
|
|
27
|
-
The accepted sibling inputs are [AU01 C1 with universal source-replacement matching](content-model-s06-au-01.md), [PW01 R-240 v1](content-model-s06-pw-01.md) and [DT01 A v1](content-model-s06-dt-01.md). Their exact artifact hashes are pinned in the [S06 manifest](../test/conformance/s06-research-manifest.json). Invoke them only for the obligations described below; accepting these inputs does not settle RE01's complete theorem.
|
|
28
|
-
|
|
29
|
-
## Identity and context model
|
|
30
|
-
|
|
31
|
-
### Actual and proposed identity
|
|
32
|
-
|
|
33
|
-
An actual component ID is the immutable canonical ID, including symbol role, expanded QName, original local owner/path and chameleon/import interpretation. Equality is identity equality, never structural equality, a generated TypeScript name or a lexical QName spelling. Builtins occupy a separate immutable namespace keyed by XSD namespace and admitted builtin local name.
|
|
34
|
-
|
|
35
|
-
New components use candidate-local IDs disjoint from every actual and builtin ID. A fresh intermediate has a fresh identity even if its component properties equal original named `T`; it cannot claim `T`'s global QName. New anonymous components identify their candidate owner and stable plan-local path, with original sources recorded as provenance rather than adopted identity.
|
|
36
|
-
|
|
37
|
-
Exactly one actual definition can be replaced: the designated final endpoint complex type. Its proposed definition retains the actual endpoint identity, global/scoped identity and all properties required by endpoint comparison, except the declared derivation construction. The actual definition remains accessible only through the actual context; this is a second definition in another context, never mutation of an established actual component.
|
|
38
|
-
|
|
39
|
-
The intermediate is either an unchanged original type whose immediate actual base is the designated ancestor by extension, or a fresh constructed type whose immediate proposed base is that ancestor by extension. The proposed endpoint's immediate base is exactly that intermediate by restriction. Ancestor selection follows the actual chain to the definition whose base is `anyType`, including the simple builtin case described in the RE01 record; there is no arbitrary ancestor override.
|
|
40
|
-
|
|
41
|
-
Replacing another existing type, declaration, AU, group, particle or builtin is malformed plan input. Additional actual component identities may be shared individually, including an original group-owned AU; sharing does not reparent its original local declaration or rewrite its source contribution. Source-representability is not promised by an abstract plan.
|
|
42
|
-
|
|
43
|
-
### Membership, closure and permitted omissions
|
|
44
|
-
|
|
45
|
-
The candidate explicitly lists its retained actual IDs and its added components. Membership is authoritative and cannot grow silently during lookup. Required roots are ancestor, intermediate and endpoint; the ancestor's actual chain operands used for selecting it are also retained. The member set must contain every semantic target, containment child and local owner reachable from these roots or any other listed member, including references beneath zero occurrences and prohibited/source-only AU operands.
|
|
46
|
-
|
|
47
|
-
Closure follows type bases, list items, union members, element/attribute types, substitution heads, group uses, AU declarations, value/facet type operands and local owners. It also follows content and AU property edges and every retained original source contribution. Builtins require no user membership entry. An excluded outgoing target is `input-error: outside-context`, not fallback to the actual graph or permission to insert it.
|
|
48
|
-
|
|
49
|
-
Preparation indexes the entire supplied actual input once to record incoming relationships crossing the candidate boundary. The boundary manifest lists each excluded owner and its outgoing slot into an included component; it also lists excluded substitution affiliates of retained heads, including transitive affiliates. Ownership, references and affiliation are finite edges, so this census does not unfold content recursion.
|
|
50
|
-
|
|
51
|
-
Incoming owners are not automatically included. A smaller explicitly declared component schema may omit an unrelated global element, its substitution affiliation, a descendant type or an unused group. No in-context component may still refer to it, and no omitted component's actual assessment transfers to the proposed context. Schema-wide validity of excluded components and preservation of their payload languages are outside the returned guarantee.
|
|
52
|
-
|
|
53
|
-
For in-context substitution groups, potential members are computed from retained global elements only, then filtered by the in-context type/block predicates. Thus an excluded affiliate does not become an implicit particle member. The boundary manifest makes this reduced universe observable; a caller requiring preservation of an existing operation or head's full substitution set must explicitly include those affiliates and their outgoing closure before preparation.
|
|
54
|
-
|
|
55
|
-
The resolver does not choose whether a complete RE01 witness may use such a smaller schema. #234 owns that quantification and any stronger ambient-schema preservation theorem. This specification permits explicit smaller contexts and prevents their success from being misreported as whole-loaded-schema legality.
|
|
56
|
-
|
|
57
|
-
### Owners, sharing and provenance
|
|
58
|
-
|
|
59
|
-
Ownership and use are separate relations. A containment edge to a newly constructed local component must agree with its declared owner; a semantic reference can share an original AU or particle without changing that original owner. A fresh local declaration cannot substitute for an anchored declaration merely because its QName/type match.
|
|
60
|
-
|
|
61
|
-
All actual records are borrowed readonly; candidate additions and endpoint replacement records are validated and snapshotted under budget. Neither callers nor predicates may mutate them during a request. Public views contain readonly records/arrays; indexes and mutable caches remain private and are not exposed as mutable `Map` objects.
|
|
62
|
-
|
|
63
|
-
Provenance records distinguish `actual`, `constructed` and `endpoint-replacement`, retain original source URI/path, namespace bindings, effective namespace, chameleon interpretation and lexical operands, and record the actual operands motivating each constructed node. A diagnostic concerning proposed ancestry names both the proposed owner and related original operand sources.
|
|
64
|
-
|
|
65
|
-
## TypeScript contract
|
|
66
|
-
|
|
67
|
-
The following private research signatures are one standalone strict TypeScript example. `Id` is opaque text: the implementation validates its actual versus candidate namespace rather than trusting a cast. `Facts` is a small component view, not persisted canonical graph data or a replacement compiler.
|
|
68
|
-
|
|
69
|
-
```typescript
|
|
70
|
-
type Id = string;
|
|
71
|
-
type Method = "extension" | "restriction" | "list" | "union";
|
|
72
|
-
type Name = Readonly<{namespace: string; local: string}>;
|
|
73
|
-
type Kind = "type" | "element" | "attribute" | "particle" | "attributeUse"
|
|
74
|
-
| "group" | "attributeGroup";
|
|
75
|
-
type Source = Readonly<{
|
|
76
|
-
uri: string; digest: string; path: string; baseUri: string;
|
|
77
|
-
start: Readonly<{line: number; column: number}>;
|
|
78
|
-
end: Readonly<{line: number; column: number}>;
|
|
79
|
-
namespaces: Readonly<Record<string, string>>;
|
|
80
|
-
effectiveNamespace: string; interpretation: string; chameleon: boolean;
|
|
81
|
-
}>;
|
|
82
|
-
type Ref = Readonly<
|
|
83
|
-
{kind: "symbol"; role: "type" | "element" | "attribute" | "group" | "attributeGroup";
|
|
84
|
-
name: Name; target: Id; source: Source} |
|
|
85
|
-
{kind: "local"; target: Id} |
|
|
86
|
-
{kind: "builtin"; name: Name}
|
|
87
|
-
>;
|
|
88
|
-
type Operand = Readonly<{type: Ref; lexical: string; source: Source}>;
|
|
89
|
-
type Facet = Readonly<{id: Id; name: string; fixed: boolean; operand: Operand}>;
|
|
90
|
-
type Value = Readonly<{kind: "fixed" | "default"; operand: Operand}>;
|
|
91
|
-
type Occurs = Readonly<{min: string; max: string | "unbounded"}>;
|
|
92
|
-
type Wildcard = Readonly<{
|
|
93
|
-
namespaces: Readonly<{kind: "set" | "not"; values: readonly string[]}>;
|
|
94
|
-
process: "strict" | "lax" | "skip"; source: Source;
|
|
95
|
-
}>;
|
|
96
|
-
type Content = Readonly<
|
|
97
|
-
{kind: "empty"} | {kind: "simple"; type: Ref} |
|
|
98
|
-
{kind: "element-only" | "mixed"; roots: readonly Id[]} |
|
|
99
|
-
{kind: "opaque-builtin"; type: Ref}
|
|
100
|
-
>;
|
|
101
|
-
type Facts = Readonly<
|
|
102
|
-
{kind: "type"; variety: "complex" | "atomic" | "list" | "union";
|
|
103
|
-
base: Ref; method: Method; final: readonly Method[];
|
|
104
|
-
block: readonly ("extension" | "restriction")[]; abstract: boolean;
|
|
105
|
-
content: Content; declaredContent: Content;
|
|
106
|
-
attributeUses: readonly Id[]; wildcard?: Wildcard; declaredWildcard?: Wildcard;
|
|
107
|
-
items: readonly Ref[]; facets: readonly Facet[]} |
|
|
108
|
-
{kind: "element"; name: Name; type: Ref; nillable: boolean; abstract: boolean;
|
|
109
|
-
final: readonly Method[]; block: readonly (Method | "substitution")[];
|
|
110
|
-
value?: Value; head?: Ref; identityConstraints: readonly string[]} |
|
|
111
|
-
{kind: "attribute"; name: Name; type: Ref; value?: Value} |
|
|
112
|
-
{kind: "attributeUse"; declaration: Ref; required: boolean; value?: Value} |
|
|
113
|
-
{kind: "particle"; occurs: Occurs; term: "element" | "group" | "any"
|
|
114
|
-
| "sequence" | "choice" | "all"; reference?: Ref;
|
|
115
|
-
children: readonly Id[]; wildcard?: Wildcard} |
|
|
116
|
-
{kind: "group"; root: Id} |
|
|
117
|
-
{kind: "attributeGroup"; uses: readonly Id[]; wildcard?: Wildcard}
|
|
118
|
-
>;
|
|
119
|
-
type Identity = Readonly<
|
|
120
|
-
{kind: "global"; role: Kind; name: Name} |
|
|
121
|
-
{kind: "local"; owner: Id; path: string; role: Kind} |
|
|
122
|
-
{kind: "fresh"; owner?: Id; path: string; role: Kind}
|
|
123
|
-
>;
|
|
124
|
-
type SourceUse = Readonly<
|
|
125
|
-
{kind: "admitted"; owner: Id; origin: string; use: Id;
|
|
126
|
-
role: "local" | "group"; ownValue?: Value; source: Source} |
|
|
127
|
-
{kind: "local-prohibition"; owner: Id; origin: string; name: Name;
|
|
128
|
-
role: "direct-prohibition" | "group-prohibition"; source: Source;
|
|
129
|
-
representationChecks: readonly string[]} |
|
|
130
|
-
{kind: "reference-prohibition"; owner: Id; origin: string; declaration: Ref;
|
|
131
|
-
role: "direct-prohibition" | "group-prohibition"; source: Source;
|
|
132
|
-
representationChecks: readonly string[]}
|
|
133
|
-
>;
|
|
134
|
-
type SourceGroupUse = Readonly<{
|
|
135
|
-
owner: Id; origin: string; reference: Ref; source: Source;
|
|
136
|
-
}>;
|
|
137
|
-
type Component = Readonly<{
|
|
138
|
-
id: Id; identity: Identity; facts: Facts; owns: readonly Id[];
|
|
139
|
-
source: Source; sourceUses: readonly SourceUse[];
|
|
140
|
-
sourceGroups: readonly SourceGroupUse[];
|
|
141
|
-
unassessed: readonly Readonly<{rule: string; owner: string; source: Source}>[];
|
|
142
|
-
provenance: Readonly<{kind: "actual" | "constructed" | "endpoint-replacement";
|
|
143
|
-
originals: readonly Id[]}>;
|
|
144
|
-
}>;
|
|
145
|
-
type ActualInput = Readonly<{key: string; components: readonly Component[]}>;
|
|
146
|
-
type AttributeAction = Readonly<
|
|
147
|
-
{name: Name; role: "retain"} |
|
|
148
|
-
{name: Name; role: "replace"; uses: readonly Id[]} |
|
|
149
|
-
{name: Name; role: "prohibit"}
|
|
150
|
-
>;
|
|
151
|
-
type Candidate = Readonly<{
|
|
152
|
-
key: string; ancestor: Ref; intermediate: Id; endpoint: Id;
|
|
153
|
-
retained: readonly Id[]; additions: readonly Component[];
|
|
154
|
-
endpointDefinition: Component; attributes: readonly AttributeAction[];
|
|
155
|
-
}>;
|
|
156
|
-
type Limits = Readonly<{maxNodes?: number; maxWork?: number}>;
|
|
157
|
-
type Usage = Readonly<{nodes: number; work: number}>;
|
|
158
|
-
type Diagnostic = Readonly<{
|
|
159
|
-
code: string; rule: string; context: string; candidate?: string;
|
|
160
|
-
component?: Id; slot?: string; source?: Source; related: readonly Source[];
|
|
161
|
-
}>;
|
|
162
|
-
type BoundaryEdge = Readonly<{owner: Id; slot: string; target: Id}>;
|
|
163
|
-
declare const contextBrand: unique symbol;
|
|
164
|
-
type Context = Readonly<{
|
|
165
|
-
[contextBrand]: true; key: string; kind: "actual" | "proposed";
|
|
166
|
-
members: readonly Id[]; excludedIncoming: readonly BoundaryEdge[];
|
|
167
|
-
}>;
|
|
168
|
-
type Result<T> = Readonly<
|
|
169
|
-
{kind: "ok"; value: T; usage: Usage} |
|
|
170
|
-
{kind: "input-error" | "candidate-rejected" | "unresolved";
|
|
171
|
-
diagnostic: Diagnostic; usage: Usage} |
|
|
172
|
-
{kind: "resource-limit"; limit: "nodes" | "work"; usage: Usage}
|
|
173
|
-
>;
|
|
174
|
-
type Target = Readonly<
|
|
175
|
-
{kind: "component"; component: Component} | {kind: "builtin"; name: Name}
|
|
176
|
-
>;
|
|
177
|
-
type Prepared = Readonly<{actual: Context; proposed: Context}>;
|
|
178
|
-
type Pair = readonly [Id, Id];
|
|
179
|
-
type Correspondence = Readonly<{actualRoot: Id; proposedRoot: Id;
|
|
180
|
-
pairs: readonly Pair[]}>;
|
|
181
|
-
type CorrespondenceReceipt = Readonly<{scope: "endpoint-properties-and-incidence";
|
|
182
|
-
actualContext: string; proposedContext: string; pairs: readonly Pair[]}>;
|
|
183
|
-
declare function prepareContexts(input: ActualInput, candidate: Candidate,
|
|
184
|
-
limits?: Limits): Result<Prepared>;
|
|
185
|
-
declare function resolveReference(context: Context, owner: Id, slot: string): Result<Target>;
|
|
186
|
-
declare function compareEndpoint(prepared: Prepared, certificate: Correspondence):
|
|
187
|
-
Result<CorrespondenceReceipt>;
|
|
188
|
-
```
|
|
189
|
-
|
|
190
|
-
`prepareContexts` owns one request budget shared by its returned contexts, subsequent lookups, comparison and validation adapters. `usage` is cumulative for that request. A context is factory-issued and cannot be forged, used in another request or revived after exhaustion; a subsequent independent request starts fresh. Actual-only lookups use `prepared.actual`, whose membership is the full actual input, and cannot see additions.
|
|
191
|
-
|
|
192
|
-
### Facts and slot invariants
|
|
193
|
-
|
|
194
|
-
The type view carries prepared effective `content` and original raw `declaredContent` plus source uses; it does not derive them in the resolver. A complex type uses content, AU IDs and optional attribute wildcard; atomic/list/union types have empty complex content/AUs and use base/items/facets. `items` contains exactly one list item, declared union members in order, or no entries otherwise.
|
|
195
|
-
|
|
196
|
-
Facet operands retain their original ID, name, fixed flag, ordered layer position and type/lexical context. Identity-constraint strings are immutable canonical operand keys with original source records supplied by the semantic owner. The narrow resolver treats both as opaque obligations, never as value equality proven by matching text.
|
|
197
|
-
|
|
198
|
-
Particle `reference` is required only for element/group terms, `wildcard` only for `any`, and children only for compositors. Exact finite bounds are canonical nonnegative decimal strings; `unbounded` is admitted only for maximum. A group's root is a compositor; AU declaration references target attributes; element/attribute type references target types; head references target global elements.
|
|
199
|
-
|
|
200
|
-
`owns` lists containment of mapped semantic components, preserving order; effective shared property edges are not additional ownership edges. Each local identity has its original containing declaration, not its immediate use position. Noncomponent prohibited attributes and source group-use syntax are nested records, never fabricated declarations/AUs or members of `owns`.
|
|
201
|
-
|
|
202
|
-
`sourceUses.kind="admitted"` points to the original AU and preserves its own value/source operand independently of any declaration constraint. A local prohibition has only its expanded matching name and source representation checks, with no declaration/type/runtime scalar obligation; prohibited global references retain their actual declaration target and that declaration's own legality obligations. Representation checks preserve relevant name/ref, default/fixed and lexical syntax rules without constructing a nonexistent local scalar operand.
|
|
203
|
-
|
|
204
|
-
`sourceGroups` preserves every original attribute-group use/reference, even empty and repeated references, in source order. It has a resolved attribute-group target, owner and original source key; it preserves outgoing closure, incoming boundary evidence and group-expansion cycle edges that a flattened AU set cannot recover. `attributeGroup.wildcard`, `type.declaredWildcard` and their original contexts retain group/own wildcard operands independently of the prepared effective type wildcard.
|
|
205
|
-
|
|
206
|
-
`unassessed` carries every retained component constraint or unsupported syntax operand not represented by the narrow facts view. R4 must emit unresolved for each entry lacking a qualified owner receipt; an empty list is a preparation-authority assertion checked by the future production adapter, never inferred merely because the resolver recognizes the other fields.
|
|
207
|
-
|
|
208
|
-
Reference slots are fixed names: `base`, `items/<index>`, `content/type`, `declaredContent/type`, `type`, `head`, `declaration`, `value/operand/type`, `facets/<index>/operand/type`, `sourceUses/<index>/declaration` for reference prohibitions, `sourceUses/<index>/ownValue/operand/type` for admitted own constraints, `sourceGroups/<index>/reference` and `reference`. Nonreference edges use `content/roots/<index>`, `declaredContent/roots/<index>`, `attributeUses/<index>`, `children/<index>`, `root`, `uses/<index>`, `sourceUses/<index>/use`, `owns/<index>` and `identity/owner`. Unknown slots, wrong field combinations or mismatched kinds are input errors; consumers never provide a replacement arbitrary reference to bypass slot validation.
|
|
209
|
-
|
|
210
|
-
### Explicit semantic dependencies and receipts
|
|
211
|
-
|
|
212
|
-
The resolver hands prepared contexts and original operand IDs to direct owned functions: `checkTypeDerivation`, `checkSubstitution`, `checkTypeConstruction`, `checkAttributes`, `checkParticleRestriction`, `checkAttribution`, `checkDeclarations` and `checkScalarOperands`. These are separate adapters, not a configurable policy dispatcher. Their inputs and scopes are specified in the ownership table; none may consult a context-free global node index.
|
|
213
|
-
|
|
214
|
-
Each adapter returns `Result<Readonly<{context: string; rule: string; operands: readonly Id[]; authority: string}>>`. `ok` means exactly that named predicate passed for those operands in that context, under its declared accepted authority; `candidate-rejected` means that predicate fails for this candidate, not that all candidates fail. Missing predicate implementation, qualification or a violated preparation assumption returns `unresolved` with the precise owner/rule.
|
|
215
|
-
|
|
216
|
-
A checking caller may produce a `checked-candidate` receipt only after every required obligation and endpoint correspondence passes. Its receipt includes the explicit members, excluded-incoming manifest, complete obligation receipts and their authorities. Its scope is the listed component schema under those predicates, excluding source reconstruction, global witness completeness and production assessment acceptance; there is no bare `valid: true` result.
|
|
217
|
-
|
|
218
|
-
## Resolution rules
|
|
219
|
-
|
|
220
|
-
| Reference or edge | Actual context | Proposed context |
|
|
221
|
-
|---|---|---|
|
|
222
|
-
| Resolved symbol | Verify target role/QName; return actual target | Verify membership and role/QName; select endpoint override if targeted |
|
|
223
|
-
| Local reference | Return exact target; verify allowed original owner | Same identity; preserve original owner or validate fresh owner |
|
|
224
|
-
| Builtin | Validate XSD namespace and supported builtin name | Same immutable builtin handle; never overridden |
|
|
225
|
-
| Type/base/item/member | Follow actual facts in caller context | Follow selected facts in caller context |
|
|
226
|
-
| Particle/group/declaration | Follow original component IDs | Follow original or constructed IDs without structural copying |
|
|
227
|
-
| AU/group/value/facet operand | Preserve exact original operand identity/context | Preserve operand identity/context and explicit plan role |
|
|
228
|
-
| Containment/owner | Validate complete original ownership | Validate original ownership and fresh candidate containment |
|
|
229
|
-
|
|
230
|
-
Symbol targets are already resolved; the resolver never reparses prefixes, performs namespace loading or finds a different same-QName target. An unknown builtin, absent target, duplicate ID, unresolved symbol, wrong target kind, collision or invalid override is an input error, including below disabled particles. The diagnostic points to the reference's original source when available.
|
|
231
|
-
|
|
232
|
-
For a proposed lookup the order is membership check, designated endpoint definition, candidate addition, retained actual definition. There is no actual fallback after membership failure. Reading an unchanged actual `T`, `M`, group or particle does not switch evaluation context: a recursive reference to `D` still sees proposed `D`.
|
|
233
|
-
|
|
234
|
-
Legal self/mutual content recursion and sharing remain references. Preparation separately rejects cycles in local ownership, syntactic containment, group expansion, AU-group expansion, simple derivation/item/member expansion, complex base derivation and substitution affiliation. The builtin `anyType` ur-type sentinel terminates traversal and is not a user derivation cycle; no other cycle exemption exists.
|
|
235
|
-
|
|
236
|
-
The AU-group cycle check follows `sourceGroups` references even when every effective use set is empty; it never follows admitted AU declaration/type references as expansion edges. Source-only local prohibition records contribute representation checks but no semantic target edge, while reference prohibitions contribute declaration closure without inventing an AU.
|
|
237
|
-
|
|
238
|
-
A malformed actual input, invalid plan shape or missing/wrong target is an input error. A well-formed proposed edge set with a prohibited cycle is candidate-rejected with its cycle rule and related sources; an actual cycle violates the resolved-input precondition and is an input error. Failed semantic predicates also reject only the supplied candidate, while missing authority is unresolved.
|
|
239
|
-
|
|
240
|
-
Keep reference resolution separate from predicate evaluation. A validly resolved type can still fail derivation, final/block, substitution or particle predicates. A recursive predicate dependency must use its owner's proved termination rule; an active cache entry is not a proof of success.
|
|
241
|
-
|
|
242
|
-
## Endpoint comparison
|
|
243
|
-
|
|
244
|
-
The single comparison root is actual final endpoint `D` against proposed `D`. The compared projection follows every non-derivation effective property: content roots and particles, element declarations, AU/declaration/value operands, scalar content, facets, local scopes and sharing. It omits the endpoint's derivation edge and syntactic source contribution classification, which are replaced by the explicit construction plan and checked separately.
|
|
245
|
-
|
|
246
|
-
The ancestor and existing intermediate are exact reused identities, verified by plan preparation. Every actual ID reached by the endpoint property projection is anchored, including particles/wrappers, named/global types and declarations, original AUs, local owner identities and anonymous scalar operands. Fresh components, including construction wrappers, may occur only outside the endpoint projection, such as in a fresh intermediate; no endpoint wrapper-renaming or insertion exception is permitted.
|
|
247
|
-
|
|
248
|
-
The projection stops at referenced type definitions and local-owner identities: it compares their anchored IDs, not their ancestry, content or other roots' properties. Element recursion is therefore represented by an anchored reference to `D`, while semantic queries on that reference use the selected context. Particle/group expansion and AU component properties remain in the projection; no type-content unfolding crosses an element/type reference.
|
|
249
|
-
|
|
250
|
-
The supplied certificate must be a total injective bijection over those two finite projections, map the root to the root, fix all anchored identities, preserve component kind, exact occurrences, content variety, mixed/abstract/final/block properties, declarations, scopes, original constraint operands and edge order/multiplicity, and preserve shared versus distinct nodes. Because every endpoint projection component is anchored, the certificate is an identity mapping; requiring it explicitly prevents hidden root/closure changes. Annotations are excluded from semantic comparison, while original source provenance remains immutable; text equality never substitutes for typed scalar equality.
|
|
251
|
-
|
|
252
|
-
Correspondence failure rejects only this certificate/candidate projection. It proves neither that no certificate exists nor that no RE01 witness exists. The existing [incidence checker](../test/research/re01/incidence-probe.ts) supplies bounded AU certificate mechanics, not automatic whole-endpoint equality; the future adapter must preserve order for particle child edges rather than reuse its unordered edge-multiset check indiscriminately.
|
|
253
|
-
|
|
254
|
-
Original named group `G` is not an additional comparison root merely because actual `D` once imported it. D1 can share individual original `G/g` and `G/h` while leaving `G` unchanged; this preserves their IDs and owners. The XML-source fresh-AU correspondence in the RE01 record is a different witness domain, outside this resolver's identity policy.
|
|
255
|
-
|
|
256
|
-
## Validation ownership
|
|
257
|
-
|
|
258
|
-
All members are checked in the proposed context, including unchanged members and source-only operands. This deliberately conservative rule avoids inventing a difficult incremental invalidation theorem. Actual context checks are comparison evidence, not automatically reusable legality receipts; only immutable builtin admission and identical original lexical/source records can be borrowed, while context-sensitive predicate answers are recomputed.
|
|
259
|
-
|
|
260
|
-
| Obligation | Context and inputs | Rule owner | Reuse/closure decision |
|
|
261
|
-
|---|---|---|---|
|
|
262
|
-
| IDs, targets, local owners, member closure | Both contexts; all slots/owners | Context preparation R1/R2 | Recheck candidate membership; actual IDs remain immutable |
|
|
263
|
-
| Prohibited cycles | Proposed expansion/base/head edges | Preparation R1 | Iterative active/done check; content recursion excluded |
|
|
264
|
-
| Type derivation method exclusions | Declared query context; derived/base/exclusion set | Relation adapter R3 | Recompute through proposed ancestry |
|
|
265
|
-
| Type `final`, element `final`, type/element `block` | Proposed type edges and element properties | R3 plus construction adapter R4 | Distinguish derivation final from substitution blocking |
|
|
266
|
-
| Intermediate extension and endpoint restriction | Proposed ancestor/intermediate/endpoint; original raw operands | R4/#234 component predicates | No transitivity assumption; no recursive RE01 search |
|
|
267
|
-
| Substitution affiliation and substitutability | Every retained global member/head; transitive affiliation | R3 | Recompute even for unchanged declarations |
|
|
268
|
-
| Effective substitution group membership | Retained global universe, abstract/block/type facts | R3 | Excluded affiliates recorded, not implicit members |
|
|
269
|
-
| UPA/particle attribution | Every member type/group content, use positions, in-context substitutions | R4/#179 particle owner | Recompute; group uses retain distinct attribution positions |
|
|
270
|
-
| Element declaration consistency | Same content closure, implicit substitution members | R4/#179 declaration owner | Named type identity required; structural equality insufficient |
|
|
271
|
-
| AU sets, restrictions and uniqueness | Every type/group original AU and source contribution | R4/AU01 C1 | All original constraints; no flattened QName projection |
|
|
272
|
-
| Wildcard namespace/process/member ranges | Original wildcard and particle operands | R4/PW01 R-240 | Formal whole-group and adjusted member checks remain separate |
|
|
273
|
-
| Scalar derivation/value/facet operands | Original type/lexical/namespace context per operand | R4/#179 scalar owner; DT01 A when calendar | No new scalar engine; missing authority remains unresolved |
|
|
274
|
-
| Original raw all placement and content variety | Original extension operand and proposed construction | R4/#179 component owner | Restriction pointlessness cannot erase extension constraints |
|
|
275
|
-
| Endpoint properties and incidence | Actual versus proposed endpoint projection | Comparison R2 | Supplied certificate only |
|
|
276
|
-
|
|
277
|
-
### Predicate rules that must remain distinct
|
|
278
|
-
|
|
279
|
-
`checkTypeDerivation` takes derived reference, base reference and a canonical excluded-method set in one context. For complex types, [Type Derivation OK](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#cos-ct-derived-ok) first allows identical definitions; otherwise the derived method must be allowed, then immediate-base equality or the permitted recursive base comparison applies. For simple types, use [the separate simple rule](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#cos-st-derived-ok), including base `final`, list/union ur-type and base-union alternatives; do not implement it as a generic ancestry walk.
|
|
280
|
-
|
|
281
|
-
[NameAndTypeOK](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#rcase-NameAndTypeOK) 3.2.5 excludes extension/list/union for the local element comparison. [Element properties](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#e-props-correct) 4 checks an affiliate's type against its head's type using the head's substitution-group exclusions. [Substitution Group OK](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#cos-equiv-derived-ok-rec) additionally checks affiliation chain and disallowed methods against head and intermediate type blocking constraints; head `block="substitution"` suppresses substitutability without making the affiliation property absent.
|
|
282
|
-
|
|
283
|
-
[EDC](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#cos-element-consistent) includes implicit substitution members and requires the same named top-level type for repeated same-QName declarations. [UPA](https://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#cos-nonambig) distinguishes particle positions even when they originate from the same shared group. Neither an occurrence interval nor reference-graph closure proves those obligations.
|
|
284
|
-
|
|
285
|
-
R4 constructs a finite inventory with one entry per applicable rule/operand tuple in stable order. All member constraints are included, not merely predicates directly reached from the final particle comparison. Complete XSD rules not implemented by the accepted predicate owner remain named unresolved inventory entries; adapters must never declare complete legality by passing only their available subset.
|
|
286
|
-
|
|
287
|
-
### Attribute construction roles
|
|
288
|
-
|
|
289
|
-
Actual source roles are immutable `sourceUses`, including local/group replacement, direct prohibition and ineffective group prohibition. The proposed restriction instead has exactly one explicit `AttributeAction` for each expanded QName in the union of intermediate and endpoint AU sets. Duplicate or missing actions are malformed input; there is no role inference from equality or source order.
|
|
290
|
-
|
|
291
|
-
`retain` inherits the intermediate's entire same-QName AU-ID set unchanged. `replace` installs its listed endpoint AUs and invokes accepted AU01 requiredness, original-type derivation and typed fixed retention against every intermediate matching AU. `prohibit` produces no endpoint AU for that name and fails if any original intermediate matching AU is required. A replacement for a new name requires admission by the intermediate's original wildcard.
|
|
292
|
-
|
|
293
|
-
An extension plan preserves all ancestor AU IDs and may add individually shared original final AUs; uniqueness and every use/declaration's own constraint remain separate checks. Retention never compares conflicting inherited fixed uses pairwise as if they were source replacements; every present runtime value would still satisfy all C1 fixed obligations. Differing defaults are not fixed constraints, and QName/calendar aliases retain their original typed contexts.
|
|
294
|
-
|
|
295
|
-
### Established retained-substitution negative control
|
|
296
|
-
|
|
297
|
-
The new [actual schema](../test/conformance/fixtures/xsd/re01/substitution-actual.xsd) independently defines empty `A`, `T` extending `A`, `B` restricting `A`, `D` extending `B`, head `H:B` and member `M:D` affiliated with `H`. With no exclusions, actual `D` has immediate base `B`, satisfying `e-props-correct` 4 and the invoked complex type relation.
|
|
298
|
-
|
|
299
|
-
The [retained proposed schema](../test/conformance/fixtures/xsd/re01/substitution-retained.xsd) changes only `D` to restrict `T`. Its ancestry is `D -> T -> A -> anyType`; it never reaches `B`, so retained `M/H` fails that required type relation even though the declarations themselves are unchanged. This is an independently sourced negative result for this explicit context, not a statement that all candidates must retain `M/H`.
|
|
300
|
-
|
|
301
|
-
The [omitted-member control](../test/conformance/fixtures/xsd/re01/substitution-omitted.xsd) removes `M` and retains `H`. That smaller component schema has no `M/H` affiliation obligation. The [focused strict TypeScript tests](../test/conformance/reference/re01-substitution-context.test.ts) check the written source premises and literal ancestry expectations separately from current libxml2 construction observations; the live primary accepts actual/omitted and rejects retained proposed.
|
|
302
|
-
|
|
303
|
-
## Algorithms and data flow
|
|
304
|
-
|
|
305
|
-
### Preparation and deterministic lookup
|
|
306
|
-
|
|
307
|
-
```text
|
|
308
|
-
validate positive safe-integer limits; create one request budget
|
|
309
|
-
reserve actual plus fresh component node count before indexing
|
|
310
|
-
validate and index every original ID, kind, identity, source and slot
|
|
311
|
-
validate one endpoint replacement and candidate-local additions
|
|
312
|
-
validate roots and two immediate derivation edges against original ancestor
|
|
313
|
-
build explicit proposed membership; do not auto-add missing targets
|
|
314
|
-
for every member in stable ID order:
|
|
315
|
-
select proposed definition; validate every outgoing slot and owner
|
|
316
|
-
record all original source operands, including nonsurviving uses
|
|
317
|
-
check forbidden edge DAGs iteratively; preserve content-reference cycles
|
|
318
|
-
scan original incoming references and substitution chains for exclusions
|
|
319
|
-
freeze member/boundary views; issue actual and proposed context handles
|
|
320
|
-
on lookup: validate context/owner/slot; charge access; select exact target
|
|
321
|
-
on any failed charge: invalidate request; return resource-limit only
|
|
322
|
-
```
|
|
323
|
-
|
|
324
|
-
Iteration order is ascending UTF-16 ID order, then the fixed slot order above with numeric indexes in source order. Input arrays for set-valued membership/AUs are canonicalized by ID; semantic particle/union/containment order is preserved. Duplicate membership entries, additions or endpoint actions are input errors instead of order-dependent last-writer behavior.
|
|
325
|
-
|
|
326
|
-
The boundary census needs no speculative graph framework. Keep an ID index, fixed-slot visitor and reverse-reference lists inside preparation; derive substitution descendants by finite head-edge traversal. These structures have one consumer and no public mutation, transport or policy hooks.
|
|
327
|
-
|
|
328
|
-
### Comparison and delegated validation
|
|
329
|
-
|
|
330
|
-
```text
|
|
331
|
-
build each endpoint non-derivation projection with visited IDs
|
|
332
|
-
stop expansion at anchored type and local-owner references
|
|
333
|
-
verify supplied root pair and bijection; compare properties and edge incidence
|
|
334
|
-
enumerate applicable member obligations, including unchanged members
|
|
335
|
-
invoke the named owned adapters in deterministic rule/operand order
|
|
336
|
-
pass context, original operands and the shared charging functions
|
|
337
|
-
retain only complete rule receipts; never cache partial acceptance
|
|
338
|
-
if any rule fails: reject this candidate, with original related sources
|
|
339
|
-
if any rule lacks authority: unresolved, naming rule and owner
|
|
340
|
-
if all pass: emit scoped checked-candidate receipt and excluded boundary
|
|
341
|
-
```
|
|
342
|
-
|
|
343
|
-
The direct component predicates may invoke context-aware type queries but must not invoke the RE01 candidate search recursively to validate their own candidate. RE01's existential clause remains a caller proof obligation; the proposed two-step construction supplies its candidate without assuming the complete candidate family. If a delegated predicate cannot terminate without an unproved recursive assumption, it returns unresolved.
|
|
344
|
-
|
|
345
|
-
### Future production adapter
|
|
346
|
-
|
|
347
|
-
R6's documented production seam consumes `resolved.graph`, `resolved.links` and source context from `prepareResolvedCompilationInput`. It maps canonical simple/complex types into type facts, group-use nodes into explicit reference slots, and immutable IDs into anchors. It extracts final/block defaults from original declared/schema attributes, preserving lexical context and retained unsupported syntax as obligations.
|
|
348
|
-
|
|
349
|
-
`composed.types` can supply content contribution roots, but its QName-collapsed `attributes` cannot supply AU facts. The adapter obtains original use/declaration/group contribution IDs directly from `resolved.graph` and passes them to the AU01 owner. It never guesses original uses from effective attributes or imports unaccepted #231 modules into research.
|
|
350
|
-
|
|
351
|
-
The accepted [`OccurrenceAnalysis`](../src/compiler/occurrenceAnalysis.ts) supplies exact total range and `schemaEmptiable` only where a particle predicate requests them. For changed/fresh particle operands, the future semantic owner supplies a context-qualified view to that same analysis contract; the resolver does not derive occurrences or substitute `nullable`. An unchanged particle summary is reusable only when that owner's input content/occurrence closure is identical; changed type-level composition summaries are not reused.
|
|
352
|
-
|
|
353
|
-
The read-only #231 trace at `460f5b8379c68ffef79917284e445b5ab046429e` shows `assessmentContext` indexing one actual graph, scalar `derives` following that index and particle assessment calling it with a restriction-only boolean. R3/R4 require explicit context plus the full excluded-method set at that future seam; roots, normalized views and scalar descriptions also need context-specific caches. This is architectural guidance for #179's later reviewed integration, not copied executable code.
|
|
354
|
-
|
|
355
|
-
## Caching and resources
|
|
356
|
-
|
|
357
|
-
### Cache keys and lifetime
|
|
358
|
-
|
|
359
|
-
All caches belong to one prepared request. A key includes actual input identity, candidate identity, context identity, predicate/rule authority version, ordered operand identities, relevant occurrence/source operand identities and canonical predicate options, including the sorted deduplicated excluded-method set. Fixed-value keys also include each operand's original lexical and namespace context; QName spelling alone is insufficient.
|
|
360
|
-
|
|
361
|
-
Actual and proposed contexts never share predicate entries merely because an unchanged record object is shared. Two candidates never share entries even when they use the same final ID. Lookup keys include owner and slot; group attribution keys include use position; comparison keys include both contexts and supplied projection/certificate identities.
|
|
362
|
-
|
|
363
|
-
Cache states are absent, active or complete. Complete positive and negative predicate answers may be reused only within the same context/key; unresolved answers may be recorded for deterministic diagnostics but never promoted to success. A rejected candidate's cache dies with that request; an exhausted request clears all active/complete entries and exposes no usable context or partial receipt.
|
|
364
|
-
|
|
365
|
-
An active content reference is returned as a reference, not an expanded node. An active forbidden derivation path rejects the candidate. An active delegated semantic evaluation without its own proved fixed-point rule is unresolved; it cannot be treated as true to break recursion.
|
|
366
|
-
|
|
367
|
-
### Inclusive budget and cost model
|
|
368
|
-
|
|
369
|
-
Defaults are independently inclusive 100,000 nodes and 1,000,000 work units. Overrides must be positive safe integers. A reservation checks `requested <= remaining` before allocation/execution and never increments usage past the limit; sums use checked subtraction instead of overflowing machine counters.
|
|
370
|
-
|
|
371
|
-
Node usage counts every actual input component once, even when excluded, plus every fresh addition once. The endpoint replacement reuses one component identity and consumes work for its record/copies but no extra node slot; builtin handles are fixed shared constants. Set membership, incoming references and repeated uses never multiply the node count, but each edge and use position consumes work.
|
|
372
|
-
|
|
373
|
-
| Operation | Charge before allocation or execution |
|
|
374
|
-
|---|---|
|
|
375
|
-
| Input indexing/validation | One per record, field, edge and collection entry; each text code unit |
|
|
376
|
-
| Candidate snapshot/override | Record/field/entry costs plus copied text length |
|
|
377
|
-
| Map/set/queue/stack/cache | One per created container, inserted entry, push/pop, read or state transition |
|
|
378
|
-
| Reference traversal/cache hit | One per access plus key construction/comparison text |
|
|
379
|
-
| Sorting and canonical keys | Each comparator visit and compared UTF-16 unit; output entries/text |
|
|
380
|
-
| Original/source/context data | Every inspected namespace, source, bound, facet and lexical text code unit |
|
|
381
|
-
| Certificate/obligation output | Each receipt/diagnostic record, field, edge, list entry and copied text |
|
|
382
|
-
| Exact arithmetic/predicate work | Owning accepted contract's charged operands/results; same request budget |
|
|
383
|
-
|
|
384
|
-
Lengths may be read in constant time to reserve text work, but scanning, hashing, string comparison, concatenation and serialization must charge their inspected/produced UTF-16 units. Immutable borrowed text is charged when indexed/inspected; a further copy is charged again before copying. Deep-freezing traversals, diagnostic source copies and certificate arrays are included; returning an already borrowed immutable record avoids an uncharged copy.
|
|
385
|
-
|
|
386
|
-
Reserve one constant-size terminal failure envelope at request start. On resource exhaustion, return only that envelope and counters, with no unbounded diagnostic formatting or partial target/certificate/legality receipts; all later calls on its contexts return the same resource failure without work. Ordinary diagnostics are charged before output; if their construction exhausts the request, resource-limit supersedes the rejection or input error.
|
|
387
|
-
|
|
388
|
-
Preparation costs `O(N + E + L)` before deterministic sorting, where N is distinct input/addition components, E includes semantic, source, ownership and boundary edges, and L is inspected text length. Charged comparison sorting adds its actual comparator/text cost; space is `O(N + E + Lcopies)`. Endpoint certificate checking is linear in its finite projections and certificate entries, apart from charged canonicalization.
|
|
389
|
-
|
|
390
|
-
Type-chain queries visit finite derivation operands and union alternatives under their owner's cost model. Substitution descendant computation is finite over retained elements; complete UPA/particle/scalar work has its owning predicate's bounds, not a claimed resolver-linear bound. Shared DAGs remain references, exact huge occurrences stay decimal operands and neither legal recursion nor finite repetition is expanded into repeated structures.
|
|
391
|
-
|
|
392
|
-
## Behavioral test matrix
|
|
393
|
-
|
|
394
|
-
These are future observable resolver tests, not placeholder executable calls to nonexistent APIs. Each expectation's authority and scope is explicit; current fixtures prove only their documented predicates. Future test names below are intended files under `test/research/re01/`, owned by the named task.
|
|
395
|
-
|
|
396
|
-
| ID / requirement | Independent expectation and scope | Evidence / intended test | Task |
|
|
397
|
-
|---|---|---|---|
|
|
398
|
-
| B01 context propagation | Actual D method excluded; proposed D immediate base T passes local type query | Existing endpoint all [control](../test/conformance/reference/re01-endpoint-continuation.test.ts); `resolver-resolution.test.ts` | R2/R3 |
|
|
399
|
-
| B02 named identity | Reused T matches; fresh T-copy does not match anchored T and reaches excluded extension | Same dated clause/source contrast; `resolver-relations.test.ts` | R3 |
|
|
400
|
-
| B03 legal content recursion | Self/mutual element-type refs resolve without expansion or recursion error | #175/#178 contracts; independent two-type records in `resolver-context.test.ts` | R1/R2 |
|
|
401
|
-
| B04 forbidden cycles | Base, list/member, group, ownership and head cycles fail; builtin sentinel terminates | S05 forbidden-edge contract; hand-written cycle records | R1 |
|
|
402
|
-
| B05 identity/reference errors | Wrong owner, missing target, wrong role/QName, builtin collision and nonendpoint override are input errors | Canonical ID/owner contract; `resolver-context.test.ts` | R1/R2 |
|
|
403
|
-
| B06 unchanged traversal | Unchanged M.type or group path to D selects proposed D; actual context selects actual D | Explicit slot rules; independent literal records | R2 |
|
|
404
|
-
| B07 explicit membership | Excluded outgoing target is outside-context; excluded incoming M is recorded, never auto-added | Membership contract and omitted schema control | R1/R2 |
|
|
405
|
-
| B08 retained substitution | Actual M/H passes; retained proposed M/H rejects; omitted M has no such obligation | New [substitution control](../test/conformance/reference/re01-substitution-context.test.ts); `resolver-validation.test.ts` | R3/R4 |
|
|
406
|
-
| B09 incoming implicit members | Retained head's substitution set uses retained affiliates only; boundary lists omitted affiliates | `cos-equiv-class`; hand-written H/M/descendant records | R3 |
|
|
407
|
-
| B10 final and block | Base final extension rejects even vacuous extension; head block substitution suppresses substitution | Existing [final control](../test/conformance/reference/re01-particle-continuation.test.ts) and dated substitution clauses | R3/R4 |
|
|
408
|
-
| B11 predicate isolation | Same pair in actual/proposed, two candidates and differing exclusion sets yields its own answer | B01/B02 contrasting premises; `resolver-cache.test.ts` | R5 |
|
|
409
|
-
| B12 request isolation | Rejected/exhausted request followed by independent valid one has fresh counters/results | Failure-lifetime contract; literal two-request controls | R5 |
|
|
410
|
-
| B13 immutability/provenance | Actual records stay deep-equal/identical; proposed diagnostics retain original related paths | Canonical immutable contract; freeze and snapshot assertions | R1/R2/R5 |
|
|
411
|
-
| B14 deterministic failures | Shuffled set-valued inputs give same first diagnostic and canonical output | Stable ID/slot/rule order; independent multiple-error fixture | R1/R4/R5 |
|
|
412
|
-
| B15 inclusive resources | Same finite request succeeds at its charged count; one less exhausts with no partial result | Published cost model; separately authored operation ledger in `resolver-budget.test.ts` | R5 |
|
|
413
|
-
| B16 node sharing/exact values | 100,000 distinct input/addition IDs admitted with sufficient work; 100,001 fails; repeated refs do not expand | #178 and existing probe boundary evidence; independent ledger | R5 |
|
|
414
|
-
| B17 endpoint certificate | Distinct equal AUs cannot collapse; wrong local scope/fixed operand/order fails; D derivation alone may differ | Existing [incidence tests](../test/research/re01/incidence-probe.test.ts); `resolver-comparison.test.ts` | R2 |
|
|
415
|
-
| B17a particle identity | Replacing/inserting an endpoint wrapper rejects; fresh wrappers outside that projection do not change its certificate | Explicit anchored-particle policy; independent original/fresh wrapper records | R2 |
|
|
416
|
-
| B18 AU roles | Omission/retain preserves original IDs; replacement checks all original matching fixed/required uses | Accepted AU01 literal matching table and group-incidence control | R4 |
|
|
417
|
-
| B19 delegated authority | Missing UPA/scalar/normalization authority returns named unresolved; lookup can still succeed | Success scope and inventory contract; `resolver-validation.test.ts` | R4 |
|
|
418
|
-
| B20 original particle constraints | Raw singleton all cannot become appendable through restriction normalization; direct restriction need not be transitive | Existing particle continuation controls | R4 |
|
|
419
|
-
| B21 attribution/EDC inputs | Distinct group use positions and implicit retained affiliates reach the owning checker | Dated UPA/EDC clauses; independently authored request-capture records | R4 |
|
|
420
|
-
| B22 source-only prohibitions | Local prohibition has no target/type; global-reference prohibition retains original declaration checks; neither adds an AU | Accepted AU01 prohibited/omitted table; `resolver-context.test.ts` and validation captures | R1/R4 |
|
|
421
|
-
| B23 original group references | Empty/repeated group refs remain explicit; indirect cycles or excluded group target fail; original group wildcard survives | `src-attribute_group` and group properties; hand-written group/source records | R1/R4 |
|
|
422
|
-
|
|
423
|
-
B01/B02/B08/B10/B18/B20/B22/B23 have established narrow clause or selected-contract expectations now. B03-B07/B09/B11-B17/B19/B21 are contract-level expectations independently specified here and require handwritten prepared records, not expectations generated from the implementation. B15's complete numeric work ledger must be authored and independently reviewed in R5 before accepting exact-boundary results; old probe counts are not resolver counts.
|
|
424
|
-
|
|
425
|
-
The matrix does not establish general UPA, scalar equivalence, source-normalization or full restriction predicates by supplying truth tables. R4 adapter tests verify context/operand delivery and refusal when authority is missing; actual predicate acceptance remains with its semantic owner. No essential resolver behavior waits on a theorem about all possible RE01 candidates.
|
|
426
|
-
|
|
427
|
-
## Implementation tasks
|
|
428
|
-
|
|
429
|
-
Each task has one accountable implementing agent identified by a role below; bind that role to the actual agent/session when work starts. The #234 research coordinator integrates the leaf PRs and preserves these acceptance boundaries. Each implementing agent supplies an independent reviewer who did not author the task's material.
|
|
430
|
-
|
|
431
|
-
| Task | Accountable agent role | Dependencies | Bounded deliverable |
|
|
432
|
-
|---|---|---|---|
|
|
433
|
-
| R1 | Context preparation agent | Reviewed #256 specification | `resolver-context.ts` and owned context tests |
|
|
434
|
-
| R2 | Resolution/comparison agent | R1 reviewed interfaces | `resolver-resolution.ts`, `resolver-comparison.ts` and tests |
|
|
435
|
-
| R3 | Relation adapter agent | R1/R2 context lookup | `resolver-relations.ts` and relation tests |
|
|
436
|
-
| R4 | Validation integration agent | R1-R3 and accepted predicate records | `resolver-validation.ts` and delivery tests |
|
|
437
|
-
| R5 | Cache/resource agent | R1-R4 reviewed functions | `resolver-budget.ts`, private cache integration and boundary tests |
|
|
438
|
-
| R6 | Research integration agent | R1-R5 reviewed leaves | Integration evidence, production seam document and handoff |
|
|
439
|
-
| R7 | Fresh final reviewer | Exact R6 commit/tree and required checks | Independent readiness/guarantee review |
|
|
440
|
-
|
|
441
|
-
All modules above live in `test/research/re01/`; no implementation issue is opened by this session. Budget hooks and charge-before-work are part of R1's initial contract and every subsequent leaf; R5 audits/integrates them rather than postponing boundedness. R3 and R2's comparison implementation may run in parallel after R1 and R2's lookup contract are reviewed, with separate files; R4 needs both accepted results and R5 follows their integrated ledger.
|
|
442
|
-
|
|
443
|
-
### R1: Prepare explicit identities and contexts
|
|
444
|
-
|
|
445
|
-
Implement the readonly view validation, original/addition indexes, endpoint-only replacement, membership/outgoing closure, excluded-incoming manifest and forbidden-edge traversal. Own `resolver-context.ts`, a minimal shared type file and context tests only. Acceptance is B03-B05/B07/B13/B14/B22/B23 plus preallocation exhaustion controls; the review gate checks every reference/owner edge and all actual-source roles.
|
|
446
|
-
|
|
447
|
-
Semantic uncertainty is low at this structural boundary because actual IDs/owners are supplied and all membership rules are explicit. Integration depends on independently prepared research facts, not production extraction. Verification is moderately involved: cycle-kind distinctions, transitive excluded affiliation and local owner sharing need separate literal fixtures.
|
|
448
|
-
|
|
449
|
-
### R2: Resolve deterministically and verify endpoint correspondence
|
|
450
|
-
|
|
451
|
-
Implement validated owner/slot lookup in the caller context and the exact non-derivation endpoint projection/certificate check. Own resolution/comparison modules and their tests; retain direct references rather than materializing recursive trees. Acceptance is B01/B06/B07/B13/B17 and wrong-slot/forged-context controls, with no schema-legality success inferred from `ok`.
|
|
452
|
-
|
|
453
|
-
Semantic uncertainty is bounded by the selected D1 anchored-identity policy; source-representable fresh AU equivalence is excluded from this task. Integration depends on R1's issued handles and budget. Verification difficulty comes from ordered particle edges versus AU set incidence and the anchored type/owner expansion stop; reviewers trace every comparison edge to the specification.
|
|
454
|
-
|
|
455
|
-
### R3: Provide context-aware derivation and substitution relations
|
|
456
|
-
|
|
457
|
-
Implement the dated complex/simple TypeDerivationOK control flow and substitution affiliation/group relation using context lookup and explicit exclusions/final/block inputs. Builtin relationships come from the existing semantic owner or a reviewed fixed research table; do not copy a second scalar evaluator. Own the relation module and B01/B02/B08-B10 tests, plus same-type, union/list, head cycle and block/final contrasts.
|
|
458
|
-
|
|
459
|
-
Semantic uncertainty concerns authority coverage, not how contexts resolve: supplied tables do not prove complete simple-type semantics. The leaf must document each builtin/simple-rule premise and return unresolved for an unqualified premise; introducing a general scalar engine is outside scope. Its reviewer checks the simple rule independently, immediate identity tests before traversal and all excluded-method permutations.
|
|
460
|
-
|
|
461
|
-
### R4: Enumerate required checks and integrate owned predicates
|
|
462
|
-
|
|
463
|
-
Implement the finite all-member obligation inventory and narrow direct adapters with context/operand/authority receipts. Own validation module/tests; integrate accepted AU01 source roles and PW01/DT01 only where invoked, while treating unimplemented complete component predicates as explicit unresolved entries. Acceptance is B08/B10/B18-B23 and a scoped checked-candidate receipt only when the entire named inventory has qualified passes.
|
|
464
|
-
|
|
465
|
-
Semantic uncertainty remains in broader RE01 full-type predicates and is not hidden inside coding: this task implements context delivery and an honest completeness ledger, not their missing proofs. Integration depends on R3 and the accepted sibling artifacts; verification must capture original raw particles, every AU constraint, excluded substitution members and distinct attribution positions. Independent review rejects any subset-of-checks shortcut or reuse of actual context receipts.
|
|
466
|
-
|
|
467
|
-
### R5: Audit cache isolation and inclusive resources
|
|
468
|
-
|
|
469
|
-
Integrate request-local cache keys/states and audit every index, sort, text, queue, predicate, copy and output charge against the published cost model. Own budget/cache modules and boundary tests, with narrowly reviewed changes in predecessor modules where a charge is missing. Acceptance is B11-B16, a handwritten independently reviewed work ledger and exact at/one-below controls for one complete finite request.
|
|
470
|
-
|
|
471
|
-
There is no semantic uncertainty about exhaustion: it proves no negative conclusion and yields no partial success. Integration depends on all charging hooks and predicate costs; verification is difficult because cache hits, boundary census, freezing and diagnostics can hide work. The review gate audits before-allocation accounting and a fresh valid request after each failure class.
|
|
472
|
-
|
|
473
|
-
### R6: Integrate research behavior and implementation handoff
|
|
474
|
-
|
|
475
|
-
Complete all matrix rows on the combined research modules, reproduce existing endpoint/group/particle and new substitution controls, update hashes and document the exact future production adapter seam. Own combined tests, affected documentation/provenance and handoff only; do not edit production modules or activate #231. Acceptance requires all required #232 commands on the exact delivered head and a clean deterministic diff.
|
|
476
|
-
|
|
477
|
-
Semantic uncertainty is explicitly inherited from delegated predicates and the whole RE01 theorem; it does not authorize claiming complete candidate legality. Integration is substantial because every leaf's authority and resource receipt must survive combination. Independent verification checks that a positive resolver result, a supplied-predicate conditional check and a proved full-type witness are reported separately.
|
|
478
|
-
|
|
479
|
-
### R7: Review exact delivery independently
|
|
480
|
-
|
|
481
|
-
The fresh reviewer reads this assignment/specification/references without previous chat, reviews the exact R6 commit/tree and traces all behavioral cases to contracts. The deliverable is a verdict naming missing semantics, omissions, cache/resource findings and any qualifications, followed by renewed review after substantive changes. No code or specification author may supply this verdict for their own material.
|
|
482
|
-
|
|
483
|
-
The first ready task after specification readiness review is R1. R3's qualification limits and R4's unresolved semantic receipts are explicit implementation behavior, not unspecified resolver decisions. A new essential resolver question requires a focused prerequisite with a written counterexample, source clauses, proposed contract amendment and reviewed exit condition before dependent work proceeds.
|
|
484
|
-
|
|
485
|
-
## Proof boundary and handoff
|
|
486
|
-
|
|
487
|
-
This specification fixes one-context resolution, member/closure boundaries, identity preservation, explicit hypothetical AU roles, anchored endpoint comparison, validation ownership and deterministic bounded request behavior. Research implementation readiness means those contracts and tasks can be implemented without inventing a hidden semantic policy; it does not mean every delegated XSD predicate has already been implemented or the RE01 theorem proved.
|
|
488
|
-
|
|
489
|
-
#234 still owns positive full-type witness soundness, complete candidate-family reduction including original intermediate identities, content/simple/mixed cases, source-valid normalization/all placement, AU integration, anonymous scalar identity, ambient-schema preservation assumptions and the complete negative-answer/termination theorem with sufficient resources. An unsuccessful candidate, rejected certificate, smaller-context success or resource exhaustion cannot discharge those obligations.
|
|
490
|
-
|
|
491
|
-
#232 still owns joint consistency and independently reviewed research acceptance. #179 retains production adapter/complete legality integration and all guarded qualifications; #153 owns combined S06 acceptance. Accepted AU01/PW01/DT01 are not reopened, and S07/S08 readiness, public support and production activation remain unchanged.
|
|
492
|
-
|
|
493
|
-
### Delivery and verification ledger
|
|
494
|
-
|
|
495
|
-
The specification owner is Codex session `/root` for #256. The independent review, resolved findings, reviewed commit/tree, current command results, hosted checks and implementation readiness verdict belong in the linked draft PR and #256 handoff, avoiding self-referential commit hashes in this document. Substantive changes after review require renewed review of the delivered content.
|
|
496
|
-
|
|
497
|
-
Reproduce with supported Node and existing dependencies:
|
|
498
|
-
|
|
499
|
-
```bash
|
|
500
|
-
npm ci --cache tmp/cache/npm
|
|
501
|
-
npm run reference:setup
|
|
502
|
-
npm run check:toolchain
|
|
503
|
-
npm run docs:validate
|
|
504
|
-
npm run typecheck:research
|
|
505
|
-
npm run typecheck:reference
|
|
506
|
-
npx vitest run test/conformance/s06-research.test.ts test/conformance/reference/re01-substitution-context.test.ts
|
|
507
|
-
npm run ci
|
|
508
|
-
npm run test:reference:full
|
|
509
|
-
npm run test:conformance
|
|
510
|
-
git diff --check
|
|
511
|
-
```
|
|
512
|
-
|
|
513
|
-
IDE inspections are unavailable; repository documentation/snippet validation, scoped TypeScript, provenance, executable reference controls and independent review supply portable verification. #256 remains open until this specification has no essential resolver blockers, passes the independent review/checks and reaches main through normal protected merges; an unmerged parent branch alone does not satisfy closure.
|