Child pages
  • Developing Algorithms for the HTRC Framework

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


  • Algorithm name
  • Short name for the algorithm (at most 8 characters in length)
  • Version
  • Brief text description
  • Authors
  • User input parameters, name, type, label, brief description
  • Name of the shell script wrapper
  • Name of the property file expected
  • Key-value pairs for each property to be written to the property file
    • Bash-style variables are used to refer to input parameters and system-provided values
  • Names and types of result files, and whether they are optional

An example algorithm XML file is provided below.

Code Block
titleExample of an algorithm XML file

    <description>TestAlgorithm performs ABC analysis and produces XYZ results.</description>
        <author name="Htrc Superuser"/>
            <label>Please select a collection for analysis</label>
            <description>A collection argument example.</description>
            <label>Select a number</label>
            <description>An example of a non-collection argument.</description>

  <!-- walltime should have the form hhh:mm:ss or hh:mm:ss -->
    <input_size min="0" max="500">
    <input_size min="501" max="3000">


      <e key="volume_id">$input_collection</e>
      <e key="num">$n</e>
      <e key="max_volumes">2000</e>
      <e key="token">$auth_token</e>
      <e key="data_api_url">$data_api_url</e>
      <e key="output_folder">$output_dir</e>

      <result type="text/html" name="output.html"/>
      <!-- if the "optional" attribute is true, then the result may or may not be produced in a successful job run; "optional" name="output.html is false by default -->
      <result type="text/plain" name="volume_errors.txt" optional="true"/>



The <results> element describes all the result files produced by the algorithm. It also Each <result> element specifies the name and MIME type of each the result file. In addition, an "optional" attribute may also be specified. If "optional" is true, then the result may or may not be produced in a successful job run. "optional" is false by default. A value of false indicates that the result is produced in successful job runs.