diff --git a/data/wikimedica/alignement.py b/data/wikimedica/alignement.py index cb807df..231acca 100644 --- a/data/wikimedica/alignement.py +++ b/data/wikimedica/alignement.py @@ -15,7 +15,7 @@ USER_AGENT = "WikimedicaDiseaseSearch/0.1 (https://gitlab.com/matteodelabre/wiki session = requests.Session() session.headers = {'User-Agent': USER_AGENT} -def make_sparql_request_wikimedica(page, request): +def request_wikimedica(page, request): """ Effectue une requête SPARQL sur une page de WikiMedica @@ -31,7 +31,7 @@ def make_sparql_request_wikimedica(page, request): return [row.asdict() for row in qres] -def make_sparql_request_endpoint(endpoint, request): +def request_endpoint(endpoint, request): """ Effectue une requête SPARQL sur point d'accés @@ -60,7 +60,7 @@ request_name_uri = """ } """ -entitys_dic = make_sparql_request_wikimedica( +entitys_dic = request_wikimedica( SIGNES_ET_SYMPTOMES_WIKIMEDICA_PAGE, request_name_uri ) @@ -83,7 +83,7 @@ for entity in entitys_dic: }} """.format(PREFIX_PROPERTY) - prop_Wikidata_id = make_sparql_request_wikimedica( + prop_Wikidata_id = request_wikimedica( entity['uri'], request_prop_Wikidata_id ) @@ -108,7 +108,7 @@ for entity in entitys_dic: }} """.format((entity['name']).lower(), (entity['name']).capitalize()) - list_wikidata_pages_uri = (make_sparql_request_endpoint( + list_wikidata_pages_uri = (request_endpoint( WIKIDATA_SPARQL_ENDPOINT, request_search_by_name ))['results']['bindings']