Updated translate template

added test file
This commit is contained in:
bacon
2023-08-26 12:12:22 +03:00
parent 64f7089f2e
commit 21a54e1585
2 changed files with 16 additions and 7 deletions

View File

@@ -29,7 +29,8 @@ def translate(_input, lang='RU'):
"commonJobParams": {},
"timestamp": int(round(time.time() * 1000))
},
"id": 40890008
"id": 40890009
}
)
print(r.json())
return r.json()['result']['translations'][0]['beams'][0]['postprocessed_sentence']