Towards a Programming Language for Biology Protocols Bill Thies Joint work with Vaishnavi Ananthanarayanan Microsoft Research India.

Slides:



Advertisements
Similar presentations
GMD German National Research Center for Information Technology Darmstadt University of Technology Perspectives and Priorities for Digital Libraries Research.
Advertisements

System Integration and Performance
Computer Abstractions and Technology
The Assembly Language Level
CSC 2400 Computer Systems I Lecture 3 Big Ideas. 2 Big Idea: Universal Computing Device All computers, given enough time and memory, are capable of computing.
Computer-Aided Design for Microfluidic Chips Based on Multilayer Soft Lithography Nada Amin 1, William Thies 2, Saman Amarasinghe 1 1 Massachusetts Institute.
Microfluidic Biochips: Design, Programming, and Optimization Bill Thies Joint work with Vaishnavi Ananthanarayanan, J.P. Urbanski, Nada Amin, David.
Towards a High-Level Programming Language for Standardizing and Automating Biology Protocols Vaishnavi Ananthanarayanan and William Thies Microsoft Research.
EET 4250: Chapter 1 Performance Measurement, Instruction Count & CPI Acknowledgements: Some slides and lecture notes for this course adapted from Prof.
CS533 - Concepts of Operating Systems
Improving Rural Healthcare Delivery via Transparent Monitoring Bill Thies Microsoft Research India In collaboration with Manish Bhardwaj 1,2, Sara Cinnamon.
Chapter 7 design rules.
Chapter 6: An Introduction to System Software and Virtual Machines
Technologies for Healthcare Delivery Bill Thies Microsoft Research India Joint work with Vaishnavi Ananthanarayanan, Michael Paik, Manish Bhardwaj, Emma.
Isolation of Plasmid DNA June 21, 2007 Leeward Community College.
Plasmid DNA Isolation Exercise 8.
Genomic DNA purification
Programmable Microfluidics Bill Thies Computer Science and Artificial Intelligence Laboratory Massachusetts Institute of Technology UC Berkeley – October.
Technology for Emerging Markets group Offline Wikipedia on Low-Cost Devices Bill Thies Joint work with Gaurav Paruthi and Arunesh Mathur.
Types of software. Sonam Dema..
 A data processing system is a combination of machines and people that for a set of inputs produces a defined set of outputs. The inputs and outputs.
