bridge.services.edam.edam_ingestor module#

Async client for resolving EDAM ontology terms by name through EMBL-EBI OLS4.

Searches for an EDAM concept by preferred label or synonym and returns a single unambiguous match. The returned search record includes the EDAM IRI and compact identifier.

exception bridge.services.edam.edam_ingestor.EDAMTermAmbiguousError[source]#

Bases: Exception

Raised when multiple EDAM concepts plausibly match the requested term.

class bridge.services.edam.edam_ingestor.EDAMTermByNameIngestor(name, *, exact=True, include_obsolete=False)[source]#

Bases: Ingestor

Resolve an EDAM ontology concept by human-readable name.

Parameters:
  • name (str) – Preferred label or synonym, for example "proteomics".

  • exact (bool, default=True) – Ask OLS4 to restrict results to exact text matches.

  • include_obsolete (bool, default=False) – Whether obsolete EDAM concepts may be returned.

async fetch()[source]#

Resolve one unambiguous EDAM concept.

Returns:

Compact OLS4 search result. Common fields include iri, label, short_form, ontology_name, description, and synonym.

Return type:

dict

Raises:
  • EDAMTermNotFoundError – If no usable EDAM concept matches the requested name.

  • httpx.RequestError, httpx.HTTPStatusError – For network or HTTP failures.

ontology = 'edam'#
exception bridge.services.edam.edam_ingestor.EDAMTermNotFoundError[source]#

Bases: Exception

Raised when no EDAM concept matches the requested term.