ModelManifest

dicechess.engine.model.ModelManifest
See theModelManifest companion class
object ModelManifest

Attributes

Companion
class
Source
ModelManifest.scala
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Type members

Inherited and Abstract types

type MirroredElemLabels <: Tuple

The names of the product elements.

The names of the product elements.

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type.

The name of the type.

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def computeSha256(path: Path): Either[String, String]

The SHA-256 of the file at path, lowercase hex, streamed rather than buffered whole.

The SHA-256 of the file at path, lowercase hex, streamed rather than buffered whole.

Attributes

Source
ModelManifest.scala
def load(path: Path): Either[String, ModelManifest]

Reads and parses the manifest at path, tagging every message with the file it came from.

Reads and parses the manifest at path, tagging every message with the file it came from.

Attributes

Source
ModelManifest.scala
def parse(text: String): Either[String, ModelManifest]

Parses manifest JSON, applying the per-version defaults described in ModelManifest. Structural only: the values are checked by validate, which a caller that assembled a manifest by hand still owes.

Parses manifest JSON, applying the per-version defaults described in ModelManifest. Structural only: the values are checked by validate, which a caller that assembled a manifest by hand still owes.

Attributes

Source
ModelManifest.scala
def validate(manifest: ModelManifest, engineVersion: String): Either[String, Unit]

Checks every field whose violation would mis-serve the model, first failure wins.

Checks every field whose violation would mis-serve the model, first failure wins.

engineVersion is the host's engine version, stated by the host rather than discovered: a library cannot reliably read its own version (there is no jar manifest on a test or sbt classpath), and guessing it would turn a compatibility gate into a coin flip. It must be a release MAJOR.MINOR.PATCH — a host running a -SNAPSHOT passes the release it derives from, matching the comparator grammar the training and evaluation sides already implement.

Attributes

Source
ModelManifest.scala
def verifyDigest(modelPath: Path, manifest: ModelManifest): Either[String, Unit]

Proves the manifest describes these exact bytes. A mismatch means the pair is not a package — either the model was replaced after the manifest was written or the two come from different runs — and nothing about the manifest's other promises can be trusted.

Proves the manifest describes these exact bytes. A mismatch means the pair is not a package — either the model was replaced after the manifest was written or the two come from different runs — and nothing about the manifest's other promises can be trusted.

Attributes

Source
ModelManifest.scala

Concrete fields

val CurrentVersion: String

The manifest version this engine writes about in documentation and expects from a new artifact.

The manifest version this engine writes about in documentation and expects from a new artifact.

Attributes

Source
ModelManifest.scala
val DefaultInputName: String

Attributes

Source
ModelManifest.scala
val DefaultOutputName: String

Attributes

Source
ModelManifest.scala
val LegacyVersion: String

The version the evaluation service and the kcp-13 serving contract emit, accepted in the ModelRole.PositionValue role with this object's defaults filled in.

The version the evaluation service and the kcp-13 serving contract emit, accepted in the ModelRole.PositionValue role with this object's defaults filled in.

Attributes

Source
ModelManifest.scala
val MoverPerspective: String

The only perspective this engine can consume: the feature row and the score are both stated for the color being evaluated (own minus opponent), independent of which side happens to be to move in the position.

The only perspective this engine can consume: the feature row and the score are both stated for the color being evaluated (own minus opponent), independent of which side happens to be to move in the position.

Every extractor in FeatureSchema takes that color as an argument, and the search always passes the color it wants the score for — so the engine never performs the 1 - p flip the evaluation service's turn analysis needs (it extracts for state.activeColor instead). Same vectors, same convention, one fewer transformation.

Attributes

Source
ModelManifest.scala
val SupportedPerspectives: Set[String]

Attributes

Source
ModelManifest.scala
val SupportedVersions: Set[String]

Attributes

Source
ModelManifest.scala