GTL User Facilities Facility II: Whole Proteome Analysis Michelle V. Buchanan.
Tabu Search-Based Synthesis of Dynamically Reconfigurable Digital Microfluidic Biochips Elena Maftei, Paul Pop, Jan Madsen Technical University of Denmark.
Virtualization Technology Prof D M Dhamdhere CSE Department IIT Bombay Moving towards Virtualization… Department of Computer Science and Engineering, IIT.
Design and Verification Tools for Continuous Fluid Flow- based Microfluidic Devices Jeffrey McDaniel, Auralila Baez, Brian Crites, Aditya Tammewar, Philip.
Chapter 1 CSF 2009 Computer Abstractions and Technology.
Bringing Programmability to Experimental Biology Bill Thies Joint work with Vaishnavi Ananthanarayanan, J.P. Urbanski, Nada Amin, David Craig, Jeremy Gunawardena,
Database System Development Lifecycle © Pearson Education Limited 1995, 2005.
An Introduction Chapter Chapter 1 Introduction2 Computer Systems  Programmable machines  Hardware + Software (program) HardwareProgram.
BIOLOGY 3020 Fall 2008 “Keys of Corn” Project Plasmid isolation Genetic Diversity in corn. Lots of different types of corn are offered for sale at the.
1 SWE 513: Software Engineering Usability II. 2 Usability and Cost Good usability may be expensive in hardware or special software development User interface.
Introduction and Overview Questions answered in this lecture: What is an operating system? How have operating systems evolved? Why study operating systems?
Programmable Microfluidics Using Soft Lithography J.P. Urbanski Advisor: Todd Thorsen Hatsopoulos Microfluidics Lab, MIT January 25/2006.
CHAPTER FOUR COMPUTER SOFTWARE.
Purification of DNA from a cell extract In addition to DNA, bacterial cell wall extract contain significant quantities of protein and RNA. A variety of.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
EET 4250: Chapter 1 Computer Abstractions and Technology Acknowledgements: Some slides and lecture notes for this course adapted from Prof. Mary Jane Irwin.
Sogang University Advanced Computing System Chap 1. Computer Architecture Hyuk-Jun Lee, PhD Dept. of Computer Science and Engineering Sogang University.
Low-Cost, High-Latency, Unlimited-Bandwidth Communication Kentaro Toyama Assistant Managing Director Microsoft Research India WWW 2007 Banff – May 9, 2007.
The Beauty and Joy of Computing Lecture #3 : Creativity & Abstraction UC Berkeley EECS Lecturer Gerald Friedland.
Invitation to Computer Science 5 th Edition Chapter 6 An Introduction to System Software and Virtual Machine s.
Week 7 Wednesday: –Screening of library transformants –Innoculation of colonies for plasmid preps –Practice PCR Turn in Lab #11 Thursday: –Plasmid minipreps.
Programmable Microfluidics William Thies*, J.P. Urbanski †, Mats Cooper †, David Wentzlaff*, Todd Thorsen †, and Saman Amarasinghe * * Computer Science.
1 Towards Optimal Custom Instruction Processors Wayne Luk Kubilay Atasu, Rob Dimond and Oskar Mencer Department of Computing Imperial College London HOT.
1 International Technology University CEN 951 Computer Architecture Lecture 1 - Introduction.
CAPE Biology Workshop on Concepts in Biotechnology & Genetic Engineering Prepared and presented by Dr. Marcia E. Roye.
Fall 2004EE 3563 Digital Systems Design EE 3563 VHSIC Hardware Description Language  Required Reading: –These Slides –VHDL Tutorial  Very High Speed.
Chapter 1 Computer Abstractions and Technology. Chapter 1 — Computer Abstractions and Technology — 2 The Computer Revolution Progress in computer technology.
Technology and Design for Socio-Economic Development
1 Text Reference: Warford. 2 Computer Architecture: The design of those aspects of a computer which are visible to the programmer. Architecture Organization.
A Nanoliter-Scale Nucleic Acid Processor with Parallel Architecture Jong Wook Hong, Vincent Studer, Giao Hang, W French Andreson, Stephen R Quake presented.
Abstraction Layers for Scalable Microfluidic Biocomputers William Thies*, J.P. Urbanski †, Todd Thorsen † and Saman Amarasinghe * * Computer Science and.
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Control Unit.
Wajid Minhass, Paul Pop, Jan Madsen Technical University of Denmark
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
Chapter 1 Basic Concepts of Operating Systems Introduction Software A program is a sequence of instructions that enables the computer to carry.
MOLECULAR BIOLOGY IN ACTION In this project, students will use what they have learned in the previous courses to complete a larger multi-step molecular.
Riyadh Philanthropic Society For Science Prince Sultan College For Woman Dept. of Computer & Information Sciences CS 251 Introduction to Computer Organization.
Miniprep 학기 기초유전학실험.
1 Chapter 1 Basic Structures Of Computers. Computer : Introduction A computer is an electronic machine,devised for performing calculations and controlling.
Gene Expression PowerPoint presentation text copied directly from NJCTL with corrections made as needed. Graphics may have been substituted with a similar.
Invitation to Computer Science 6th Edition
The Development Process of Web Applications
COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE
Sample Projects MSR India: TEM Rural Microfinance and IT
Programmable Microfluidics Bill Thies Joint work with J. P
T Computer Architecture, Autumn 2005
DNA Extraction from Blood
HIGH LEVEL SYNTHESIS.
Presentation transcript:

Towards a Programming Language for Biology Protocols Bill Thies Joint work with Vaishnavi Ananthanarayanan Microsoft Research India

Microsoft Research India Established January, 2005 Seven research areas –Algorithms –Cryptography, Security & Applied Math –Graphics and Visualization –Mobility, Networks, and Systems –Multilingual Systems –Rigorous Software Engineering –Technology for Emerging Markets Contributions to Microsoft: –MultiPoint, Netra, Virtual India Currently ~55 full-time staff, growing Collaborations with government, academia, industry, and NGOs in India Microsoft Research India Sadashivnagar, Bangalore

