colrev.settings.SearchSource

class SearchSource(**data)[source]

Bases: BaseModel

Search source settings

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Methods

get_api_feed

Get a feed to add and update records

get_origin_prefix

Get the corresponding origin prefix

get_query

Get the query filepath

is_curated_source

Check whether the source is a curated source (for preparation)

is_md_source

Check whether the source is a metadata source (for preparation)

setup_for_load

Set the SearchSource up for the load process (initialize statistics)

validate_filename

Validate the filename

Attributes

endpoint

filename

search_type

search_parameters

comment

to_import

imported_origins

len_before

source_records_list

get_api_feed(review_manager, source_identifier, update_only, prep_mode=False)[source]

Get a feed to add and update records

Return type:

SearchAPIFeed

get_origin_prefix()[source]

Get the corresponding origin prefix

Return type:

str

get_query()[source]

Get the query filepath

Return type:

str

is_curated_source()[source]

Check whether the source is a curated source (for preparation)

Return type:

bool

is_md_source()[source]

Check whether the source is a metadata source (for preparation)

Return type:

bool

setup_for_load(*, source_records_list, imported_origins)[source]

Set the SearchSource up for the load process (initialize statistics)

Return type:

None

classmethod validate_filename(values)[source]

Validate the filename