File size: 909 Bytes
ef243c4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | """Audit the pinned actual Unsloth parser/encoder, without training or truncating data."""
from pathlib import Path
import runpy
import sys
import shutil
ROOT=Path(__file__).resolve().parents[1];WORKSPACE=ROOT.parents[1]
sys.path.insert(0,str(WORKSPACE/'scripts'))
import quality_common
def benchmark_rows(splits=None,data=None):
for row in quality_common.rows(ROOT/'data/benchmark.parquet'):yield 'public_evaluation',row
quality_common.active_rows=benchmark_rows
prefix='jevbench_de_'
sys.argv=['check_training_path.py','--data',str(ROOT),'--report-prefix',prefix]
runpy.run_path(str(WORKSPACE/'scripts/check_training_path.py'),run_name='__main__')
for name in ['training_path.json','training_render_samples.json']:
shutil.copyfile(quality_common.REPORT/(prefix+name),ROOT/'audit'/name)
shutil.copyfile(quality_common.OUT/(prefix+'training_token_lengths.parquet'),ROOT/'audit/token_lengths.parquet')
|