“Technology for Emerging Markets” Understand potential technology users in developing communities Design and evaluate technology and systems that contribute to socio-economic development of poor communities worldwide Collaborate with development- focused organizations for sustained, scaled impact Computer-skills camp in Nakalabande, Bangalore (MSR India, Stree Jagruti Samiti, St. Joseph’s College) Research Group Goals

Multidisciplinary Research Aishwarya Lakshmi Ratan – Public Administration and International Development Jonathan Donner –Communications Nimmi Rangaswamy – Social Anthropology Indrani Medhi – Design Kentaro Toyama (Group Lead) – Computer Science Society Group Technology Individual Society Group Technology Individual Innovation Understanding Impact Innovation Understanding Impact Rikin Gandhi – Astrophysics Bill Thies - Computer science Saurabh Panjwani - Computer science David Hutchful – Human Computer Interaction

Kelsa+ Microfinance & TechnologyIT and Microentrepreneurs Information ecology of very small businesses Potential of technology to support microfinance Microenterprise PC + mobile Mixed-method study Research only Text-Free UI Text-free user interfaces for non-literate users User interfaces PC Design User studies Guidelines Microfinance PC + mobile Qualitative studies Business analysis Research only Sample Projects Information access PC Qualitative study Usage analysis Pilot Featherweight Multimedia Paper and cheap electronics for low-cost multimedia General education Electronics HCI User studies Prelim research Simultaneous Shared Access Primary education PC HCI User studies Software SDK Warana UnwiredDigital Green Video and mediated instruction for agriculture extension Substitution of mobile phones for rural PC kiosks Agriculture Video Intervention Control trials Pilot Info systems Mobile Intervention Rural kiosks Pilot Free access PCs for low- income office staff Multi-user systems for educational

1. PowerPoint Presentations on DVD - TV / DVD is cheap, robust, easy to use - We converted one CLT subject to DVD - CLT liked it, moved all content to DVD - In schools, teachers prefer TV / DVD 2. Books and Encyclopedias on DVD - Developed tool to map 90K pages to DVD - Almost done: 1,000 children’s books on 1 DVD - Next: Wikipedia (Hindi full or English subset) - Usability studies planned in libraries Can we leverage the advanced features of DVD players to extend the reach of interactive educational materials? Interactive DVDs for Education with Kiran, Gaurav, CLT India, Int’l Digital Children’s Library, Pratham Books, … RMB 7 per book RMB 7 per 1,000 books Computer TV / DVD

Key milestones: - Prototype fingerprint + netbook + SMS system  Successful 1-week field trials in Delhi, Sep Evaluated accuracy of reporting data over mobiles  For low-education health workers, live operator is best Can we utilize lightweight mobile devices to ensure that tuberculosis patients receive and take their medication? Technology for Tuberculosis Treatment with Michael Paik, Innovators In Health, and Operation Asha BiometricsPhoneSmart pillbox

Towards a Programming Language for Biology Protocols Bill Thies Joint work with Vaishnavi Ananthanarayanan Microsoft Research India

Microfluidic Chips Idea: a whole biology lab on a single chip –Input/output –Sensors: pH, glucose, temperature, etc. –Actuators: mixing, PCR, electrophoresis, cell lysis, etc. Benefits: –Small sample volumes –High throughput –Low-cost Applications: –Biochemistry - Cell biology –Biological computing 1 mm 10x real-time

