Mxode commited on
Commit
5ca8421
·
verified ·
1 Parent(s): 1b12f01

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +2 -2
README.md CHANGED
@@ -36,7 +36,7 @@ tokenizer = AutoTokenizer.from_pretrained(model_path)
36
 
37
  def translate(
38
  text: str,
39
- to: Literal["chinese", "english"] = "chinese",
40
  **kwargs
41
  ):
42
  generation_args = dict(
@@ -73,7 +73,7 @@ def translate(
73
  return response
74
 
75
  text = "After a long day at work, I love to unwind by cooking a nice dinner and watching my favorite TV series. It really helps me relax and recharge for the next day."
76
- response = translate(text=text, to='chinese')
77
  print(f'Translation: {response}')
78
 
79
  """
 
36
 
37
  def translate(
38
  text: str,
39
+ to: Literal["Chinese", "English"] = "Chinese",
40
  **kwargs
41
  ):
42
  generation_args = dict(
 
73
  return response
74
 
75
  text = "After a long day at work, I love to unwind by cooking a nice dinner and watching my favorite TV series. It really helps me relax and recharge for the next day."
76
+ response = translate(text=text, to='Chinese')
77
  print(f'Translation: {response}')
78
 
79
  """