mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-08-02 01:47:43 +00:00
feat(kaggle): several update in kaggle scenarios (#476)
* udpate plot * log and reduce token * trace tag * add simple_background parameter to get_scenario_all_desc * update trace * update first version code * chat model map * add annotation for stack index * add annotation * reformatted by black * several update on kaggle scenarios * update some new change * fix CI * fix CI * fix a bug * fix bugs in graph RAG --------- Co-authored-by: Tim <illking@foxmail.com>
This commit is contained in:
@@ -83,7 +83,7 @@ class ModelCodeEvaluator(Evaluator):
|
||||
.from_string(evaluate_prompts["evaluator_code_feedback"]["system"])
|
||||
.render(
|
||||
scenario=(
|
||||
self.scen.get_scenario_all_desc(target_task)
|
||||
self.scen.get_scenario_all_desc(target_task, filtered_tag=target_task.model_type)
|
||||
if self.scen is not None
|
||||
else "No scenario description."
|
||||
)
|
||||
@@ -145,7 +145,7 @@ class ModelFinalEvaluator(Evaluator):
|
||||
.from_string(evaluate_prompts["evaluator_final_feedback"]["system"])
|
||||
.render(
|
||||
scenario=(
|
||||
self.scen.get_scenario_all_desc(target_task)
|
||||
self.scen.get_scenario_all_desc(target_task, filtered_tag=target_task.model_type)
|
||||
if self.scen is not None
|
||||
else "No scenario description."
|
||||
)
|
||||
|
||||
@@ -76,7 +76,7 @@ class ModelCoderEvolvingStrategy(EvolvingStrategy):
|
||||
coder_prompts["evolving_strategy_model_coder"]["system"],
|
||||
)
|
||||
.render(
|
||||
scenario=self.scen.get_scenario_all_desc(),
|
||||
scenario=self.scen.get_scenario_all_desc(filtered_tag=target_task.model_type),
|
||||
queried_former_failed_knowledge=queried_former_failed_knowledge_to_render,
|
||||
current_code=current_code,
|
||||
)
|
||||
|
||||
@@ -13,9 +13,11 @@ valid_y = pd.Series(np.random.randint(0, 2, 8))
|
||||
|
||||
model = fit(train_X, train_y, valid_X, valid_y)
|
||||
execution_model_output = predict(model, valid_X)
|
||||
|
||||
if isinstance(execution_model_output, torch.Tensor):
|
||||
execution_model_output = execution_model_output.cpu().detach().numpy()
|
||||
|
||||
|
||||
execution_feedback_str = f"Execution successful, output numpy ndarray shape: {execution_model_output.shape}"
|
||||
|
||||
pickle.dump(execution_model_output, open("execution_model_output.pkl", "wb"))
|
||||
|
||||
Reference in New Issue
Block a user