dataesr/scientific-paragraphs-categorization huggingface dataset:
T he understanding and engineering of biological systems require practical and efficient experimental and computational approaches  [1] [2] [3] [4] [5]. Machine learning algorithms hold a big promise for the study, design, and optimization of different biological systems  [6] [7] [8] [9]  , including genomics studies  [10] [11] [12]  , protein, enzyme and metabolic engineering  4, 13, 14  , prediction and optimization of CRISPR sequences and proteins  [15] [16] [17] [18]  , as well as complex genetic circuits design and optimization  [19] [20] [21]. Yet, applying machine learning is limited by the need for informatics expertise and large user-labeled datasets, which are typically time-, laborand cost-intensive. Active learning, sometimes called optimal experimental design  22, 23  , is a type of machine learning that interactively suggests a next set of experiments after being trained on previous results  24.
This makes active learning valuable for wet-lab scientists, especially when dealing with a limited number of userlabeled data  25. Active learning approaches reduce experimental time, labor and cost and have been used in cellular imaging  26  , systems biology  27  , biochemistry  [28] [29] [30]  , and synthetic biology  31. Despite these examples, a challenge in applying active learning methods for experimental biologists is the lack of customizable programs and workflows. Here, aimed at democratization and standardization, we describe METIS (Machine-learning guided Experimental Trials for Improvement of Systems, named after the ancient goddess of wisdom and crafts Μῆτις, lit. "wise counsel"), a modular and versatile active machine learning workflow for data-driven optimization of a biological objective function (an output/target that depends on multiple factors) with minimal datasets.
Note that, active learning for optimizing a system is also known as Bayesian optimization. We created METIS for experimentalists with no experience in programming, who can use the entire process of personalized active learning, experimental setup, data analysis and visualization without any advanced computational skills. METIS runs on Google Colab, a free online platform to write and execute Python codes developed for education, data science, and machine learning purposes  32. The open platform does not need any installation/registration and local computational power and can be simply used via a personal copy of the respective notebook. To establish the workflow, we first assessed the performance of different machine learning algorithms on a minimal training dataset and experimentally validated the best performing algorithm (XGBoost) by optimization of an in vitro cell-free transcription-translation (TXTL) system of Escherichia coli that is commonly used in cell-free synthetic biology for a variety of applications  33  , including biosensor development  34  , metabolic pathway prototyping  35  , and gene circuit design  36.
Results Assessing the performance of different algorithms for our workflow. We first tested which machine learning algorithm would perform best with a limited number of experimental data typical for a standard research lab setup. To that end, we took advantage of an existing dataset from a recent optimization of an E. coli extract-based in vitro TXTL system  31. In their study, Borkowski et al. optimized cell-free protein production in E. coli lysate by varying 12 different factors including salts, energy mix, amino acids, and tRNAs, and measuring production yield of Gfp (produced by a plasmid expressing Gfp) as output. Altogether, the dataset encompassed around 1000 data points. We fitted the dataset to obtain a standard as a gold regressor (a reference model fitted on pre-existing experimental data to evaluate new algorithms) and divided it further into test and training sets, with 20% and 80% of data, respectively.
While the latter set was used to train the model, the test set was used to validate the gold regressor (Methods). We used the gold regressor to assess the performance of four different machine learning algorithms over 10 rounds of active learning (Fig. 1a ). The tested algorithms included deep neural networks (DNN), multilayer perceptrons (MLP), linear regressors, and XGBoost gradient boosting, which all show different capabilities for a given problem set and its data sample size. Over 10 rounds of active learning with 100 data points in each round, XGBoost and linear regressors showed better performance (Fig. 1b ) compared to DNN and MLP, which generally need larger datasets for training  40. XGBoost outperformed linear regressors when fewer data points per round were used (Supplementary Fig.
1 ). XGBoost is an improved random forest-type algorithm, working through gradient boosted decision trees  41  by aggregating and compiling sets of models. This algorithm is a sparsity-aware, fast, scalable as well as versatile model for handling tabular data with complex non-linear interactions  41. These features make XGBoost a promising algorithm for machine learning applications on different biological systems with limited datasets. For our workflow, we therefore selected XGBoost, which has also been used for different biological applications previously  18, 42, 43. To determine the minimum dataset required for optimization, we compared active learning rounds with 5, 10, 25, and 100 data points. Notably, a sample size as low as 10 data points still allowed sufficient yield optimization (i.
e. , the effect of each individual factor on the objective function. The importance is given as a relative fraction (or percentage) in the prediction of the values of the objective function by the model, with the sum of all factors set to 100%. Our analysis showed that tRNA mix and Mg-glutamate were the most important components in optimizing Gfp yield, while cAMP and NAD were the least important contributors. Figure  1g  shows the distribution of Gfp yield at different concentrations of individual factors (see also Supplementary Fig. 3 ). Decreasing concentrations of tRNA and NTP mixes correlated with high yield, while PEG 8000, Mg-glutamate, 3-PGA, folinic acid, and spermidine showed similar effects at increasing concentrations. Together, these data did not only result in an optimized TXTL system but also allowed to identify the most crucial components during system optimization, providing the basis for a deeper understanding of the system itself.
All combinations and yields are provided as results files for each experimental round (Data availability), and the Google Colab notebook with all analyses and visualization modules are also accessible (Code availability). Development of METIS, a user-friendly, versatile modular workflow. After demonstrating that our workflow is capable of working efficiently with minimal datasets, we sought to build METIS, a modular architecture that can be easily applied for the optimization of different biological objective functions. We implemented our workflow in Google Colab Python notebooks that can be accessed by the user-without installation or registration-simply through a personal copy of the notebook from a web browser. Defining the objective function and the variable factors (Fig. 2a ), the user can simply open the link of Google Colab notebook and directly use the workflow as shown in Fig.
2a , b, Supplementary Figs. 4 5 6. In Supplementary Note 2, we provide a detailed description of all features of METIS. The modular workflow enables the use of factors with numerical values (examples in Figs. 1, 3  and 5 ), categories (examples in Fig. 4 , Supplementary Fig. 19 ), or both (example in Figs. 3  and 5 ). Active learning can be initialized by random combinations generated by the workflow in the first round (example in Figs. 1, 3  and 4 ). Alternatively, pre-existing datasets can be imported and used for optimization or simulations (examples in Supplementary Figs. 18  and 19 ). Although our workflow is designed as an active learning approach over iterative experimental rounds, it can be also used in a classical machine learning setup, when only using one round of experiments. Multiple data analysis and visualization modules are available that can be used in each round of active learning as shown in example applications (Fig.
1  Assessing the performance of different algorithms and testing the active learning workflow with minimal data points. a An existing dataset of cell-free gene expression compositions composed of 1000 data points was used to build a gold standard regressor and assess the performance of different machine learning algorithms in 10 rounds of active learning. b Top panel: performance of 4 algorithms, multilayer perceptrons (MLP), deep neural networks (DNN), linear regressors, and XGBoost gradient boosting in 10 rounds of active learning (100 data points per round). Bottom panel: performance of the XGBoost gradient boosting algorithm as the selected algorithm with different sample sizes. The boxplots with whisker length of 1. 5, represent the minimum, 25th percentile (bottom bound of box), median (center of box), 75th percentile (upper bound of box), and maximum.
g Distribution of different concentrations of each factor within the measured yields. The Google Colab Python notebook and all active learning data (combinations and yields) in this figure are available at https://github. com/amirpandi/METIS. By performing a titration experiment with P T7 -LacI, we could show that addition of the LacI plasmid has indeed a strong negative effect on the optimal LacI circuit (i. e. , with pTHS) (Fig. 3f ) and in an independent TXTL protein production (Fig. 3g ) (see also Supplementary Note 3 for details of the active learning cycle and titration experiments). To further investigate this effect, we titrated the LacI plasmid with either T7 or a constitutive promoter against a fixed concentration of the Gfp expressing plasmid under control of either T7 or a constitutive promoter.
3j ), resulting in a strong improvement in the objective function, and in particular Gfp fold-change (Fig. 3k ). Note that among these 20 combinations were again all four SLC and MLC circuits. All of them improved upon providing external LacI, clearly demonstrating that resource competition had been limiting performance of the SLC and MLC circuits. Continuing with only one additional round of active learning using this dataset, we were able to improve the foldchange to up to 123 (Fig. 3k ), which is 15-fold improvement compared to that of 10 rounds of active learning with the P T7 -LacI plasmid and 34-fold improvement compared to the initial setup. Overall, these experiments demonstrated how our workflow can be used to improve the signal-to-noise-ratio of an existing in vitro gene circuit by two orders of magnitude.
These plots show glycolate production over 8 h (h) and its first 15 min with slopes (i), initial production rate versus the final glycolate yield (j), total amount of measured CoA esters after 8 h versus the final glycolate yield (k), and quantified CoA esters over 8 h (l). The plotted values in h-k are the average of triplicates (n = 3 independent experiments), and the error bars represent the standard deviation. In (l), bars are the average of triplicates (n = 3 independent experiments), each compound is plotted with error bars in Supplementary Fig. 17. In l the amount of propionyl-CoA within the zero samples is the added amount (100 µM) to start the reaction and was not measured by LC-MS. The Google Colab Python notebook and all active learning data (combinations and yields) in this figure are available at https://github.
In our empirical experience, the exploration to exploitation ratio should gradually decrease towards the late rounds of active learning to enable more explorative combinations in early rounds and more exploitation in late rounds for efficient optimization (Supplementary Note 2). Workflows can be started either from scratch (random combination as initialization) or using existing datasets (then performing active learning). Although our workflow is designed as an active learning approach (over multiple rounds of experiments), it can also be used as a classical machine learning with only one round of experiments. Factors of a given objective function can be numerical and/or categorical. Active learning parameters can be further customized using a detailed explanation in Supplementary Note 2. METIS provides a variety of choices for visualization and analysis of results.
Efficient explorative approaches are needed not only for the optimization of existing biological networks, but also for the design and realization of new-to-nature genetic and metabolic networks for which sampling the entire combinatorial space becomes practically impossible. Apart from network optimization with minimal experimental datasets, METIS can simultaneously help to discover so far unknown interactions and bottlenecks in these networks, which paves the way for their hypothesis-driven improvement. In the LacI circuit optimization, we showed how a bottleneck (i. e. , resource competition) can be identified, targeted, and finally overcome, which allowed us to improve the system by 34-fold. Similarly, during optimization of the CETCH cycle, we identified Mco, Hbs and B 12 as limiting factors.
Methods Gold regressor and analyzing different machine learning algorithms. To find out which machine learning algorithm and sample size are suitable for our workflow, we conducted the following simulation: -1017 data points (compositions and yields) were collected from a recent study  31. -An XGBRegressor model (gold regressor) was trained on 80% of the dataset and 20% of the dataset was used for validation and to avoid overfitting via early stopping. -100 combinations produced randomly within the range of each factor for Day_1. -Instead of doing experiments in the laboratory to determine the yield of each combination, yield values were assigned by the gold regressor. -Note that, in this phase the test model predicts the yields and ranks them to suggest for the experiments of the next day, and the gold regressor (trained on pre-data) is used to assign yield values by prediction instead of performing the experiments in the laboratory.
General description of METIS notebook. All scripts used in this study were written in Python 3. Our modular tool, METIS, runs on Google Colab working through web browsers with a link without users needing to install Python or any packages. Packages used in the development of METIS: -Data processing: pandas (1. 1. The core algorithm of active learning. After measuring the value of the objective function (yield) for random combinations of Day_1, we continued with the following algorithm: -RandomSearchCV is used to find the optimal 20 hyperparameters for the XGBoost model. -The ensemble of 20 models is trained with the hyperparameters on data from all previous days (Day_1 to present day). -100000 combinations out of possible combinations are randomly selected. -The mean and standard deviation of ensemble predictions are calculated.
-The model is trained using the selected hyperparameter. Using the built-in "feature_importances_" property of the XGBoost package, the ratio of feature importance is calculated throughout the training process for each day cumulatively. Finding nonlinear (mutual) interactions. In complex systems, factors usually interact with each other and epistatically affect the output. These interactions can be among many factors, however, the most relevant is the mutual or double interaction between factors  56. This analysis can be a hint to discover biological phenomena's behavior. The mutual interactions were calculated through the following algorithm:  57  -A linear regression model is fitted on the dataset and its performance is evaluated based on the R squared of predicted and actual values. This performance is considered as the baseline.
-Iteratively, a new feature is added to the temporary dataset that equals F i × F j for i and j in the list of factors. -The linear regression is fitted on the temporary dataset (which now has one more feature, F i × F j ) its performance is measured similarly to the baseline. -The difference between each performance and the baseline, j, is calculated and visualized. METIS prediction. In contrast to METIS optimization that tries to find the most promising combinations through maximizing the objective function, METIS prediction aims to maximize the model performance on the prediction of the objective function for unseen combinations. We modified the core active learning algorithm: -Instead of UCB (exploitation × mean + exploration × std), combinations are sorted based on only their std value and set exploitation to zero.
We used the Google Text2Speech python package to transform the text into a voice file. There are two ways to interact with this notebook to continue with the next pipetting volume. The first is to do it manually with your keyboard (what we did), the second is using the voice assistant. For transforming voice to text (specific commands like 'next', 'repeat', etc. ). We used the SpeechRecognition (3. 8. 1) python package. The code is available on https://github. com/amirpandi/Liquid-Handling-Assistant. Plasmid and DNA preparation. The constitutive Gfp under the control of J23101 promoter and B0032 RBS was built in a recent study (pBEAST-J23101-B0032-sfGfp)  58. Using golden gate cloning (BsaI-HF Ⓡ v2 NEB #R3733L, T4 DNA ligase NEB #M0202T), in this plasmid, the super folder Gfp gene was replaced by LacI for constitutive-LacI, then the promoter was replaced by a T7 promoter (gaatttaatacgactcactatagggaga) to construct P T7 -LacI plasmid.
The Gfp fluorescence was monitored (excitation: 485, emission: 528 nM, gain: 80) every 10 min in a plate reader (Tecan Infinite 200 PRO). The yield (objective function) in Fig. 1e , as provided in the Data availability, is the Gfp fluorescence (after 6 h incubation at 30 °C) of each composition normalized by a composition in which the concentration of all variable factors is at mid-range. However, the plotted yields are those values divided by 0. 33, the average ratio of Gfp fluorescence between the active learning reference and a commonly used composition  33. The objective function of the LacI circuit active learning in Fig. 3c  is fold-change (FC) × dynamic range (DR) of the output (Gfp fluorescence) between 0 and 10 mM input (concentration of IPTG). For cell-free reactions in Fig. 4c , the final volume of 5 µL was prepared directly in a 384-well plate, 10 nM final concentration of each linear DNA was transferred and the mix of other components of the cell-free lysate plus T7 polymerase (40 µg.
The resulting RNA produced a substantial qPCR signal (iTaq Universal SYBR Green Supermix Bio-Rad #1725120) when converted to cDNA by ProtoScript ® II Reverse Transcriptase (NEB #M0368) using the standard protocol and random hexamer primers (ThermoFisher #SO142), but not in control reactions lacking reverse transcriptase. In order to account for potential sample-tosample variability in extraction efficiency, all data presented herein is represented as a relative difference in cycle threshold (Ct) between Gfp and LacI cDNA within each sample. Standard curves with known concentrations of plasmid DNA were analyzed in parallel for Gfp and LacI primer sets, indicating comparable qPCR efficiencies and template specificity. No further normalization was required. Western blot. Cell-free expression reactions and LacI-6xHis purified protein dilutions were mixed with 4 µL of non-reducing sample loading buffer (Thermo Scientific #39001) and incubated at 90 °C for 5 minutes.
The in vivo yield in Fig. 4e , f is the Gfp fluorescence readout (after 6 h) of each transcription & translation unit normalized by the Gfp fluorescence of a commonly used sequence in our lab, wild-type T7 promoter, B0032 RBS, and sfGfp sequence. In cases where pipetting errors occurred, we used our Excep-tions_to_Worklist script for correction of failed transfers (provided in Code availability). This script generates a new worklist out of the exception file generated by the ECHO ® and provides a list with how much volume needs to be added into which well. Dissecting the worklists guarantees for example that all buffers are transferred before enzymes are added. Note that we used fresh enzyme stocks in each round to prevent loss of activity due to repetitive freeze-thaw cycles. As source plates we used ECHO ® qualified 384-Well PP 2.
We quantified the CoAs using external standard curves prepared in water with formic acid at pH 3. The standard curves were measured before and after the samples. Except for methylsuccinyl-CoA, all compounds were stable. For methysuccinyl-CoA we calculated the concentration as an average of the two standard curves at the time point the sample was measured. The parameters for the multiple reaction monitoring (MRMs) and the gradient are shown in the tables below. The data analysis was done with Agilent MassHunter Quantitative Analysis (for QQQ). See Supplementary Table  4  (Gradient for the separation of CoA esters) and Supplementary Table  5  (MRM transitions). LC-MS analysis of glycolate. Glycolate was measured on a triple quadrupole mass spectrometer (Agilent Technologies 6495 Triple Quad LC-MS) equipped with a UHPLC (Agilent Technologies 1290 Infinity II) using a 150 ×2.
1 mm C18 column (Kinetex 1. 7 µm EVO C18 100 Å) at 25 °C. The injection volume was 0. 5 µL. The diluted samples (1:10 in water), as well as the external standard curve, were diluted 1:2 with 10 µM 13 C 2 -labeled glycolic acid as internal standard. The flow was set to 0. 100 mL. min -1 and the separation was performed using dH 2 O with 0. 1% formic acid (buffer A) and methanol with 0. 1% formic acid (buffer B). The parameters for the multiple reaction monitoring (MRMs) and the gradient are displayed below. Data analysis was done using the Agilent Mass Hunter Workstation Software. See Supplementary Table  6  (Gradient for the separation of CoA esters) and Supplementary Table  7  (MRM transitions).
Acknowledgements We wish to thank  V. Gureghian  for stimulating discussions during conception of the work,  T. E. Gorochowski  ( University of Bristol, UK ) for providing SLC and MLC constructs, and  M. Kushwaha  ( INRAE, Jouy en Josas, France ) for E. coli DH10β, harboring the autoregulated T7 polymerase construct. We thank  S. Burgener ,  S. Luo ,  A. Sánchez-Pascuala Jerez ,  N. Odermatt , and  A. Schrodt  for graphical, technical and experimental support, as well as fruitful discussion. We thank  Jule P. M. Erb  for drafting the METIS logo. This work was supported by a  European Molecular Biology Organization (EMBO)  long-term postdoctoral fellowship (A. P. ALTG  165-2020 ), the  Gordon and Betty Moore Foundation ,  GBMF10652 , grant  DOI 10. 37807/GBMF10652  (T. J. E. ), the  Max Planck Research Network in Synthetic Biology (MaxSynBio)  of the  Max Planck Society  and the  Federal Ministry of Education and Research (BMBF ; T.
J. E. ), the  UDOPIA PhD program  and the  French National Research Institute for Agriculture, Food, and Environment (INRAE)  through the  Métaprogramme BIOLPREDICT program  (L. F. ), BMBF Grant, MetAFor, No. 031B0850B  (T. J. E. ),  ANR   iCFree grant  ( ANR-20-BiopNSE ) (J-L. F. ) and the  Max-Planck Society  ( MPG-FhG  project eBioCO 2 n). Figures were created with Biorender. com.
Data availability The source data underlying Figs. 3f-i, 4a, e, and 5h-l and Supplementary Figures  2, 7a , b, 9b, 11, 16a, b are provided as a Source Data file. All active learning data (combinations and yields) are available along with Google Colab Python notebook of each application on GitHub, https://github. com/amirpandi/METIS. Primers used for transcription and translation units (Fig. 4 ) are provided in Supplementary Tables  8, 9. Source data are provided with this paper.