Automating BCL Conversion

When a sequencing run is complete, it is often desirable to pass data to CASAVA for BCL conversion automatically rather than manually. This section proposes a method to configure this automation.

NOTE: This solution is not tested end-to-end on an instrument.

The proposed approach involves adding an automation trigger to the Sequencing step, such that it invokes a script that launches the BCL Conversion step.

However, because the BCL Conversion step does not run immediately, it is launched in a dormant state until the Sequencing step is complete.

The key event here is the Run Report that is created and attached to the Sequencing step. As the last event to occur in the step, the creation of this report is used to prompt the BCL Conversion step to 'wake up' from its dormant state and begin processing.

The following pseudocode describes the work that must occur within the script:

Harvest the command line parameters

Use the API to convert the LIMS ID (that was passed to the script as the -r parameter) to a full URI

Craft the XML required to create the Input-Output Map for the BCL Conversion Process with -
- the URI we just discovered as the input artifact to the Input-Output Map

POST the XML to the API 

Solution details

Step 1. Create Script to Launch BCL Conversion Process / Step

A required script that launches the BCL Conversion step via the API might be absent. The creation of such a script is covered in Process Execution with EPP/Automation Support. This example only covers the functionality of the script rather than code.

In addition to the expected processURI, username, and password parameters/tokens, the script should accept another parameter (the LIMSID of the Run Report from the Sequencing step).

For example, the script can be invoked as follows:

/path/to/script/scriptname -i {processURI:v2:http} -u {username} \
-p {password} -r {runreportLIMSID} 

Use this syntax when configuring the command line on the Sequencing process/step.

Step 2. Configure the Clarity LIMS Web Interface

Configure the automation so the script is automatically triggered when exiting the Record Details screen.

Example configuration details

  1. The BCL Conversion process is configured:

    • To take in a ResultFile input and generate a non-shared ResultFile output

    • With a process parameter of 'Standard,' which initiates the actual BCL conversion.

  2. The script is passed the value '92-3771' as the -r parameter.

  3. This is then converted to a full URI and became the input element of the following XML, which is POSTed to the /processes API resource:

<?xml version="1.0" encoding="UTF-8"?>
  <prx:process xmlns:prx="http://genologics.com/ri/processexecution">
    <type>BCL Conversion</type>
    <technician uri="http://localhost:8080/api/v2/researchers/1"></technician>
    <input-output-map shared="false">
       <input uri="http://localhost:8080/api/v2/artifacts/92-3771"></input>
       <output type="ResultFile"></output>
    </input-output-map>
    <process-parameter name="Standard"></process-parameter>
</prx:process>

Notes

  • Update all URIs in the XML to point to the hostname and API version for the system.

  • Provide a valid URI for the lab scientist. There might be a user in the system with LIMS ID of '1'.

  • If the POST is successful, the API returns the valid XML for the created process.

Note: This scenario is one of the few occasions where the POST succeeds, yet returns XML that differs from the input XML. The results can be confusing, because a standard approach for validating whether POSTs are successful is to compare the output XML with the input. If they differ, assume that the POST failed. However, in this scenario it did not fail.

Last updated