Multi-tube design example (advanced)

Design small conditional RNAs (scRNAs) for conditional Dicer substrate formation (Hochrein et al., J Am Chem Soc, 2013; see Figure 3).

See the accompanying design specification (PDF files). See also the LaTeX spec file that you can edit to make your own design specs in a standardized format.

This is a 2-step reaction. To design one scRNA system, there are 3 elementary step tubes plus 1 global crosstalk tube.

Target test tubes:

  • Step 0: Reactants
  • Step 1: Intermediates
  • Step 2: Products
  • Global crosstalk

Material: RNA
Temperature: 23 C

In [1]:
# Import Python NUPACK module
from nupack import *
In [2]:
# Define physical model
my_model = Model(material='rna', celsius=37)

# Define sequence domains
a = Domain('N6', name='a')
c = Domain('N8', name='c')
b = Domain('N4', name='b')
w = Domain('N2', name='w')
y = Domain('N4', name='y')
x = Domain('N12', name='x')
z = Domain('N3', name='z')
s = Domain('N5', name='s')

# Define strands containing these domains
sC_out  = TargetStrand([w, x, y, s], name='sC_out')
sA      = TargetStrand([~c, ~b, ~a, ~z, ~y], name='sA')
sA_toe  = TargetStrand([~c], name='sA_toe')
sC      = TargetStrand([w, x, y, s, ~a, ~z, ~y, ~x, ~w], name='sC')
sC_loop = TargetStrand([s, ~a, ~z], name='sC_loop')
sB      = TargetStrand([x, y, z, a, b], name='sB')
sX      = TargetStrand([a, b, c], name='sX')

# Define target complexes
C      = TargetComplex([sC], 'D2 D12 D4( U5 U6 U3 )', name='C')
B      = TargetComplex([sB], 'U12 U4 U3 U6 U4', name='B')
C_loop = TargetComplex([sC_loop], 'U14', name='C_loop')
AB     = TargetComplex([sA, sB], 'U8 D4 D6 D3 D4(+ U12)', name='AB')
X      = TargetComplex([sX], 'U18', name='X')
XA     = TargetComplex([sX, sA], 'D6 D4 D8(+) U3 U4', name='XA')
C_out  = TargetComplex([sC_out], 'U23', name='C_out')
BC     = TargetComplex([sB, sC], 'D12 D4 D3 D6 (U4 + U2 U12 U4 U5) U2', name='BC')
A_toe  = TargetComplex([sA_toe], 'U8', name='A_toe')

# Define elementary step tubes
Step_0 = TargetTube(on_targets={C: 1e-08, X: 1e-08, AB: 1e-08}, 
    off_targets=SetSpec(max_size=2, include=[[sA], BC], exclude=[XA]), name='Step_0')
Step_1 = TargetTube(on_targets={XA: 1e-08, B: 1e-08}, 
    off_targets=SetSpec(max_size=2, include=[X, AB]), name='Step_1')
Step_2 = TargetTube(on_targets={BC: 1e-08}, 
    off_targets=SetSpec(max_size=2, include=[B, C]), name='Step_2')

# Define global crosstalk tube
Crosstalk = TargetTube(on_targets={
    AB: 1e-08,
    C: 1e-08,
    X: 1e-08,
    B: 1e-08,
    C_out: 1e-08,
    C_loop: 1e-08,
    A_toe: 1e-08,
}, off_targets=SetSpec(max_size=2, exclude=[XA, BC, [sX, sA_toe], [sB, sC_loop]]), name='Crosstalk')

# Define hard sequence constraints

# GC content constraints
hard = [
    Similarity(d, 'S'*d.nt(), limits=(0.45, 0.55)) 
        for d in [sC_out, sA, sC, sC_loop, sB, sX]
]

# Biological sequences 
# Note: biological sequence constraints often require a higher stop condition
tpm3 = 'GAACACTATTAGCTATTTGTAGTACTCTAAAGAGGACTGCAGAACGCATCGCAGTAGTGGTGAAAAGCCGTGCGTGCGCGTGAAACATCTGATCCTCACGTTACTTCCACTCGCTCTGCGTTTGACTTGTTGGCGGGGCGTTGGTGCCTTGGACTTTTTTTTCCTCCTTCTCTTCTTCGCGGCTCGGTCCACTACGCTGCTCGAGAGGAATCTGCTTTATTCGACCACACTACTCCTAAAGTAACACATTAAAATGGCCGGATCAAACAGCATCGATGCAGTTAAGAGAAAAATCAAAGTTTTACAACAGCAAGCAGATGAGGCAGAAGAAAGAGCCGAGATTTTGCAGAGACAGGTCGAGGAGGAGAAGCGTGCCAGGGAGCAGGCTGAGGCAGAGGTGGCTTCTCTGAACAGGCGTATCCAGCTGGTTGAGGAGGAGTTGGATCGTGCTCAGGAGAGACTGGCCACAGCCCTGCAAAAGCTGGAGGAAGCCGAGAAGGCCGCAGATGAGAGCGAGAGAGGGATGAAGGTGATTGAGAACAGGGCTCTGAAGGATGAGGAGAAGATGGAGCTGCAGGAGATCCAGCTTAAGGAGGCCAA'
desm = 'CATTTACACAGCGTACAAACCCAACAGGCCCAGTCATGAGCACGAAATATTCAGCCTCCGCCGAGTCGGCGTCCTCTTACCGCCGCACCTTTGGCTCAGGTTTGGGCTCCTCTATTTTCGCCGGCCACGGTTCCTCAGGTTCCTCTGGCTCCTCAAGACTGACCTCCAGAGTTTACGAGGTGACCAAGAGCTCCGCTTCTCCCCATTTTTCCAGCCACCGTGCGTCCGGCTCTTTCGGAGGTGGCTCGGTGGTCCGTTCCTACGCTGGCCTTGGTGAGAAGCTGGATTTCAATCTGGCTGATGCCATAAACCAGGACTTCCTCAACACGCGTACTAATGAGAAGGCCGAGCTCCAGCACCTCAATGACCGCTTCGCCAGCTACATCGAGAAGGTGCGCTTCCTCGAGCAGCAGAACTCTGCCCTGACGGTGGAGATTGAGCGTCTGCGGGGTCGCGAGCCCACCCGTATTGCAGAGCTGTACGAGGAGGAGATGAGAGAGCTGCGCGGACAGGTGGAGGCACTGACCAATCAGAGATCCCGTGTGGAGATCGAGAGGGACAACCTAGTCGATGACCTACAGAAACTAAAGCTCAGACTTC'

