API Reference

Welcome to the ASReview API. This API reference contains documentation on the modules, classes, and functions of the ASReview software.

asreview

Classes

asreview.datasets.BaseDataGroup

asreview.datasets.BaseDataSet

asreview.datasets.BaseVersionedDataSet

asreview.datasets.BenchmarkDataGroup

asreview.datasets.DatasetManager

asreview.settings.ASReviewSettings

Object to store the configuration of a review session.

Functions

asreview.batch.batch_simulate

asreview.batch.create_jobs

asreview.compat.convert_id_to_idx

Convert record_id to row number.

asreview.compat.convert_idx_to_id

Convert row number to record_id.

asreview.datasets.dataset_from_url

asreview.datasets.download_from_metadata

Download metadata to dataset.

asreview.init_sampling.sample_prior_knowledge

Function to sample prelabelled articles.

asreview.search.fuzzy_find

Find a record using keywords.

asreview.analysis

Classes

analysis.Analysis

Analysis object to do statistical analysis on state files.

asreview.data

This module contains the data handling.

Classes

data.ASReviewData

Data object to the dataset with texts, labels, DOIs etc.

Functions

data.load_data

Load data from file, URL, or plugin.

data.statistics.abstract_length

Return the average length of the abstracts.

data.statistics.n_irrelevant

Return the number of irrelevant records.

data.statistics.n_keywords

Return the number of keywords.

data.statistics.n_missing_abstract

Return the number of records with missing abstracts.

data.statistics.n_missing_title

Return the number of records with missing titles.

data.statistics.n_records

Return the number of records.

data.statistics.n_relevant

Return the number of relevant records.

data.statistics.n_unlabeled

Return the number of unlabeled records.

data.statistics.title_length

Return the average length of the titles.

asreview.entry_points

Base Classes

entry_points.BaseEntryPoint

Base class for defining entry points.

Classes

entry_points.AlgorithmsEntryPoint

entry_points.BatchEntryPoint

entry_points.LABEntryPoint

entry_points.SimulateEntryPoint

asreview.models

Base Classes

models.base.BaseModel

Abstract class for any kind of model.

Functions

asreview.models.balance

Base Classes

balance.base.BaseBalance

Abstract class for balance strategies.

Classes

balance.SimpleBalance

Simple (no balancing) balance strategy.

balance.DoubleBalance

Double balance strategy.

balance.TripleBalance

Triple balance strategy.

balance.UndersampleBalance

Undersampling balance strategy.

Functions

balance.get_balance_model

Get an instance of a balance model from a string.

balance.get_balance_class

Get class of balance model from string.

balance.list_balance_strategies

List available balancing strategy classes.

asreview.models.classifiers

Base Classes

classifiers.base.BaseTrainClassifier

Base model, abstract class to be implemented by derived ones.

Classes

classifiers.NaiveBayesClassifier

Naive Bayes classifier.

classifiers.RandomForestClassifier

Random forest classifier.

classifiers.SVMClassifier

Support vector machine classifier.

classifiers.LogisticClassifier

Logistic regression classifier.

classifiers.LSTMBaseClassifier

LSTM-base classifier.

classifiers.LSTMPoolClassifier

LSTM-pool classifier.

classifiers.NN2LayerClassifier

Fully connected neural network (2 hidden layers) classifier.

Functions

classifiers.get_classifier

Get an instance of a model from a string.

classifiers.get_classifier_class

Get class of model from string.

classifiers.list_classifiers

List available classifier classes.

asreview.models.feature_extraction

Base Classes

feature_extraction.base.BaseFeatureExtraction

Base class for feature extraction methods.

Classes

feature_extraction.Tfidf

TF-IDF feature extraction technique.

feature_extraction.Doc2Vec

Doc2Vec feature extraction technique.

feature_extraction.EmbeddingIdf

Embedding IDF feature extraction technique.

feature_extraction.EmbeddingLSTM

Embedding LSTM feature extraction technique.

feature_extraction.SBERT

Sentence BERT feature extraction technique.

Functions

feature_extraction.get_feature_model

Get an instance of a feature extraction model from a string.

feature_extraction.get_feature_class

Get class of feature extraction from string.

feature_extraction.list_feature_extraction

List available feature extraction method classes.

asreview.models.query

Base Classes

query.base.BaseQueryStrategy

Abstract class for query strategies.

query.base.ProbaQueryStrategy

query.base.NotProbaQueryStrategy

Classes

query.MaxQuery

Maximum query strategy.

query.MixedQuery

Mixed query strategy.

query.MaxRandomQuery

Mixed (95% Maximum and 5% Random) query strategy.

query.MaxUncertaintyQuery

Mixed (95% Maximum and 5% Uncertainty) query strategy.

query.UncertaintyQuery

Uncertainty query strategy.

query.RandomQuery

Random query strategy.

query.ClusterQuery

Clustering query strategy.

Functions

query.get_query_model

Get an instance of the query strategy.

query.get_query_class

Get class of query strategy from its name.

query.list_query_strategies

List available query strategy classes.

asreview.review

Base Classes

review.BaseReview

Base class for Systematic Review.

Classes

review.MinimalReview

Minimal review class, can be used to do reviewing in a granularly

review.ReviewSimulate

ASReview Simulation mode class.

Functions

review.get_reviewer

Get a review object from arguments.

review.review

Perform a review from arguments.

review.review_simulate

CLI simulate mode.

asreview.state

Base Classes

state.BaseState

Classes

state.DictState

Class for storing the state of a review with no permanent storage.

state.HDF5State

Class for storing the review state with HDF5 storage.

state.JSONState

Class for storing the state of a Systematic Review using JSON files.

Functions

state.open_state

Open a state from a file.

state.states_from_dir

Obtain a dictionary of states from a directory.

state.state_from_file

Obtain a single state from a file.

state.state_from_asreview_file

Obtain the state from a .asreview file.