Command Line Interface

pyobo automatically installs the command pyobo. See pyobo --help for usage details.

pyobo

CLI for PyOBO.

Usage

pyobo [OPTIONS] COMMAND [ARGS]...

Options

--version

Show the version and exit.

clean

Delete all cached files.

Usage

pyobo clean [OPTIONS]

Options

--remove-obo

database

Build the PyOBO Database.

Usage

pyobo database [OPTIONS] COMMAND [ARGS]...

alts

Make the prefix-alt-id dump.

Usage

pyobo database alts [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

build

Build all databases.

Usage

pyobo database build [OPTIONS]

Options

--eager-versions
--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

cache

Cache all things.

Usage

pyobo database cache [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

definitions

Make the prefix-identifier-definition dump.

Usage

pyobo database definitions [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

edges

Make the edges dump.

Usage

pyobo database edges [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

mappings

Make the SSSOM dump.

Usage

pyobo database mappings [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

metadata

Make the prefix-metadata dump.

Usage

pyobo database metadata [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

names

Make the prefix-identifier-name dump.

Usage

pyobo database names [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

properties

Make the properties dump.

Usage

pyobo database properties [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

relations

Make the relation dump.

Usage

pyobo database relations [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

species

Make the prefix-identifier-species dump.

Usage

pyobo database species [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

synonyms

Make the prefix-identifier-synonym dump.

Usage

pyobo database synonyms [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

typedefs

Make the typedef prefix-identifier-name dump.

Usage

pyobo database typedefs [OPTIONS]

Options

--zenodo

Automatically upload to zenodo

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

--directory <directory>

Build location. Defaults to /home/docs/.data/pyobo/database/<today>

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--skip-pyobo

Skip prefixes whose ontologies are implemented as PyOBO sources

--skip-below <skip_below>

Skip prefixes lexically sorted below the given one

lookup

Lookup resources.

Usage

pyobo lookup [OPTIONS] COMMAND [ARGS]...

alts

Page through alt ids in a namespace.

Usage

pyobo lookup alts [OPTIONS] PREFIX

Options

-i, --identifier <identifier>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

ancestors

Look up ancestors.

Usage

pyobo lookup ancestors [OPTIONS] CURIE

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

CURIE

Required argument

definitions

Page through the identifiers and definitions of entities in the given namespace.

Usage

pyobo lookup definitions [OPTIONS] PREFIX

Options

-i, --identifier <identifier>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

descendants

Look up descendants.

Usage

pyobo lookup descendants [OPTIONS] CURIE

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

CURIE

Required argument

hierarchy

Page through the hierarchy for entities in the namespace.

Usage

pyobo lookup hierarchy [OPTIONS] PREFIX

Options

--include-part-of
--include-has-member
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

ids

Page through the identifiers of entities in the given namespace.

Usage

pyobo lookup ids [OPTIONS] PREFIX

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

mappings

Page through mappings for the given namespace.

Usage

pyobo lookup mappings [OPTIONS] PREFIX

Options

-t, --target <target>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

metadata

Print the metadata for the given namespace.

Usage

pyobo lookup metadata [OPTIONS] PREFIX

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

names

Page through the identifiers and names of entities in the given namespace.

Usage

pyobo lookup names [OPTIONS] PREFIX

Options

-i, --identifier <identifier>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

prefixes

Page through prefixes appearing in an ontology.

Usage

pyobo lookup prefixes [OPTIONS] PREFIX

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

properties

Page through the properties for entities in the given namespace.

Usage

pyobo lookup properties [OPTIONS] PREFIX

Options

-k, --key <key>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

relations

Page through the relations for entities in the given namespace.

Usage

pyobo lookup relations [OPTIONS] PREFIX

Options

--relation <relation>

CURIE for the relationship or just the ID if local to the ontology

--summarize
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

species

Page through the identifiers and species of entities in the given namespace.

Usage

pyobo lookup species [OPTIONS]

Options

-i, --identifier <identifier>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

synonyms

Page through the synonyms for entities in the given namespace.

Usage

pyobo lookup synonyms [OPTIONS] PREFIX

Options

-i, --identifier <identifier>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

typedefs

Page through the identifiers and names of typedefs in the given namespace.

Usage

pyobo lookup typedefs [OPTIONS] PREFIX

Options

-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

xrefs

Page through xrefs for the given namespace to the second given namespace.

Usage

pyobo lookup xrefs [OPTIONS] PREFIX

Options

-t, --target <target>
-v, --verbose

Enable verbose mode. More -v’s means more verbose.

-f, --force

Force re-downloading and re-processing

--force-process

Force re-processing, but not necessarily re-downloading

--strict, --no-strict

Turn on or off failure on unparsable CURIEs

Default:

False

--version <version>

Explicit version of the data. If not given, the most recent will be looked up.

Arguments

PREFIX

Required argument

ls

List how big all of the OBO files are.

Usage

pyobo ls [OPTIONS]

obo-lexical-review

Make a lexical review of an ontology.

Example usage for a non-OBO Foundry ontology requires giving the –uri-format and –location

$ pyobo obo-lexical-review --uri-format "http://semanticscience.org/resource/SIO_" --location http://semanticscience.org/ontology/sio/v1.59/sio-release.owl sio

Usage

pyobo obo-lexical-review [OPTIONS] PREFIX

Options

--location <location>

Local path or URL to an OBO Graph JSON file or OWL file. If not given, will try and look up through the OBO PURL system

--uri-prefix <uri_prefix>

The URI prefix to use to identify terms that belong to the graph. If not given, assumes that the URI prefix should be constructed as an OBO PURL like http://purl.obolibrary.org/obo/<prefix>_. If you

--index-url <index_url>

Define an alternate term index. Note, this gets cached locally. Big ones take a few minutes to load.

Default:

'https://github.com/biopragmatics/biolexica/raw/main/lexica/obo/obo.ssslm.tsv.gz'

--show-passed

Output statistics about passing terms to the console

--skip-upper

if true, skip matching to upper level ontologies {‘ncit’}, which are often false positives (or unhelpful for review)

--index-force

if true, force re-downloading the lexical index

Arguments

PREFIX

Required argument