mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-07-27 15:37:44 +00:00
fix: increase time default not controlled by LLM (#1196)
* fix: add longer timeout configuration for data science scenarios * fix CI
This commit is contained in:
@@ -140,6 +140,7 @@ class DataScienceBasePropSetting(KaggleBasePropSetting):
|
||||
|
||||
model_architecture_suggestion_time_percent: float = 0.75
|
||||
allow_longer_timeout: bool = False
|
||||
longer_timeout_by_llm: bool = False
|
||||
coder_longer_timeout_multiplier_upper: int = 3
|
||||
runner_longer_timeout_multiplier_upper: int = 2
|
||||
timeout_increase_stage: float = 0.3
|
||||
|
||||
@@ -119,9 +119,17 @@ class DataScienceScen(Scenario):
|
||||
)
|
||||
self.metric_name = response_json_analysis.get("Metric Name", "custom_metric")
|
||||
self.metric_direction_guess = response_json_analysis.get("Metric Direction", True)
|
||||
self.longer_time_limit_required = response_json_analysis.get(
|
||||
"Longer time limit required", False
|
||||
) # True or False, whether the competition scenario requires a longer time limit to the code.
|
||||
self.longer_time_limit_required = (
|
||||
False
|
||||
if not DS_RD_SETTING.allow_longer_timeout
|
||||
else (
|
||||
response_json_analysis.get("Longer time limit required", False)
|
||||
if DS_RD_SETTING.longer_timeout_by_llm
|
||||
else True
|
||||
)
|
||||
)
|
||||
|
||||
# True or False, whether the competition scenario requires a longer time limit to the code.
|
||||
|
||||
def real_debug_timeout(self):
|
||||
return (
|
||||
@@ -130,7 +138,7 @@ class DataScienceScen(Scenario):
|
||||
DS_RD_SETTING.coder_longer_timeout_multiplier_upper,
|
||||
self.timeout_increase_count * DS_RD_SETTING.timeout_increase_stage + 1,
|
||||
)
|
||||
if self.longer_time_limit_required and DS_RD_SETTING.allow_longer_timeout
|
||||
if self.longer_time_limit_required
|
||||
else DS_RD_SETTING.debug_timeout
|
||||
)
|
||||
|
||||
@@ -144,7 +152,7 @@ class DataScienceScen(Scenario):
|
||||
DS_RD_SETTING.runner_longer_timeout_multiplier_upper,
|
||||
self.timeout_increase_count * DS_RD_SETTING.timeout_increase_stage + 1,
|
||||
)
|
||||
if self.longer_time_limit_required and DS_RD_SETTING.allow_longer_timeout
|
||||
if self.longer_time_limit_required
|
||||
else DS_RD_SETTING.full_timeout
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user