恍兮惚兮 c055b23acd some
2024-11-15 10:56:12 +08:00

17 lines
393 B
Python

from translator.basetranslator import basetrans
class TS(basetrans):
def translate(self, query):
json_data = {
"content": query,
"message": "translate sentences",
}
response = self.proxysession.post(self.config["api"], json=json_data)
try:
return response.json()
except:
raise Exception(response)