Moore’s Law of Microfluidics: Valve Density Doubles Every 4 Months Source: Fluidigm Corporation (

Moore’s Law of Microfluidics: Valve Density Doubles Every 4 Months Source: Fluidigm Corporation (

Current Practice: Manage Gate-Level Details from Design to Operation For every change in the experiment or the chip design: 1. Manually draw in AutoCAD 2. Operate each gate from LabView fabricate chip

Abstraction Layers for Microfluidics C x86 Pentium III, Pentium IV Silicon Analog transistors, registers, … Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3

Abstraction Layers for Microfluidics Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3 BioStream Language [IWBDA 2009] Contributions Optimized Compilation [Natural Computing 2007] Demonstrate Portability [DNA 2006] Micado AutoCAD Plugin [MIT 2008, ICCD 2009] Digital Sample Control Using Soft Lithography [Lab on a Chip ‘06]

Abstraction Layers for Microfluidics Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3 BioStream Language [IWBDA 2009] Contributions Optimized Compilation [Natural Computing 2007] Demonstrate Portability [DNA 2006] Micado AutoCAD Plugin [MIT 2008, ICCD 2009] Digital Sample Control Using Soft Lithography [Lab on a Chip ‘06]

“Immunological detection... was carried out as described in the Boehringer digoxigenin-nucleic acid detection kit with some modifications.”

Problems with Existing Descriptions of Protocols Incomplete –Cascading references several levels deep –Some information missing completely Ambiguous –One word can refer to many things –E.g., “inoculate” a culture Non-uniform –Different words can refer to the same thing –E.g., “harvest”, “pellet down”, “centrifuge” are equivalent Not suitable for automation

Towards a High-Level Programming Language for Biology Protocols 1. Enable automation via microfluidic chips 2. Improve reproducibility of manual experiments In biology publications, can we replace the textual description of the methods used with a computer program?

The BioStream Language BioStream is a protocol language for reuse & automation –Portable –Volume-independent –Initial focus: molecular biology Implemented as a C library –Used to express 37 protocols, 3800 lines of code –General backend: emit readable instructions for human –Restricted backend: automatic execution on microfluidic chips Validation –Used to direct actions of scientists in the lab (IISc) –Used to control microfluidic chips (MIT) –Standardizing online Wiki; interest from Berkeley, UW, UMN…

Declaration / measurement / disposal - declare_fluid - declare_column - measure_sample - measure_fluid - volume - discard - transfer - transfer_column - declare_tissue Combination / mixing - combine - mix - combine_and_mix - addto_column - mixing_table Centrifugation - centrifuge_pellet - centrifuge_phases - centrifuge_column Temperature - set_temp - use_or_store - autoclave Timing - wait - time_constraint - store_until - inoculation - invert_dry Detection - ce_detect - gas_chromatography - nanodrop - electrophoresis - mount_observe_slide - sequencing Language Primitives

FluidSample f1 = measure_and_add(f0, lysis_buffer, 100*uL); FluidSample f2 = mix(f1, INVERT, 4, 6); time_constraint(f1, 2*MINUTES, next_step); Example: Plasmid DNA Extraction I. Original protocol (Source: Klavins Lab) II. BioStream code III. Auto-generated text output Add 100 ul of 7X Lysis Buffer (Blue) and mix by inverting the tube 4-6 times. Proceed to step 3 within 2 minutes. Add 100 ul of 7X Lysis Buffer (Blue). Invert the tube 4-6 times. NOTE: Proceed to the next step within 2 mins.

Example: Plasmid DNA Extraction Auto-Generated Dependence Graph

1. Data Types Sample FluidSample SolidSample Stock Fluid Solid conceptually infinite volume finite volume measure instruction Can measure symbolic volume which is resolved by compiler / runtime system depending on eventual uses declare_fluid instruction other instructions

2. Standardizing Ad-Hoc Language Need to convert qualitative words to quantitative scale Example: a common scale for mixing –When a protocol says “mix”, it could mean many things –Level 1: tap –Level 2: stir –Level 3: invert –Level 4: vortex / resuspend / dissolve Similar issues with temperature, timing, opacity, …

3. Separating Instructions from Hints How to translate abstract directions? –“Remove the medium by aspiration, leaving the bacterial pellet as dry as possible.” Hints provide tutorial or self-check information –Can be ignored if rest of protocol is executed correctly Separating instructions and hints keeps language tractable –Small number of precise instructions –Extensible set of hints Centrifuge(&medium,...); hint(pellet_dry) Aspirate and remove medium. Leave the pellet as dry as possible.

4. Timing Constraints Precise timing is critical for many biology protocols –Minimum delay: cell growth, enzyme digest, denaturing, etc. –Maximum delay: avoid precipitation, photobleaching, etc. –Exact delay: regular measurements, synchronized steps, etc. May require parallel execution –Fluid f1 = mix(…); useBetween(f1, 10, 10); –Fluid f2 = mix(…); useBetween(f2, 10, 10); –Fluid f3 = mix(f1, f2); Addressed via lazy execution f1f1 f2f2 f3f3 10

Benchmark Suite Textbook: Alkaline lysis with SDS - Miniprep87 Academic lab: 2ab Assembly Protocol133 CTAB DNA Plant Miniprep408 Ligation46 Protein insitu localization120 Restriction digestion48 DNA Miniprep93 Non- radioactive in-situ hybridization163 Plant RNA isolation97 Transformation56 Published paper: Splinkerette PCR143 Touchdown PCR40 Molecular barcodes145 SIRT1 Redistribution180 Transcriptional instability142 Commercial kit: Allprep RNA Protein protocol150 Plasmid purification125 DNA Sequencing110 OpenWetWare: Miniprep/GET Buffer121 DNA Extraction - Salting Out93 Endy: Colony PCR61 Engineering BioBricks - Restriction Digest40 Engineering BioBricks - Colony PCR47 Ethanol precipitation of small DNA fragments52 Filamentous fungi genomic DNA isolation119 Knight: Colony PCR53 Maxiprep168 Miniprep/Kit-free high-throughput75 Miniprep/Qiagen kit84 One-step Miniprep62 Silver: Restriction Digest78 Yeast DNA prep75 DNA Precipitation68 DNA extraction from tissue108 Chromosomal DNA extraction from E.coli87 Blackburn : Yeast Colony PCR90 PNK Treatment of DNA ends36 37 protocols 3800 LOC

Example: PCR repeat thermocycling

Example: Molecular Barcodes Preparation + PCR (2)

Example: DNA Sequencing Preparation PCR Analysis PCR

3.Add 1.5 vol. CTAB to each MCT and vortex. Incubate at 65° C for mins 4.Add 1 vol. Phenol:chloroform:isoamylalcohol: 48:48:4 and vortex thoroughly 5.Centrifuge at 13000g at room temperature for 5 mins 6.Transfer aqueous (upper) layer to clean MCT and repeat the extraction using chloroform: Isoamyalcohol: 96:4 Exposing Ambiguity in Original Protocols ? Coding protocols in precise language removes ambiguity and enables consistency checking

Validating the Language Eventual validation: automatic execution –But BioStream more capable than most chips today –Need to decouple language research from microfluidics research Initial validation: human execution –In collaboration with Prof. Utpal Nath’s lab at IISc –Target Plant DNA Isolation, common task for summer intern Biologist is never exposed to original lab notes To the best of our knowledge, first execution of a real biology protocol from a portable programming language Original Lab Notes BioStream Code Auto-Generated Protocol Execution in Lab

Growing a Community

Abstraction Layers for Microfluidics Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3

Toward “General Purpose” Microfluidic Chips

Abstraction 1: Digital Architecture Recent techniques can control independent samples –Droplet-based samples –Continuous-flow samples –Microfluidic latches In abstract machine, all samples have unit volume –Input/output a sample –Store a sample –Operate on a sample Challenge for a digital architecture: fluid loss –No chip is perfect – will lose some volume over time –Causes: imprecise valves, adhesion to channels, evaporation,... –How to maintain digital abstraction? [Fair et al.] [Our contribution]

Maintaining a Digital Abstraction Instruction Set Architecture (ISA) High-Level Language Hardware Electronics Microfluidics Replenish charge (GAIN) Loss of charge Randomized Gates [Palem] Soft error Handling? Replenish fluids? - Maybe (e.g., with water) - But may affect chemistry Loss of fluids ? ? ? ? ? ? Expose loss in ISA - Compiler deals with it Expose loss in language - User deals with it

Example: Mix Instruction Microfluidic chips have various mixing technologies –Electrokinetic mixing –Droplet mixing –Rotary mixing Common attributes: –Ability to mix two samples in equal proportions, store result Fluidic ISA: mix (int src 1, int src 2, int dst) –Ex: mix(1, 2, 3) –To allow for lossy transport, only 1 unit of mixture retained [Quake et al.] [Fair et al.] [Levitan et al.] Storage Cells Mixer

Implementation: Oil-Driven Chip InputsStorage CellsBackground PhaseWash PhaseMixing Chip 128Oil—Rotary

Implementation: Oil-Driven Chip InputsStorage CellsBackground PhaseWash PhaseMixing Chip 128Oil—Rotary mix (S 1, S 2, D) { 1. Load S 1 2. Load S 2 3. Rotary mixing 4. Store into D } 50x real-time

Implementation 2: Air-Driven Chip InputsStorage CellsBackground PhaseWash PhaseMixing Chip 128Oil—Rotary Chip 2432AirWaterIn channels

Implementation 2: Air-Driven Chip mix (S 1, S 2, D) { 1. Load S 1 2. Load S 2 3. Mix / Store into D 4. Wash S 1 5. Wash S 2 } InputsStorage CellsBackground PhaseWash PhaseMixing Chip 128Oil—Rotary Chip 2432AirWaterIn channels 50x real-time

Demonstration: Gradient Generation Hidden from programmer: –Location of fluids –Details of mixing, I/O –Logic of valve control –Timing of chip operations 450 Valve Operations Fluid yellow = input (0); Fluid blue = input(1); for (int i=0; i<=4; i++) { mix(yellow, 1-i/4, blue, i/4); }

Demonstration: Gradient Generation 450 Valve Operations input(0, 0); input(1, 1); input(0, 2); mix(1, 2, 3); input(0, 2); mix(2, 3, 1); input(1, 3); input(0, 4); mix(3, 4, 2); input(1, 3); input(0, 4); mix(3, 4, 5); input(1, 4); mix(4, 5, 3); mix(0, 4); Fluidic ISA

setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); Demonstration: Gradient Generation Valve Actuations 450 Valve Operations wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW); setValve(0, HIGH); setValve(1, HIGH); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, LOW); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, LOW); setValve(11, HIGH); setValve(12, LOW); setValve(13, HIGH); setValve(14, LOW); setValve(15, HIGH); setValve(16, LOW); setValve(17, LOW); setValve(18, LOW); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(14, HIGH); setValve(2, LOW); wait(1000); setValve(4, HIGH); setValve(12, LOW); setValve(16, HIGH); setValve(18, HIGH); setValve(19, LOW); wait(2000); setValve(0, LOW); setValve(1, LOW); setValve(2, LOW); setValve(3, HIGH); setValve(4, LOW); setValve(5, HIGH); setValve(6, HIGH); setValve(7, LOW); setValve(8, LOW); setValve(9, HIGH); setValve(10, HIGH); setValve(11, LOW); setValve(12, LOW); setValve(13, LOW); setValve(14, LOW); setValve(15, HIGH); setValve(16, HIGH); setValve(17, LOW); setValve(18, HIGH); setValve(19, LOW);