# Window constraints on detection target 'a-b-c' and silencing target 'w-x-y-z'
hard += [Window([a, b, c], [tpm3])]     
hard += [Window([w, x, y, z], [desm])]  

# Diversity constraint
hard += [Diversity(word=4, types=2)]

# Set a stop condition of 8% 
# Set seed for random number generation to get a reproducible result for this demo
my_options = DesignOptions(f_stop=0.08, seed=93)

# Define and run the test tube design job
des = tube_design(tubes=[Step_0, Step_1, Step_2, Crosstalk], model=my_model, hard_constraints=hard, options=my_options)
result = des.run(trials=1)[0]

# Display the result
result
Out[2]:
Domain results:
Domain Sequence
a
AUGAGG
a*
CCUCAU
b
AGAA
b*
UUCU
c
GAUGGAGC
c*
GCUCCAUC
s
AACAC
s*
GUGUU
w
CG
w*
CG
x
AGGAGGAGAUGA
x*
UCAUCUCCUCCU
y
GAGA
y*
UCUC
z
GCU
z*
AGC
Strand results:
Strand Sequence
sC_out
CGAGGAGGAGAUGAGAGAAACAC
sC
CGAGGAGGAGAUGAGAGAAACACCCUCAUAGCUCUCUCAUCUCCUCCUCG
sC_loop
AACACCCUCAUAGC
sA_toe
GCUCCAUC
sB
AGGAGGAGAUGAGAGAGCUAUGAGGAGAA
sX
AUGAGGAGAAGAUGGAGC
sA
GCUCCAUCUUCUCCUCAUAGCUCUC
Objective function:
Objective type Value
Weighted ensemble defect 0.0532
Ensemble defect: 0.0532

On-target complex defects:
Complex Complex defect (nt) Normalized complex defect
C 1.18 0.0237
XA 0.788 0.0183
AB 1.32 0.0245
BC 1.81 0.0229
A_toe 0.00620 0.000775
B 2.16 0.0746
X 0.154 0.00853
C_out 0.639 0.0278
C_loop 0.110 0.00788
Tube defects:
Tube Tube defect (M) Normalized tube defect
Step_0 2.67e-08 0.0219
Step_1 8.14e-08 0.113
Step_2 1.97e-08 0.0249
Crosstalk 1.04e-07 0.0529
Complex contributions to tube defects:
Tube On-target complex Structural defect (M) Concentration defect (M) Total defect (M)
Step_0 C 1.18e-08 3.88e-11 1.19e-08
Step_0 X 1.54e-09 9.12e-15 1.54e-09
Step_0 AB 1.32e-08 4.05e-11 1.33e-08
Step_1 XA 7.29e-09 3.23e-08 3.96e-08
Step_1 B 2.00e-08 2.18e-08 4.18e-08
Step_2 BC 1.80e-08 1.67e-09 1.97e-08
Crosstalk AB 1.32e-08 2.28e-10 1.34e-08
Crosstalk C 1.15e-08 1.46e-08 2.61e-08
Crosstalk X 1.46e-09 8.54e-09 1.00e-08
Crosstalk B 2.14e-08 3.43e-09 2.48e-08
Crosstalk C_out 6.06e-09 1.19e-08 1.79e-08
Crosstalk C_loop 1.03e-09 8.67e-09 9.70e-09
Crosstalk A_toe 6.08e-11 1.57e-09 1.64e-09
On-target complex concentrations:
Tube Complex Concentration (M) Target concentration (M)
Step_0 C 1.00e-08 1.00e-08
Step_0 X 1.00e-08 1.00e-08
Step_0 AB 1.00e-08 1.00e-08
Step_1 XA 9.25e-09 1.00e-08
Step_1 B 9.25e-09 1.00e-08
Step_2 BC 9.98e-09 1.00e-08
Crosstalk AB 1.00e-08 1.00e-08
Crosstalk C 9.71e-09 1.00e-08
Crosstalk X 9.53e-09 1.00e-08
Crosstalk B 9.88e-09 1.00e-08
Crosstalk C_out 9.48e-09 1.00e-08
Crosstalk C_loop 9.38e-09 1.00e-08
Crosstalk A_toe 9.80e-09 1.00e-08
Significant off-target complex concentrations (≥ 1% max complex concentration in tube):
Tube Complex Concentration (M)
Step_1 AB 7.51e-10
Step_1 X 7.51e-10
Crosstalk (sA_toe+sB) 1.22e-10
Crosstalk (sC_out+sC) 2.92e-10
Crosstalk (sC_loop+sC_out) 1.45e-10
Crosstalk (sC_loop+sX) 4.74e-10
Step_2
Step_0