semantifold 0.8.0 → 0.9.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.
@@ -395,6 +395,104 @@
395
395
  * @property {Readonly<Record<string, unknown>>} [metadata] - Detached target-specific JSON metadata.
396
396
  */
397
397
 
398
+ /**
399
+ * @typedef PublicationBuildArtifactInput
400
+ * @property {string} path - Normalized path relative to the target build projection.
401
+ * @property {string} mediaType - Stable media type for the validator/compiler output.
402
+ * @property {string} role - Stable language-neutral role for the validator/compiler output.
403
+ */
404
+
405
+ /**
406
+ * @typedef PublicationValidatorContext
407
+ * @property {string} targetId - Explicit target identity.
408
+ * @property {string} sourcePath - Exact generation-scoped generated-source directory.
409
+ * @property {string} buildPath - Exact generation-scoped compiler-output directory.
410
+ */
411
+
412
+ /** @typedef {(context: Readonly<PublicationValidatorContext>) => Promise<PublicationBuildArtifactInput[] | void> | PublicationBuildArtifactInput[] | void} PublicationValidator */
413
+
414
+ /** @typedef {"text" | "binary" | "application"} PublicationTargetRole */
415
+
416
+ /**
417
+ * @typedef PublicationTargetInput
418
+ * @property {string} id - Explicit project target identity.
419
+ * @property {GeneratedArtifactSet} artifactSet - Complete already-validated generated artifacts.
420
+ * @property {PublicationTargetRole} role - Explicit language-neutral target role.
421
+ * @property {string} sourceProjection - Generation-relative generated-source projection.
422
+ * @property {string} buildProjection - Generation-relative compiler-output projection.
423
+ * @property {readonly PublicationValidator[]} [validators] - Ordered candidate validators.
424
+ */
425
+
426
+ /**
427
+ * @typedef PublicationRequest
428
+ * @property {string} generationId - Unique explicit generation/cycle identity.
429
+ * @property {readonly PublicationTargetInput[]} targets - Complete ordered project targets.
430
+ */
431
+
432
+ /**
433
+ * @typedef GenerationContentHash
434
+ * @property {"sha256"} algorithm - Hash algorithm.
435
+ * @property {string} value - Lowercase hexadecimal digest.
436
+ */
437
+
438
+ /**
439
+ * @typedef GenerationArtifactManifest
440
+ * @property {string} path - Artifact-set-relative path.
441
+ * @property {"text" | "binary"} contentKind - Original artifact content representation.
442
+ * @property {string} mediaType - Declared artifact media type.
443
+ * @property {GeneratedArtifactRole} role - Declared artifact role.
444
+ * @property {ArtifactProvenance} provenance - Complete persisted rich, byte, or synthetic provenance.
445
+ * @property {number} byteLength - Exact staged byte length.
446
+ * @property {GenerationContentHash} hash - Exact staged byte hash.
447
+ */
448
+
449
+ /**
450
+ * @typedef GenerationBuildArtifactManifest
451
+ * @property {string} path - Build-projection-relative path.
452
+ * @property {string} mediaType - Declared validator/compiler output media type.
453
+ * @property {string} role - Declared language-neutral validator/compiler output role.
454
+ * @property {number} byteLength - Exact staged byte length.
455
+ * @property {GenerationContentHash} hash - Exact staged byte hash.
456
+ */
457
+
458
+ /**
459
+ * @typedef GenerationTargetManifest
460
+ * @property {string} id - Explicit project target identity.
461
+ * @property {PublicationTargetRole} role - Explicit language-neutral target role.
462
+ * @property {string} target - Artifact-set backend target identity.
463
+ * @property {{source: string, build: string}} projections - Disjoint generation-relative projections.
464
+ * @property {readonly GenerationArtifactManifest[]} artifacts - Ordered generated artifacts.
465
+ * @property {readonly GenerationBuildArtifactManifest[]} buildArtifacts - Ordered validator/compiler outputs.
466
+ * @property {Readonly<Record<string, unknown>>} [metadata] - Persisted target-specific artifact-set metadata.
467
+ */
468
+
469
+ /**
470
+ * @typedef GenerationManifest
471
+ * @property {"SemantifoldGenerationManifest"} schema - Schema discriminator.
472
+ * @property {1} version - Manifest schema version.
473
+ * @property {string} projectId - Explicit project identity.
474
+ * @property {string} generationId - Explicit generation/cycle identity.
475
+ * @property {readonly GenerationTargetManifest[]} targets - Complete ordered target records.
476
+ */
477
+
478
+ /**
479
+ * @typedef PublishedTargetPaths
480
+ * @property {string} id - Explicit project target identity.
481
+ * @property {PublicationTargetRole} role - Explicit language-neutral target role.
482
+ * @property {string} sourcePath - Exact immutable generated-source directory.
483
+ * @property {string} buildPath - Exact immutable compiler-output directory.
484
+ */
485
+
486
+ /**
487
+ * @typedef PublishedGeneration
488
+ * @property {string} generationId - Resolved generation identity.
489
+ * @property {string} generationPath - Exact immutable generation directory.
490
+ * @property {string} manifestPath - Exact generation manifest path.
491
+ * @property {GenerationManifest} manifest - Verified immutable generation manifest.
492
+ * @property {readonly PublishedTargetPaths[]} targets - Exact generation-scoped target paths.
493
+ * @property {boolean} cleanupPending - Whether post-commit journal cleanup remains for recovery.
494
+ */
495
+
398
496
  /**
399
497
  * @typedef DiscoveredToolchain
400
498
  * @property {string} id - Toolchain ID.