Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions fastchat/llm_judge/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,12 +454,12 @@ def chat_completion_openai_azure(model, conv, temperature, max_tokens, api_dict=
)
output = response["choices"][0]["message"]["content"]
break
except openai.error.OpenAIError as e:
print(type(e), e)
time.sleep(API_RETRY_SLEEP)
except openai.error.InvalidRequestError as e:
print(type(e), e)
break
except openai.error.OpenAIError as e:
print(type(e), e)
time.sleep(API_RETRY_SLEEP)
except KeyError:
print(response)
break
Expand Down
4 changes: 3 additions & 1 deletion fastchat/serve/gradio_block_arena_anony.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,9 @@ def share_click(state0, state1, model_selector0, model_selector1, request: gr.Re
OUTAGE_MODELS = []


def get_sample_weight(model, outage_models, sampling_weights, sampling_boost_models=[]):
def get_sample_weight(model, outage_models, sampling_weights, sampling_boost_models=None):
if sampling_boost_models is None:
sampling_boost_models = []
if model in outage_models:
return 0
weight = sampling_weights.get(model, 0)
Expand Down
Loading