Structured contract copied for validation or lookup.
- Purpose
- Validate the manifest emitted by `galaxy-tool-cache summarize` before handing it to downstream step Molds.
Pull JSON schema, container, source, inputs/outputs for a Galaxy tool.
Directory Mold with only index.md frontmatter.
target-specific fields are coherent.
eval.md declares cases and check type.
5 typed references; 0 resolver issues.
All on-demand references describe triggers.
Hypothesis references include verification.
Typed Mold references describe what casting consumes and when the generated skill should load each artifact.
Structured contract copied for validation or lookup.
Structured contract copied for validation or lookup.
Background synthesis loaded by explicit progressive-disclosure metadata.
Background synthesis loaded by explicit progressive-disclosure metadata.
Background synthesis loaded by explicit progressive-disclosure metadata.
Deterministic Galaxy tool summary manifest emitted by `galaxy-tool-cache summarize`: cache provenance, embedded ParsedTool, generated input JSON Schemas.
Pin from [[discover-shed-tool]]; identifies which cached ParsedTool to summarize. Authored UDTs from [[author-galaxy-tool-wrapper]] bypass this Mold.
Read a cached Galaxy ParsedTool object for an existing wrapper and emit a compact tool summary that downstream step implementation can bind to. This Mold runs after discover-shed-tool has selected a Tool Shed pin and after the caller has populated galaxy-tool-cache for that pin.
This Mold owns the wrapper summarization step only. It does not search the Tool Shed, choose a version, author XML, or decide how a workflow step should use the wrapper. Its job is to preserve the wrapper’s executable contract: identity, command shape, inputs, outputs, requirements, tests, and any conditional or data-table behavior that could affect binding.
The v1 input-source decision is galaxy-tool-summary-input-source: read cached ParsedTool JSON, using raw XML only as supporting evidence when the cache object is lossy or ambiguous.
The Mold expects:
tool_shed_url, owner, repo, tool_id, version, and changeset_revision.galaxy-tool-cache directory containing the cached ParsedTool JSON for that pin.A single JSON document conforming to galaxy-tool-summary — the deterministic manifest emitted by galaxy-tool-cache summarize from @galaxy-tool-util/cli. Top-level fields: schema_version, tool_id, tool_version, cache_key, source, artifacts, parsed_tool, input_schemas, warnings. The parsed_tool subtree is the upstream parsed-tool payload verbatim; input_schemas.workflow_step and input_schemas.workflow_step_linked carry generated JSON Schemas describing the tool’s inputs at workflow-step authoring time.
This Mold does not hand-author the manifest — it invokes galaxy-tool-cache summarize against a cache populated for the Tool Shed pin. Wrapper-derived facts that are not yet exposed by upstream ParsedTool (currently: requirements, containers, stdio) flow into the manifest additively as Galaxy upstream extends ParsedTool; no Foundry-side schema change is needed when they ship.
Locate the ParsedTool JSON in the configured galaxy-tool-cache directory using the Tool Shed pin. Fail early if the cache entry is missing; do not silently re-search the Tool Shed.
Confirm the cached identity matches the requested pin. If the cache exposes a tool id or version that conflicts with the pin, emit a hard failure rather than summarizing the wrong wrapper.
Populate source from the discovery pin and cache metadata. Populate tool from the parsed wrapper identity fields, not from the search hit. Search hits can omit version and changeset detail.
Keep both forms when they differ:
id for human matching.Read <requirements> into structured package/container requirements. Preserve requirement type, name, version, and any container URI or resolver hints exposed by the cache.
Do not invent Bioconda equivalences here. Equivalence inference belongs to author-galaxy-tool-wrapper when authoring a new UDT. Existing wrapper summaries report what the wrapper declares.
Preserve the command template enough for downstream binding to understand which inputs and parameters are consumed. Record strict-shell, stdio regexes, exit-code handling, environment variables, and dynamic output behavior when present.
The command summary should be readable, but lossy prose is not enough. Keep template fragments and wrapper flags where they affect required inputs, output discovery, or runtime failure classification.
For every wrapper input parameter, emit:
name and label/help text when available.data, data_collection, select, integer, float, boolean, text, conditional section, repeat, section).Nested conditionals must preserve branch ownership. Do not flatten when branches into independent parameters without recording the controlling selector and branch value.
For every output and collection output, emit:
from_work_dir or discovery rule when available.If output discovery depends on runtime filenames, record that as a warning for downstream test and debug Molds.
Summarize wrapper tests into input fixture expectations, parameter settings, and output assertions. Do not treat wrapper tests as workflow tests; they are evidence about legal parameter combinations and output behavior.
Preserve citations, help text, and upstream URLs when present because they help resolve ambiguous wrappers during review.
Warnings should identify missing or lossy surfaces, especially: