Taxonomies
Access any taxonomy defined by AI-on-Demand.
Some metadata fields in AI-on-Demand only accept a limited set of values. These values are defined in hierarchical taxonomies. The taxonomy defines terms with a unique name and a definition. For example, in the taxonomy of 'Scientific Domains', one might define a term 'Chemical Sciences' with the definition 'The scientific study of the properties and behavior of matter.'. The fact that the taxonomy is hierarchical means that each term may have subterms defined which can further specify the entry. For example, 'Chemical Sciences' could be a subterm of 'Natural Sciences', with 'Biology' and 'Physics' being other subterms ("siblings").
Examples:
[
Term(taxonomy='news categories', term='Business', definition='', subterms=[
Term(taxonomy='news categories', term='Funding', definition='', subterms=[]),
..., # more subterms, which each may have subterms
]),
..., # more terms
]
Notes
Defined taxonomies differ by version of the REST API. This module lists all taxonomies for all supported versions of the REST API. If you access a taxonomy that is not available for your defined version, an EndpointUndefinedError is raised.
Term
Describes a specific term in a hierarchical taxonomy.
Attributes:
Name | Type | Description |
---|---|---|
taxonomy |
str
|
Name of the taxonomy from which the term originates, e.g., 'industrial sectors'. |
term |
str
|
A unique name for the term, e.g., 'Clinical Medicine'. |
definition |
str
|
A description further clarifying the meaning of the term, e.g., 'The branch of medicine that deals with the [...].'. |
subterms |
list[Term]
|
A list of subterms which provide a finer granularity. This list may be empty. |
industrial_sectors()
Return the hierarchical taxonomy of industrial sectors.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.industrial_sectors.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
licenses()
Return the hierarchical taxonomy of licenses.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.licenses.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
news_categories()
Return the hierarchical taxonomy of news categories.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.news_categories.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
number_of_employees()
Return the hierarchical taxonomy of number of employees.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.number_of_employees.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
publication_types()
Return the hierarchical taxonomy of publication types.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.publication_types.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
research_areas()
Return the hierarchical taxonomy of research areas.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.research_areas.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
scientific_domains()
Return the hierarchical taxonomy of scientific domains.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.scientific_domains.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |
turnovers()
Return the hierarchical taxonomy of turnovers.
This function uses caching, and only the first call will result in a call to the server.
The cache does not persist between Python sessions. You can clear the cache anytime by calling
aiod.taxonomies.turnovers.cache_clear()
.
Returns:
Type | Description |
---|---|
list[Term]
|
A hierarchical taxonomy, each entry has a 'term', 'definition', and 'subterms'. The 'term' is a short unique name representing the entry. The 'definition' provides additional text to clarify the meaning for the term. 'Subterms' provides terms which are part of this term, and may themselves have subterms as well. |
Raises:
Type | Description |
---|---|
EndpointUndefinedError
|
If the taxonomy is not available for the configured version of the REST API. |
RuntimeError
|
For unexpected server responses. |