Updated translate template
added test file
This commit is contained in:
@@ -32,10 +32,9 @@ def translate(_input, lang='RU'):
|
||||
"commonJobParams": {},
|
||||
"timestamp": int(round(time.time() * 1000))
|
||||
},
|
||||
"id": 40890008
|
||||
"id": _id
|
||||
}
|
||||
)
|
||||
print(_id)
|
||||
try:
|
||||
return r.json()['result']['translations'][0]['beams'][0]['postprocessed_sentence']
|
||||
except:
|
||||
|
||||
Reference in New Issue
Block a user