Archetype Command Line Interface

There are a few archetype-specific Cyclus CLI commands that allow introspecting details of archetypes that Cyclus can find. Most expose data that is automatically generated by the Cyclus preprocessor. For example, member variables added with #pragma cyclus var are added to the generated input XML schema. Agents are referenced on the command line by their single-string form spec (e.g. :cycamore:Source) which is discussed here.

To view the auto-generated XML schema used for validating archetype configuration parameters in input files:

$ cyclus --agent-schema :agents:Source
    <element name="commod">
        <data type="token"/>
        <element name="recipe_name">
            <data type="token"/>
    <element name="capacity">
        <data type="double"/>

To view a JSON structured output of all the data generated and collected from #pragma cyclus annotations for a particular archetype:

$ cyclus --agent-annotations :cycamore:Source
 "all_parents": [
 "doc": "This facility acts as a source of material with a fixed...

And to list all archetypes inside a particular library:

$ cyclus --agent-listing :cycamore

Archetype Versioning

The cyclus::Agent class exposes a version() member function which can be queried with the Cyclus CLI. For example,

$ cyclus --agent-version :agents:Source

This is generated from some git version control information. You can make your own version tag information for some archetype like


virtual std::string version() { return "My Version"; }


def version(self):
    return "My Version"

and then access the version with

$ cyclus --agent-version my/path:my_library:MyArchetype
My Version