Še en mini fix za boljšo čitljivost

This commit is contained in:
marko.ferme
2023-01-10 12:31:19 +01:00
parent a2a8fd25a3
commit dc92c93786
2 changed files with 7 additions and 4 deletions
@@ -23,6 +23,7 @@ ATEapi_endpoint = "http://ate-api:5000/predict"
def do_izlusci(conllus, prepovedane_besede,definicije=False):
tmp_file_path = ""
print(definicije);
ret = {'terminoloski_kandidati':[]}
try:
big_conllu = cl_utils.multipla_conllus_to_one_from_conllus_arr(conllus)
tmp_file_path = create_random_file_in_tmp_folder(big_conllu, ".conllu")
@@ -36,7 +37,8 @@ def do_izlusci(conllus, prepovedane_besede,definicije=False):
data = json.loads(res.text)
ret = {'terminoloski_kandidati': [
ret['terminoloski_kandidati']=[
{
'POSoznake': tk['term_example_pos'],
'kandidat': tk['lemma'], # more to bit lemma al terms?
@@ -49,7 +51,7 @@ def do_izlusci(conllus, prepovedane_besede,definicije=False):
'pogostostpojavljanja': [tk['frequency'], 0] # ???????
}
for tk in data if tk['canonical'] not in prepovedane_besede
]}
]
+2 -1
View File
@@ -657,7 +657,7 @@ components:
type: string
kanonicnaoblika:
type: string
definition:
definicija:
type: string
POSoznake:
type: string
@@ -685,6 +685,7 @@ components:
kanonicnaoblika: kanonicnaoblika
nosilnautez: 0.8008282
kandidat: kandidat
definicija: "Kandidat je besedna zveza, ki bi lahko bila strokoven termin"
JobResponse:
required:
- finished_job