dataesr/scientific-paragraphs-categorization huggingface dataset:
Development of CAPRIB CAPRIB is developed in Perl, SQL and Java. Perl is used to filter the BLAST reports, but also to communicate with the CDD-NCBI and combine this result with the candidate protein files, ultimately generating the report in TSV format. SQL is used to build, manage and access the database. Finally, the core of CAPRIB and its GUI are in Java, mainly using the javax. swing and java. awt graphical libraries. It is designed to work on macOS, GNU/Linux and windows on a standard computer. CAPRIB uses the results of TBLASTN (which can be generated directly with CAPRIB) in order to determine the similarity links (identical, similar or different) between the amino acids for the homologous proteins of the given dataset. Of note, we used TBLASTN (as compared to BLASTP) to avoid differences due to disparities in annotation/prediction of protein sequences from the dataset.
Phylogeny of mycobacteria A dataset of species of the Mycobacterium bacterial genus has been assembled to optimize the quality of genomes and to be representative of species diversity (Supplementary File 1). A phylogenetic tree was created using a bioinformatics protocol published elsewhere  [34]. Briefly, the 56 genome sequences (including the outgroup) were annotated using Prokka version 1. 13. 7  [35]. Homologous links between the translated coding sequences were found using the combination of the two algorithms COG  [36]  and OMCL  [37]  through GET_HOMOLOGUES version 20190411  [13]. The 958 gene sequences (excluding paralogs) corresponding to the softcore (sequences present in more than 95% of the genomes) were aligned using mafft version 7. 407  [38]. The resulting alignments were filtered using BMGE version 1.
Analysis with CAPRIB Three databases were constructed: one using M. tuberculosis H37Rv (slow growing) as the reference, one with M. gilvum Spyr1 (fast growing), and one with M. abscessus ATCC 19977 (basal fast growing). The comparisons were generated using TBLASTN version 2. 9. 0+  [45]. The same 56 genomes utilized for the presented phylogeny were also used but M. leprea and M. lepraemurium were excluded since they have a specific welldescribed evolution by reductive genomics and gene decay with respectively 41%  [46]  and 30% pseudogenes  [47]. The identity threshold for considering two sequences as homologues was determined by calculating the 10th percentile median for all BLAST results for a given reference. Although analyses could be done without any threshold, we recommend this empirical threshold to minimize the likelihood of false-positive assignments due to low-level similarity as determined previously  [8].
This permitted determining a minimum of 40% of protein similarity using M. tuberculosis H37Rv (i. e. we extracted AA changes only for proteins harboring > 40% similarity score with all species in the dataset), 35% for M. gilvum Spyr1, and 33% for M. abscessus ATCC 19977 as references. The functional categories for some proteins of interest were determined using the  eggNOG 5. 0. 0 database  [48]. For comparative analysis between fast-growing and slow-growing mycobacteria, only the species after node 2 in Fig. 2  were considered for the slow category (excluding M. terrae clade species because of their intermediate phenotype) and all species before node 1 in Fig. 2  (excluding outgroup species) were grouped in the fast category. Most of the AA changes have been verified using standard alignments.
Description of CAPRIB main functions In order to investigate the amino acid changes that may have been involved in the evolution of a group of organisms and in the emergence of a new phenotype (see Fig. 1a ), we have created CAPRIB, a tool with an easy-touse graphical interface (Fig. 1b ). To make CAPRIB accessible to a maximum number of users, it only requires some dependencies that are often already installed on biologists' computers (Java, MySQL, PERL and BLAST+). It has also been designed to work on most operating systems (Windows, macOS and GNU/Linux). The architecture of CAPRIB, relying on relational databases (Fig. 1c ), allows users to create projects and to change parameters easily for a given database, without having to redo the BLAST searches. A summary of the results can be visualized directly through CAPRIB while complete detailed results are available in a CSV file, compatible with spreadsheet tools.
The SQL database The user is performing TBLASTN (with BLAST+ using the Java interface) of protein sequences from reference (herein M. tuberculosis H37Rv a slow-growing species, M. gilvum Spyr1 a rapid-growing bacteria, and M. abscessus ATCC 19977 a basal fast-growing species) against genomic sequences of other species from the studied genus (herein 51 mycobacteria species and the three outgroup bacteria). Subsequently, the user is using the results of these comparisons to feed the database. The database is structured as shown in Fig. 1c  with a table of general features from the reference organism (such as the name of proteins, locus tags, accession numbers), a second table with the blast information (query and subject names) and a third table that comprises the information extracted from the BLAST file.
Comparisons The user can query the database according to different evolutionary strategies (Table  1  We have also implemented an option that links the result file with CDD (Conserved Domain Database) of NCBI  [49]  as described in the help of CDD (https://www. ncbi. nlm. nih. gov/Structure/cdd/cdd_help. shtml#BatchRPSBWebAPI_GE TorPOST). We have used the class CddNcbi which starts the script ccd. pl, collects results and fuses them with the list of AA changes to produce a TSV file that can be directly opened in CAPRIB or online on the CDD website. With Validation and comparison of CAPRIB with a gold standard method The accuracy of CAPRIB has been validated by comparing it to the Snippy tool (https://github. com/tseemann/ snippy), which automates a gold-standard bioinformatics procedure commonly used to compare bacterial genomes.
Use of CAPRIB to monitor the phylogenetic landscape and assess putative abnormality Mycobacteria were historically separated into two large phylogenetic groups that were correlated with their growth rate  [31] : the slow-growing and fast-growing lineages. Recently, a third group (M. terrae complex) has been revealed to be an intermediate (in terms of phylogeny but also in terms of growth phenotype) between the slow and fast-growing mycobacteria  [33, 53]. The fact that mycobacteria can be separated phylogenetically based on a phenotype (growth rate) makes it a model of choice to be investigated with CAPRIB. Three databases were constructed using 53 genomes of mycobacteria with genomes of good quality (Supplementary File 1) and M. tuberculosis H37Rv (slow grower), M. gilvum Spyr1 (fast grower), and M.
abscessus ATCC 19977 (basal fast grower) as references. The Fig. 3  presents the phylogenetic relations of species composing this dataset, which is in accordance with previously published phylogenies  [33, 53]. A second phylogeny was made from  nucleotide sequences as indicated in the implementation section. Both phylogenies are highly identical, with the exception of a node inside the MTBC (data not shown). Defining groups is crucial in order to achieve optimal results with CAPRIB. Of note, gold standard tools to infer phylogenetic reconstruction by maximum-likelihood, such as IQ-TREE  [42]  and RAxML  [55, 56]  could eventually bias grouping as they force strict bifurcating trees and do not allow polytomy. The fact that M. terrae clade species are considered as intermediates between slow and fast growers can cause a problem in the definition of groups and thus in the different AA changes found to explain the phenotype (i.
In a second step, since it was possible to confirm that the terrae-clade shares a common ancestor with slow growers, we further investigated the relationships between these two groups (node 2 in Fig. 3 ) (Fig. 4b ). Since the fast growing phenotype is paraphyletic, two databases were used, one with M. abscessus ATCC 19977 as the reference and the other with M. gilvum Spyr1, allowing to assess the topologies using references from both fast groups. This also permitted to exclude any effect due to the choice of reference. Again and as expected, the topology with the most markers is the one that corroborates the molecular phylogeny, namely that the terrae-clade is basal to the slow-growing-species group, composed of the tuberculosis and avium clades, which share a common ancestor. Results obtained with the two databases are also very similar.
To illustrate this concept, we could cite the mycomembrane, which has evolved long before the host-adaptation of mycobacteria and is now playing a key role in M. tuberculosis pathogenesis  [63]. The CAPR IB tool described in this study allows users to extract, at the genus scale, drastic AA changes that are concomitant to a phenotypic switch between two bacterial groups. Rich from this knowledge, biologists could now Fig. 5  a AA changes between the slow and fast-growing mycobacteria, but conserved in each group. a STRING analysis showing putative relationships between proteins from the "a" panel focus their attention on these key residues and on the impact of these changes using molecular microbiology approaches. One of CAPRIB's goals is to make data analysis simple, so it integrates a user-friendly graphical interface and relies on an SQL relational database, allowing comparisons between genomes to be saved.
In addition, to maximize accessibility to CAPRIB, it has been designed to work on the majority of operating systems (Windows and UNIX-like). During our software optimization, we realized that several AA changes in many proteins were detected but the majority of them were conservative. This is why CAPRIB integrates two scores (Grantham's distance and exchangeability score) for each amino acid change, allowing user to infer the potential impact of the detected changes. In addition, CAPRIB allows to connect the list of AA changes with the NCBI CDD database, making it possible to check whether the permutations are in conserved domains. However, no absolute rule can infer with certainty the impact that a mutation may have on the functionality of a protein and on the network of interaction with other biological molecules.
The study of AA polymorphism profiles with CAPRIB requires some essential prerequisites in order to obtain optimal results. Among these, there is, of course, the quality of the dataset. The more complete a dataset is, which should be representative of the diversity of the bacterial groups studied, the more powerful the results will be. This obviously includes having a robust molecular phylogeny to properly assign the species studied to different groups. This is why a core-genome approach, with several phylogenetic markers, has been favored in this study compared to a 16S phylogeny, that is faster to perform, but often less accurate  [66]. Moreover, since CAPRIB makes it possible to analyze the AA changes finely, it goes without saying that it is essential to have sequences of good quality.
Funding This work was supported by the  Natural Sciences and Engineering Research Council of Canada (NSERC)  under Grant  RGPIN-2016-04940  and by  Institut Pasteur  through grants  PTR 30-2017  and  PTR 73-2017. ATV received a  Postdoctoral Fellowship  from the  NSERC. FJV is a research scholar of the  Fonds de Recherche du Québec -Santé. The funding bodies played no role in the design of the study and collection, analysis, and interpretation of data and in writing the manuscript.
Availability and requirements Project name: CAPRIB Project home page: https://github. com/BactSymEvol/ Caprib Operating systems: Windows, MacOS and UNIX-like operating systems Programming language: Java, Perl Other requirements: Java, MySQL, PERL, BLAST+ and XAMP (Windows and Linux: 7. 3. 0-0; MacOS: 5. 6. 39). All of the dependencies are provided with the software in a ready-to-use virtual machine, available in the GitHub. License: GPLv3 Any restrictions to use by non-academics: No.
Data type and variable declaration. In addition to the programming paradigms, languages supported by CyMLT can be classified by their type system, in particular their type expression (explicit or implicit). This can affect the quality of the generated code. Although some languages (e. g. C# and C++) allow both implicit and explicit type expression, we chose to provide explicit typing. Basic types (integer, logical, character, and real) are built-in data types in all languages. However, other more complex types like datetime or sequence are supported but require external or standard libraries. Moreover, various libraries exist to handle the same data structure. CyMLT's datatypes map appropriately to target languages by using their standard library (Supporting Information Table  S1 ). Some compromises have been made for the transformation of complex types.
CyML arrays are modeled on a standard Python list. However, the size of list datatype variables is not fixed. We propose to use the Numpy array in the next version of CyMLT. In Fortran, CyMLT generates allocable arrays to map to CyML list data types and provides some functions to handle it. These functions are extracted from CyMLT library and integrated into the generated code to make it independent of the library of transformation. In C++, datetime type handling is not easy. It is converted into a string, which could be split for processing. CyML arrays without a specified size in the function parameter are mapped to C++ arrays using templates (Listing 6, line 1). In Java, there are many standard Time APIs. (e. g. , Date, LocalDateTime) depending on the version of Java. We have chosen to use the Date Library in Java and the DateTime Library in C#.
R is a popular language used for statistical analyses and data visualization. Many modelers use R to start the development of their model  (Zhao et al. 2019 ). Thus, with this extension, modelers can in the same environment conduct the first steps for model Listing 11. Operators mapping. Adapting Standard Functions. CyML defines three standard libraries (i. e. math, system, and io) to provide mathematical, system, and file management functions in the different languages. A mapping is needed to link these functions to native R ones for each library. Some functions are identical between CyML and R, like min or max. Others require a transformation to another type of node. It is useful for model developers to observe the generated ASG of each CyML construct in order to define the equivalent of the construct.
For example, the construct of a modulo binary operation in CyML is a standard_call node in the ASG whose namespace is system, the function is modulo and the arguments are the two operands. This node is transformed into a binary_op node (binary operation) with the function -translateModulo‖ (Listing 12). The new node is visited to produce R fragment code. Listing 12. Standard functions mapping. Standard methods mapping. Standard methods are functions applied to a particular data type of CyML language (Listing 13). Thus, a set of methods is provided for each CyML datatype. Their equivalents in R language are defined using the same mapping mechanism used for standard functions. In Listing 13 at Line 9 the append method applied to a list is transformed to an assignment node whose value is a function c that takes as arguments the name of the variable of type list (receiver) and the argument of the append method (args).
Second, CyML provides primitive types whose equivalence in some platforms are objects with some properties. This means that coding an existing model algorithm in CyML could require an additional CyML external function to emulate the properties of these objects. Third, CyML has some limitations with data type conversion. For example, Datetime type is not supported in Fortran or C++. In this case, CyML converts it into strings. However, the translator could be extended to depend on specific libraries used by simulation platforms to perform the transformation. Finally, some platforms are close to the philosophy of their underlying language (e. g. DSSAT, BioMA, OpenAlea) whereas others extend their language with a high-level specificity (Record, Simplace) that requires a complex transformation.
Indeed, this language limitation reduces ambiguity in the language transformation since the base language (Cython) has some features that cannot be transformed into some target languages. CyML does not interact with the simulation paradigms of the platforms. Its sole concern is to represent and transform the process models. Its evaluation capabilities are only used to check the correctness of the transformation. Moreover, CyML does not provide a formalism to link model components with data to build a modeling solution. Thus, the processes to read inputs, parameters values and write output values in a file is separated from the algorithm implementation given that it reduces reusability. Although CyML focuses on the implementation and reuse of biophysical models, it could be used in general purpose.
We describe the integration of multi-batch cytometry datasets (iMUBAC), a flexible, robust, and scalable computational framework for unsupervised cell-type identification across multiple batches of highdimensional cytometry datasets. After overlaying cells from healthy controls across multiple batches, iMUBAC learns batch-specific cell-type classification boundaries and identifies aberrant immunophenotypes in patient samples. We illustrate unbiased and streamlined immunophenotyping, using both in-house and public mass and flow cytometry datasets.
(Tregs). Thus, current computational approaches do not accomplish high-dimensional batch correction and unbiased immunophenotyping with sufficient resolution from multiple batches of datasets. Here, we present iMUBAC (integration of multi-batch cytometry datasets), a flexible, robust, and scalable computational framework for rational interbatch comparisons through high-dimensional batch correction and unsupervised cell-type identification across multiple batches (Fig. 1 ). The workflow can be broken down into four steps. First, iMUBAC performs a data-adaptive, automated preprocessing, such as excluding doublets and dead cells and ensuring inter-batch consistency in panel design. Second, iMUBAC batch-corrects cells from healthy local controls, but not from travel/family controls or patients, using Harmony  12  to reduce batch effects before clustering.
We first tested iMUBAC on in-house multi-batch CyTOF datasets for peripheral blood mononuclear cells (PBMCs) from patients with unusually severe infectious diseases and their travel/family controls (75 individuals, 6 batches, 38 surface markers). After batch-correction with healthy local controls as "anchors," FlowSOM/ConsensusClusterPlus defined 60 metaclusters, which we merged and identified manually (Fig. S1-3 ). We calculated the percentages of the various subsets among live single leukocytes (CD45 -CD66b + cells, excluding granulocytes). The cell-type frequencies of both technical (i. e. , experiments performed on different dates with aliquots of identical biological materials, N=2) and biological (i. e. , experiments performed on different dates with biological materials obtained from identical donors on different occasions, N=2) duplicates.
CC-BY 4. 0 International license available under a was not certified by peer review) is the author/funder, who has granted bioRxiv a license to display the preprint in perpetuity. It is made The copyright holder for this preprint (which this version posted July 15, 2020. ; https://doi. org/10. 1101/2020. 07. 14. 202432 doi: bioRxiv preprint correlated well between the two batches tested (Fig. S4 ). Moreover, the estimated and manually determined frequencies of both abundant (e. g. , αβ T cells) and rare (e. g. , innate lymphoid cells) cell subsets correlated reasonably well across a wide range of percentages (from ~0. 01% to ~70%), not only among local controls but also among travel/family controls and patients (Fig. S5 ). Collectively, iMUBAC rationally integrates multibatch cytometry datasets, to identify cell types consistent with state-of-the-art gating in both controls and patients.
We then applied iMUBAC to in-house multi-batch spectral flow cytometry datasets for PBMCs (14 individuals, 2 batches, 14 cell-surface and 4 intracellular markers). The datasets included data from patients with two monogenic forms of autoimmunity: FAS deficiency  15, 16  and STAT3 gain-of-function  [17] [18] [19]  , both of which are known to be accompanied by lymphoproliferation and high counts of circulating CD4 -CD8 -doublenegative αβ T (DN T) cells. After manually gating out dead cells and doublets, we defined 50 metaclusters with FlowSOM/ConsensusClusterPlus, which we merged and identified manually (Fig. 2a , 2b, and S6). As expected, we observed an expansion of a cluster representing DN T cells in patients with FAS deficiency and, to a lesser extent, in those with STAT3 gain-of-function (Fig.
2c ). Conventional flow cytometry with a different antibody panel validated this expansion of DN T cells (Fig. S7 ). iMUBAC also revealed a decrease in the levels of Vδ2 γδ T, CD8 + mucosal-associated invariant T (MAIT), and CD16 + natural killer (NK) cells in both groups, possibly reflecting a previously unappreciated level of immunopathological homogeneity between these two inborn errors of immunity (Fig. 2c ). iMUBAC can be applied to spectral flow cytometry datasets, as well as CyTOF datasets, and readily identifies both known and unappreciated immunophenotypes in patients with rare immunological disorders. Finally, we applied iMUBAC to previously published CyTOF datasets for PBMCs from 10 healthy controls and 20 patients with stage IV melanoma before and after PD-1 blockade immunotherapy (11 responders and nine non-responders, respectively) that had been stained with three antibody panels  20.
We analyzed two batches simultaneously (i. e. , discovery and validation cohorts). Healthy controls were used for batch correction, clustering with FlowSOM/ConsensusClusterPlus, and classifier training (Fig. 2d  and S8-10). We tested the differential abundance (DA) between responders and non-responders using the quasi-likelihood F-test (QLF) in edgeR  21  , as previously applied to CyTOF analysis  8, 22. Eight DA subsets were identified, with statistical significance after adjustment for treatment status and batch effects. In particular, the "CD14 Mono 2" cluster, corresponding to CD14 + CD16 -HLA-DR hi CD86 hi PD-L1 hi monocytes, was expanded in responders consistent with the findings of the original report  20  (Fig. 2e ). Moreover, four DA subsets, all T-cell subsets, were reproducibly identified even if only pretreatment datasets were used (Fig.
2f ). These subsets could potentially be used as biomarkers of a better prognosis, before the initiation of PD-1 blockade immunotherapy. iMUBAC can be used to streamline an exploratory immunophenotyping analysis in clinical pilot studies of common disease conditions. High-dimensional cytometry has considerably improved human immunological studies, despite limited sample availability. Moreover, platforms such as FlowRepository or Cytobank facilitate the sharing of cytometry data, making it possible to foster discoveries through meta-analysis. We anticipate that this flexible, robust, and scalable workflow, available on GitHub (https://github. com/casanova-lab/iMUBAC), will expedite rational comparative analyses of multi-batch cytometry datasets and facilitate novel discoveries through unbiased and streamlined immunophenotyping.