Abstraction Layers for Microfluidics Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3

Algorithms for Efficient Mixing Mixing is fundamental operation of microfluidics –Prepare samples for analysis –Dilute concentrated substances –Control reagant volumes How to synthesize complex mixture using simple steps? –Many systems support only 50/50 mixers –Should minimize number of mixes, reagent usage –Note: some mixtures only reachable within error tolerance  N Analogous to ALU operations on microprocessors Interesting scheduling and optimization problem

Why Not Binary Search? 0 1 3/8 1/4 1/2 3/8 5 inputs, 4 mixes

Why Not Binary Search? 0 1 3/8 3/4 1/2 3/8 4 inputs, 3 mixes 1/4 1/2 3/8 5 inputs, 4 mixes

Min-Mix Algorithm Simple algorithm yields minimal number of mixes –For any number of reagents, to any reachable concentration –Also minimizes reagent usage on certain chips

1.The mixing process can be represented by a tree. Min-Mix Algorithm: Key Insights B A B A 5/8 A, 3/8 B

1.The mixing process can be represented by a tree. 2.The contribution of an input sample to the overall mixture is 2 -d, where d is the depth of the sample in the tree Min-Mix Algorithm: Key Insights B A B A 5/8 A, 3/8 B d d 1/8 1/4 1/2

