mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-07-28 16:07:46 +00:00
342d78e234
* refine prompt * small update * fix a small bug * remove debug config after execution * fix: only remove <think> at start * feat: support creating dataset & multi-eval frame (#1302) * feat: add iterative evolve and evaluation support with partial chain stop * feat: add FTDataEvaluator and support multiple implement functions in finetune * feat: data implement for pre-proposal and proposal and add datasets (#1303) * feat:(1) support for multi layer dataset extraction (2) add category.json for dataset in datasets/ * fix: fix bug for generate category.json * feat: add get_dataset_folder_desc * init data proposal and merge qzli/ft * update data proposal prompts and add max_position_embeddings and resolve confilcts * remove sample counts in data proposal * turn data and train to unified hypo_gen * refine prompts * remove category.json and add it to dataset_info * fix jinja problem and proposal done * lint * add ai-generated description and raw readme into dataset_info.json * update prompt for description * add datasets * initial fix for proposal of data * final version for data proposal * lint * feat: add stats in dataset_info, and enable data coder (#1306) * refactor(dataset): add stats into dataset_info.json, and remove dataset from gitignore_folder * feat: enable data coder and run data process * feat: Merge data coder (#1307) * feat: implement finetune data coding, evaluation, and config improvements * fix: deepspeed config path * fix: dataset info columns --------- Co-authored-by: Young <afe.young@gmail.com> * replace str length with token_limit * add readme to dataset_info and remove useless blank lines in scenario description * feat: dataset prepare * fix: extract prams script name * feat: add loss&predictions samples to feedback * remove duplicate envs and and add llm_api_preferences and enhance reasoning token limits * feat: network for ft_env * fix: remove gpt-4o, which has low quota * feat: a simple ui * feat: merge data and train task type (#1309) * feat: filter redundant prams of lf * fix: ui bug caused by removing task_type * fix: force agent to use high concurrency, and remove redundant prompt * feat: extract info from llama factory log, and check data exists before download * fix: add compatibility rules * feat: llm evaluator for data coder * feat: openai package in ft docker, and refine prompt * feat: refine ft ui, add more info * feat: add raw logs * refine data coder prompt(for feedback debug) * feat: select dataset in scen init * fix: ui for docker log seperately * feat: sync log through blob * improve ui, and add llm feedback in Runner&Exp2FB (#1312) * fix: ui bug to visualize docker log, and lint * feat: unified docker log for ft env, and some refactor * fix bugs and improve ui * feat: save log of evaluator(single feedback) * feat: add evaluator, set cleanup docker log * feat: call llm in RunnerEvaluator and Feedback * fix: extract structured error message in RunnerEvaluator * feat: feedback improve, and fix some bugs * feat: feedback improve when runner fails * small update * feat(UI): add running info and benchmark metric in loop expander * feat(UI): add render markdown toggle * feat: refine prompts and add error type in exp2fb * feat: add filterd params reason, set default benchmark timeout to infinite, and refine train loss express * recover dataset deepscaler * feat: set timeout in .env * refactor: unifiied ft_env timeout * feat: debug mode for data coder * feat: deliver data_stats after generate debug_data * feat: use gpt-5.1 as judge model, set judge_retry, and refine debug mode prompt * refine prompt * refactor: llama factory manager logic, and refine data processing prompt * feat(DockerEnv): support GPU selection via CUDA_VISIBLE_DEVICES * feat: set api concurrency via .env * fix: ft env timeout bug * feat: enable CondaEnv run * fix: can't update bin path in first run, and path bug in lf manager * feat(ui): set log path through .env * refactor(ui): wrap_lines, remove css * feat(coder): retry when parse code-block fail * fix: refine single-fb in ui, and fix path bug(not allow proposal to decide path) * fix: opencompass CondaEnv torch compatible with vllm * fix: refine error text in coding * feat: deepspeed config for CondaEnv * feat: memory estimator * fix: deepspeed package for condaenv * fix: use `client.chat.completions.create()` only * feat: flash attention for condaenv * feat: strong and weak models interface * fix: condaenv package dependency * use multi round conversation in llm finetune proposal * refine prompt for data processing * enable evolving in data coder * maximize output token size * fix: refine ui * fix: optional packages for llama factory * fix: torch denpendency for b200 * fix: opencompass dependency * update cot prompts * skip the sub implement * skip conda preparation if env exists * update chemcot datasets * fix: unify docker to use litellm * update readme and instructions * fix: set CUDA_VISIBLE_DEVICES for CondaEnv * feat: add panorama dataset, refactor dataset interface * feat: calculate token using tiktoken, and ndarray bug * fix: download subtasks of chemcotdataset seperately * feat: customized prepare func for datasets * feat: update new benchmarks * add datasets package * docs: readme for llm finetune * feat: download raw data directly, with post-process function * feat: analyze raw dataset * suppress litellm debug info * feat(ui): summary page * feat: run multi-jobs * feat: improve ui * feat: add path and checkout options to LLM finetune loop entrypoint * feat: add FinanceIQ_ppl benchmark with auto-download and dataset desc rendering * refactor: remove unused imports and dead code, fix session folder logging * feat: enable tablebench and tableInstruct dataset * refine dataset readme, and coder prompt * refine proposal and coder prompt * fix: ui path (default log path) * feat: add automatic LoRA model merging for benchmarking with vLLM * refactor: reorganize finetune benchmark and merge modules under benchmark dir * refactor: modularize benchmark config and error extraction for finetune scenario * fix: update benchmark import paths and disable env cache for device info * refactor docke&conda env and fix import bugs * modify init python file * feat: add FinanceIQ dataset split utility and integrate with pipeline * feat: set weak and strong model by env, distribute workload across models * feat: sample dataset and rm params for tensorboard, wandb * update script to run jobs * refine proposal prompt, remove specific dataset name * fix(ui): auto switch log folder * fix: estimate the processed full data after sample * feat: filter raw data more aggressively, and lower data_eval standard * feat: sync workspace to blob * feat: rdkit for chemcotbench * update qwen2.5&llama3.1 context * fix: force failure on validation error and remove try/except in validator * feat: unified error sample extraction (with test scripts) * feat: set conda cache with .env * feat: skip data eval if data pass in last evo * fix: rm redundant param * fix ui bug * refactor: centralize assign_code_list_to_evo in MultiProcessEvolvingStrategy * feat: add test_params.yaml generation and workspace cleanup improvements for finetune * refactor: replace get_clear_ws_cmd with clear_workspace and update prompts for hard check criteria * add bioprobench dataset * fix: handle commas in training config extraction and refactor prompt includes * bioprobench description * add bioprobench readme * feat: merge lora adapter for blackwell gpu * feat: support for multi benchmarks in one job * change dfficult aware content for training * update difficulty-aware and logging principles * fix: resolve variable name conflict in FTRunnerEvaluator * set job id accuracy to minute * feat(ui): display one selected metric per benchmark * feat: store sota exp, and fix ws_ckp bug * fix: truncate data.json in feedback * fix: opencompass data for conda env * fix: save only the last model * feat: set log path and ws path * fix: set overwrite_cache to avoid lock contention(through injecting params) * feat: redirect stdout to file in localenv * add pickle cache to dataset desc * fix CI * fix: remove redundant wrapper * feat: set python_unbuffered * move redirect stdout to env run * fix a small bug * move model folder * feat(ui): display benchmark baseline * fix: enrich scenario and benchmark description * fix: rewrite runner eval to accept easier * feat: compare with baseline when no SOTA * update tablebench readme * fix: switch back to single benchmark (for baseline) * feat(ui): add ws path in ui * refactor: update SOTA tracking to use DAG traversal and parent selection * fix: prioritize local_selection in trace and refactor sibling retrieval logic * refactor: unify error handling in feedback generation and update workspace injection * feat: add skip_loop_error_stepname to control error skip step in LoopBase * fix: set local_selection to NEW_ROOT for experiments without parent * feat: set different ports for jobs * feat: set different ports for jobs * feat: add upper data size limit for LLM fine-tuning and update related prompts * fix: replace get_truncated_stdout() with stdout for consistent output handling * refactor: remove data.json from cache and workspace logic, focus on script-based reuse * fix: rm target_scenario * feat: add selective cache extraction and custom cache key for data processing * fix(ui): bug when displaying tablebench * fix: filter config in dataset_info.json * feat: add test set, set valid set * feat(ui): update test score, and set color for final decision * feat: add test score for baseline and update ui * fix: use [-100:] as test range * feat: update data_stats in runner * feat: wait for opencompass init when run multi jobs * fix: adjust test&valid split * feat: force to generate COT(with <think> token), and add answer format in scenarios.json * feat: improve ui * fix: unify benchmark volume mounts and set extra_volumes for conda env * fix(ui): number color * fix: update GPU memory handling to use total memory in GB and streamline code * fix: set use_cot_postprocessor * feat: add env_dict to config classes and merge env vars in Env run * fix: let coder obey proposal * fix(ui): direction bug and update chemcot core metirc * fix: set consistent benchmark mount points and env vars for docker and conda * fix: addintional target for LoRA * feat: workspace dir log for benchmark running * fix: tableInstruct path bug and update benchmark description * feat: timeout for whole job * fix: align FinanceIQ import to opencompass * feat: use llm_judge for FinanceIQ * feat: switch to turn on <think> or not * feat: using scripts to redirect stdout, and run in different windows * feat: sync litellm log * fix: gpu memory format * fix: escape special characters in benchmark desc * fix: set data processing timeout to 1h * feat: set valid_loss and save_best_model * fix: inject timeout and stage * fix: loss history extract logic * feat: inject output dir * feat: inject eval batch size * feat: inject save_total_limit * feat: update data prompt * fix: escape shell special characters * fix: tablebench visualization UI * fix: move implementation validation to coder, and ignore injected params * feat: README for FinanceIQ dataset * fix: bioprobench desc error * fix: remove task alignment when coder eval * fix: FinanceIQ now extracts last capital as answer * fix: stdout contains binary data * feat: recover estimate full output and set eval setting automatically * fix(ui): precision for summary table * fix(ui): import error * feat: try to use lora * fix(api): fix litellm bug for code block * fix: refine prompts to give agent more decision space * chore(ci): fix mypy typing issues * chore(ci): format code with black * chore(ci): fix ruff lint violations * chore(ci): sort imports with isort * chore(ci): format code with black * test: temporarily skip extract_parameters imports due to numpy pin * fix: compatibility issues for qlib scenarios on finetune branch * fix(fin_factor): skip to fb for coder error * fix(loop): default skip to feedback step on skip_loop_error When skip_loop_error exception happens and skip_loop_error_stepname is not explicitly set, default to jumping to 'feedback' step if it exists, otherwise fall back to the last step (record). This prevents KeyError when record step tries to access feedback data that doesn't exist because we skipped the feedback phase. Also removed redundant skip_loop_error_stepname from finetune loop since it's now the default behavior. * add 'skip to record' to DS scenario like other scenarios * fix 2 scenarios bug about rd_loop class * fix: lint(mypy, ruff, black) error * fix: mypy lint error * fix data science scenario bug --------- Co-authored-by: Xu Yang <peteryang@vip.qq.com> Co-authored-by: Qizheng Li <jenssenlee@163.com> Co-authored-by: you-n-g <you-n-g@users.noreply.github.com> Co-authored-by: amstrongzyf <201840057@smail.nju.edu.cn> Co-authored-by: Young <afe.young@gmail.com> Co-authored-by: amstrongzyf <amstrongzyf@126.com> Co-authored-by: chelsea97 <zhuowbrown@gmail.com> Co-authored-by: SunsetWolf <Lv.Linlang@hotmail.com>
305 lines
12 KiB
Python
305 lines
12 KiB
Python
"""
|
|
Simplified LLM Fine-tuning Configuration Validator
|
|
|
|
Two-step validation:
|
|
1. Parameter filtering - Remove unsupported parameters
|
|
2. Micro-batch testing - Runtime validation with small dataset
|
|
"""
|
|
|
|
import json
|
|
import re
|
|
import time
|
|
from dataclasses import dataclass, field
|
|
from pathlib import Path
|
|
from typing import Dict, List, Optional, Set
|
|
|
|
import yaml
|
|
|
|
from rdagent.components.coder.finetune.conf import (
|
|
FT_DEBUG_YAML_FILE_NAME,
|
|
FT_TEST_PARAMS_FILE_NAME,
|
|
get_ft_env,
|
|
get_workspace_prefix,
|
|
)
|
|
from rdagent.core.experiment import FBWorkspace
|
|
from rdagent.log import rdagent_logger as logger
|
|
from rdagent.scenarios.finetune.scen.llama_factory_manager import LLaMAFactory_manager
|
|
|
|
DIRNAME = Path(__file__).absolute().resolve().parent
|
|
|
|
# System-managed parameters that are automatically injected during validation.
|
|
# These should NOT be checked for alignment in eval prompts.
|
|
# Single source of truth: modify here to change injected parameters.
|
|
SYSTEM_MANAGED_PARAMS = {
|
|
"overwrite_cache": True, # Avoid HF datasets cache lock contention
|
|
"save_only_model": True, # Save disk space
|
|
# "save_total_limit": 1, # Limit checkpoint count to save disk space
|
|
"output_dir": "./output", # Standardize model output location
|
|
"per_device_eval_batch_size": 1, # Prevent OOM during evaluation
|
|
}
|
|
|
|
|
|
@dataclass
|
|
class ValidationResult:
|
|
"""Configuration validation result"""
|
|
|
|
success: bool
|
|
filtered_config: str
|
|
execution_output: str = "" # Parsed/summarized output for LLM
|
|
raw_stdout: str = "" # Full raw stdout for UI display
|
|
errors: List[str] = field(default_factory=list)
|
|
execution_time: float = 0.0
|
|
|
|
|
|
class LLMConfigValidator:
|
|
"""LLM configuration validator with two-step validation:
|
|
|
|
1. Parameter filtering - Remove unsupported parameters
|
|
2. Micro-batch test - Runtime validation with small dataset
|
|
|
|
The micro-batch test inherently validates completeness, so no separate completeness check is needed.
|
|
"""
|
|
|
|
def __init__(self):
|
|
self._supported_params_cache: Optional[Set[str]] = None
|
|
|
|
def validate_and_test(self, config_yaml: str, workspace: FBWorkspace, env) -> ValidationResult:
|
|
"""Three-step validation: parameter filtering + injection + micro-batch testing"""
|
|
start_time = time.time()
|
|
|
|
# Step 1: Parameter filtering
|
|
filtered_config, removed_params = self._filter_parameters(config_yaml)
|
|
|
|
# Step 2: Inject required parameters for multi-task environments
|
|
injected_config = self._inject_required_parameters(filtered_config)
|
|
|
|
# Step 3: Micro-batch testing (validates everything at runtime)
|
|
result = self._run_micro_batch_test(injected_config, workspace, env)
|
|
result.execution_time = time.time() - start_time
|
|
|
|
# Add filtered params info to execution_output for agent learning
|
|
if removed_params:
|
|
filter_info = (
|
|
f"\n\n[Filtered Parameters] {len(removed_params)} unsupported params removed: {removed_params}"
|
|
)
|
|
result.execution_output += filter_info
|
|
|
|
return result
|
|
|
|
def _filter_parameters(self, config_yaml: str) -> tuple[str, List[str]]:
|
|
"""Filter configuration parameters to only include supported ones.
|
|
|
|
Returns:
|
|
tuple: (filtered_yaml, removed_params_list)
|
|
"""
|
|
config_dict = yaml.safe_load(config_yaml)
|
|
if not isinstance(config_dict, dict):
|
|
return config_yaml, []
|
|
|
|
supported_params = self._get_supported_parameters()
|
|
|
|
filtered_config = {}
|
|
removed_params = []
|
|
for k, v in config_dict.items():
|
|
if k in supported_params:
|
|
filtered_config[k] = v
|
|
else:
|
|
removed_params.append(k)
|
|
|
|
if removed_params:
|
|
logger.info(f"Filtered out {len(removed_params)} unsupported parameters: {removed_params}")
|
|
|
|
return yaml.dump(filtered_config, default_flow_style=False, sort_keys=False), removed_params
|
|
|
|
def _inject_required_parameters(self, config_yaml: str) -> str:
|
|
"""Inject required parameters for multi-task environments.
|
|
|
|
Uses SYSTEM_MANAGED_PARAMS as the single source of truth.
|
|
"""
|
|
config = yaml.safe_load(config_yaml)
|
|
if not isinstance(config, dict):
|
|
return config_yaml
|
|
|
|
config.update(SYSTEM_MANAGED_PARAMS)
|
|
|
|
logger.info(f"Injected required parameters: {SYSTEM_MANAGED_PARAMS}")
|
|
return yaml.dump(config, default_flow_style=False, sort_keys=False)
|
|
|
|
def _get_supported_parameters(self) -> Set[str]:
|
|
"""Get supported parameters from LlamaFactory Manager"""
|
|
if self._supported_params_cache is not None:
|
|
return self._supported_params_cache
|
|
|
|
all_params = LLaMAFactory_manager.get_parameters()
|
|
|
|
# Extract all parameter names from all parameter types (including nested structures)
|
|
supported_params = set()
|
|
for param_type, params_dict in all_params.items():
|
|
if isinstance(params_dict, dict):
|
|
# Recursively extract parameter names from nested dictionaries
|
|
for key, value in params_dict.items():
|
|
if isinstance(value, dict) and "name" in value:
|
|
# This is a parameter definition with metadata
|
|
supported_params.add(key)
|
|
elif isinstance(value, dict):
|
|
# This is a nested category (e.g., BaseModelArguments, LoraArguments)
|
|
# Extract parameter names from the nested structure
|
|
for nested_key, nested_value in value.items():
|
|
if isinstance(nested_value, dict) and "name" in nested_value:
|
|
supported_params.add(nested_key)
|
|
|
|
if not supported_params:
|
|
raise RuntimeError("No parameters found in LlamaFactory Manager")
|
|
|
|
logger.info(f"Loaded {len(supported_params)} parameters from LlamaFactory Manager")
|
|
self._supported_params_cache = supported_params
|
|
return supported_params
|
|
|
|
def _parse_execution_log(self, stdout: str, exit_code: int, failed_stage: str = None) -> str:
|
|
"""Parse execution log and extract key information for LLM evaluation.
|
|
|
|
Reduces log from ~36k tokens to ~500 tokens by extracting only:
|
|
- Status and exit code
|
|
- Error messages (if any)
|
|
- Training metrics (if successful)
|
|
- Warnings (limited)
|
|
- Timeout and stage information (if applicable)
|
|
|
|
Args:
|
|
stdout: The execution output
|
|
exit_code: The process exit code
|
|
failed_stage: Which stage failed - "data_processing" or "training"
|
|
"""
|
|
result = {
|
|
"status": "success" if exit_code == 0 else "failed",
|
|
"exit_code": exit_code,
|
|
}
|
|
|
|
# Handle timeout (exit_code 124)
|
|
if exit_code == 124:
|
|
result["timeout"] = True
|
|
if failed_stage:
|
|
result["failed_stage"] = failed_stage
|
|
|
|
# 1. Extract error information (highest priority)
|
|
# Strategy: extract rank0's error block (each line prefixed with [rank0]:)
|
|
error_text = None
|
|
|
|
# Method A: Extract [rank0]: prefixed lines and reconstruct traceback
|
|
rank0_lines = re.findall(r"\[rank0\]:[^\n]+", stdout)
|
|
if rank0_lines:
|
|
rank0_block = "\n".join(line.replace("[rank0]: ", "").replace("[rank0]:", "") for line in rank0_lines)
|
|
# Find traceback in rank0 block
|
|
tb_match = re.search(
|
|
r"Traceback \(most recent call last\):.*?(?:Error|Exception):[^\n]+", rank0_block, re.DOTALL
|
|
)
|
|
if tb_match:
|
|
error_text = tb_match.group(0)
|
|
|
|
# Method B: Fallback to generic traceback (no rank prefix)
|
|
# Use findall to get ALL tracebacks, then keep the first one (root cause)
|
|
if not error_text:
|
|
all_tracebacks = re.findall(
|
|
r"Traceback \(most recent call last\):.*?(?:Error|Exception):[^\n]+", stdout, re.DOTALL
|
|
)
|
|
if all_tracebacks:
|
|
# First traceback is usually the root cause
|
|
error_text = all_tracebacks[0]
|
|
if len(all_tracebacks) > 1:
|
|
error_text += f"\n\n[Note: {len(all_tracebacks)} total errors, showing root cause]"
|
|
|
|
if error_text:
|
|
# Limit length but keep from the END (actual error type/message is at the end of traceback)
|
|
result["error"] = error_text[-4000:] if len(error_text) > 4000 else error_text
|
|
|
|
# 2. Extract training information
|
|
if "Running training" in stdout:
|
|
result["training_started"] = True
|
|
|
|
# Extract training config
|
|
# NOTE: we may have log like "Num examples = 1,000,000" and "Num Epochs = 1,000"; So we need to handle ","
|
|
num_examples = re.search(r"Num examples\s*=\s*([\d,]+)", stdout)
|
|
num_epochs = re.search(r"Num Epochs\s*=\s*([\d,]+)", stdout)
|
|
if num_examples:
|
|
result["num_examples"] = int(num_examples.group(1).replace(",", ""))
|
|
if num_epochs:
|
|
result["num_epochs"] = int(num_epochs.group(1).replace(",", ""))
|
|
|
|
# Extract final metrics (JSON format from trainer output)
|
|
final_metrics = re.search(r"\{'train_runtime':[^}]+\}", stdout)
|
|
if final_metrics:
|
|
try:
|
|
metrics = eval(final_metrics.group(0)) # Safe: only numbers and strings
|
|
result["final_metrics"] = {
|
|
"train_loss": metrics.get("train_loss"),
|
|
"train_runtime": metrics.get("train_runtime"),
|
|
"train_samples_per_second": metrics.get("train_samples_per_second"),
|
|
}
|
|
except Exception:
|
|
pass
|
|
|
|
# Check completion
|
|
if "Training completed" in stdout:
|
|
result["completed"] = True
|
|
|
|
# 3. Extract warnings (limit to 20)
|
|
warnings = re.findall(r"\[WARNING[^\]]*\][^\n]+", stdout)
|
|
if warnings:
|
|
result["warnings"] = list(set(warnings))[:20]
|
|
|
|
# 4. Fallback: if parsing failed, include truncated raw log
|
|
if not result.get("error") and not result.get("training_started"):
|
|
result["raw_log_tail"] = stdout[-2000:] if len(stdout) > 2000 else stdout
|
|
|
|
return json.dumps(result, indent=2, ensure_ascii=False)
|
|
|
|
def _run_micro_batch_test(self, config_yaml: str, workspace: FBWorkspace, env) -> ValidationResult:
|
|
"""Run micro-batch training test for runtime validation"""
|
|
result = ValidationResult(success=True, filtered_config=config_yaml)
|
|
ws_prefix = get_workspace_prefix(env)
|
|
|
|
# Create micro-batch test configuration
|
|
config = yaml.safe_load(config_yaml)
|
|
if not isinstance(config, dict):
|
|
result.success = False
|
|
result.execution_output = "Invalid YAML configuration"
|
|
result.errors.append("Invalid configuration for micro-batch test")
|
|
return result
|
|
|
|
test_config = config.copy()
|
|
|
|
# Load extra test parameters from workspace (generated by coder in 2nd turn)
|
|
extra_test_params = yaml.safe_load(workspace.file_dict[FT_TEST_PARAMS_FILE_NAME])
|
|
|
|
# Merge extra test parameters (overrides previous settings)
|
|
if extra_test_params:
|
|
test_config.update(extra_test_params)
|
|
|
|
# Run micro-batch training
|
|
workspace.inject_files(**{FT_DEBUG_YAML_FILE_NAME: yaml.dump(test_config, default_flow_style=False)})
|
|
training_result = workspace.run(
|
|
env=env,
|
|
entry=f"llamafactory-cli train {FT_DEBUG_YAML_FILE_NAME}",
|
|
)
|
|
|
|
# Remove micro-batch test files
|
|
workspace.remove_files([FT_DEBUG_YAML_FILE_NAME, FT_TEST_PARAMS_FILE_NAME])
|
|
|
|
# Parse and store structured execution output (reduces ~36k tokens to ~500)
|
|
raw_stdout = training_result.stdout if training_result.stdout else ""
|
|
result.raw_stdout = raw_stdout # Keep full log for UI
|
|
result.execution_output = self._parse_execution_log(raw_stdout, training_result.exit_code)
|
|
|
|
# Check results
|
|
progress_indicators = ["train_loss", "Training:", "Epoch", "loss:", "step"]
|
|
has_progress = any(ind.lower() in training_result.stdout.lower() for ind in progress_indicators)
|
|
|
|
if training_result.exit_code == 0 and has_progress:
|
|
logger.info("Micro-batch test passed")
|
|
result.success = True
|
|
else:
|
|
result.success = False
|
|
result.errors.append(f"Micro-batch test failed (exit_code={training_result.exit_code})")
|
|
|
|
return result
|