Bikatr7 commited on
Commit
6123e16
1 Parent(s): e3c1552

bump to 3.4.7

Browse files
modules/common/toolkit.py CHANGED
@@ -15,7 +15,7 @@ class Toolkit():
15
 
16
  """
17
 
18
- CURRENT_VERSION = "v3.4.6"
19
 
20
  ##-------------------start-of-clear_console()---------------------------------------------------------------------------------------------------------------------------------------------------------------------------
21
 
 
15
 
16
  """
17
 
18
+ CURRENT_VERSION = "v3.4.7"
19
 
20
  ##-------------------start-of-clear_console()---------------------------------------------------------------------------------------------------------------------------------------------------------------------------
21
 
modules/common/translator.py CHANGED
@@ -727,7 +727,7 @@ class Translator:
727
  translation_instructions = translation_instructions_methods[Translator.TRANSLATION_METHOD]
728
 
729
  ## get cost estimate and confirm
730
- num_tokens, min_cost, model = EasyTL.calculate_cost(text=Translator.text_to_translate, service=Translator.TRANSLATION_METHOD, model=model,translation_instructions=translation_instructions)
731
 
732
  print("Note that the cost estimate is not always accurate, and may be higher than the actual cost. However cost calculation now includes output tokens.\n")
733
 
@@ -736,7 +736,7 @@ class Translator:
736
 
737
  entity_word = "tokens" if Translator.TRANSLATION_METHOD in ["openai", "gemini"] else "characters"
738
 
739
- logging.info("Estimated number of tokens : " + str(num_tokens))
740
  logging.info("Estimated minimum cost : " + str(min_cost) + " USD")
741
 
742
  if(not omit_prompt):
 
727
  translation_instructions = translation_instructions_methods[Translator.TRANSLATION_METHOD]
728
 
729
  ## get cost estimate and confirm
730
+ num_entities, min_cost, model = EasyTL.calculate_cost(text=Translator.text_to_translate, service=Translator.TRANSLATION_METHOD, model=model,translation_instructions=translation_instructions)
731
 
732
  print("Note that the cost estimate is not always accurate, and may be higher than the actual cost. However cost calculation now includes output tokens.\n")
733
 
 
736
 
737
  entity_word = "tokens" if Translator.TRANSLATION_METHOD in ["openai", "gemini"] else "characters"
738
 
739
+ logging.info(f"Estimated number of {entity_word} : " + str(num_entities))
740
  logging.info("Estimated minimum cost : " + str(min_cost) + " USD")
741
 
742
  if(not omit_prompt):
requirements.txt CHANGED
@@ -1,5 +1,5 @@
1
  backoff==2.2.1
2
  gradio==4.20.0
3
  kairyou==1.6.1
4
- easytl==0.4.0-alpha-3
5
  ja_core_news_lg @ https://github.com/explosion/spacy-models/releases/download/ja_core_news_lg-3.7.0/ja_core_news_lg-3.7.0-py3-none-any.whl#sha256=f08eecb4d40523045c9478ce59a67564fd71edd215f32c076fa91dc1f05cc7fd
 
1
  backoff==2.2.1
2
  gradio==4.20.0
3
  kairyou==1.6.1
4
+ easytl==0.4.0
5
  ja_core_news_lg @ https://github.com/explosion/spacy-models/releases/download/ja_core_news_lg-3.7.0/ja_core_news_lg-3.7.0-py3-none-any.whl#sha256=f08eecb4d40523045c9478ce59a67564fd71edd215f32c076fa91dc1f05cc7fd