Invocation, options and results
Linktopaz lispex embed run
topaz lispex embed run --source <rule.lspx> --input <value.lpxvalue> --limits <limits.json> --output <new-directory>
Input
Require exactly one each of -, -, - and -. Their order is free. Paths are nonempty separate arguments and may not be mistaken for another option.
Reject positional operands, missing or repeated options, equals forms and all unlisted options. In particular reject compiler, language, root and output format selectors.
Read source, input and limits as named regular files. Reject symlinks and special files. The limits file is UTF-8 JSON using topaz. and is at most 65536 bytes. Source and canonical input must satisfy the byte ceilings declared by those limits.
Options and conflicts
| Option | Default | Contract | Conflicts |
|---|---|---|---|
--source <rule.lspx> | Not specified | Takes the indicated value. Required. | None listed |
--input <value.lpxvalue> | Not specified | Takes the indicated value. Required. | None listed |
--limits <limits.json> | Not specified | Takes the indicated value. Required. | None listed |
--output <new-directory> | Not specified | Takes the indicated value. Required. | None listed |
Output channels
stdout
stderr
Exit status
0
A complete settled evaluator report is published, including a recorded semantic failure or limit exhaustion.
2
Command usage or limits file validation fails.
3
Source or input admission, output destination checks, staging, writing or publication without replacement is refused.
4
Evaluator selection, admitted component verification, an engine contract or engine operation fails.
Effects
The output parent must already exist. Require a new UTF-8 directory name and reject every existing destination, including an existing empty directory or symlink.
Write report and result files into a private sibling staging directory. Publish that directory without replacement only after every required file has been written. A competing creation of the destination is a refusal.
On failure retain the caller source, input, limits and existing destination bytes. Remove only the staging directory created by this invocation. A failure to clean private staging must not authorize deletion elsewhere.
The admitted evaluator is embedded in the executable. Do not discover, download or fall back to another evaluator. Evaluation has no filesystem, network or process capability.
With identical source bytes, canonical input bytes, limits, evaluator bytes, runtime policy, target and product release, a settled report and result have identical bytes.
Private staging names and host operational failures are outside the semantic result. An engine fault or transport refusal must not be rewritten as a deterministic semantic outcome.
This command does not load topaz., topaz. or a registry. Relative paths are resolved from the invocation directory and do not select a package.
The embedded component identity is fixed by the installed product. There is no component selector, dependency resolution or lock update.
Operation
LinkSupply the embedded evaluator request shape accepted by the installed component. Language and resource constraints belong to that request.
Example contract
LinkExample contract
The invocation topaz lispex embed run main. is expected to exit with 2.
The restricted embedded-evaluator parser rejects the positional fixture operand. No evaluator request is executed and no output directory is created.
Why
An evaluator request names its source, input, limits, and output separately. Rejecting an unlabelled operand prevents a path from being assigned the wrong role.
Source evidence
- compiler/crates/topaz_cli/src/command/flags.rs at
b48527d0a174 - compiler/crates/topaz_cli/src/lispex_embed.rs at
b48527d0a174
Behavior contract
LinkCommand behavior
Arguments and rejection
Require exactly one each of -, -, - and -. Their order is free. Paths are nonempty separate arguments and may not be mistaken for another option.
Reject positional operands, missing or repeated options, equals forms and all unlisted options. In particular reject compiler, language, root and output format selectors.
Read source, input and limits as named regular files. Reject symlinks and special files. The limits file is UTF-8 JSON using topaz. and is at most 65536 bytes. Source and canonical input must satisfy the byte ceilings declared by those limits.
Output
A successful invocation writes no report to standard output. It publishes report. using topaz. in the requested directory. Publish result. only when the settled outcome supplies a canonical result.
The report contains schema, admission, execution, operations, outcome, semantic and portable. outcome records string fields category, operation and code. semantic records the admitted component and codec identities, limits and source and input digests, with a result digest or null. The Lispex outcomes contract distinguishes canonical settlement from admission and interrupted attempts.
Human usage, refusal and engine explanations use standard error. There is no human rendering of the result directory and no - option. Its fixed JSON report and canonical value file are artifacts of evaluation.
Exit status
Exit 0 only after the complete settled report has been published. A semantic failure or limit exhaustion recorded by the evaluator is a settled outcome and still exits 0.
Exit 2 for CLI usage errors or an unreadable, oversized, non UTF-8 or invalid limits file.
Exit 3 for source or canonical input refusal, size violations, an invalid or already existing output destination, inability to reserve staging storage, or failure to write or publish the output without replacement.
Exit 4 for evaluator identity or selection failure, violated component contracts, engine faults or operational failures inside the evaluator.
Filesystem effects
The output parent must already exist. Require a new UTF-8 directory name and reject every existing destination, including an existing empty directory or symlink.
Write report and result files into a private sibling staging directory. Publish that directory without replacement only after every required file has been written. A competing creation of the destination is a refusal.
On failure retain the caller source, input, limits and existing destination bytes. Remove only the staging directory created by this invocation. A failure to clean private staging must not authorize deletion elsewhere.
Network access
The admitted evaluator is embedded in the executable. Do not discover, download or fall back to another evaluator. Evaluation has no filesystem, network or process capability.
Reproducibility
With identical source bytes, canonical input bytes, limits, evaluator bytes, runtime policy, target and product release, a settled report and result have identical bytes.
Private staging names and host operational failures are outside the semantic result. An engine fault or transport refusal must not be rewritten as a deterministic semantic outcome.
Packages and locks
This command does not load topaz., topaz. or a registry. Relative paths are resolved from the invocation directory and do not select a package.
The embedded component identity is fixed by the installed product. There is no component selector, dependency resolution or lock update.
Why
Source, canonical input, limits and output have different roles and require named path options. A settled language outcome is useful output even when evaluation fails semantically. Separating that outcome from usage, refusal and engine failures preserves the evidence the caller requested.
Source evidence
- compiler/crates/topaz_cli/src/command/flags.rs at
b48527d0a174 - compiler/crates/topaz_cli/src/lispex_embed.rs at
b48527d0a174
The linked public CLI recipe checks the exact displayed argument rejection before the requested operation. It does not execute the successful operation or verify its effects.
The reviewed recipe only checks rejection of a positional source operand. Evaluation with three input files and creation of an output directory is outside the execution allowlist.
Example
LinkArgument-rejection example
Linkfunction identity<T>(value: T) -> T {value}
Expected result
Expected result
Textual rejection details remain Pending in the reference model. The independent Tools example gate expects exit 2.
The restricted embedded-evaluator parser rejects the positional fixture operand. No evaluator request is executed and no output directory is created.
Source evidence
- compiler/crates/topaz_cli/src/command/flags.rs at
b48527d0a174 - compiler/crates/topaz_cli/src/lispex_embed.rs at
b48527d0a174
Verification scope
LinkObserved with Topaz 5.21.3 on 2026-11-06T08:36:29.642Z. This invocation passed; exit 2. 3 assertions were evaluated against the independent expected result. Execution record. This result covers the displayed invocation.