Package: small-text
Active Learning for Text Classification in Python.Installation|Quick Start|Contribution|Changelog|DocsSmall-Text provides state-of-the-artActive Learningfor Text Classification.
Several pre-implemented Query Strategies, Initialization Strategies, and Stopping Critera are provided,
which can be easily mixed and matched to build active learning experiments or applications.What is Active Learning?Active Learningallows you to efficiently label training data in a small data scenario.FeaturesProvides unified interfaces for Active Learning so that you can
easily mix and match query strategies with classifiers provided bysklearn,Pytorch, ortransformers.Supports GPU-basedPytorchmodels and integratestransformersso that you can use state-of-the-art Text Classification models for Active Learning.GPU is supported but not required. In case of a CPU-only use case,
a lightweight installation only requires a minimal set of dependencies.Multiple scientifically evaluated components are pre-implemented and ready to use (Query Strategies, Initialization Strategies, and Stopping Criteria).NewsVersion 1.3.3(v1.3.3) - December 29th, 2023Bugfix release.Version 1.3.2(v1.3.2) - August 19th, 2023Bugfix release.Paper accepted at EACL 2023 🎉Thepaperintroducing small-text has been accepted atEACL 2023. Meet us at the conference in May!Update: the paper was awardedEACL Best System Demonstration. Thank you, for your support!Version 1.3.0(v1.3.0): Highlights - February 20th, 2023Added dropout sampling toSetFitClassification.Version 1.2.0(v1.2.0): Highlights - February 4th, 2023Makehuggingface/setfit(SetFit) usable as a small-text classifier.New query strategy:BALD.Added two new SetFit notebooks, and also updated existing notebooks.For a complete list of changes, see the change log.InstallationSmall-Text can be easily installed via pip:pipinstallsmall-textFor a full installation include the transformers extra requirement:pipinstallsmall-text[transformers]It requires Python 3.7 or newer. For using the GPU, CUDA 10.1 or newer is required.
More information regarding the installation can be found in thedocumentation.Quick StartFor a quick start, see the provided examples forbinary classification,pytorch multi-class classification, andtransformer-based multi-class classification,
or check out the notebooks.Notebooks#Notebook1Intro: Active Learning for Text Classification with Small-Text2Using Stopping Criteria for Active Learning3Active Learning using SetFit4Using SetFit's Zero Shot Capabilities for Cold Start InitializationShowcaseTutorial: 👂 Active learning for text classification with small-text(Use small-text conveniently from theargillaUI.)A full list of showcases can be foundin the docs.🎀Would you like to share your use case?Regardless if it is a paper, an experiment, a practical application, a thesis, a dataset, or other, let us know and we will add you to theshowcase sectionor even here.DocumentationRead the latest documentationhere. Noteworthy pages include:Overview of Query StrategiesReproducibility NotesAlternativesmodAL,ALiPy,libactContributionContributions are welcome. Details can be found inCONTRIBUTING.md.AcknowledgmentsThis software was created by Christopher Schröder (@chschroeder) at Leipzig University'sNLP groupwhich is a part of theWebisresearch network.
The encompassing project was funded by the Development Bank of Saxony (SAB) under project number 100335729.CitationSmall-Text has been introduced in detail in the EACL23 System Demonstration Paper"Small-Text: Active Learning for Text Classification in Python"which can be cited as follows:@inproceedings{schroeder2023small-text,
    title = "Small-Text: Active Learning for Text Classification in Python",
    author = {Schr{\"o}der, Christopher  and  M{\"u}ller, Lydia  and  Niekler, Andreas  and  Potthast, Martin},
    booktitle = "Proceedings of the 17th Conference of the European Chapter of the Association for Computational Linguistics: System Demonstrations",
    month = may,
    year = "2023",
    address = "Dubrovnik, Croatia",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2023.eacl-demo.11",
    pages = "84--95"
}LicenseMIT License