1.The mixing process can be represented by a tree. 2.The contribution of an input sample to the overall mixture is 2 -d, where d is the depth of the sample in the tree 3.In the optimal mixing tree, a reagent appears at depths corresponding to the binary representation of its overall concentration. Min-Mix Algorithm: Key Insights B A B A 5/8 A, 3/8 B d d 1/8 1/4 1/2 3 = =

Min-Mix Algorithm Example: mix 5/16 A, 7/16 B, 4/16 C To mix k fluids with precision 1/n: –Min-mix algorithm: O(k log n) mixes –Binary search: O(k n) mixes B C A B A B A A B B B C 1/16 1/8 1/4 1/2 2 -d d A=5 B=7 C=4 =0101 =0111 =0100 [Natural Computing 2007]

Abstraction Layers for Microfluidics Fluidic Instruction Set Architecture (ISA) - primitives for I/O, storage, transport, mixing Protocol Description Language - architecture-independent protocol description Fluidic Hardware Primitives - valves, multiplexers, mixers, latches chip 1chip 2chip 3

Micado: An AutoCAD Plugin for Microfluidic Chips Automates design of control layer of microfluidic chips 1. Language for fluidic ISA 2. Infer control valves 3. Infer control sharing 4. Route valves to control ports 5. Generate an interactive GUI Realistic use by at least 3 microfluidic researchers Freely available at:

