Yu (Hope) Hou commited on
Commit
084e2df
·
1 Parent(s): e326608

fix FE check inconsistency issue

Browse files
Files changed (2) hide show
  1. src/about.py +6 -0
  2. src/submission/check_validity.py +1 -1
src/about.py CHANGED
@@ -85,6 +85,12 @@ I don’t understand where I could start to build a QA system for submission.
85
 
86
  I want to use API-based QA systems for submission, like GPT4. What should I do?
87
  - We don't support API-based models now but you could train your model with the GPT cache we provided: https://github.com/Pinafore/nlp-hw/tree/master/models.
 
 
 
 
 
 
88
  """
89
 
90
  EVALUATION_QUEUE_TEXT = """
 
85
 
86
  I want to use API-based QA systems for submission, like GPT4. What should I do?
87
  - We don't support API-based models now but you could train your model with the GPT cache we provided: https://github.com/Pinafore/nlp-hw/tree/master/models.
88
+
89
+ I want to test my model locally before submission. How could I do that?
90
+ - In addition to tutorial test, please also ensure your model could be loaded with the below code, so it could pass the frontend check.
91
+ ```
92
+ AutoConfig.from_pretrained(model_name, revision="main", trust_remote_code=True/False, token=ACCESS_TOKEN)
93
+ ```
94
  """
95
 
96
  EVALUATION_QUEUE_TEXT = """
src/submission/check_validity.py CHANGED
@@ -31,7 +31,7 @@ def check_model_card(repo_id: str) -> tuple[bool, str]:
31
 
32
  return True, ""
33
 
34
- def is_model_on_hub(model_name: str, revision: str, token: str = None, trust_remote_code=False, test_tokenizer=False) -> tuple[bool, str]:
35
  """Checks if the model model_name is on the hub, and whether it (and its tokenizer) can be loaded with AutoClasses."""
36
  try:
37
  config = AutoConfig.from_pretrained(model_name, revision=revision, trust_remote_code=trust_remote_code, token=token)
 
31
 
32
  return True, ""
33
 
34
+ def is_model_on_hub(model_name: str, revision: str, token: str = None, trust_remote_code=True, test_tokenizer=False) -> tuple[bool, str]:
35
  """Checks if the model model_name is on the hub, and whether it (and its tokenizer) can be loaded with AutoClasses."""
36
  try:
37
  config = AutoConfig.from_pretrained(model_name, revision=revision, trust_remote_code=trust_remote_code, token=token)