diff --git a/hydra_agent/redis_core/graphutils_operations.py b/hydra_agent/redis_core/graphutils_operations.py index 1782fe1..8b3eaed 100644 --- a/hydra_agent/redis_core/graphutils_operations.py +++ b/hydra_agent/redis_core/graphutils_operations.py @@ -26,7 +26,9 @@ def __init__(self, entrypoint_url: str, api_doc: dict, self.api_doc = api_doc self.redis_proxy = redis_proxy self.redis_connection = redis_proxy.get_connection() - self.vocabulary = 'vocab' + self.complete_vocabulary_url = self.api_doc.generate()['@context']['vocab'] + # extract 'vocab' from 'localhost/api/vocab#' + self.vocabulary = self.complete_vocabulary_url.split('/')[-1].split('#')[0] self.graph_utils = GraphUtils(redis_proxy) self.redis_graph = Graph("apigraph", self.redis_connection) self.session = Session()