Embryonic Cell Culture Courtesy J.P. Urbanski

Embryonic Cell Culture Courtesy J.P. Urbanski

Metabolite Detector Courtesy J.P. Urbanski

Metabolite Detector Courtesy J.P. Urbanski

Cell Culture with Waveform Generator Courtesy David Craig

Cell Culture with Waveform Generator Courtesy David Craig

Research Opportunities Adapt the language to biologists –Consider ‘natural language’ authoring rather than programming –Share language and protocols on a public wiki Backends for BioStream –Generate graphical protocol –Schedule separate protocols onto shared hardware, maximizing utilization of shared resource (e.g., thermocycler) Hardware description language for microfluidic chips –Automate design of the flow layer from a problem description Program analysis and optimization –Adapt unique (linear) types for microfluidics –Sound scheduling under timing constraints –Dynamic optimization of slow co-processors (lazy vectorization?)

Related Work EXACT: EXperimental ACTions ontology as a formal representation for biology protocols [Soldatova et al., 2009] Aquacore: ISA and architecture for programmable microfluidics, builds on our prior work [Amin et al., 2007] Robot Scientist: functional genomics driven by macroscopic laboratory automation [King et al., 2004] PoBol: RDF-based data exchange standard for BioBricks

Conclusions A high-level programming language for biology protocols is tractable and useful –Improves readability –Enables automation Vision: a de-facto language for experimental science –Replace ad-hoc language with precise, reusable description –Download a colleague’s code, automatically map to your microfluidic chip or lab setup Next steps: public release and community-building Courtesy J.P. Urbanski

Extra Slides

5. Generating Readable Instructions In typical programming languages- minimal set of orthogonal primitives But can detract from readability Original: “Mix the sample with 1uL restriction enzyme.” BioStream with orthogonal primitives: FluidSample s1 = measure(restriction_enzyme, 1*uL); FluidSample s2 = combine(sample, s1); mix(s2, TAP); Measure out 1ul of restriction enzyme. Combine the sample with the restriction enzyme. Mix the combined sample by tapping the tube.

5. Generating Readable Instructions In typical programming languages- minimal set of orthogonal primitives But can detract from readability Original: “Mix the sample with 1uL restriction enzyme.” BioStream with compound primitives: combine_and_mix(restriction_enzyme, 1*uL, sample, TAP); Add 1uL restriction enzyme and mix by tapping the tube.  Define a standard library that combines primitive operations

5. Generating Readable Instructions mixing_table_pcr(7,20,array_pcr,initial_conc, final_conc,vol);

Application to Rural Diagnostics Disposable Enteric Card PATH, Washington U. Micronics, Inc., U. Washington Targets: - E. coli, Shigella, Salmonella, C. jejuni DxBox U. Washington, Micronics, Inc., Nanogen, Inc. Targets: - malaria (done) - dengue, influenza, Rickettsial diseases, typhoid, measles (under development) CARD Rheonix, Inc. Targets: - HPV diagnosis - Detection of specific gene sequences