diff --git a/api/api_functions.py b/api/api_functions.py index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..e53910630e1cb92dcded85a0588408e7fad5ea9b 100644 --- a/api/api_functions.py +++ b/api/api_functions.py @@ -0,0 +1,12 @@ +from func.ner.ner import * +from func.usas.usas import * + + +def get_ner_for_data(): + result = run_ner_on_text() + return result + + +def get_usas_for_data(): + result = run_usas_on_text() + return result diff --git a/func/ner/ner.py b/func/ner/ner.py new file mode 100644 index 0000000000000000000000000000000000000000..06a1ee6fe5c59cd58babec878148a149775c255d --- /dev/null +++ b/func/ner/ner.py @@ -0,0 +1,3 @@ + +def run_ner_on_text(): + return "hello ner" diff --git a/func/usas/usas.py b/func/usas/usas.py new file mode 100644 index 0000000000000000000000000000000000000000..a7bc640e79270c081751f42c98a5fe57ce00f9d5 --- /dev/null +++ b/func/usas/usas.py @@ -0,0 +1,3 @@ + +def run_usas_on_text(): + return "hello usas" \ No newline at end of file diff --git a/functions /ner/ner.py b/functions /ner/ner.py deleted file mode 100644 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/functions /usas/usas.py b/functions /usas/usas.py deleted file mode 100644 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/main.py b/main.py index b244cfb66fc1aaa7a871cc2bcf472df3d572430e..8d5bd63e8bbc56a69afd09120fefd6038a4094d0 100644 --- a/main.py +++ b/main.py @@ -1,5 +1,7 @@ from flask import Flask +from api.api_functions import * + app = Flask(__name__) @@ -10,9 +12,11 @@ def home(): @app.route("/ner") def ner(): - return "Hello ner!" + result = get_ner_for_data() + return result @app.route("/usas") def usas(): - return "Hello usas!" + result = get_usas_for_data() + return result