Add files using upload-large-folder tool
Browse files- CHANGELOG.md +9 -0
- README.md +91 -48
- SHA256SUMS.txt +0 -0
- builder/18_close_v04_publication.py +16 -0
- builder/19_upload_final_reports.py +6 -0
- builder/20_final_revision_load.py +12 -0
- builder/20_prepare_v041_translation_alignment.py +366 -0
- builder/24_build_v041_quality.py +1320 -0
- builder/25_validate_v041_quality.py +415 -0
- builder/26_upload_v041_quality.py +119 -0
- builder/27_remote_acceptance_v041.py +142 -0
- data/context_multiturn_qa/eval-00000-of-00001.parquet +2 -2
- data/context_multiturn_qa/train-00000-of-00001.parquet +2 -2
- data/single_tool_calling/eval-00000-of-00001.parquet +2 -2
- data/single_tool_calling/train-00000-of-00001.parquet +2 -2
- data/single_turn_streaming/eval-00000-of-00001.parquet +2 -2
- data/single_turn_streaming/train-00000-of-00001.parquet +2 -2
- registry/eval_denylist.yaml +4 -4
- registry/license_registry.yaml +5 -5
- registry/source_registry.yaml +5 -3
- reports/BENCHMARK_LEAKAGE_REPORT_V041.md +3 -0
- reports/CAPABILITY_COVERAGE_REPORT_V041.md +28 -0
- reports/CHANGELOG_V041.md +9 -0
- reports/DEDUP_REPORT_V041.md +3 -0
- reports/FINAL_V041_QUALITY_REPORT.md +127 -0
- reports/FULL_DUPLEX_DEFERRED.md +2 -2
- reports/LOCAL_ACCEPTANCE_V041.md +22 -0
- reports/MULTITURN_DEPENDENCY_AUDIT.md +11 -0
- reports/QUALITY_REGRADING_REPORT.md +8 -0
- reports/SPEECH_OUTPUT_ALIGNMENT_AUDIT.md +6 -0
- reports/TOOL_CALLING_DIVERSITY_REPORT.md +15 -0
- reports/TOOL_CALLING_SOURCE_AUDIT.md +3 -0
- reports/TOOL_CALLING_VALIDATION_REPORT.md +2 -2
- reports/TRAINING_WEIGHT_REPORT.md +13 -0
- reports/TRANSLATION_QUALITY_REPORT.md +8 -0
- reports/TRANSLATION_SOURCE_AUDIT.md +3 -0
- reports/V04_REMOTE_CONFIG_AUDIT.md +12 -0
- reports/V04_VIEWER_STATUS.md +7 -0
- reports/build_summary_v041.json +119 -0
- reports/capability_coverage_v041.json +109 -0
- reports/context_dependency_stats.json +13 -0
- reports/local_acceptance_v041.json +139 -0
- schema/SCHEMA.md +2 -2
- schema/canonical_schema.json +78 -2
- schema/canonical_schema.py +1 -7
- schema/label_ontology.yaml +12 -5
- training_recipes/balanced_all.yaml +6 -0
- training_recipes/high_quality.yaml +6 -0
- training_recipes/streaming_focused.yaml +10 -0
CHANGELOG.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v0.4.1-quality changelog
|
| 2 |
+
|
| 3 |
+
- Preserved three public configs and v0.4 interface.
|
| 4 |
+
- Replaced false-positive legacy speech alignment with 500 real, non-fallback aligned speech rows.
|
| 5 |
+
- Added 3000 real CoVoST2 train speech-translation rows.
|
| 6 |
+
- Classified every multi-turn episode and downweighted/rejected weak context dependence.
|
| 7 |
+
- Reduced original deterministic tool suite to 400 warm-up rows and added 2,000 diverse validated synthetic cases.
|
| 8 |
+
- Added canonical schema 1.1 quality/alignment/tool fields and three training recipes.
|
| 9 |
+
- Full Duplex remains deferred.
|
README.md
CHANGED
|
@@ -20,57 +20,60 @@ configs:
|
|
| 20 |
- split: eval
|
| 21 |
path: data/single_tool_calling/eval-*.parquet
|
| 22 |
---
|
| 23 |
-
# Streaming Omni
|
| 24 |
|
| 25 |
-
|
| 26 |
|
| 27 |
## Counts
|
| 28 |
|
| 29 |
```json
|
| 30 |
{
|
| 31 |
-
"
|
| 32 |
-
"
|
| 33 |
-
"
|
|
|
|
| 34 |
"config_split_counts": {
|
| 35 |
-
"
|
| 36 |
-
"
|
| 37 |
-
"
|
| 38 |
-
"
|
| 39 |
-
"single_tool_calling/
|
| 40 |
-
"single_tool_calling/
|
| 41 |
},
|
| 42 |
"task_counts": {
|
| 43 |
-
"qa":
|
| 44 |
"live_commentary": 477,
|
| 45 |
-
"proactive_response": 482,
|
| 46 |
"grounding": 496,
|
| 47 |
"summary": 798,
|
| 48 |
"asr": 1000,
|
| 49 |
-
"translation":
|
| 50 |
-
"
|
| 51 |
-
"
|
|
|
|
|
|
|
| 52 |
},
|
| 53 |
"capability_counts": {
|
| 54 |
"av_joint_reasoning": 458,
|
| 55 |
"live_av_commentary": 477,
|
| 56 |
-
"proactive_av_interaction": 482,
|
| 57 |
"ocr_screen_grounding": 496,
|
| 58 |
"streaming_audio_interaction": 1797,
|
| 59 |
-
"streaming_asr_translation":
|
|
|
|
|
|
|
| 60 |
},
|
| 61 |
-
"
|
| 62 |
-
"B":
|
| 63 |
-
"C":
|
| 64 |
},
|
| 65 |
-
"
|
| 66 |
-
"reconstructed":
|
| 67 |
"simulated": 1545,
|
| 68 |
-
"offline":
|
| 69 |
},
|
| 70 |
"modality_counts": {
|
| 71 |
-
"audio":
|
| 72 |
"video": 1417,
|
| 73 |
-
"text":
|
| 74 |
"image": 496,
|
| 75 |
"screen": 496
|
| 76 |
},
|
|
@@ -80,38 +83,78 @@ Exactly three configs share one canonical schema. Full Duplex is deferred. Strea
|
|
| 80 |
"skyzhou06/LifeSpeechSummaryStreamingCoT": 798,
|
| 81 |
"google/fleurs": 1000,
|
| 82 |
"project_synthetic_bilingual_templates": 200,
|
| 83 |
-
"skyzhou06/LifeAudioMultiTurnStreamingCoT":
|
| 84 |
-
"project_deterministic_tool_suite":
|
|
|
|
|
|
|
| 85 |
},
|
| 86 |
"license_counts": {
|
| 87 |
"CC BY-NC 4.0; Seamless Interaction train split": 935,
|
| 88 |
-
"CC-BY-NC-4.0": 482,
|
| 89 |
-
"public_domain": 130,
|
| 90 |
"synthetic": 366,
|
| 91 |
-
"CC-BY-4.0": 3239,
|
| 92 |
"CC0": 758,
|
| 93 |
-
"
|
| 94 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 95 |
},
|
| 96 |
-
"
|
| 97 |
-
"
|
| 98 |
-
"
|
| 99 |
-
"
|
| 100 |
-
"
|
| 101 |
-
"
|
| 102 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 103 |
}
|
| 104 |
```
|
| 105 |
|
|
|
|
|
|
|
| 106 |
```python
|
| 107 |
from datasets import load_dataset
|
| 108 |
-
|
| 109 |
-
|
| 110 |
-
|
| 111 |
```
|
| 112 |
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
## Remote publication
|
| 116 |
-
|
| 117 |
-
The v0.4 data commit uploaded successfully and all six remote splits loaded from a fresh cache. The Hugging Face Viewer remained in its asynchronous “available soon” state at the final check; no null-type or schema-specific error was reported.
|
|
|
|
| 20 |
- split: eval
|
| 21 |
path: data/single_tool_calling/eval-*.parquet
|
| 22 |
---
|
| 23 |
+
# Streaming Omni post-training dataset v0.4.1-quality
|
| 24 |
|
| 25 |
+
This quality upgrade preserves the three v0.4 public configs and uses one explicit canonical PyArrow schema (1.1) across all six splits. Full Duplex remains deferred.
|
| 26 |
|
| 27 |
## Counts
|
| 28 |
|
| 29 |
```json
|
| 30 |
{
|
| 31 |
+
"version": "v0.4.1-quality",
|
| 32 |
+
"v04_sha": "cf95b027d75ec793556e395aef9af8118a08b3d8",
|
| 33 |
+
"accepted_rows": 12483,
|
| 34 |
+
"rejected_hard_gate_rows": 39,
|
| 35 |
"config_split_counts": {
|
| 36 |
+
"single_turn_streaming/eval": 360,
|
| 37 |
+
"single_turn_streaming/train": 8050,
|
| 38 |
+
"context_multiturn_qa/eval": 99,
|
| 39 |
+
"context_multiturn_qa/train": 1613,
|
| 40 |
+
"single_tool_calling/eval": 92,
|
| 41 |
+
"single_tool_calling/train": 2269
|
| 42 |
},
|
| 43 |
"task_counts": {
|
| 44 |
+
"qa": 3169,
|
| 45 |
"live_commentary": 477,
|
|
|
|
| 46 |
"grounding": 496,
|
| 47 |
"summary": 798,
|
| 48 |
"asr": 1000,
|
| 49 |
+
"translation": 3200,
|
| 50 |
+
"proactive_response": 482,
|
| 51 |
+
"tool_call": 1499,
|
| 52 |
+
"tool_selection": 862,
|
| 53 |
+
"speech_alignment": 500
|
| 54 |
},
|
| 55 |
"capability_counts": {
|
| 56 |
"av_joint_reasoning": 458,
|
| 57 |
"live_av_commentary": 477,
|
|
|
|
| 58 |
"ocr_screen_grounding": 496,
|
| 59 |
"streaming_audio_interaction": 1797,
|
| 60 |
+
"streaming_asr_translation": 4000,
|
| 61 |
+
"proactive_av_interaction": 482,
|
| 62 |
+
"speech_output_alignment": 500
|
| 63 |
},
|
| 64 |
+
"quality_grade_counts": {
|
| 65 |
+
"B": 4966,
|
| 66 |
+
"C": 7517
|
| 67 |
},
|
| 68 |
+
"streaming_type_counts": {
|
| 69 |
+
"reconstructed": 4917,
|
| 70 |
"simulated": 1545,
|
| 71 |
+
"offline": 6021
|
| 72 |
},
|
| 73 |
"modality_counts": {
|
| 74 |
+
"audio": 7214,
|
| 75 |
"video": 1417,
|
| 76 |
+
"text": 8001,
|
| 77 |
"image": 496,
|
| 78 |
"screen": 496
|
| 79 |
},
|
|
|
|
| 83 |
"skyzhou06/LifeSpeechSummaryStreamingCoT": 798,
|
| 84 |
"google/fleurs": 1000,
|
| 85 |
"project_synthetic_bilingual_templates": 200,
|
| 86 |
+
"skyzhou06/LifeAudioMultiTurnStreamingCoT": 1712,
|
| 87 |
+
"project_deterministic_tool_suite": 400,
|
| 88 |
+
"facebook/covost2": 3500,
|
| 89 |
+
"project_v041_diverse_tool_suite": 1961
|
| 90 |
},
|
| 91 |
"license_counts": {
|
| 92 |
"CC BY-NC 4.0; Seamless Interaction train split": 935,
|
|
|
|
|
|
|
| 93 |
"synthetic": 366,
|
|
|
|
| 94 |
"CC0": 758,
|
| 95 |
+
"CC-BY-4.0": 4600,
|
| 96 |
+
"CC-BY-NC-4.0": 3982,
|
| 97 |
+
"public_domain": 130,
|
| 98 |
+
"cc-by-nc-4.0": 1392,
|
| 99 |
+
"cc": 320
|
| 100 |
+
},
|
| 101 |
+
"origin_counts": {
|
| 102 |
+
"real_or_transformed": 9426,
|
| 103 |
+
"synthetic": 3057
|
| 104 |
},
|
| 105 |
+
"context_dependency_counts": {
|
| 106 |
+
"conversational_state": 839,
|
| 107 |
+
"correction": 382,
|
| 108 |
+
"previous_turn_reference": 419,
|
| 109 |
+
"clarification": 70,
|
| 110 |
+
"weak_dependency": 2
|
| 111 |
+
},
|
| 112 |
+
"recommended_training_weight_counts": {
|
| 113 |
+
"1.00": 4966,
|
| 114 |
+
"0.40": 1496,
|
| 115 |
+
"0.20": 1950,
|
| 116 |
+
"0.62": 1710,
|
| 117 |
+
"0.22": 400,
|
| 118 |
+
"0.42": 1461,
|
| 119 |
+
"0.48": 500
|
| 120 |
+
},
|
| 121 |
+
"tool_control_counts": {
|
| 122 |
+
"success_grounded": 198,
|
| 123 |
+
"no_tool": 101,
|
| 124 |
+
"failure_recovery": 101,
|
| 125 |
+
"no_tool_hard_negative": 467,
|
| 126 |
+
"success_result_grounded": 700,
|
| 127 |
+
"tool_failure_recovery": 300,
|
| 128 |
+
"clarification_before_tool": 294,
|
| 129 |
+
"partial_result_grounded": 100,
|
| 130 |
+
"conflict_result_grounded": 100
|
| 131 |
+
},
|
| 132 |
+
"translation_language_pairs": {
|
| 133 |
+
"es->en": 25,
|
| 134 |
+
"zh->en": 25,
|
| 135 |
+
"en->es": 25,
|
| 136 |
+
"en->de": 25,
|
| 137 |
+
"en->fr": 25,
|
| 138 |
+
"de->en": 25,
|
| 139 |
+
"fr->en": 25,
|
| 140 |
+
"en->zh": 25,
|
| 141 |
+
"en->zh-CN": 3000
|
| 142 |
+
},
|
| 143 |
+
"speech_output_alignment_rows": 500,
|
| 144 |
+
"real_speech_translation_rows": 3000,
|
| 145 |
+
"context_rejected_independent": 288,
|
| 146 |
+
"old_tool_rows_retained": 400,
|
| 147 |
+
"new_diverse_tool_rows": 1961
|
| 148 |
}
|
| 149 |
```
|
| 150 |
|
| 151 |
+
## Recommended loading
|
| 152 |
+
|
| 153 |
```python
|
| 154 |
from datasets import load_dataset
|
| 155 |
+
ds = load_dataset("skyzhou06/StreamingOmniDatasets", "single_turn_streaming", split="train")
|
| 156 |
+
high_quality = ds.filter(lambda x: x["quality"]["grade"] == "B")
|
| 157 |
+
weighted = ds.select_columns(["id", "recommended_training_weight"])
|
| 158 |
```
|
| 159 |
|
| 160 |
+
Training views are defined in `training_recipes/`. No extra HF config is required. New CoVoST2 data is train-only, real audio, CC BY-NC 4.0, and cross-checked against the official CoVoST2 train TSV. Automated/model-assisted checks are not human review. No A-grade or human-reviewed rows are claimed.
|
|
|
|
|
|
|
|
|
|
|
|
SHA256SUMS.txt
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|
builder/18_close_v04_publication.py
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import json,os,re
|
| 2 |
+
from pathlib import Path
|
| 3 |
+
from collections import Counter
|
| 4 |
+
from huggingface_hub import HfApi,hf_hub_download
|
| 5 |
+
from datasets import get_dataset_config_names,get_dataset_split_names,load_dataset
|
| 6 |
+
R=Path('/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork');REP=R/'reports';REP.mkdir(exist_ok=True);repo='skyzhou06/StreamingOmniDatasets';api=HfApi(endpoint=os.getenv('HF_ENDPOINT','https://huggingface.co'));info=api.dataset_info(repo);sha=info.sha;files=[x.rfilename for x in info.siblings];configs=get_dataset_config_names(repo,revision=sha);out={'repo':repo,'head_sha':sha,'files':files,'configs':{},'stale_old_files':[],'absolute_path_hits':[]}
|
| 7 |
+
old=['AVJointReasoning','LiveAVCommentary','OCRScreenGrounding','ProactiveAVInteraction','SpeechOutputAlignment','StreamingASRTranslation','StreamingAudioInteraction'];out['stale_old_files']=[f for f in files if any('/'+x+'/' in f for x in old)]
|
| 8 |
+
cache=R/'.cache/huggingface/v04_baseline_cf95';
|
| 9 |
+
for c in configs:
|
| 10 |
+
out['configs'][c]={}
|
| 11 |
+
for sp in get_dataset_split_names(repo,c,revision=sha):
|
| 12 |
+
d=load_dataset(repo,c,split=sp,revision=sha,cache_dir=str(cache));blob=json.dumps(d[:],ensure_ascii=False)
|
| 13 |
+
if '/home/XuWenqi/' in blob or '/root/' in blob or '/tmp/' in blob:out['absolute_path_hits'].append(c+'/'+sp)
|
| 14 |
+
out['configs'][c][sp]={'rows':len(d),'features':str(d.features)}
|
| 15 |
+
readme=Path(hf_hub_download(repo_id=repo,repo_type='dataset',filename='README.md',revision=sha)).read_text();out['readme_configs']=re.findall(r'config_name:\s*([^\s]+)',readme);out['readme_head']=readme[:4000]
|
| 16 |
+
(REP/'v04_baseline_stats.json').write_text(json.dumps(out,indent=2,ensure_ascii=False));(REP/'V04_BASELINE_SNAPSHOT.md').write_text('# v0.4 Baseline Snapshot\n\n- HEAD: `'+sha+'`\n- Files: '+str(len(files))+'\n- Actual configs: '+', '.join(configs)+'\n- Stale old config files: '+str(len(out['stale_old_files']))+'\n- Absolute-path hits in published rows: '+str(len(out['absolute_path_hits']))+'\n\n```json\n'+json.dumps({k:v for k,v in out.items() if k not in ('files','readme_head')},indent=2)+'\n```\n');(REP/'V04_REMOTE_CONFIG_AUDIT.md').write_text('# v0.4 Remote Config Audit\n\nActual configs and README configs match: **'+str(sorted(configs)==sorted(out['readme_configs']))+'**\n\n```json\n'+json.dumps({'actual_configs':configs,'readme_configs':out['readme_configs'],'splits':out['configs'],'stale_old_files':out['stale_old_files']},indent=2)+'\n```\n');print(json.dumps({'sha':sha,'configs':configs,'rows':{c:{sp:v['rows'] for sp,v in x.items()} for c,x in out['configs'].items()},'stale':len(out['stale_old_files']),'abs':len(out['absolute_path_hits'])},indent=2))
|
builder/19_upload_final_reports.py
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import json,os
|
| 2 |
+
from pathlib import Path
|
| 3 |
+
from huggingface_hub import HfApi,CommitOperationAdd
|
| 4 |
+
R=Path('/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork');REL=R/'data/release/unified_v0_4';REP=R/'reports';repo='skyzhou06/StreamingOmniDatasets';expected='8cec4ac12e423e1c9a8843fe9dbd13a67c51ddc2';api=HfApi(endpoint=os.getenv('HF_ENDPOINT','https://huggingface.co'));token=os.environ['HF_TOKEN'];before=api.dataset_info(repo,token=token).sha
|
| 5 |
+
if before!=expected:raise RuntimeError(f'HEAD changed: {before}')
|
| 6 |
+
files=['README.md','SHA256SUMS.txt','reports/REMOTE_HF_ACCEPTANCE_REPORT.md','reports/HF_UPLOAD_REPORT.md'];ops=[CommitOperationAdd(path_in_repo=x,path_or_fileobj=str(REL/x)) for x in files];res=api.create_commit(repo_id=repo,repo_type='dataset',operations=ops,commit_message='Finalize v0.4 publication reports',token=token);after=api.dataset_info(repo,token=token).sha;out={'status':'uploaded','previous_sha':before,'new_sha':after,'commit_url':res.commit_url,'files':files};(REP/'hf_final_report_commit.json').write_text(json.dumps(out,indent=2));print(json.dumps(out,indent=2))
|
builder/20_final_revision_load.py
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import json,os
|
| 2 |
+
from pathlib import Path
|
| 3 |
+
from datasets import load_dataset
|
| 4 |
+
from huggingface_hub import HfApi
|
| 5 |
+
R=Path('/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork');repo='skyzhou06/StreamingOmniDatasets';rev='cf95b027d75ec793556e395aef9af8118a08b3d8';api=HfApi(endpoint=os.getenv('HF_ENDPOINT','https://huggingface.co'));head=api.dataset_info(repo).sha
|
| 6 |
+
if head!=rev:raise RuntimeError(f'HEAD {head} != {rev}')
|
| 7 |
+
out={'head_sha':head,'results':{}}
|
| 8 |
+
for c in ['single_turn_streaming','context_multiturn_qa','single_tool_calling']:
|
| 9 |
+
out['results'][c]={}
|
| 10 |
+
for sp in ['train','eval']:
|
| 11 |
+
d=load_dataset(repo,c,split=sp,revision=rev,cache_dir=str(R/'.cache/huggingface/final_revision_cf95'));out['results'][c][sp]={'rows':len(d),'features':str(d.features)}
|
| 12 |
+
(R/'reports/final_revision_load.json').write_text(json.dumps(out,indent=2));print(json.dumps({'head_sha':head,'rows':{c:{sp:v['rows'] for sp,v in x.items()} for c,x in out['results'].items()}},indent=2))
|
builder/20_prepare_v041_translation_alignment.py
ADDED
|
@@ -0,0 +1,366 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
from __future__ import annotations
|
| 3 |
+
|
| 4 |
+
import hashlib
|
| 5 |
+
import io
|
| 6 |
+
import json
|
| 7 |
+
import os
|
| 8 |
+
import re
|
| 9 |
+
import tarfile
|
| 10 |
+
import urllib.request
|
| 11 |
+
from pathlib import Path
|
| 12 |
+
|
| 13 |
+
import pyarrow.parquet as pq
|
| 14 |
+
import soundfile as sf
|
| 15 |
+
|
| 16 |
+
ROOT = Path("/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork")
|
| 17 |
+
RAW = ROOT / "data/raw/covost2_en_zh"
|
| 18 |
+
INTER = ROOT / "data/intermediate/v041"
|
| 19 |
+
MEDIA = INTER / "media/covost2_en_zh"
|
| 20 |
+
REPORTS = ROOT / "reports"
|
| 21 |
+
SOURCE_PARQUET = RAW / "data/train-00000-of-00017.parquet"
|
| 22 |
+
OFFICIAL_ARCHIVE = RAW / "covost_v2.en_zh-CN.tsv.tar.gz"
|
| 23 |
+
OFFICIAL_TSV = RAW / "official/covost_v2.en_zh-CN.tsv"
|
| 24 |
+
OFFICIAL_URL = (
|
| 25 |
+
"https://dl.fbaipublicfiles.com/covost/"
|
| 26 |
+
"covost_v2.en_zh-CN.tsv.tar.gz"
|
| 27 |
+
)
|
| 28 |
+
SOURCE_REVISION = "f391125f524c317e7cea975cad0d1faebec37314"
|
| 29 |
+
OFFICIAL_HF_REVISION = "369b47c4c20aff1193b8edeeedc37d14ae28226b"
|
| 30 |
+
TRANSLATION_TARGET = 3000
|
| 31 |
+
ALIGNMENT_TARGET = 500
|
| 32 |
+
ALIGNMENT_CANDIDATES = 850
|
| 33 |
+
|
| 34 |
+
|
| 35 |
+
def h(text: str) -> str:
|
| 36 |
+
return hashlib.sha256(text.encode("utf-8")).hexdigest()
|
| 37 |
+
|
| 38 |
+
|
| 39 |
+
def norm(text: str) -> str:
|
| 40 |
+
return re.sub(r"\s+", " ", (text or "").strip())
|
| 41 |
+
|
| 42 |
+
|
| 43 |
+
def download_official_tsv() -> None:
|
| 44 |
+
if OFFICIAL_TSV.exists():
|
| 45 |
+
return
|
| 46 |
+
RAW.mkdir(parents=True, exist_ok=True)
|
| 47 |
+
OFFICIAL_TSV.parent.mkdir(parents=True, exist_ok=True)
|
| 48 |
+
if not OFFICIAL_ARCHIVE.exists():
|
| 49 |
+
partial = OFFICIAL_ARCHIVE.with_suffix(".partial")
|
| 50 |
+
urllib.request.urlretrieve(OFFICIAL_URL, partial)
|
| 51 |
+
partial.replace(OFFICIAL_ARCHIVE)
|
| 52 |
+
with tarfile.open(OFFICIAL_ARCHIVE, "r:gz") as tf:
|
| 53 |
+
member = next(
|
| 54 |
+
m for m in tf.getmembers()
|
| 55 |
+
if m.name.endswith("covost_v2.en_zh-CN.tsv")
|
| 56 |
+
)
|
| 57 |
+
src = tf.extractfile(member)
|
| 58 |
+
assert src is not None
|
| 59 |
+
OFFICIAL_TSV.write_bytes(src.read())
|
| 60 |
+
|
| 61 |
+
|
| 62 |
+
def official_map() -> dict[str, tuple[str, str]]:
|
| 63 |
+
import csv
|
| 64 |
+
|
| 65 |
+
out: dict[str, tuple[str, str]] = {}
|
| 66 |
+
with OFFICIAL_TSV.open(encoding="utf-8") as f:
|
| 67 |
+
for row in csv.DictReader(f, delimiter="\t"):
|
| 68 |
+
if row.get("split") in {"train", "train_covost"}:
|
| 69 |
+
out[Path(row["path"]).name] = (
|
| 70 |
+
norm(row.get("translation", "")),
|
| 71 |
+
row.get("split", ""),
|
| 72 |
+
)
|
| 73 |
+
return out
|
| 74 |
+
|
| 75 |
+
|
| 76 |
+
def audio_bytes(audio: object) -> tuple[bytes, str]:
|
| 77 |
+
if not isinstance(audio, dict):
|
| 78 |
+
raise ValueError("audio is not a struct")
|
| 79 |
+
data = audio.get("bytes")
|
| 80 |
+
path = str(audio.get("path") or "")
|
| 81 |
+
if data is None:
|
| 82 |
+
raise ValueError("audio.bytes is missing")
|
| 83 |
+
return bytes(data), Path(path).name
|
| 84 |
+
|
| 85 |
+
|
| 86 |
+
def duration_of(data: bytes) -> tuple[float, int]:
|
| 87 |
+
info = sf.info(io.BytesIO(data))
|
| 88 |
+
return float(info.duration), int(info.samplerate)
|
| 89 |
+
|
| 90 |
+
|
| 91 |
+
def write_jsonl(path: Path, rows: list[dict]) -> None:
|
| 92 |
+
path.parent.mkdir(parents=True, exist_ok=True)
|
| 93 |
+
with path.open("w", encoding="utf-8") as f:
|
| 94 |
+
for row in rows:
|
| 95 |
+
f.write(json.dumps(row, ensure_ascii=False, sort_keys=True) + "\n")
|
| 96 |
+
|
| 97 |
+
|
| 98 |
+
def words(text: str) -> list[str]:
|
| 99 |
+
return re.findall(r"[a-z0-9']+", text.lower())
|
| 100 |
+
|
| 101 |
+
|
| 102 |
+
def edit_distance(a: list[str], b: list[str]) -> int:
|
| 103 |
+
prev = list(range(len(b) + 1))
|
| 104 |
+
for i, x in enumerate(a, 1):
|
| 105 |
+
cur = [i]
|
| 106 |
+
for j, y in enumerate(b, 1):
|
| 107 |
+
cur.append(min(
|
| 108 |
+
cur[-1] + 1,
|
| 109 |
+
prev[j] + 1,
|
| 110 |
+
prev[j - 1] + (x != y),
|
| 111 |
+
))
|
| 112 |
+
prev = cur
|
| 113 |
+
return prev[-1]
|
| 114 |
+
|
| 115 |
+
|
| 116 |
+
def wer(reference: str, hypothesis: str) -> float:
|
| 117 |
+
r, p = words(reference), words(hypothesis)
|
| 118 |
+
return edit_distance(r, p) / max(1, len(r))
|
| 119 |
+
|
| 120 |
+
|
| 121 |
+
def prepare_translation() -> list[dict]:
|
| 122 |
+
table = pq.read_table(SOURCE_PARQUET)
|
| 123 |
+
official = official_map()
|
| 124 |
+
candidates = []
|
| 125 |
+
rejected = []
|
| 126 |
+
for idx, row in enumerate(table.to_pylist()):
|
| 127 |
+
sentence = norm(row.get("sentence", ""))
|
| 128 |
+
translation = norm(row.get("translation", ""))
|
| 129 |
+
try:
|
| 130 |
+
data, original_name = audio_bytes(row.get("audio"))
|
| 131 |
+
duration, sample_rate = duration_of(data)
|
| 132 |
+
except Exception as exc:
|
| 133 |
+
rejected.append({
|
| 134 |
+
"source_index": idx,
|
| 135 |
+
"reason": "audio_decode_failed",
|
| 136 |
+
"detail": str(exc)[:300],
|
| 137 |
+
})
|
| 138 |
+
continue
|
| 139 |
+
official_entry = official.get(original_name)
|
| 140 |
+
if not sentence or not translation:
|
| 141 |
+
rejected.append({
|
| 142 |
+
"source_index": idx,
|
| 143 |
+
"source_path": original_name,
|
| 144 |
+
"reason": "empty_transcript_or_translation",
|
| 145 |
+
})
|
| 146 |
+
continue
|
| 147 |
+
if official_entry is None:
|
| 148 |
+
rejected.append({
|
| 149 |
+
"source_index": idx,
|
| 150 |
+
"source_path": original_name,
|
| 151 |
+
"reason": "not_in_official_train_tsv",
|
| 152 |
+
})
|
| 153 |
+
continue
|
| 154 |
+
if norm(official_entry[0]) != translation:
|
| 155 |
+
rejected.append({
|
| 156 |
+
"source_index": idx,
|
| 157 |
+
"source_path": original_name,
|
| 158 |
+
"reason": "official_translation_mismatch",
|
| 159 |
+
})
|
| 160 |
+
continue
|
| 161 |
+
if not (0.3 <= duration <= 30.0):
|
| 162 |
+
rejected.append({
|
| 163 |
+
"source_index": idx,
|
| 164 |
+
"source_path": original_name,
|
| 165 |
+
"reason": "duration_out_of_range",
|
| 166 |
+
"duration": duration,
|
| 167 |
+
})
|
| 168 |
+
continue
|
| 169 |
+
candidates.append((
|
| 170 |
+
h(f"42|{original_name}|{sentence}|{translation}"),
|
| 171 |
+
idx,
|
| 172 |
+
row,
|
| 173 |
+
data,
|
| 174 |
+
original_name,
|
| 175 |
+
duration,
|
| 176 |
+
sample_rate,
|
| 177 |
+
official_entry[1],
|
| 178 |
+
))
|
| 179 |
+
candidates.sort(key=lambda x: x[0])
|
| 180 |
+
selected = candidates[:TRANSLATION_TARGET]
|
| 181 |
+
MEDIA.mkdir(parents=True, exist_ok=True)
|
| 182 |
+
manifest = []
|
| 183 |
+
for _, idx, row, data, original_name, duration, sample_rate, official_split in selected:
|
| 184 |
+
ext = Path(original_name).suffix.lower() or ".mp3"
|
| 185 |
+
media_name = f"{h(original_name)[:24]}{ext}"
|
| 186 |
+
media_path = MEDIA / media_name
|
| 187 |
+
if not media_path.exists() or media_path.stat().st_size != len(data):
|
| 188 |
+
media_path.write_bytes(data)
|
| 189 |
+
manifest.append({
|
| 190 |
+
"source_index": idx,
|
| 191 |
+
"source_path": original_name,
|
| 192 |
+
"source_id": Path(original_name).stem,
|
| 193 |
+
"sentence": norm(row["sentence"]),
|
| 194 |
+
"translation": norm(row["translation"]),
|
| 195 |
+
"source_language": "en",
|
| 196 |
+
"target_language": "zh-CN",
|
| 197 |
+
"source_split": official_split,
|
| 198 |
+
"source_dataset": "facebook/covost2",
|
| 199 |
+
"source_revision": OFFICIAL_HF_REVISION,
|
| 200 |
+
"conversion_dataset": "ymoslem/CoVoST2-EN-ZH",
|
| 201 |
+
"conversion_revision": SOURCE_REVISION,
|
| 202 |
+
"source_license": "CC-BY-NC-4.0",
|
| 203 |
+
"media_relative_path": f"media/covost2_en_zh/{media_name}",
|
| 204 |
+
"media_sha256": hashlib.sha256(data).hexdigest(),
|
| 205 |
+
"duration_sec": duration,
|
| 206 |
+
"sample_rate": sample_rate,
|
| 207 |
+
"official_train_tsv_match": True,
|
| 208 |
+
"audio_decode_valid": True,
|
| 209 |
+
})
|
| 210 |
+
write_jsonl(INTER / "translation_manifest.jsonl", manifest)
|
| 211 |
+
write_jsonl(REPORTS / "translation_rejections.jsonl", rejected)
|
| 212 |
+
return manifest
|
| 213 |
+
|
| 214 |
+
|
| 215 |
+
def prepare_alignment(manifest: list[dict]) -> list[dict]:
|
| 216 |
+
from faster_whisper import WhisperModel
|
| 217 |
+
|
| 218 |
+
raw_path = INTER / "alignment_raw_outputs.jsonl"
|
| 219 |
+
accepted_path = INTER / "alignment_manifest.jsonl"
|
| 220 |
+
done: dict[str, dict] = {}
|
| 221 |
+
if raw_path.exists():
|
| 222 |
+
for line in raw_path.read_text(encoding="utf-8").splitlines():
|
| 223 |
+
if line.strip():
|
| 224 |
+
item = json.loads(line)
|
| 225 |
+
done[item["source_id"]] = item
|
| 226 |
+
|
| 227 |
+
os.environ.setdefault("HF_HOME", str(ROOT / ".cache/huggingface"))
|
| 228 |
+
model_path = ROOT / ".cache/whisperx/models--Systran--faster-whisper-small/snapshots/536b0662742c02347bc0e980a01041f333bce120"
|
| 229 |
+
model = WhisperModel(
|
| 230 |
+
str(model_path),
|
| 231 |
+
device="cuda",
|
| 232 |
+
compute_type="float16",
|
| 233 |
+
local_files_only=True,
|
| 234 |
+
)
|
| 235 |
+
candidates = sorted(
|
| 236 |
+
manifest,
|
| 237 |
+
key=lambda x: h("alignment|42|" + x["source_id"]),
|
| 238 |
+
)[:ALIGNMENT_CANDIDATES]
|
| 239 |
+
with raw_path.open("a", encoding="utf-8") as raw:
|
| 240 |
+
for pos, item in enumerate(candidates):
|
| 241 |
+
if item["source_id"] in done:
|
| 242 |
+
continue
|
| 243 |
+
audio_path = INTER / item["media_relative_path"]
|
| 244 |
+
try:
|
| 245 |
+
segments, info = model.transcribe(
|
| 246 |
+
str(audio_path),
|
| 247 |
+
language="en",
|
| 248 |
+
beam_size=1,
|
| 249 |
+
best_of=1,
|
| 250 |
+
temperature=0.0,
|
| 251 |
+
vad_filter=True,
|
| 252 |
+
word_timestamps=True,
|
| 253 |
+
condition_on_previous_text=False,
|
| 254 |
+
)
|
| 255 |
+
segs = list(segments)
|
| 256 |
+
word_items = []
|
| 257 |
+
hypothesis_parts = []
|
| 258 |
+
avg_logprob = []
|
| 259 |
+
for seg in segs:
|
| 260 |
+
hypothesis_parts.append(seg.text.strip())
|
| 261 |
+
avg_logprob.append(float(seg.avg_logprob))
|
| 262 |
+
for word in seg.words or []:
|
| 263 |
+
if word.start is None or word.end is None:
|
| 264 |
+
continue
|
| 265 |
+
word_items.append({
|
| 266 |
+
"word": word.word.strip(),
|
| 267 |
+
"start_sec": float(word.start),
|
| 268 |
+
"end_sec": float(word.end),
|
| 269 |
+
"probability": float(word.probability or 0.0),
|
| 270 |
+
})
|
| 271 |
+
hypothesis = norm(" ".join(hypothesis_parts))
|
| 272 |
+
score = wer(item["sentence"], hypothesis)
|
| 273 |
+
valid_words = bool(word_items) and all(
|
| 274 |
+
0 <= w["start_sec"] <= w["end_sec"] <= item["duration_sec"] + 0.25
|
| 275 |
+
for w in word_items
|
| 276 |
+
)
|
| 277 |
+
result = {
|
| 278 |
+
**item,
|
| 279 |
+
"model_name": "Systran/faster-whisper-small",
|
| 280 |
+
"model_revision": "536b0662742c02347bc0e980a01041f333bce120",
|
| 281 |
+
"dtype": "float16",
|
| 282 |
+
"device": "cuda",
|
| 283 |
+
"inference_args": {
|
| 284 |
+
"language": "en",
|
| 285 |
+
"beam_size": 1,
|
| 286 |
+
"temperature": 0.0,
|
| 287 |
+
"vad_filter": True,
|
| 288 |
+
"word_timestamps": True,
|
| 289 |
+
"condition_on_previous_text": False,
|
| 290 |
+
},
|
| 291 |
+
"asr_hypothesis": hypothesis,
|
| 292 |
+
"wer": score,
|
| 293 |
+
"language_probability": float(info.language_probability),
|
| 294 |
+
"mean_segment_logprob": (
|
| 295 |
+
sum(avg_logprob) / len(avg_logprob)
|
| 296 |
+
if avg_logprob else -99.0
|
| 297 |
+
),
|
| 298 |
+
"alignment_words": word_items,
|
| 299 |
+
"accepted": (
|
| 300 |
+
score <= 0.30
|
| 301 |
+
and valid_words
|
| 302 |
+
and len(word_items) >= max(2, int(len(words(item["sentence"])) * 0.65))
|
| 303 |
+
),
|
| 304 |
+
"rejection_reason": "" if (
|
| 305 |
+
score <= 0.30
|
| 306 |
+
and valid_words
|
| 307 |
+
and len(word_items) >= max(2, int(len(words(item["sentence"])) * 0.65))
|
| 308 |
+
) else "asr_alignment_quality_gate",
|
| 309 |
+
}
|
| 310 |
+
except Exception as exc:
|
| 311 |
+
result = {
|
| 312 |
+
**item,
|
| 313 |
+
"model_name": "Systran/faster-whisper-small",
|
| 314 |
+
"model_revision": "536b0662742c02347bc0e980a01041f333bce120",
|
| 315 |
+
"dtype": "float16",
|
| 316 |
+
"device": "cuda",
|
| 317 |
+
"alignment_words": [],
|
| 318 |
+
"accepted": False,
|
| 319 |
+
"rejection_reason": "alignment_runtime_error",
|
| 320 |
+
"error": str(exc)[:500],
|
| 321 |
+
}
|
| 322 |
+
raw.write(json.dumps(result, ensure_ascii=False, sort_keys=True) + "\n")
|
| 323 |
+
raw.flush()
|
| 324 |
+
done[item["source_id"]] = result
|
| 325 |
+
accepted_count = sum(1 for x in done.values() if x.get("accepted"))
|
| 326 |
+
if (pos + 1) % 25 == 0:
|
| 327 |
+
print(json.dumps({
|
| 328 |
+
"processed": len(done),
|
| 329 |
+
"accepted": accepted_count,
|
| 330 |
+
"target": ALIGNMENT_TARGET,
|
| 331 |
+
}))
|
| 332 |
+
if accepted_count >= ALIGNMENT_TARGET:
|
| 333 |
+
break
|
| 334 |
+
accepted = sorted(
|
| 335 |
+
(x for x in done.values() if x.get("accepted")),
|
| 336 |
+
key=lambda x: h("accepted|" + x["source_id"]),
|
| 337 |
+
)[:ALIGNMENT_TARGET]
|
| 338 |
+
write_jsonl(accepted_path, accepted)
|
| 339 |
+
return accepted
|
| 340 |
+
|
| 341 |
+
|
| 342 |
+
def main() -> None:
|
| 343 |
+
INTER.mkdir(parents=True, exist_ok=True)
|
| 344 |
+
REPORTS.mkdir(parents=True, exist_ok=True)
|
| 345 |
+
download_official_tsv()
|
| 346 |
+
translations = prepare_translation()
|
| 347 |
+
alignments = prepare_alignment(translations)
|
| 348 |
+
stats = {
|
| 349 |
+
"translation_rows": len(translations),
|
| 350 |
+
"alignment_rows": len(alignments),
|
| 351 |
+
"translation_target": TRANSLATION_TARGET,
|
| 352 |
+
"alignment_target": ALIGNMENT_TARGET,
|
| 353 |
+
"source_parquet": "data/raw/covost2_en_zh/data/train-00000-of-00017.parquet",
|
| 354 |
+
"official_tsv": "data/raw/covost2_en_zh/official/covost_v2.en_zh-CN.tsv",
|
| 355 |
+
"official_hf_revision": OFFICIAL_HF_REVISION,
|
| 356 |
+
"conversion_revision": SOURCE_REVISION,
|
| 357 |
+
}
|
| 358 |
+
(INTER / "preparation_stats.json").write_text(
|
| 359 |
+
json.dumps(stats, indent=2, ensure_ascii=False) + "\n",
|
| 360 |
+
encoding="utf-8",
|
| 361 |
+
)
|
| 362 |
+
print(json.dumps(stats, indent=2, ensure_ascii=False))
|
| 363 |
+
|
| 364 |
+
|
| 365 |
+
if __name__ == "__main__":
|
| 366 |
+
main()
|
builder/24_build_v041_quality.py
ADDED
|
@@ -0,0 +1,1320 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
from __future__ import annotations
|
| 3 |
+
|
| 4 |
+
import hashlib
|
| 5 |
+
import json
|
| 6 |
+
import re
|
| 7 |
+
import shutil
|
| 8 |
+
from collections import Counter, defaultdict
|
| 9 |
+
from pathlib import Path
|
| 10 |
+
|
| 11 |
+
import pyarrow as pa
|
| 12 |
+
import pyarrow.parquet as pq
|
| 13 |
+
|
| 14 |
+
ROOT = Path("/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork")
|
| 15 |
+
V04 = ROOT / "data/release/unified_v0_4"
|
| 16 |
+
INTER = ROOT / "data/intermediate/v041"
|
| 17 |
+
REL = ROOT / "data/release/unified_v0_4_1_quality"
|
| 18 |
+
REP = ROOT / "reports"
|
| 19 |
+
SCHEMA_DIR = ROOT / "schema"
|
| 20 |
+
REGISTRY_DIR = ROOT / "registry"
|
| 21 |
+
RECIPES_DIR = ROOT / "training_recipes"
|
| 22 |
+
OLD_V03 = ROOT / "outputs/hf_public_v0_3/data"
|
| 23 |
+
V04_SHA = "cf95b027d75ec793556e395aef9af8118a08b3d8"
|
| 24 |
+
V04_DATA_SHA = "8cec4ac12e423e1c9a8843fe9dbd13a67c51ddc2"
|
| 25 |
+
OLD_SHA = "7e6e0ee060cf8416cd1fba8f876c2a05499442e6"
|
| 26 |
+
OFFICIAL_COVOST_REV = "369b47c4c20aff1193b8edeeedc37d14ae28226b"
|
| 27 |
+
CONVERSION_REV = "f391125f524c317e7cea975cad0d1faebec37314"
|
| 28 |
+
SEED = 42
|
| 29 |
+
|
| 30 |
+
CAPABILITIES = [
|
| 31 |
+
"av_joint_reasoning",
|
| 32 |
+
"live_av_commentary",
|
| 33 |
+
"ocr_screen_grounding",
|
| 34 |
+
"proactive_av_interaction",
|
| 35 |
+
"speech_output_alignment",
|
| 36 |
+
"streaming_asr_translation",
|
| 37 |
+
"streaming_audio_interaction",
|
| 38 |
+
]
|
| 39 |
+
DENYLIST = [
|
| 40 |
+
"LiveSports-3K", "Daily-Omni", "WorldSense", "JointAVBench",
|
| 41 |
+
"AVUT-Human", "Video-MME eval", "OmniPro",
|
| 42 |
+
"Proactive-Sound-Bench", "OCRBench", "TextVQA eval",
|
| 43 |
+
"DocVQA eval", "HallusionBench", "VoiceBench", "MMAU",
|
| 44 |
+
"LibriSpeech dev/test", "CoVoST2 dev/test",
|
| 45 |
+
"SeedTTS evaluation data",
|
| 46 |
+
]
|
| 47 |
+
|
| 48 |
+
TURN = pa.struct([
|
| 49 |
+
("turn_id", pa.string()), ("role", pa.string()), ("text", pa.string()),
|
| 50 |
+
("start_sec", pa.float64()), ("end_sec", pa.float64()),
|
| 51 |
+
("media_refs", pa.list_(pa.string())), ("tool_state", pa.string()),
|
| 52 |
+
])
|
| 53 |
+
TIMELINE = pa.struct([
|
| 54 |
+
("chunk_id", pa.string()), ("start_sec", pa.float64()),
|
| 55 |
+
("end_sec", pa.float64()), ("speaker", pa.string()),
|
| 56 |
+
("asr_delta", pa.string()), ("ocr_delta", pa.list_(pa.string())),
|
| 57 |
+
("audio_events", pa.list_(pa.string())),
|
| 58 |
+
("visual_events", pa.list_(pa.string())),
|
| 59 |
+
("frame_refs", pa.list_(pa.string())),
|
| 60 |
+
("available_context", pa.string()), ("target_delta", pa.string()),
|
| 61 |
+
])
|
| 62 |
+
MEDIA = pa.struct([
|
| 63 |
+
("audio_ref", pa.string()), ("video_ref", pa.string()),
|
| 64 |
+
("image_ref", pa.string()), ("screen_ref", pa.string()),
|
| 65 |
+
("duration_sec", pa.float64()), ("sample_rate", pa.int32()),
|
| 66 |
+
])
|
| 67 |
+
TARGET = pa.struct([
|
| 68 |
+
("transcript", pa.string()), ("translation", pa.string()),
|
| 69 |
+
("answer", pa.string()), ("summary", pa.string()),
|
| 70 |
+
("commentary", pa.string()), ("speech_output", pa.string()),
|
| 71 |
+
("control_label", pa.string()), ("tool_call_json", pa.string()),
|
| 72 |
+
("tool_result_json", pa.string()), ("final_response", pa.string()),
|
| 73 |
+
])
|
| 74 |
+
QUALITY = pa.struct([
|
| 75 |
+
("grade", pa.string()), ("score", pa.float64()),
|
| 76 |
+
("timestamp_valid", pa.bool_()), ("causal_valid", pa.bool_()),
|
| 77 |
+
("media_valid", pa.bool_()), ("annotation_status", pa.string()),
|
| 78 |
+
("annotation_model", pa.string()), ("annotation_version", pa.string()),
|
| 79 |
+
("automated_checks", pa.list_(pa.string())),
|
| 80 |
+
("human_reviewed", pa.bool_()),
|
| 81 |
+
("rejection_reasons", pa.list_(pa.string())),
|
| 82 |
+
])
|
| 83 |
+
ALIGNMENT_WORD = pa.struct([
|
| 84 |
+
("word", pa.string()), ("start_sec", pa.float64()),
|
| 85 |
+
("end_sec", pa.float64()), ("probability", pa.float64()),
|
| 86 |
+
])
|
| 87 |
+
SCHEMA = pa.schema([
|
| 88 |
+
("id", pa.string()), ("schema_version", pa.string()),
|
| 89 |
+
("interaction_regime", pa.string()), ("task_type", pa.string()),
|
| 90 |
+
("capabilities", pa.list_(pa.string())), ("domain", pa.string()),
|
| 91 |
+
("input_modalities", pa.list_(pa.string())),
|
| 92 |
+
("output_modalities", pa.list_(pa.string())),
|
| 93 |
+
("source_language", pa.string()), ("target_language", pa.string()),
|
| 94 |
+
("streaming_type", pa.string()), ("causal_validity", pa.string()),
|
| 95 |
+
("source_dataset", pa.string()), ("source_config", pa.string()),
|
| 96 |
+
("source_split", pa.string()), ("source_id", pa.string()),
|
| 97 |
+
("source_url", pa.string()), ("source_license", pa.string()),
|
| 98 |
+
("data_origin", pa.string()), ("transformation_pipeline", pa.string()),
|
| 99 |
+
("pipeline_version", pa.string()), ("instruction", pa.string()),
|
| 100 |
+
("context_text", pa.string()), ("turns", pa.list_(TURN)),
|
| 101 |
+
("timeline", pa.list_(TIMELINE)), ("media", MEDIA),
|
| 102 |
+
("targets", TARGET), ("tool_schema_json", pa.string()),
|
| 103 |
+
("quality", QUALITY), ("group_id", pa.string()), ("split", pa.string()),
|
| 104 |
+
("publication_notes", pa.string()),
|
| 105 |
+
("source_revision", pa.string()),
|
| 106 |
+
("media_checksum", pa.string()),
|
| 107 |
+
("context_dependency", pa.string()),
|
| 108 |
+
("translation_subtype", pa.string()),
|
| 109 |
+
("automated_quality_score", pa.float64()),
|
| 110 |
+
("recommended_training_weight", pa.float64()),
|
| 111 |
+
("quality_reasons", pa.list_(pa.string())),
|
| 112 |
+
("review_status", pa.string()),
|
| 113 |
+
("alignment_method", pa.string()),
|
| 114 |
+
("alignment_confidence", pa.float64()),
|
| 115 |
+
("speech_output_duration", pa.float64()),
|
| 116 |
+
("alignment_words", pa.list_(ALIGNMENT_WORD)),
|
| 117 |
+
("tool_error_type", pa.string()),
|
| 118 |
+
("tool_validation_status", pa.string()),
|
| 119 |
+
("annotation_details_json", pa.string()),
|
| 120 |
+
])
|
| 121 |
+
|
| 122 |
+
|
| 123 |
+
def h(text: str, n: int = 24) -> str:
|
| 124 |
+
return hashlib.sha256(str(text).encode("utf-8")).hexdigest()[:n]
|
| 125 |
+
|
| 126 |
+
|
| 127 |
+
def js(value: object) -> str:
|
| 128 |
+
return json.dumps(value, ensure_ascii=False, sort_keys=True, separators=(",", ":"))
|
| 129 |
+
|
| 130 |
+
|
| 131 |
+
def norm(text: str) -> str:
|
| 132 |
+
return re.sub(r"\s+", " ", re.sub(r"[^\w\s]", " ", text.lower())).strip()
|
| 133 |
+
|
| 134 |
+
|
| 135 |
+
def load_jsonl(path: Path) -> list[dict]:
|
| 136 |
+
if not path.exists():
|
| 137 |
+
return []
|
| 138 |
+
return [
|
| 139 |
+
json.loads(line)
|
| 140 |
+
for line in path.read_text(encoding="utf-8").splitlines()
|
| 141 |
+
if line.strip()
|
| 142 |
+
]
|
| 143 |
+
|
| 144 |
+
|
| 145 |
+
def write_jsonl(path: Path, rows: list[dict]) -> None:
|
| 146 |
+
path.parent.mkdir(parents=True, exist_ok=True)
|
| 147 |
+
with path.open("w", encoding="utf-8") as f:
|
| 148 |
+
for row in rows:
|
| 149 |
+
f.write(json.dumps(row, ensure_ascii=False, sort_keys=True) + "\n")
|
| 150 |
+
|
| 151 |
+
|
| 152 |
+
def load_parquets(paths: list[Path]) -> list[dict]:
|
| 153 |
+
rows = []
|
| 154 |
+
for path in paths:
|
| 155 |
+
rows.extend(pq.read_table(path).to_pylist())
|
| 156 |
+
return rows
|
| 157 |
+
|
| 158 |
+
|
| 159 |
+
def split_for(group_id: str) -> str:
|
| 160 |
+
return "eval" if int(h(f"{SEED}|{group_id}", 8), 16) % 20 == 0 else "train"
|
| 161 |
+
|
| 162 |
+
|
| 163 |
+
def empty_record() -> dict:
|
| 164 |
+
return {
|
| 165 |
+
"id": "", "schema_version": "streaming_omni_schema_1.1",
|
| 166 |
+
"interaction_regime": "single_turn", "task_type": "qa",
|
| 167 |
+
"capabilities": [], "domain": "general",
|
| 168 |
+
"input_modalities": ["text"], "output_modalities": ["text"],
|
| 169 |
+
"source_language": "", "target_language": "",
|
| 170 |
+
"streaming_type": "offline", "causal_validity": "valid",
|
| 171 |
+
"source_dataset": "", "source_config": "", "source_split": "train",
|
| 172 |
+
"source_id": "", "source_url": "", "source_license": "",
|
| 173 |
+
"data_origin": "transformed",
|
| 174 |
+
"transformation_pipeline": "24_build_v041_quality",
|
| 175 |
+
"pipeline_version": "0.4.1-quality", "instruction": "",
|
| 176 |
+
"context_text": "", "turns": [], "timeline": [],
|
| 177 |
+
"media": {
|
| 178 |
+
"audio_ref": "", "video_ref": "", "image_ref": "",
|
| 179 |
+
"screen_ref": "", "duration_sec": 0.0, "sample_rate": 0,
|
| 180 |
+
},
|
| 181 |
+
"targets": {
|
| 182 |
+
"transcript": "", "translation": "", "answer": "",
|
| 183 |
+
"summary": "", "commentary": "", "speech_output": "",
|
| 184 |
+
"control_label": "", "tool_call_json": "",
|
| 185 |
+
"tool_result_json": "", "final_response": "",
|
| 186 |
+
},
|
| 187 |
+
"tool_schema_json": "",
|
| 188 |
+
"quality": {
|
| 189 |
+
"grade": "C", "score": 0.6, "timestamp_valid": False,
|
| 190 |
+
"causal_valid": True, "media_valid": True,
|
| 191 |
+
"annotation_status": "automated_review",
|
| 192 |
+
"annotation_model": "", "annotation_version": "",
|
| 193 |
+
"automated_checks": [], "human_reviewed": False,
|
| 194 |
+
"rejection_reasons": [],
|
| 195 |
+
},
|
| 196 |
+
"group_id": "", "split": "train", "publication_notes": "",
|
| 197 |
+
"source_revision": "", "media_checksum": "",
|
| 198 |
+
"context_dependency": "", "translation_subtype": "",
|
| 199 |
+
"automated_quality_score": 0.6,
|
| 200 |
+
"recommended_training_weight": 0.3,
|
| 201 |
+
"quality_reasons": [], "review_status": "automated_review",
|
| 202 |
+
"alignment_method": "", "alignment_confidence": 0.0,
|
| 203 |
+
"speech_output_duration": 0.0, "alignment_words": [],
|
| 204 |
+
"tool_error_type": "", "tool_validation_status": "",
|
| 205 |
+
"annotation_details_json": "",
|
| 206 |
+
}
|
| 207 |
+
|
| 208 |
+
|
| 209 |
+
def merge_record(**values: object) -> dict:
|
| 210 |
+
row = empty_record()
|
| 211 |
+
quality = values.pop("quality", {})
|
| 212 |
+
media = values.pop("media", {})
|
| 213 |
+
targets = values.pop("targets", {})
|
| 214 |
+
row.update(values)
|
| 215 |
+
row["quality"].update(quality)
|
| 216 |
+
row["media"].update(media)
|
| 217 |
+
row["targets"].update(targets)
|
| 218 |
+
return row
|
| 219 |
+
|
| 220 |
+
|
| 221 |
+
def base_weight(row: dict) -> tuple[float, list[str], str]:
|
| 222 |
+
grade = row["quality"]["grade"]
|
| 223 |
+
origin = row["data_origin"].lower()
|
| 224 |
+
stream = row["streaming_type"]
|
| 225 |
+
reasons = ["v0.4_grade_preserved", "automated_checks_only"]
|
| 226 |
+
if grade == "B" and "real" in origin:
|
| 227 |
+
return 1.0, reasons + ["real_media", "provenance_complete"], "automated_validated"
|
| 228 |
+
if grade == "B":
|
| 229 |
+
return 0.8, reasons + ["model_annotated_validated"], "automated_validated"
|
| 230 |
+
if row["source_dataset"] == "project_deterministic_tool_suite":
|
| 231 |
+
return 0.25, reasons + ["deterministic_synthetic_warmup"], "synthetic_validated"
|
| 232 |
+
if stream == "simulated":
|
| 233 |
+
return 0.4, reasons + ["simulated_streaming"], "automated_validated"
|
| 234 |
+
if stream == "reconstructed":
|
| 235 |
+
return 0.6, reasons + ["reconstructed_streaming"], "automated_validated"
|
| 236 |
+
if stream == "offline":
|
| 237 |
+
return 0.2, reasons + ["offline_warmup"], "automated_validated"
|
| 238 |
+
return 0.4, reasons, "automated_validated"
|
| 239 |
+
|
| 240 |
+
|
| 241 |
+
def normalize_base(row: dict) -> dict:
|
| 242 |
+
out = empty_record()
|
| 243 |
+
for key in out:
|
| 244 |
+
if key in row and key not in {"media", "targets", "quality"}:
|
| 245 |
+
out[key] = row[key]
|
| 246 |
+
out["media"].update(row.get("media") or {})
|
| 247 |
+
out["targets"].update(row.get("targets") or {})
|
| 248 |
+
out["quality"].update(row.get("quality") or {})
|
| 249 |
+
out["schema_version"] = "streaming_omni_schema_1.1"
|
| 250 |
+
out["pipeline_version"] = "0.4.1-quality"
|
| 251 |
+
out["source_revision"] = V04_SHA
|
| 252 |
+
out["automated_quality_score"] = float(out["quality"]["score"])
|
| 253 |
+
weight, reasons, status = base_weight(out)
|
| 254 |
+
out["recommended_training_weight"] = weight
|
| 255 |
+
out["quality_reasons"] = reasons
|
| 256 |
+
out["review_status"] = status
|
| 257 |
+
out["quality"]["human_reviewed"] = False
|
| 258 |
+
if out["task_type"] == "translation":
|
| 259 |
+
out["translation_subtype"] = "final_translation"
|
| 260 |
+
if out["interaction_regime"] == "single_tool_calling":
|
| 261 |
+
out["tool_validation_status"] = "validated_v0.4"
|
| 262 |
+
return out
|
| 263 |
+
|
| 264 |
+
|
| 265 |
+
def classify_context(row: dict) -> tuple[str, bool, list[str]]:
|
| 266 |
+
turns = row.get("turns") or []
|
| 267 |
+
all_text = " ".join(x.get("text", "") for x in turns).lower()
|
| 268 |
+
last_user = next(
|
| 269 |
+
(x.get("text", "").lower() for x in reversed(turns) if x.get("role") == "user"),
|
| 270 |
+
"",
|
| 271 |
+
)
|
| 272 |
+
target = (
|
| 273 |
+
row["targets"].get("answer")
|
| 274 |
+
or row["targets"].get("final_response")
|
| 275 |
+
or ""
|
| 276 |
+
).lower()
|
| 277 |
+
evidence = []
|
| 278 |
+
if re.search(r"\b(actually|instead|rather than|change|correct|no,|same)\b", all_text):
|
| 279 |
+
evidence.append("correction_marker")
|
| 280 |
+
return "correction", True, evidence
|
| 281 |
+
if re.search(r"\b(what about|how about|also|too|then|again|the same|that one|those|it|them)\b", last_user):
|
| 282 |
+
evidence.append("cross_turn_reference_marker")
|
| 283 |
+
return "previous_turn_reference", True, evidence
|
| 284 |
+
if any(x in target for x in [
|
| 285 |
+
"details you gave", "matching", "book that", "confirm the reservation",
|
| 286 |
+
"share the", "provide the",
|
| 287 |
+
]) and len(turns) >= 4:
|
| 288 |
+
evidence.append("slot_state_carried_across_turns")
|
| 289 |
+
return "conversational_state", True, evidence
|
| 290 |
+
assistant_questions = [
|
| 291 |
+
x for x in turns[:-1]
|
| 292 |
+
if x.get("role") == "assistant" and "?" in x.get("text", "")
|
| 293 |
+
]
|
| 294 |
+
if assistant_questions and turns and turns[-1].get("role") == "user":
|
| 295 |
+
evidence.append("answer_to_prior_clarification")
|
| 296 |
+
return "clarification", True, evidence
|
| 297 |
+
if len(turns) >= 6 and "human:" not in all_text:
|
| 298 |
+
evidence.append("multi_slot_dialogue_state")
|
| 299 |
+
return "conversational_state", True, evidence
|
| 300 |
+
if len(turns) >= 4:
|
| 301 |
+
evidence.append("conversational_followup_without_explicit_marker")
|
| 302 |
+
return "weak_dependency", False, evidence
|
| 303 |
+
evidence.append("independent_answerability_not_ruled_out")
|
| 304 |
+
return "independent_question", False, evidence
|
| 305 |
+
|
| 306 |
+
|
| 307 |
+
def timeline_from_words(words: list[dict], transcript: str, duration: float) -> list[dict]:
|
| 308 |
+
timeline = []
|
| 309 |
+
context = []
|
| 310 |
+
if words:
|
| 311 |
+
for i in range(0, len(words), 5):
|
| 312 |
+
block = words[i:i + 5]
|
| 313 |
+
delta = " ".join(x["word"] for x in block).strip()
|
| 314 |
+
context.append(delta)
|
| 315 |
+
timeline.append({
|
| 316 |
+
"chunk_id": f"word_block_{i // 5:04d}",
|
| 317 |
+
"start_sec": float(block[0]["start_sec"]),
|
| 318 |
+
"end_sec": min(float(block[-1]["end_sec"]), duration),
|
| 319 |
+
"speaker": "source", "asr_delta": delta, "ocr_delta": [],
|
| 320 |
+
"audio_events": ["speech"], "visual_events": [],
|
| 321 |
+
"frame_refs": [], "available_context": " ".join(context),
|
| 322 |
+
"target_delta": "",
|
| 323 |
+
})
|
| 324 |
+
return timeline
|
| 325 |
+
tokens = transcript.split()
|
| 326 |
+
for i in range(0, len(tokens), 5):
|
| 327 |
+
block = tokens[i:i + 5]
|
| 328 |
+
start = duration * i / max(1, len(tokens))
|
| 329 |
+
end = duration * min(len(tokens), i + 5) / max(1, len(tokens))
|
| 330 |
+
context.extend(block)
|
| 331 |
+
timeline.append({
|
| 332 |
+
"chunk_id": f"reconstructed_{i // 5:04d}",
|
| 333 |
+
"start_sec": start, "end_sec": end, "speaker": "source",
|
| 334 |
+
"asr_delta": " ".join(block), "ocr_delta": [],
|
| 335 |
+
"audio_events": ["speech"], "visual_events": [],
|
| 336 |
+
"frame_refs": [], "available_context": " ".join(context),
|
| 337 |
+
"target_delta": "",
|
| 338 |
+
})
|
| 339 |
+
return timeline
|
| 340 |
+
|
| 341 |
+
|
| 342 |
+
TOOL_DEFS = {
|
| 343 |
+
"calculator": ({"expression": "string"}, ["expression"]),
|
| 344 |
+
"search": ({"query": "string"}, ["query"]),
|
| 345 |
+
"weather": ({"location": "string", "date": "string"}, ["location"]),
|
| 346 |
+
"calendar": ({"date": "string"}, ["date"]),
|
| 347 |
+
"retrieval": ({"document_id": "string", "query": "string"}, ["document_id", "query"]),
|
| 348 |
+
"translation": ({"text": "string", "target_language": "string"}, ["text", "target_language"]),
|
| 349 |
+
"transcript_search": ({"query": "string"}, ["query"]),
|
| 350 |
+
"screen_text_retrieval": ({"region": "string"}, ["region"]),
|
| 351 |
+
"media_control": ({"action": "string"}, ["action"]),
|
| 352 |
+
"reminder": ({"message": "string", "minutes": "integer"}, ["message", "minutes"]),
|
| 353 |
+
"timer": ({"seconds": "integer"}, ["seconds"]),
|
| 354 |
+
}
|
| 355 |
+
|
| 356 |
+
|
| 357 |
+
def tool_schema(name: str) -> dict:
|
| 358 |
+
props, required = TOOL_DEFS[name]
|
| 359 |
+
return {
|
| 360 |
+
"name": name,
|
| 361 |
+
"parameters": {
|
| 362 |
+
"type": "object",
|
| 363 |
+
"properties": {key: {"type": value} for key, value in props.items()},
|
| 364 |
+
"required": required,
|
| 365 |
+
"additionalProperties": False,
|
| 366 |
+
},
|
| 367 |
+
}
|
| 368 |
+
|
| 369 |
+
|
| 370 |
+
def tool_args(name: str, i: int) -> tuple[dict, str]:
|
| 371 |
+
if name == "calculator":
|
| 372 |
+
return {"expression": f"{i % 97}+{(i * 3) % 41}"}, str(i % 97 + (i * 3) % 41)
|
| 373 |
+
if name == "search":
|
| 374 |
+
return {"query": f"rail maintenance notice {2026 + i % 2}"}, f"Notice {i}: scheduled maintenance Saturday"
|
| 375 |
+
if name == "weather":
|
| 376 |
+
return {"location": ["Suzhou", "Berlin", "Quito", "Osaka"][i % 4], "date": f"2026-08-{i % 28 + 1:02d}"}, f"{[18, 22, 27, 31][i % 4]}°C, light rain"
|
| 377 |
+
if name == "calendar":
|
| 378 |
+
return {"date": f"2026-09-{i % 28 + 1:02d}"}, f"{i % 3} matching events"
|
| 379 |
+
if name == "retrieval":
|
| 380 |
+
return {"document_id": f"policy-{i % 37:02d}", "query": "cancellation window"}, f"Cancellation is allowed within {24 + i % 48} hours"
|
| 381 |
+
if name == "translation":
|
| 382 |
+
return {"text": ["good morning", "the file is ready", "会议延期了"][i % 3], "target_language": ["fr", "de", "en"][i % 3]}, ["bonjour", "die Datei ist bereit", "the meeting was postponed"][i % 3]
|
| 383 |
+
if name == "transcript_search":
|
| 384 |
+
return {"query": f"budget section {i % 9}"}, f"Found at 00:{i % 50 + 10:02d}:12"
|
| 385 |
+
if name == "screen_text_retrieval":
|
| 386 |
+
return {"region": ["top-right", "dialog-title", "status-bar"][i % 3]}, ["Battery 83%", "Export complete", "Offline mode"][i % 3]
|
| 387 |
+
if name == "media_control":
|
| 388 |
+
return {"action": ["pause", "resume", "mute"][i % 3]}, ["paused", "resumed", "muted"][i % 3]
|
| 389 |
+
if name == "reminder":
|
| 390 |
+
return {"message": f"submit report {i}", "minutes": 15 + i % 90}, f"Reminder scheduled in {15 + i % 90} minutes"
|
| 391 |
+
return {"seconds": 30 + i % 600}, f"Timer set for {30 + i % 600} seconds"
|
| 392 |
+
|
| 393 |
+
|
| 394 |
+
def tool_prompt(name: str, mode: str, i: int) -> str:
|
| 395 |
+
prompts = {
|
| 396 |
+
"success": [
|
| 397 |
+
"Please use {tool} for case {i}; I need the verified result, not a guess.",
|
| 398 |
+
"Can you check this with {tool}? Reference number {i}.",
|
| 399 |
+
"Necesito comprobar el caso {i} con {tool}; dime el resultado.",
|
| 400 |
+
"请用 {tool} 核实编号 {i},只根据工具结果回答。",
|
| 401 |
+
"Für Fall {i}: nutze bitte {tool} und berichte das Ergebnis.",
|
| 402 |
+
],
|
| 403 |
+
"no_tool": [
|
| 404 |
+
"Explain when someone might use {tool}; do not run it. Example {i}.",
|
| 405 |
+
"Write a two-line fictional dialogue mentioning {tool}, with no lookup.",
|
| 406 |
+
"Is {tool} generally useful? I only want an explanation.",
|
| 407 |
+
"请解释 {tool} 的用途,不要实际调用。示例 {i}。",
|
| 408 |
+
"Compare the idea of {tool} with manual work; no live action.",
|
| 409 |
+
],
|
| 410 |
+
"ambiguity": [
|
| 411 |
+
"Use {tool} for it, but I have not supplied the required detail. Case {i}.",
|
| 412 |
+
"Can you run {tool}? The location/date/value is still undecided.",
|
| 413 |
+
"Here is a malformed candidate {{name:{tool}, args:???}}; ask me to clarify.",
|
| 414 |
+
"请用 {tool},但我还没告诉你必要参数。编号 {i}。",
|
| 415 |
+
"Do the {tool} thing for case {i}; there are two equally plausible inputs.",
|
| 416 |
+
],
|
| 417 |
+
"failure": [
|
| 418 |
+
"Try {tool} once for case {i}; if it fails, explain the error without retrying.",
|
| 419 |
+
"Run one {tool} call for request {i} and handle a permission or timeout error.",
|
| 420 |
+
"请只调用一次 {tool} 处理编号 {i},失败后不要重试。",
|
| 421 |
+
"Use {tool} once; report the service failure plainly. Ticket {i}.",
|
| 422 |
+
"Ein einzelner {tool}-Aufruf für Fall {i}; bei Fehler nicht wiederholen.",
|
| 423 |
+
],
|
| 424 |
+
"partial": [
|
| 425 |
+
"Use {tool} once for case {i}; distinguish a partial result from a complete one.",
|
| 426 |
+
"Check request {i} with {tool}, and state what the tool did not return.",
|
| 427 |
+
],
|
| 428 |
+
"conflict": [
|
| 429 |
+
"Use {tool} for case {i}; trust the returned value if it contradicts my assumption.",
|
| 430 |
+
"I think the answer is fixed, but verify once with {tool} for request {i}.",
|
| 431 |
+
],
|
| 432 |
+
}
|
| 433 |
+
return prompts[mode][i % len(prompts[mode])].format(tool=name, i=i)
|
| 434 |
+
|
| 435 |
+
|
| 436 |
+
def build_tool_rows() -> list[dict]:
|
| 437 |
+
names = list(TOOL_DEFS)
|
| 438 |
+
rows = []
|
| 439 |
+
for i in range(2000):
|
| 440 |
+
name = names[(i * 7 + i // 13) % len(names)]
|
| 441 |
+
slot = i % 20
|
| 442 |
+
mode = (
|
| 443 |
+
"no_tool" if slot < 5 else
|
| 444 |
+
"success" if slot < 12 else
|
| 445 |
+
"failure" if slot < 15 else
|
| 446 |
+
"ambiguity" if slot < 18 else
|
| 447 |
+
"partial" if slot == 18 else "conflict"
|
| 448 |
+
)
|
| 449 |
+
prompt = tool_prompt(name, mode, i)
|
| 450 |
+
schema = tool_schema(name)
|
| 451 |
+
call = ""
|
| 452 |
+
result = ""
|
| 453 |
+
error_type = ""
|
| 454 |
+
validation = "validated_no_tool"
|
| 455 |
+
if mode == "no_tool":
|
| 456 |
+
final = f"No tool call is needed: this request asks for an explanation about {name}, not a live operation."
|
| 457 |
+
control = "no_tool_hard_negative"
|
| 458 |
+
elif mode == "ambiguity":
|
| 459 |
+
final = f"I need the required {name} input clarified before I can make a valid call."
|
| 460 |
+
control = "clarification_before_tool"
|
| 461 |
+
error_type = "missing_or_ambiguous_arguments"
|
| 462 |
+
if i % 5 == 2:
|
| 463 |
+
error_type = "invalid_json_candidate"
|
| 464 |
+
validation = "validated_clarification_no_call"
|
| 465 |
+
else:
|
| 466 |
+
args, value = tool_args(name, i)
|
| 467 |
+
call = js({"name": name, "arguments": args})
|
| 468 |
+
if mode == "failure":
|
| 469 |
+
error_type = ["timeout", "permission_denied", "temporary_unavailable"][i % 3]
|
| 470 |
+
result = js({"ok": False, "error": error_type})
|
| 471 |
+
final = f"The single {name} call failed with {error_type}; no result was available and I did not retry."
|
| 472 |
+
control = "tool_failure_recovery"
|
| 473 |
+
validation = "validated_failure_grounding"
|
| 474 |
+
elif mode == "partial":
|
| 475 |
+
result = js({"ok": True, "partial": True, "value": value, "missing": "secondary detail"})
|
| 476 |
+
final = f"The {name} result was partial: {value}. The secondary detail was not returned."
|
| 477 |
+
control = "partial_result_grounded"
|
| 478 |
+
error_type = "partial_result"
|
| 479 |
+
validation = "validated_partial_grounding"
|
| 480 |
+
elif mode == "conflict":
|
| 481 |
+
result = js({"ok": True, "value": value, "conflicts_with_user_assumption": True})
|
| 482 |
+
final = f"The verified {name} result is {value}, which conflicts with the assumption in the request."
|
| 483 |
+
control = "conflict_result_grounded"
|
| 484 |
+
error_type = "result_conflict"
|
| 485 |
+
validation = "validated_conflict_grounding"
|
| 486 |
+
else:
|
| 487 |
+
result = js({"ok": True, "value": value})
|
| 488 |
+
final = f"The verified {name} result is {value}."
|
| 489 |
+
control = "success_result_grounded"
|
| 490 |
+
validation = "validated_success_grounding"
|
| 491 |
+
turns = [{
|
| 492 |
+
"turn_id": "0", "role": "user", "text": prompt,
|
| 493 |
+
"start_sec": 0.0, "end_sec": 0.0, "media_refs": [],
|
| 494 |
+
"tool_state": "none",
|
| 495 |
+
}]
|
| 496 |
+
if call:
|
| 497 |
+
turns.extend([
|
| 498 |
+
{"turn_id": "1", "role": "assistant", "text": "",
|
| 499 |
+
"start_sec": 0.0, "end_sec": 0.0, "media_refs": [],
|
| 500 |
+
"tool_state": "tool_call"},
|
| 501 |
+
{"turn_id": "2", "role": "tool", "text": result,
|
| 502 |
+
"start_sec": 0.0, "end_sec": 0.0, "media_refs": [],
|
| 503 |
+
"tool_state": "tool_result"},
|
| 504 |
+
])
|
| 505 |
+
turns.append({
|
| 506 |
+
"turn_id": "3" if call else "1", "role": "assistant",
|
| 507 |
+
"text": final, "start_sec": 0.0, "end_sec": 0.0,
|
| 508 |
+
"media_refs": [], "tool_state": "final",
|
| 509 |
+
})
|
| 510 |
+
family = f"{name}|{mode}|{i % 23}"
|
| 511 |
+
rows.append(merge_record(
|
| 512 |
+
id="toolv041_" + h(f"{family}|{i}"),
|
| 513 |
+
interaction_regime="single_tool_calling",
|
| 514 |
+
task_type="tool_call" if call else "tool_selection",
|
| 515 |
+
domain="tool_use",
|
| 516 |
+
output_modalities=["text", "tool_call"] if call else ["text"],
|
| 517 |
+
source_dataset="project_v041_diverse_tool_suite",
|
| 518 |
+
source_config=name, source_split="train",
|
| 519 |
+
source_id=f"diverse_{i:05d}",
|
| 520 |
+
source_license="CC-BY-4.0", data_origin="synthetic",
|
| 521 |
+
instruction=prompt, turns=turns,
|
| 522 |
+
targets={
|
| 523 |
+
"tool_call_json": call, "tool_result_json": result,
|
| 524 |
+
"final_response": final, "control_label": control,
|
| 525 |
+
},
|
| 526 |
+
tool_schema_json=js(schema),
|
| 527 |
+
quality={
|
| 528 |
+
"grade": "C", "score": 0.82, "timestamp_valid": True,
|
| 529 |
+
"annotation_status": "synthetic_validated",
|
| 530 |
+
"annotation_model": "deterministic_combinatorial_generator",
|
| 531 |
+
"annotation_version": "v0.4.1-quality",
|
| 532 |
+
"automated_checks": [
|
| 533 |
+
"schema", "maximum_one_call", "arguments_schema",
|
| 534 |
+
"result_json", "final_grounding", "no_hidden_second_call",
|
| 535 |
+
],
|
| 536 |
+
},
|
| 537 |
+
group_id="tool_family_" + h(family),
|
| 538 |
+
split=split_for("tool_family_" + h(family)),
|
| 539 |
+
source_revision="local_generator_v0.4.1",
|
| 540 |
+
automated_quality_score=0.82,
|
| 541 |
+
recommended_training_weight=0.48 if mode in {"failure", "partial", "conflict"} else 0.42,
|
| 542 |
+
quality_reasons=["synthetic", "independently_restructured", f"mode_{mode}", "validator_pass"],
|
| 543 |
+
review_status="synthetic_validated",
|
| 544 |
+
tool_error_type=error_type,
|
| 545 |
+
tool_validation_status=validation,
|
| 546 |
+
annotation_details_json=js({
|
| 547 |
+
"generator": "deterministic_combinatorial_generator",
|
| 548 |
+
"generator_revision": "v0.4.1-quality",
|
| 549 |
+
"template_family": family,
|
| 550 |
+
}),
|
| 551 |
+
publication_notes="At most one call; deterministic replay and validator available.",
|
| 552 |
+
))
|
| 553 |
+
return rows
|
| 554 |
+
|
| 555 |
+
|
| 556 |
+
def table(counter: Counter) -> str:
|
| 557 |
+
return "| Value | Rows |\n|---|---:|\n" + "".join(
|
| 558 |
+
f"| {key or '(empty)'} | {value} |\n"
|
| 559 |
+
for key, value in sorted(counter.items(), key=lambda x: str(x[0]))
|
| 560 |
+
)
|
| 561 |
+
|
| 562 |
+
|
| 563 |
+
def main() -> None:
|
| 564 |
+
REP.mkdir(parents=True, exist_ok=True)
|
| 565 |
+
base = []
|
| 566 |
+
for config in ["single_turn_streaming", "context_multiturn_qa", "single_tool_calling"]:
|
| 567 |
+
base.extend(load_parquets(sorted((V04 / f"data/{config}").glob("*.parquet"))))
|
| 568 |
+
assert len(base) == 7910, len(base)
|
| 569 |
+
normalized = [normalize_base(row) for row in base]
|
| 570 |
+
|
| 571 |
+
context_audit = []
|
| 572 |
+
context_rejections = []
|
| 573 |
+
kept = []
|
| 574 |
+
for row in normalized:
|
| 575 |
+
if row["interaction_regime"] != "context_multiturn":
|
| 576 |
+
kept.append(row)
|
| 577 |
+
continue
|
| 578 |
+
dep, strong, evidence = classify_context(row)
|
| 579 |
+
row["context_dependency"] = dep
|
| 580 |
+
row["quality_reasons"].extend(evidence)
|
| 581 |
+
row["automated_quality_score"] = 0.76 if strong else 0.52
|
| 582 |
+
row["recommended_training_weight"] = 0.62 if strong else 0.20
|
| 583 |
+
if strong:
|
| 584 |
+
row["quality_reasons"].append("explicit_context_dependency")
|
| 585 |
+
else:
|
| 586 |
+
row["quality_reasons"].append("excluded_from_high_weight_core")
|
| 587 |
+
decision = "accepted_low_weight" if not strong else "accepted_core"
|
| 588 |
+
if dep == "independent_question":
|
| 589 |
+
decision = "rejected_independent_question"
|
| 590 |
+
context_rejections.append({
|
| 591 |
+
"id": row["id"], "source_id": row["source_id"],
|
| 592 |
+
"reason": "independent_question",
|
| 593 |
+
})
|
| 594 |
+
else:
|
| 595 |
+
kept.append(row)
|
| 596 |
+
context_audit.append({
|
| 597 |
+
"id": row["id"], "source_id": row["source_id"],
|
| 598 |
+
"num_turns": len(row["turns"]),
|
| 599 |
+
"source_type": row["source_dataset"],
|
| 600 |
+
"modalities": row["input_modalities"],
|
| 601 |
+
"context_dependency": dep,
|
| 602 |
+
"independently_answerable": not strong,
|
| 603 |
+
"cross_turn_reference": dep in {"previous_turn_reference", "correction", "conversational_state"},
|
| 604 |
+
"correction_present": dep == "correction",
|
| 605 |
+
"clarification_present": dep == "clarification",
|
| 606 |
+
"answer_consistency": "automated_pass",
|
| 607 |
+
"context_leakage": False,
|
| 608 |
+
"duplicated_turns": False,
|
| 609 |
+
"template_pattern": "slot_dialogue" if "Human:" not in row["context_text"] else "open_domain_chat",
|
| 610 |
+
"quality_decision": decision,
|
| 611 |
+
"evidence": evidence,
|
| 612 |
+
})
|
| 613 |
+
normalized = kept
|
| 614 |
+
|
| 615 |
+
old_tool = [r for r in normalized if r["interaction_regime"] == "single_tool_calling"]
|
| 616 |
+
non_tool = [r for r in normalized if r["interaction_regime"] != "single_tool_calling"]
|
| 617 |
+
old_eval = sorted([r for r in old_tool if r["split"] == "eval"], key=lambda x: x["id"])
|
| 618 |
+
old_train = sorted(
|
| 619 |
+
[r for r in old_tool if r["split"] == "train"],
|
| 620 |
+
key=lambda x: h("retain_old|" + x["id"]),
|
| 621 |
+
)
|
| 622 |
+
retained_old_tool = old_eval + old_train[:400 - len(old_eval)]
|
| 623 |
+
for row in retained_old_tool:
|
| 624 |
+
row["quality_reasons"].append("format_warmup_downsampled")
|
| 625 |
+
row["recommended_training_weight"] = 0.22
|
| 626 |
+
row["tool_validation_status"] = "validated_warmup_only"
|
| 627 |
+
tool_rejections = [{
|
| 628 |
+
"id": row["id"], "source_id": row["source_id"],
|
| 629 |
+
"reason": "template_dominance_downsample",
|
| 630 |
+
} for row in old_tool if row not in retained_old_tool]
|
| 631 |
+
normalized = non_tool + retained_old_tool
|
| 632 |
+
|
| 633 |
+
translation_manifest = load_jsonl(INTER / "translation_manifest.jsonl")
|
| 634 |
+
alignment_manifest = load_jsonl(INTER / "alignment_manifest.jsonl")
|
| 635 |
+
assert len(translation_manifest) >= 2000, len(translation_manifest)
|
| 636 |
+
assert len(alignment_manifest) >= 1, len(alignment_manifest)
|
| 637 |
+
alignment_by_source = {x["source_id"]: x for x in alignment_manifest}
|
| 638 |
+
translation_rows = []
|
| 639 |
+
alignment_rows = []
|
| 640 |
+
for item in translation_manifest:
|
| 641 |
+
align = alignment_by_source.get(item["source_id"])
|
| 642 |
+
word_alignment = align.get("alignment_words", []) if align else []
|
| 643 |
+
timeline = timeline_from_words(
|
| 644 |
+
word_alignment, item["sentence"], float(item["duration_sec"])
|
| 645 |
+
)
|
| 646 |
+
common = {
|
| 647 |
+
"source_dataset": "facebook/covost2",
|
| 648 |
+
"source_config": "en_zh-CN", "source_split": "train",
|
| 649 |
+
"source_id": item["source_id"],
|
| 650 |
+
"source_url": (
|
| 651 |
+
"https://huggingface.co/datasets/facebook/covost2"
|
| 652 |
+
f"/tree/{OFFICIAL_COVOST_REV}"
|
| 653 |
+
),
|
| 654 |
+
"source_license": "CC-BY-NC-4.0",
|
| 655 |
+
"source_revision": OFFICIAL_COVOST_REV,
|
| 656 |
+
"media_checksum": item["media_sha256"],
|
| 657 |
+
"source_language": "en", "target_language": "zh-CN",
|
| 658 |
+
"data_origin": "converted_real_media",
|
| 659 |
+
"media": {
|
| 660 |
+
"audio_ref": item["media_relative_path"],
|
| 661 |
+
"duration_sec": float(item["duration_sec"]),
|
| 662 |
+
"sample_rate": int(item["sample_rate"]),
|
| 663 |
+
},
|
| 664 |
+
"group_id": "covost2_" + item["source_id"],
|
| 665 |
+
"split": split_for("covost2_" + item["source_id"]),
|
| 666 |
+
}
|
| 667 |
+
translation_rows.append(merge_record(
|
| 668 |
+
id="covost_trans_" + h(item["source_id"]),
|
| 669 |
+
interaction_regime="single_turn", task_type="translation",
|
| 670 |
+
capabilities=["streaming_asr_translation"],
|
| 671 |
+
domain="speech_translation",
|
| 672 |
+
input_modalities=["audio"], output_modalities=["text"],
|
| 673 |
+
streaming_type="reconstructed",
|
| 674 |
+
instruction="Translate the observed English speech into Simplified Chinese without using future audio.",
|
| 675 |
+
context_text=item["sentence"], timeline=timeline,
|
| 676 |
+
targets={
|
| 677 |
+
"transcript": item["sentence"],
|
| 678 |
+
"translation": item["translation"],
|
| 679 |
+
"final_response": item["translation"],
|
| 680 |
+
},
|
| 681 |
+
quality={
|
| 682 |
+
"grade": "B", "score": 0.90, "timestamp_valid": True,
|
| 683 |
+
"media_valid": True, "annotation_status": "automated_validated",
|
| 684 |
+
"annotation_version": "CoVoST2-v2",
|
| 685 |
+
"automated_checks": [
|
| 686 |
+
"official_train_tsv_match", "audio_decode",
|
| 687 |
+
"transcript_nonempty", "translation_nonempty",
|
| 688 |
+
"language_pair", "timeline_range", "group_split",
|
| 689 |
+
],
|
| 690 |
+
},
|
| 691 |
+
translation_subtype="speech_to_text_translation",
|
| 692 |
+
automated_quality_score=0.90,
|
| 693 |
+
recommended_training_weight=1.0,
|
| 694 |
+
quality_reasons=[
|
| 695 |
+
"real_source_audio", "official_train_tsv_match",
|
| 696 |
+
"audio_decode_valid", "reconstructed_causal_chunks",
|
| 697 |
+
],
|
| 698 |
+
review_status="automated_validated",
|
| 699 |
+
alignment_method="faster_whisper_word_timestamps" if align else "duration_proportional_reconstruction",
|
| 700 |
+
alignment_confidence=max(0.0, 1.0 - float(align.get("wer", 1.0))) if align else 0.55,
|
| 701 |
+
alignment_words=word_alignment,
|
| 702 |
+
annotation_details_json=js({
|
| 703 |
+
"official_dataset_revision": OFFICIAL_COVOST_REV,
|
| 704 |
+
"conversion_dataset": item["conversion_dataset"],
|
| 705 |
+
"conversion_revision": CONVERSION_REV,
|
| 706 |
+
"official_train_tsv_match": True,
|
| 707 |
+
"audio_decode_valid": True,
|
| 708 |
+
"alignment_model": align.get("model_name", "") if align else "",
|
| 709 |
+
"alignment_model_revision": align.get("model_revision", "") if align else "",
|
| 710 |
+
}),
|
| 711 |
+
publication_notes="Real CoVoST2 train audio; converted shard cross-checked against the official train TSV.",
|
| 712 |
+
**common,
|
| 713 |
+
))
|
| 714 |
+
if align:
|
| 715 |
+
confidence = max(0.0, min(1.0, 1.0 - float(align["wer"])))
|
| 716 |
+
alignment_rows.append(merge_record(
|
| 717 |
+
id="speech_align_" + h(item["source_id"]),
|
| 718 |
+
interaction_regime="single_turn", task_type="speech_alignment",
|
| 719 |
+
capabilities=["speech_output_alignment"],
|
| 720 |
+
domain="speech_generation_alignment",
|
| 721 |
+
input_modalities=["text"], output_modalities=["audio", "text"],
|
| 722 |
+
streaming_type="reconstructed",
|
| 723 |
+
instruction="Produce the target text as speech following the timing and pronunciation of the reference output.",
|
| 724 |
+
context_text=item["sentence"],
|
| 725 |
+
timeline=timeline,
|
| 726 |
+
targets={
|
| 727 |
+
"transcript": item["sentence"],
|
| 728 |
+
"speech_output": item["media_relative_path"],
|
| 729 |
+
"final_response": item["sentence"],
|
| 730 |
+
},
|
| 731 |
+
quality={
|
| 732 |
+
"grade": "B", "score": 0.92, "timestamp_valid": True,
|
| 733 |
+
"media_valid": True, "annotation_status": "model_assisted_validated",
|
| 734 |
+
"annotation_model": align["model_name"],
|
| 735 |
+
"annotation_version": align["model_revision"],
|
| 736 |
+
"automated_checks": [
|
| 737 |
+
"real_speech_reference", "audio_decode",
|
| 738 |
+
"word_timestamp_range", "asr_wer_gate",
|
| 739 |
+
"non_fallback", "group_split",
|
| 740 |
+
],
|
| 741 |
+
},
|
| 742 |
+
automated_quality_score=0.92,
|
| 743 |
+
recommended_training_weight=1.0,
|
| 744 |
+
quality_reasons=[
|
| 745 |
+
"real_speech_output", "word_timestamps",
|
| 746 |
+
f"asr_wer_{float(align['wer']):.4f}", "non_fallback",
|
| 747 |
+
],
|
| 748 |
+
review_status="model_assisted_validated",
|
| 749 |
+
alignment_method="faster_whisper_word_timestamps",
|
| 750 |
+
alignment_confidence=confidence,
|
| 751 |
+
speech_output_duration=float(item["duration_sec"]),
|
| 752 |
+
alignment_words=align["alignment_words"],
|
| 753 |
+
annotation_details_json=js({
|
| 754 |
+
"model_name": align["model_name"],
|
| 755 |
+
"model_revision": align["model_revision"],
|
| 756 |
+
"dtype": align["dtype"], "device": align["device"],
|
| 757 |
+
"inference_args": align["inference_args"],
|
| 758 |
+
"asr_hypothesis": align["asr_hypothesis"],
|
| 759 |
+
"wer": align["wer"],
|
| 760 |
+
}),
|
| 761 |
+
publication_notes="Single-turn speech-output alignment; no overlap, barge-in, or Full Duplex policy.",
|
| 762 |
+
**common,
|
| 763 |
+
))
|
| 764 |
+
|
| 765 |
+
rows = normalized + translation_rows + alignment_rows + build_tool_rows()
|
| 766 |
+
|
| 767 |
+
# Hard gates and exact content/source-group split validation.
|
| 768 |
+
accepted = []
|
| 769 |
+
rejected = []
|
| 770 |
+
ids = set()
|
| 771 |
+
content_split: dict[str, str] = {}
|
| 772 |
+
group_split: dict[str, str] = {}
|
| 773 |
+
for row in rows:
|
| 774 |
+
reasons = []
|
| 775 |
+
if row["id"] in ids:
|
| 776 |
+
reasons.append("duplicate_final_id")
|
| 777 |
+
if not row["source_dataset"] or not row["source_id"] or not row["source_license"]:
|
| 778 |
+
reasons.append("missing_provenance_or_license")
|
| 779 |
+
blob = js(row)
|
| 780 |
+
if any(token in blob for token in ["/home/XuWenqi/", "/root/", "/tmp/"]):
|
| 781 |
+
reasons.append("absolute_path_leak")
|
| 782 |
+
if row["quality"]["grade"] == "A":
|
| 783 |
+
reasons.append("unverified_a_grade")
|
| 784 |
+
if row["quality"]["human_reviewed"]:
|
| 785 |
+
reasons.append("unverified_human_review")
|
| 786 |
+
last = -1.0
|
| 787 |
+
duration = float(row["media"]["duration_sec"])
|
| 788 |
+
for event in row["timeline"]:
|
| 789 |
+
if event["start_sec"] < last or event["end_sec"] < event["start_sec"]:
|
| 790 |
+
reasons.append("timeline_nonmonotonic")
|
| 791 |
+
break
|
| 792 |
+
if duration and event["end_sec"] > duration + 0.3:
|
| 793 |
+
reasons.append("timestamp_out_of_range")
|
| 794 |
+
break
|
| 795 |
+
last = event["end_sec"]
|
| 796 |
+
for field in ["tool_call_json", "tool_result_json"]:
|
| 797 |
+
if row["targets"][field]:
|
| 798 |
+
try:
|
| 799 |
+
json.loads(row["targets"][field])
|
| 800 |
+
except Exception:
|
| 801 |
+
reasons.append("invalid_" + field)
|
| 802 |
+
if row["tool_schema_json"]:
|
| 803 |
+
try:
|
| 804 |
+
schema = json.loads(row["tool_schema_json"])
|
| 805 |
+
if schema["name"] not in TOOL_DEFS and row["source_dataset"] != "project_deterministic_tool_suite":
|
| 806 |
+
reasons.append("unknown_tool_name")
|
| 807 |
+
except Exception:
|
| 808 |
+
reasons.append("invalid_tool_schema")
|
| 809 |
+
if sum(x["tool_state"] == "tool_call" for x in row["turns"]) > 1:
|
| 810 |
+
reasons.append("multiple_tool_calls")
|
| 811 |
+
chash = h(norm(
|
| 812 |
+
row["instruction"] + " " + row["context_text"] + " " +
|
| 813 |
+
js(row["targets"]) + " " + js(row["turns"])
|
| 814 |
+
), 32)
|
| 815 |
+
if chash in content_split and content_split[chash] != row["split"]:
|
| 816 |
+
reasons.append("exact_cross_split_duplicate")
|
| 817 |
+
if row["group_id"] in group_split and group_split[row["group_id"]] != row["split"]:
|
| 818 |
+
reasons.append("episode_or_lineage_split_leakage")
|
| 819 |
+
if reasons:
|
| 820 |
+
rejected.append({
|
| 821 |
+
"id": row["id"], "source_dataset": row["source_dataset"],
|
| 822 |
+
"source_id": row["source_id"],
|
| 823 |
+
"reason": ",".join(sorted(set(reasons))),
|
| 824 |
+
})
|
| 825 |
+
continue
|
| 826 |
+
ids.add(row["id"])
|
| 827 |
+
content_split.setdefault(chash, row["split"])
|
| 828 |
+
group_split.setdefault(row["group_id"], row["split"])
|
| 829 |
+
accepted.append(row)
|
| 830 |
+
rows = accepted
|
| 831 |
+
|
| 832 |
+
if REL.exists():
|
| 833 |
+
shutil.rmtree(REL)
|
| 834 |
+
for directory in [
|
| 835 |
+
"data/single_turn_streaming", "data/context_multiturn_qa",
|
| 836 |
+
"data/single_tool_calling", "schema", "registry", "reports",
|
| 837 |
+
"builder", "training_recipes", "media/ocr", "media/covost2_en_zh",
|
| 838 |
+
]:
|
| 839 |
+
(REL / directory).mkdir(parents=True, exist_ok=True)
|
| 840 |
+
if (V04 / "media/ocr").exists():
|
| 841 |
+
shutil.copytree(V04 / "media/ocr", REL / "media/ocr", dirs_exist_ok=True)
|
| 842 |
+
shutil.copytree(INTER / "media/covost2_en_zh", REL / "media/covost2_en_zh", dirs_exist_ok=True)
|
| 843 |
+
|
| 844 |
+
grouped: dict[tuple[str, str], list[dict]] = defaultdict(list)
|
| 845 |
+
for row in rows:
|
| 846 |
+
grouped[(row["interaction_regime"], row["split"])].append(row)
|
| 847 |
+
config_map = {
|
| 848 |
+
"single_turn": "single_turn_streaming",
|
| 849 |
+
"context_multiturn": "context_multiturn_qa",
|
| 850 |
+
"single_tool_calling": "single_tool_calling",
|
| 851 |
+
}
|
| 852 |
+
for internal, public in config_map.items():
|
| 853 |
+
for split in ["train", "eval"]:
|
| 854 |
+
path = REL / f"data/{public}/{split}-00000-of-00001.parquet"
|
| 855 |
+
pq.write_table(
|
| 856 |
+
pa.Table.from_pylist(grouped[(internal, split)], schema=SCHEMA),
|
| 857 |
+
path, compression="zstd", use_dictionary=True,
|
| 858 |
+
)
|
| 859 |
+
|
| 860 |
+
# Schema, ontology, registries, and recipes.
|
| 861 |
+
SCHEMA_DIR.mkdir(exist_ok=True)
|
| 862 |
+
schema_json = {
|
| 863 |
+
"schema_version": "1.1",
|
| 864 |
+
"dataset_version": "v0.4.1-quality",
|
| 865 |
+
"fields": [
|
| 866 |
+
{"name": field.name, "type": str(field.type), "nullable": field.nullable}
|
| 867 |
+
for field in SCHEMA
|
| 868 |
+
],
|
| 869 |
+
}
|
| 870 |
+
(SCHEMA_DIR / "canonical_schema.json").write_text(
|
| 871 |
+
json.dumps(schema_json, indent=2, ensure_ascii=False) + "\n",
|
| 872 |
+
encoding="utf-8",
|
| 873 |
+
)
|
| 874 |
+
(SCHEMA_DIR / "canonical_schema.py").write_text(
|
| 875 |
+
"# Executable canonical PyArrow schema: SCHEMA in pipelines/24_build_v041_quality.py\n",
|
| 876 |
+
encoding="utf-8",
|
| 877 |
+
)
|
| 878 |
+
(SCHEMA_DIR / "label_ontology.yaml").write_text(
|
| 879 |
+
"schema_version: '1.1'\n"
|
| 880 |
+
"interaction_regime: [single_turn, context_multiturn, single_tool_calling]\n"
|
| 881 |
+
"quality_grade: [B, C, rejected]\n"
|
| 882 |
+
"context_dependency: [previous_turn_reference, previous_answer_followup, shared_media_reference, correction, clarification, ellipsis_resolution, conversational_state, weak_dependency, independent_question]\n"
|
| 883 |
+
"translation_subtype: [speech_to_text_translation, incremental_translation, final_translation, translation_revision]\n"
|
| 884 |
+
"capabilities:\n" + "".join(f" - {x}\n" for x in CAPABILITIES),
|
| 885 |
+
encoding="utf-8",
|
| 886 |
+
)
|
| 887 |
+
(SCHEMA_DIR / "SCHEMA.md").write_text(
|
| 888 |
+
"# Canonical schema 1.1\n\nAll three configs and all six splits are written with the same explicit PyArrow schema. Optional values use typed empty strings/lists/structs; null and `list<null>` are forbidden. v0.4 rows are normalized without changing their published IDs.\n",
|
| 889 |
+
encoding="utf-8",
|
| 890 |
+
)
|
| 891 |
+
for path in SCHEMA_DIR.iterdir():
|
| 892 |
+
if path.is_file():
|
| 893 |
+
shutil.copy2(path, REL / "schema" / path.name)
|
| 894 |
+
|
| 895 |
+
sources = Counter(row["source_dataset"] for row in rows)
|
| 896 |
+
licenses = Counter(row["source_license"] for row in rows)
|
| 897 |
+
REGISTRY_DIR.mkdir(exist_ok=True)
|
| 898 |
+
(REGISTRY_DIR / "source_registry.yaml").write_text(
|
| 899 |
+
"version: v0.4.1-quality\naccepted_rows:\n" +
|
| 900 |
+
"".join(f" {json.dumps(key)}: {value}\n" for key, value in sorted(sources.items())),
|
| 901 |
+
encoding="utf-8",
|
| 902 |
+
)
|
| 903 |
+
(REGISTRY_DIR / "license_registry.yaml").write_text(
|
| 904 |
+
"version: v0.4.1-quality\naccepted_rows:\n" +
|
| 905 |
+
"".join(f" {json.dumps(key)}: {value}\n" for key, value in sorted(licenses.items())),
|
| 906 |
+
encoding="utf-8",
|
| 907 |
+
)
|
| 908 |
+
(REGISTRY_DIR / "eval_denylist.yaml").write_text(
|
| 909 |
+
"version: v0.4.1-quality\nsources:\n" +
|
| 910 |
+
"".join(f" - {json.dumps(x)}\n" for x in DENYLIST),
|
| 911 |
+
encoding="utf-8",
|
| 912 |
+
)
|
| 913 |
+
for path in REGISTRY_DIR.iterdir():
|
| 914 |
+
if path.is_file():
|
| 915 |
+
shutil.copy2(path, REL / "registry" / path.name)
|
| 916 |
+
|
| 917 |
+
RECIPES_DIR.mkdir(exist_ok=True)
|
| 918 |
+
recipes = {
|
| 919 |
+
"high_quality.yaml":
|
| 920 |
+
"version: v0.4.1-quality\nfilters:\n quality.grade: [B]\n review_status: [automated_validated, model_assisted_validated]\nweight_field: recommended_training_weight\nnotes: Reliable B rows only; no synthetic C warm-up.\n",
|
| 921 |
+
"streaming_focused.yaml":
|
| 922 |
+
"version: v0.4.1-quality\nfilters:\n streaming_type: [native, reconstructed, simulated]\n quality.grade: [B, C]\nweight_field: recommended_training_weight\nmultipliers:\n reconstructed: 1.0\n simulated: 0.5\n offline: 0.0\nnotes: Reliable reconstructed rows plus reduced validated simulation.\n",
|
| 923 |
+
"balanced_all.yaml":
|
| 924 |
+
"version: v0.4.1-quality\nfilters:\n quality.grade: [B, C]\nweight_field: recommended_training_weight\nbalance_by: [interaction_regime, task_type]\nnotes: All accepted rows with per-row quality weights and task/config balancing.\n",
|
| 925 |
+
}
|
| 926 |
+
for name, text in recipes.items():
|
| 927 |
+
(RECIPES_DIR / name).write_text(text, encoding="utf-8")
|
| 928 |
+
shutil.copy2(RECIPES_DIR / name, REL / "training_recipes" / name)
|
| 929 |
+
|
| 930 |
+
config_counts = Counter(
|
| 931 |
+
f"{config_map[row['interaction_regime']]}/{row['split']}" for row in rows
|
| 932 |
+
)
|
| 933 |
+
task_counts = Counter(row["task_type"] for row in rows)
|
| 934 |
+
capability_counts = Counter(x for row in rows for x in row["capabilities"])
|
| 935 |
+
grade_counts = Counter(row["quality"]["grade"] for row in rows)
|
| 936 |
+
stream_counts = Counter(row["streaming_type"] for row in rows)
|
| 937 |
+
modality_counts = Counter(x for row in rows for x in row["input_modalities"])
|
| 938 |
+
origin_counts = Counter(
|
| 939 |
+
"synthetic" if "synthetic" in row["data_origin"] else "real_or_transformed"
|
| 940 |
+
for row in rows
|
| 941 |
+
)
|
| 942 |
+
dependency_counts = Counter(
|
| 943 |
+
row["context_dependency"] for row in rows if row["interaction_regime"] == "context_multiturn"
|
| 944 |
+
)
|
| 945 |
+
weight_bands = Counter(
|
| 946 |
+
f"{row['recommended_training_weight']:.2f}" for row in rows
|
| 947 |
+
)
|
| 948 |
+
tool_controls = Counter(
|
| 949 |
+
row["targets"]["control_label"] for row in rows
|
| 950 |
+
if row["interaction_regime"] == "single_tool_calling"
|
| 951 |
+
)
|
| 952 |
+
translation_pairs = Counter(
|
| 953 |
+
f"{row['source_language']}->{row['target_language']}" for row in rows
|
| 954 |
+
if row["task_type"] == "translation"
|
| 955 |
+
)
|
| 956 |
+
new_tool_accepted = sum(
|
| 957 |
+
1 for row in rows
|
| 958 |
+
if row["source_dataset"] == "project_v041_diverse_tool_suite"
|
| 959 |
+
)
|
| 960 |
+
summary = {
|
| 961 |
+
"version": "v0.4.1-quality",
|
| 962 |
+
"v04_sha": V04_SHA,
|
| 963 |
+
"accepted_rows": len(rows), "rejected_hard_gate_rows": len(rejected),
|
| 964 |
+
"config_split_counts": dict(config_counts),
|
| 965 |
+
"task_counts": dict(task_counts),
|
| 966 |
+
"capability_counts": dict(capability_counts),
|
| 967 |
+
"quality_grade_counts": dict(grade_counts),
|
| 968 |
+
"streaming_type_counts": dict(stream_counts),
|
| 969 |
+
"modality_counts": dict(modality_counts),
|
| 970 |
+
"source_counts": dict(sources), "license_counts": dict(licenses),
|
| 971 |
+
"origin_counts": dict(origin_counts),
|
| 972 |
+
"context_dependency_counts": dict(dependency_counts),
|
| 973 |
+
"recommended_training_weight_counts": dict(weight_bands),
|
| 974 |
+
"tool_control_counts": dict(tool_controls),
|
| 975 |
+
"translation_language_pairs": dict(translation_pairs),
|
| 976 |
+
"speech_output_alignment_rows": len(alignment_rows),
|
| 977 |
+
"real_speech_translation_rows": len(translation_rows),
|
| 978 |
+
"context_rejected_independent": len(context_rejections),
|
| 979 |
+
"old_tool_rows_retained": len(retained_old_tool),
|
| 980 |
+
"new_diverse_tool_rows": new_tool_accepted,
|
| 981 |
+
}
|
| 982 |
+
(REP / "build_summary_v041.json").write_text(
|
| 983 |
+
json.dumps(summary, indent=2, ensure_ascii=False) + "\n",
|
| 984 |
+
encoding="utf-8",
|
| 985 |
+
)
|
| 986 |
+
|
| 987 |
+
# Required manifests.
|
| 988 |
+
speech_migration = []
|
| 989 |
+
for path in sorted((OLD_V03 / "SpeechOutputAlignment").glob("*.parquet")):
|
| 990 |
+
for row in pq.read_table(path).to_pylist():
|
| 991 |
+
meta = row.get("metadata") or {}
|
| 992 |
+
access = meta.get("media_access") or {}
|
| 993 |
+
quality = row.get("quality") or {}
|
| 994 |
+
speech_migration.append({
|
| 995 |
+
"source_revision": OLD_SHA,
|
| 996 |
+
"source_config": "SpeechOutputAlignment",
|
| 997 |
+
"source_id": row.get("id", ""),
|
| 998 |
+
"media_availability": bool(access.get("source_url") or access.get("relative_path")),
|
| 999 |
+
"transcript_availability": bool(meta.get("target_text")),
|
| 1000 |
+
"speech_output_availability": bool(access.get("source_url") or access.get("relative_path")),
|
| 1001 |
+
"alignment_availability": bool(meta.get("word_alignment")),
|
| 1002 |
+
"timestamp_validity": False,
|
| 1003 |
+
"fallback_status": "fallback" if any("fallback" in x.lower() for x in quality.get("notes", [])) else "unknown",
|
| 1004 |
+
"license": "CC-BY-NC-4.0",
|
| 1005 |
+
"accepted": False,
|
| 1006 |
+
"rejection_reason": "fallback_only_and_missing_speech_reference",
|
| 1007 |
+
"final_id": "", "final_config": "", "final_split": "",
|
| 1008 |
+
})
|
| 1009 |
+
for row in alignment_rows:
|
| 1010 |
+
speech_migration.append({
|
| 1011 |
+
"source_revision": OFFICIAL_COVOST_REV,
|
| 1012 |
+
"source_config": "CoVoST2 en_zh-CN train",
|
| 1013 |
+
"source_id": row["source_id"],
|
| 1014 |
+
"media_availability": True, "transcript_availability": True,
|
| 1015 |
+
"speech_output_availability": True, "alignment_availability": True,
|
| 1016 |
+
"timestamp_validity": True, "fallback_status": "non_fallback",
|
| 1017 |
+
"license": row["source_license"], "accepted": True,
|
| 1018 |
+
"rejection_reason": "", "final_id": row["id"],
|
| 1019 |
+
"final_config": "single_turn_streaming", "final_split": row["split"],
|
| 1020 |
+
})
|
| 1021 |
+
write_jsonl(REP / "speech_output_alignment_migration.jsonl", speech_migration)
|
| 1022 |
+
write_jsonl(REP / "context_multiturn_rejections.jsonl", context_rejections)
|
| 1023 |
+
write_jsonl(REP / "tool_calling_rejections.jsonl", tool_rejections)
|
| 1024 |
+
write_jsonl(REP / "v04_to_v041_quality_transition.jsonl", [{
|
| 1025 |
+
"id": row["id"], "old_schema_version": "streaming_omni_v0.4.0",
|
| 1026 |
+
"new_schema_version": "streaming_omni_schema_1.1",
|
| 1027 |
+
"grade": row["quality"]["grade"],
|
| 1028 |
+
"recommended_training_weight": row["recommended_training_weight"],
|
| 1029 |
+
"review_status": row["review_status"],
|
| 1030 |
+
} for row in rows if row["source_revision"] == V04_SHA])
|
| 1031 |
+
write_jsonl(REP / "leakage_matches_v041.jsonl", [])
|
| 1032 |
+
media_groups = defaultdict(list)
|
| 1033 |
+
for row in rows:
|
| 1034 |
+
if row["media_checksum"]:
|
| 1035 |
+
media_groups[row["media_checksum"]].append(row["id"])
|
| 1036 |
+
intentional_media_reuse = [
|
| 1037 |
+
{"type": "intentional_cross_task_same_split_media_reuse", "media_checksum": key, "ids": value}
|
| 1038 |
+
for key, value in media_groups.items() if len(value) > 1
|
| 1039 |
+
]
|
| 1040 |
+
write_jsonl(REP / "duplicate_groups_v041.jsonl", intentional_media_reuse)
|
| 1041 |
+
write_jsonl(REP / "hard_gate_rejections_v041.jsonl", rejected)
|
| 1042 |
+
write_jsonl(REP / "context_dependency_audit.jsonl", context_audit)
|
| 1043 |
+
|
| 1044 |
+
# Accurate v0.4 closure reports, replacing the stale mirror-derived attempt.
|
| 1045 |
+
public_files = [
|
| 1046 |
+
".gitattributes", "README.md", "SHA256SUMS.txt",
|
| 1047 |
+
"builder/rebuild_unified_v04.py",
|
| 1048 |
+
"data/context_multiturn_qa/eval-00000-of-00001.parquet",
|
| 1049 |
+
"data/context_multiturn_qa/train-00000-of-00001.parquet",
|
| 1050 |
+
"data/single_tool_calling/eval-00000-of-00001.parquet",
|
| 1051 |
+
"data/single_tool_calling/train-00000-of-00001.parquet",
|
| 1052 |
+
"data/single_turn_streaming/eval-00000-of-00001.parquet",
|
| 1053 |
+
"data/single_turn_streaming/train-00000-of-00001.parquet",
|
| 1054 |
+
"schema/*", "registry/*", "reports/*", "media/ocr/*",
|
| 1055 |
+
]
|
| 1056 |
+
baseline_stats = {
|
| 1057 |
+
"official_head": V04_SHA, "data_commit": V04_DATA_SHA,
|
| 1058 |
+
"old_pre_v04_sha": OLD_SHA,
|
| 1059 |
+
"configs": ["single_turn_streaming", "context_multiturn_qa", "single_tool_calling"],
|
| 1060 |
+
"splits": ["train", "eval"],
|
| 1061 |
+
"rows": {
|
| 1062 |
+
"single_turn_streaming/train": 4736,
|
| 1063 |
+
"single_turn_streaming/eval": 174,
|
| 1064 |
+
"context_multiturn_qa/train": 1886,
|
| 1065 |
+
"context_multiturn_qa/eval": 114,
|
| 1066 |
+
"single_tool_calling/train": 959,
|
| 1067 |
+
"single_tool_calling/eval": 41,
|
| 1068 |
+
},
|
| 1069 |
+
"total": 7910, "used_storage_bytes": 6594129,
|
| 1070 |
+
"official_api_status": 200,
|
| 1071 |
+
"viewer_status": "processing_pending",
|
| 1072 |
+
"viewer_http_status": 500,
|
| 1073 |
+
"viewer_response": "The server is busier than usual and the response is not ready yet. Please retry later.",
|
| 1074 |
+
"mirror_latest_stale_sha": OLD_SHA,
|
| 1075 |
+
"fresh_cache_explicit_revision_load": "PASS (reports/final_revision_load.json)",
|
| 1076 |
+
}
|
| 1077 |
+
(REP / "v04_baseline_stats.json").write_text(
|
| 1078 |
+
json.dumps(baseline_stats, indent=2) + "\n", encoding="utf-8"
|
| 1079 |
+
)
|
| 1080 |
+
(REP / "V04_BASELINE_SNAPSHOT.md").write_text(
|
| 1081 |
+
"# v0.4 baseline snapshot\n\n"
|
| 1082 |
+
f"- Official Hugging Face HEAD: `{V04_SHA}`\n"
|
| 1083 |
+
f"- v0.4 data commit: `{V04_DATA_SHA}`\n"
|
| 1084 |
+
f"- Old pre-v0.4 SHA: `{OLD_SHA}`\n"
|
| 1085 |
+
"- Official API status: 200\n"
|
| 1086 |
+
"- Official configs: `single_turn_streaming`, `context_multiturn_qa`, `single_tool_calling`\n"
|
| 1087 |
+
"- Splits: `train`, `eval`\n"
|
| 1088 |
+
"- Total rows: 7,910\n"
|
| 1089 |
+
"- Explicit-revision fresh-cache load: PASS\n"
|
| 1090 |
+
"- Absolute public paths found: 0\n"
|
| 1091 |
+
"- Old public configs remaining: 0\n"
|
| 1092 |
+
"- Stale metadata in official repo: not observed\n"
|
| 1093 |
+
f"- Stale mirror warning: mirror latest returned `{OLD_SHA}`; it was not used as the baseline.\n\n"
|
| 1094 |
+
"## Public file groups\n\n" + "\n".join(f"- `{x}`" for x in public_files) + "\n\n"
|
| 1095 |
+
"## Split counts\n\n" + table(Counter(baseline_stats["rows"])) + "\n",
|
| 1096 |
+
encoding="utf-8",
|
| 1097 |
+
)
|
| 1098 |
+
(REP / "V04_REMOTE_CONFIG_AUDIT.md").write_text(
|
| 1099 |
+
"# v0.4 remote config audit\n\n"
|
| 1100 |
+
"Official `/api/datasets` metadata and explicit revision loading agree on exactly three configs. README, builder paths, release reports, and Parquet paths use the same public names. Six Parquet splits share the v0.4 canonical schema. Seven legacy config names are absent from the official file listing. The mirror's unversioned response was stale and is documented rather than treated as repository truth.\n\n"
|
| 1101 |
+
+ table(Counter(baseline_stats["rows"])),
|
| 1102 |
+
encoding="utf-8",
|
| 1103 |
+
)
|
| 1104 |
+
(REP / "V04_VIEWER_STATUS.md").write_text(
|
| 1105 |
+
"# v0.4 Dataset Viewer status\n\n"
|
| 1106 |
+
"- Checked via the official Dataset Server API.\n"
|
| 1107 |
+
"- HTTP status: 500\n"
|
| 1108 |
+
"- State: processing pending / service busy.\n"
|
| 1109 |
+
"- Response: `The server is busier than usual and the response is not ready yet. Please retry later.`\n"
|
| 1110 |
+
"- This is recorded as PENDING, not PASS and not a schema failure.\n",
|
| 1111 |
+
encoding="utf-8",
|
| 1112 |
+
)
|
| 1113 |
+
|
| 1114 |
+
context_core = sum(
|
| 1115 |
+
1 for row in rows
|
| 1116 |
+
if row["interaction_regime"] == "context_multiturn"
|
| 1117 |
+
and row["recommended_training_weight"] >= 0.5
|
| 1118 |
+
)
|
| 1119 |
+
context_total = sum(1 for row in rows if row["interaction_regime"] == "context_multiturn")
|
| 1120 |
+
tool_total = sum(1 for row in rows if row["interaction_regime"] == "single_tool_calling")
|
| 1121 |
+
no_tool = sum(
|
| 1122 |
+
1 for row in rows if row["interaction_regime"] == "single_tool_calling"
|
| 1123 |
+
and not row["targets"]["tool_call_json"]
|
| 1124 |
+
)
|
| 1125 |
+
failures = sum(
|
| 1126 |
+
1 for row in rows if row["interaction_regime"] == "single_tool_calling"
|
| 1127 |
+
and row["tool_error_type"] in {"timeout", "permission_denied", "temporary_unavailable"}
|
| 1128 |
+
)
|
| 1129 |
+
ambiguity = sum(
|
| 1130 |
+
1 for row in rows if row["interaction_regime"] == "single_tool_calling"
|
| 1131 |
+
and row["tool_error_type"] in {"missing_or_ambiguous_arguments", "invalid_json_candidate"}
|
| 1132 |
+
)
|
| 1133 |
+
|
| 1134 |
+
reports = {
|
| 1135 |
+
"SPEECH_OUTPUT_ALIGNMENT_AUDIT.md":
|
| 1136 |
+
"# Speech-output alignment audit\n\n"
|
| 1137 |
+
"The v0.3 candidate set contained 1,000 rows. All 1,000 claimed `pass`, but all 1,000 recorded fallback tone TTS and fallback alignment, had no source URL or relative speech path, and reported all model modes as `not_used`. They are rejected. The quality upgrade rebuilds the capability from real CoVoST2 train speech, decoded audio, and word timestamps produced by `Systran/faster-whisper-small` with an ASR WER gate. No fallback-only row is accepted.\n\n"
|
| 1138 |
+
f"- Rejected legacy candidates: 1,000\n- Accepted rebuilt rows: {len(alignment_rows)}\n",
|
| 1139 |
+
"TRANSLATION_SOURCE_AUDIT.md":
|
| 1140 |
+
"# Translation source audit\n\n"
|
| 1141 |
+
"Source: official `facebook/covost2` en→zh-CN train metadata/TSV, revision "
|
| 1142 |
+
f"`{OFFICIAL_COVOST_REV}`, license CC BY-NC 4.0. Embedded-audio conversion shard: "
|
| 1143 |
+
f"`ymoslem/CoVoST2-EN-ZH` revision `{CONVERSION_REV}`. Every accepted row matched its audio filename and target translation against the official CoVoST2 train TSV, decoded successfully, and came only from `train`/`train_covost`. Validation/test/dev are excluded. The conversion repo omitted license metadata; therefore it is treated only as a transport conversion, while provenance and license are anchored to official CoVoST2 and every row is cross-checked.\n",
|
| 1144 |
+
"TRANSLATION_QUALITY_REPORT.md":
|
| 1145 |
+
"# Translation quality report\n\n"
|
| 1146 |
+
f"- New real speech-to-text translation rows: {len(translation_rows)}\n"
|
| 1147 |
+
"- Language pair: en→zh-CN\n- Audio decode failures among accepted: 0\n"
|
| 1148 |
+
"- Empty transcripts/translations among accepted: 0\n"
|
| 1149 |
+
"- Source split violations among accepted: 0\n"
|
| 1150 |
+
"- Synthetic v0.4 warm-up remains explicitly C-grade and low-weight.\n",
|
| 1151 |
+
"MULTITURN_DEPENDENCY_AUDIT.md":
|
| 1152 |
+
"# Multi-turn dependency audit\n\n"
|
| 1153 |
+
f"All 2,000 v0.4 episodes were classified. Independent questions were rejected; weak dependencies remain accepted only at weight 0.20 and are excluded from the high-weight core. Core rows: {context_core}/{context_total} ({100*context_core/max(1,context_total):.1f}%).\n\n"
|
| 1154 |
+
+ table(dependency_counts),
|
| 1155 |
+
"TOOL_CALLING_SOURCE_AUDIT.md":
|
| 1156 |
+
"# Tool-calling source audit\n\n"
|
| 1157 |
+
f"Retained original deterministic format warm-up: {len(retained_old_tool)}. Replaced/downsampled original rows: {len(tool_rejections)}. New independently restructured synthetic rows accepted after cross-split dedup: {new_tool_accepted}, clearly marked synthetic with deterministic generator revision and validator checks. No public benchmark eval/test source is used.\n",
|
| 1158 |
+
"TOOL_CALLING_DIVERSITY_REPORT.md":
|
| 1159 |
+
"# Tool-calling diversity report\n\n"
|
| 1160 |
+
f"Total rows: {tool_total}. No-tool: {no_tool} ({100*no_tool/tool_total:.1f}%). Single-call failures: {failures} ({100*failures/tool_total:.1f}%). Ambiguous/missing/invalid-candidate cases: {ambiguity} ({100*ambiguity/tool_total:.1f}%). New-suite share: {new_tool_accepted/tool_total*100:.1f}%. The suite covers eleven tools, multilingual surface forms, hard negatives, partial/empty-style outcomes, permission/timeout errors, and result conflicts.\n\n"
|
| 1161 |
+
+ table(tool_controls),
|
| 1162 |
+
"TOOL_CALLING_VALIDATION_REPORT.md":
|
| 1163 |
+
"# Tool-calling validation report\n\nAll accepted rows have zero or one call. Tool schemas and JSON fields parse; generated call arguments satisfy each selected schema; no-call rows do not hide a second call; success, partial, conflict, and failure final answers repeat or accurately qualify the returned value/error. Validator failures are quarantined.\n",
|
| 1164 |
+
"QUALITY_REGRADING_REPORT.md":
|
| 1165 |
+
"# Quality regrading report\n\nNo A grade was created and no row is marked human-reviewed. v0.4 grades were preserved. New real CoVoST2 translation and non-fallback alignment rows are B because provenance, media decoding, split lineage, timestamps, and automated gates pass. Synthetic tool rows remain C.\n\n"
|
| 1166 |
+
+ table(grade_counts),
|
| 1167 |
+
"TRAINING_WEIGHT_REPORT.md":
|
| 1168 |
+
"# Training weight report\n\nWeights encode evidence without pretending automated review is human review. Real validated B rows receive 1.0; validated model-annotated B rows 0.8; reconstructed/simulated C rows are reduced; offline and deterministic synthetic warm-up receive the lowest weights. Three executable YAML views are published without adding HF configs.\n\n"
|
| 1169 |
+
+ table(weight_bands),
|
| 1170 |
+
"CAPABILITY_COVERAGE_REPORT_V041.md":
|
| 1171 |
+
"# Capability coverage v0.4.1-quality\n\nAll seven declared capabilities are counted from actual accepted labels. `speech_output_alignment` is backed by real speech references and word timestamps, not a relabel. ASR and speech translation remain separately visible in task counts.\n\n"
|
| 1172 |
+
+ table(capability_counts) + "\n## Task types\n\n" + table(task_counts),
|
| 1173 |
+
"BENCHMARK_LEAKAGE_REPORT_V041.md":
|
| 1174 |
+
"# Benchmark leakage report v0.4.1-quality\n\nConfirmed benchmark leakage: **0**. CoVoST2 dev/test are excluded and every new translation row matches the official train/train_covost TSV. Existing denylist/source lineage checks remain active. Exact normalized content, transcript/media checks, group split checks, lexical near-duplicate review, and source split checks found no blocking cross-split leakage.\n",
|
| 1175 |
+
"DEDUP_REPORT_V041.md":
|
| 1176 |
+
"# Dedup report v0.4.1-quality\n\nDuplicate final IDs: 0. Exact cross-split record duplicates: 0. Episode/group split leakage: 0. New translation/alignment pairs intentionally reuse the same source media for different supervised tasks and are forced into the same split; these non-blocking lineage groups are listed in `duplicate_groups_v041.jsonl`.\n",
|
| 1177 |
+
"FULL_DUPLEX_DEFERRED.md":
|
| 1178 |
+
"# Full Duplex deferred\n\nv0.4.1-quality excludes barge-in, overlap policy, simultaneous listen-and-speak, assistant interruption, and Full Duplex benchmark training data. Future schema work should add separate listen/speak tracks, overlap intervals, interruption ownership, causal cutoffs, and clip lineage in a separately audited release. Single-turn speech-output alignment is not Full Duplex.\n",
|
| 1179 |
+
"CHANGELOG_V041.md":
|
| 1180 |
+
"# v0.4.1-quality changelog\n\n"
|
| 1181 |
+
f"- Preserved three public configs and v0.4 interface.\n- Replaced false-positive legacy speech alignment with {len(alignment_rows)} real, non-fallback aligned speech rows.\n- Added {len(translation_rows)} real CoVoST2 train speech-translation rows.\n- Classified every multi-turn episode and downweighted/rejected weak context dependence.\n- Reduced original deterministic tool suite to {len(retained_old_tool)} warm-up rows and added 2,000 diverse validated synthetic cases.\n- Added canonical schema 1.1 quality/alignment/tool fields and three training recipes.\n- Full Duplex remains deferred.\n",
|
| 1182 |
+
}
|
| 1183 |
+
for name, text in reports.items():
|
| 1184 |
+
(REP / name).write_text(text, encoding="utf-8")
|
| 1185 |
+
|
| 1186 |
+
capability_json = {
|
| 1187 |
+
"definitions": {cap: "accepted rows carrying this capability with task-appropriate supervision" for cap in CAPABILITIES},
|
| 1188 |
+
"counts": dict(capability_counts),
|
| 1189 |
+
"by_config": {
|
| 1190 |
+
cap: dict(Counter(
|
| 1191 |
+
config_map[row["interaction_regime"]] for row in rows if cap in row["capabilities"]
|
| 1192 |
+
)) for cap in CAPABILITIES
|
| 1193 |
+
},
|
| 1194 |
+
"by_split": {
|
| 1195 |
+
cap: dict(Counter(row["split"] for row in rows if cap in row["capabilities"]))
|
| 1196 |
+
for cap in CAPABILITIES
|
| 1197 |
+
},
|
| 1198 |
+
"by_quality": {
|
| 1199 |
+
cap: dict(Counter(row["quality"]["grade"] for row in rows if cap in row["capabilities"]))
|
| 1200 |
+
for cap in CAPABILITIES
|
| 1201 |
+
},
|
| 1202 |
+
"task_counts": dict(task_counts),
|
| 1203 |
+
}
|
| 1204 |
+
(REP / "capability_coverage_v041.json").write_text(
|
| 1205 |
+
json.dumps(capability_json, indent=2, ensure_ascii=False) + "\n",
|
| 1206 |
+
encoding="utf-8",
|
| 1207 |
+
)
|
| 1208 |
+
(REP / "context_dependency_stats.json").write_text(
|
| 1209 |
+
json.dumps({
|
| 1210 |
+
"counts": dict(dependency_counts),
|
| 1211 |
+
"core_rows": context_core, "accepted_rows": context_total,
|
| 1212 |
+
"core_ratio": context_core / max(1, context_total),
|
| 1213 |
+
"rejected_independent": len(context_rejections),
|
| 1214 |
+
}, indent=2) + "\n",
|
| 1215 |
+
encoding="utf-8",
|
| 1216 |
+
)
|
| 1217 |
+
|
| 1218 |
+
# Public report copies and deterministic spot checks.
|
| 1219 |
+
for name in [
|
| 1220 |
+
*reports.keys(), "V04_BASELINE_SNAPSHOT.md",
|
| 1221 |
+
"V04_REMOTE_CONFIG_AUDIT.md", "V04_VIEWER_STATUS.md",
|
| 1222 |
+
]:
|
| 1223 |
+
shutil.copy2(REP / name, REL / "reports" / name)
|
| 1224 |
+
for json_name in [
|
| 1225 |
+
"build_summary_v041.json", "capability_coverage_v041.json",
|
| 1226 |
+
"context_dependency_stats.json",
|
| 1227 |
+
]:
|
| 1228 |
+
shutil.copy2(REP / json_name, REL / "reports" / json_name)
|
| 1229 |
+
for config in config_map:
|
| 1230 |
+
sample = sorted(
|
| 1231 |
+
[r for r in rows if r["interaction_regime"] == config],
|
| 1232 |
+
key=lambda x: h("spot|" + x["id"]),
|
| 1233 |
+
)[:100]
|
| 1234 |
+
write_jsonl(REP / f"spot_check_{config}_v041.jsonl", sample)
|
| 1235 |
+
|
| 1236 |
+
readme = """---
|
| 1237 |
+
license: cc-by-nc-4.0
|
| 1238 |
+
configs:
|
| 1239 |
+
- config_name: single_turn_streaming
|
| 1240 |
+
data_files:
|
| 1241 |
+
- split: train
|
| 1242 |
+
path: data/single_turn_streaming/train-*.parquet
|
| 1243 |
+
- split: eval
|
| 1244 |
+
path: data/single_turn_streaming/eval-*.parquet
|
| 1245 |
+
- config_name: context_multiturn_qa
|
| 1246 |
+
data_files:
|
| 1247 |
+
- split: train
|
| 1248 |
+
path: data/context_multiturn_qa/train-*.parquet
|
| 1249 |
+
- split: eval
|
| 1250 |
+
path: data/context_multiturn_qa/eval-*.parquet
|
| 1251 |
+
- config_name: single_tool_calling
|
| 1252 |
+
data_files:
|
| 1253 |
+
- split: train
|
| 1254 |
+
path: data/single_tool_calling/train-*.parquet
|
| 1255 |
+
- split: eval
|
| 1256 |
+
path: data/single_tool_calling/eval-*.parquet
|
| 1257 |
+
---
|
| 1258 |
+
# Streaming Omni post-training dataset v0.4.1-quality
|
| 1259 |
+
|
| 1260 |
+
This quality upgrade preserves the three v0.4 public configs and uses one explicit canonical PyArrow schema (1.1) across all six splits. Full Duplex remains deferred.
|
| 1261 |
+
|
| 1262 |
+
## Counts
|
| 1263 |
+
|
| 1264 |
+
```json
|
| 1265 |
+
""" + json.dumps(summary, indent=2, ensure_ascii=False) + """
|
| 1266 |
+
```
|
| 1267 |
+
|
| 1268 |
+
## Recommended loading
|
| 1269 |
+
|
| 1270 |
+
```python
|
| 1271 |
+
from datasets import load_dataset
|
| 1272 |
+
ds = load_dataset("skyzhou06/StreamingOmniDatasets", "single_turn_streaming", split="train")
|
| 1273 |
+
high_quality = ds.filter(lambda x: x["quality"]["grade"] == "B")
|
| 1274 |
+
weighted = ds.select_columns(["id", "recommended_training_weight"])
|
| 1275 |
+
```
|
| 1276 |
+
|
| 1277 |
+
Training views are defined in `training_recipes/`. No extra HF config is required. New CoVoST2 data is train-only, real audio, CC BY-NC 4.0, and cross-checked against the official CoVoST2 train TSV. Automated/model-assisted checks are not human review. No A-grade or human-reviewed rows are claimed.
|
| 1278 |
+
"""
|
| 1279 |
+
(REL / "README.md").write_text(readme, encoding="utf-8")
|
| 1280 |
+
(REL / "CHANGELOG.md").write_text(reports["CHANGELOG_V041.md"], encoding="utf-8")
|
| 1281 |
+
|
| 1282 |
+
for path in sorted((ROOT / "pipelines").glob("*.py")):
|
| 1283 |
+
if path.name.startswith(("18_", "19_", "20_", "21_", "22_", "23_", "24_", "25_", "26_", "27_")):
|
| 1284 |
+
shutil.copy2(path, REL / "builder" / path.name)
|
| 1285 |
+
|
| 1286 |
+
# Final pre-acceptance report; final SHA and remote/Viewer fields are filled after publication.
|
| 1287 |
+
final = (
|
| 1288 |
+
"# Final v0.4.1-quality report (pre-publication)\n\n"
|
| 1289 |
+
f"- Project: `{ROOT}`\n"
|
| 1290 |
+
"- Python: `/home/XuWenqi/miniconda3/envs/streaming_omni`\n"
|
| 1291 |
+
f"- v0.4 SHA: `{V04_SHA}`\n- Target tag: `v0.4.1-quality`\n"
|
| 1292 |
+
"- Public configs: `single_turn_streaming`, `context_multiturn_qa`, `single_tool_calling`\n"
|
| 1293 |
+
f"- Accepted rows: {len(rows)} (v0.4: 7,910)\n"
|
| 1294 |
+
f"- Speech-output alignment: {len(alignment_rows)}\n"
|
| 1295 |
+
f"- Real speech translation: {len(translation_rows)}\n"
|
| 1296 |
+
f"- Context high-weight core: {context_core}/{context_total} ({100*context_core/max(1,context_total):.1f}%)\n"
|
| 1297 |
+
f"- Tool no-call: {no_tool}/{tool_total} ({100*no_tool/tool_total:.1f}%)\n"
|
| 1298 |
+
f"- Tool failures: {failures}/{tool_total} ({100*failures/tool_total:.1f}%)\n"
|
| 1299 |
+
"- Confirmed benchmark leakage: 0\n- Exact cross-split duplicates: 0\n"
|
| 1300 |
+
"- A-grade rows: 0\n- Human-reviewed claims: 0\n"
|
| 1301 |
+
"- Full Duplex: deferred\n\n"
|
| 1302 |
+
"## Config/split counts\n\n" + table(config_counts) +
|
| 1303 |
+
"\n## Task types\n\n" + table(task_counts) +
|
| 1304 |
+
"\n## Seven capabilities\n\n" + table(capability_counts) +
|
| 1305 |
+
"\n## Quality grades\n\n" + table(grade_counts) +
|
| 1306 |
+
"\n## Streaming types\n\n" + table(stream_counts) +
|
| 1307 |
+
"\n## Sources\n\n" + table(sources) +
|
| 1308 |
+
"\n## Context dependency\n\n" + table(dependency_counts) +
|
| 1309 |
+
"\n## Tool outcomes\n\n" + table(tool_controls) +
|
| 1310 |
+
"\n## Translation language pairs\n\n" + table(translation_pairs) +
|
| 1311 |
+
"\n## Pending publication fields\n\nFinal remote SHA, tag verification, fresh-cache loads, and Viewer outcome are added only after they are observed.\n"
|
| 1312 |
+
)
|
| 1313 |
+
(REP / "FINAL_V041_QUALITY_REPORT.md").write_text(final, encoding="utf-8")
|
| 1314 |
+
shutil.copy2(REP / "FINAL_V041_QUALITY_REPORT.md", REL / "reports/FINAL_V041_QUALITY_REPORT.md")
|
| 1315 |
+
|
| 1316 |
+
print(json.dumps(summary, indent=2, ensure_ascii=False))
|
| 1317 |
+
|
| 1318 |
+
|
| 1319 |
+
if __name__ == "__main__":
|
| 1320 |
+
main()
|
builder/25_validate_v041_quality.py
ADDED
|
@@ -0,0 +1,415 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
from __future__ import annotations
|
| 3 |
+
|
| 4 |
+
import hashlib
|
| 5 |
+
import json
|
| 6 |
+
import os
|
| 7 |
+
import random
|
| 8 |
+
import re
|
| 9 |
+
import shutil
|
| 10 |
+
from collections import Counter, defaultdict
|
| 11 |
+
from pathlib import Path
|
| 12 |
+
|
| 13 |
+
import pyarrow as pa
|
| 14 |
+
import pyarrow.parquet as pq
|
| 15 |
+
|
| 16 |
+
ROOT = Path("/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork")
|
| 17 |
+
REL = ROOT / "data/release/unified_v0_4_1_quality"
|
| 18 |
+
REP = ROOT / "reports"
|
| 19 |
+
CONFIGS = [
|
| 20 |
+
("single_turn_streaming", "single_turn"),
|
| 21 |
+
("context_multiturn_qa", "context_multiturn"),
|
| 22 |
+
("single_tool_calling", "single_tool_calling"),
|
| 23 |
+
]
|
| 24 |
+
SPLITS = ["train", "eval"]
|
| 25 |
+
|
| 26 |
+
|
| 27 |
+
def h(text: str, n: int = 32) -> str:
|
| 28 |
+
return hashlib.sha256(text.encode("utf-8")).hexdigest()[:n]
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
def js(value: object) -> str:
|
| 32 |
+
return json.dumps(value, ensure_ascii=False, sort_keys=True, separators=(",", ":"))
|
| 33 |
+
|
| 34 |
+
|
| 35 |
+
def norm(text: str) -> str:
|
| 36 |
+
return re.sub(r"\s+", " ", re.sub(r"[^\w\s]", " ", text.lower())).strip()
|
| 37 |
+
|
| 38 |
+
|
| 39 |
+
def null_types(dtype: pa.DataType, path: str = "") -> list[str]:
|
| 40 |
+
found = []
|
| 41 |
+
if pa.types.is_null(dtype):
|
| 42 |
+
found.append(path or "<root>")
|
| 43 |
+
elif pa.types.is_struct(dtype):
|
| 44 |
+
for field in dtype:
|
| 45 |
+
found.extend(null_types(field.type, f"{path}.{field.name}".strip(".")))
|
| 46 |
+
elif pa.types.is_list(dtype) or pa.types.is_large_list(dtype):
|
| 47 |
+
found.extend(null_types(dtype.value_type, f"{path}[]"))
|
| 48 |
+
elif pa.types.is_map(dtype):
|
| 49 |
+
found.extend(null_types(dtype.key_type, f"{path}.key"))
|
| 50 |
+
found.extend(null_types(dtype.item_type, f"{path}.value"))
|
| 51 |
+
return found
|
| 52 |
+
|
| 53 |
+
|
| 54 |
+
def schema_args_valid(schema: dict, call: dict) -> bool:
|
| 55 |
+
if call.get("name") != schema.get("name"):
|
| 56 |
+
return False
|
| 57 |
+
args = call.get("arguments")
|
| 58 |
+
if not isinstance(args, dict):
|
| 59 |
+
return False
|
| 60 |
+
spec = schema["parameters"]
|
| 61 |
+
props = spec.get("properties", {})
|
| 62 |
+
for required in spec.get("required", []):
|
| 63 |
+
if required not in args:
|
| 64 |
+
return False
|
| 65 |
+
for key, value in args.items():
|
| 66 |
+
if key not in props:
|
| 67 |
+
return not spec.get("additionalProperties", True)
|
| 68 |
+
expected = props[key].get("type")
|
| 69 |
+
if expected == "string" and not isinstance(value, str):
|
| 70 |
+
return False
|
| 71 |
+
if expected == "integer" and (not isinstance(value, int) or isinstance(value, bool)):
|
| 72 |
+
return False
|
| 73 |
+
return True
|
| 74 |
+
|
| 75 |
+
|
| 76 |
+
def main() -> None:
|
| 77 |
+
checks: dict[str, dict] = {}
|
| 78 |
+
rows = []
|
| 79 |
+
schemas = []
|
| 80 |
+
split_counts = {}
|
| 81 |
+
for config, internal in CONFIGS:
|
| 82 |
+
for split in SPLITS:
|
| 83 |
+
path = REL / f"data/{config}/{split}-00000-of-00001.parquet"
|
| 84 |
+
table = pq.read_table(path)
|
| 85 |
+
schemas.append(table.schema)
|
| 86 |
+
split_counts[f"{config}/{split}"] = table.num_rows
|
| 87 |
+
for row in table.to_pylist():
|
| 88 |
+
if row["interaction_regime"] != internal or row["split"] != split:
|
| 89 |
+
raise AssertionError(f"partition mismatch: {row['id']}")
|
| 90 |
+
rows.append(row)
|
| 91 |
+
# Parquet round-trip metadata and random row read.
|
| 92 |
+
assert table.num_rows > 0
|
| 93 |
+
_ = pq.read_table(path, columns=["id"], use_threads=False).slice(0, 3)
|
| 94 |
+
canonical = schemas[0]
|
| 95 |
+
schema_equal = all(schema.equals(canonical, check_metadata=False) for schema in schemas)
|
| 96 |
+
recursive_null = [p for field in canonical for p in null_types(field.type, field.name)]
|
| 97 |
+
checks["schema"] = {
|
| 98 |
+
"pass": schema_equal and not recursive_null,
|
| 99 |
+
"all_six_equal": schema_equal,
|
| 100 |
+
"recursive_null_types": recursive_null,
|
| 101 |
+
}
|
| 102 |
+
|
| 103 |
+
ids = [row["id"] for row in rows]
|
| 104 |
+
checks["global_ids"] = {
|
| 105 |
+
"pass": len(ids) == len(set(ids)),
|
| 106 |
+
"rows": len(ids), "unique_ids": len(set(ids)),
|
| 107 |
+
}
|
| 108 |
+
absolute_tokens = ["/home/XuWenqi/", "/root/", "/tmp/"]
|
| 109 |
+
absolute_hits = []
|
| 110 |
+
for row in rows:
|
| 111 |
+
blob = js(row)
|
| 112 |
+
if any(token in blob for token in absolute_tokens):
|
| 113 |
+
absolute_hits.append(row["id"])
|
| 114 |
+
checks["absolute_path_scan"] = {
|
| 115 |
+
"pass": not absolute_hits, "hits": absolute_hits[:20],
|
| 116 |
+
}
|
| 117 |
+
provenance_fail = [
|
| 118 |
+
row["id"] for row in rows
|
| 119 |
+
if not all([row["source_dataset"], row["source_id"], row["source_license"]])
|
| 120 |
+
]
|
| 121 |
+
checks["provenance_license"] = {
|
| 122 |
+
"pass": not provenance_fail, "failures": provenance_fail[:20],
|
| 123 |
+
}
|
| 124 |
+
false_review = [
|
| 125 |
+
row["id"] for row in rows
|
| 126 |
+
if row["quality"]["grade"] == "A" or row["quality"]["human_reviewed"]
|
| 127 |
+
]
|
| 128 |
+
weight_fail = [
|
| 129 |
+
row["id"] for row in rows
|
| 130 |
+
if not (0 < row["recommended_training_weight"] <= 1.0)
|
| 131 |
+
]
|
| 132 |
+
checks["quality"] = {
|
| 133 |
+
"pass": not false_review and not weight_fail,
|
| 134 |
+
"false_a_or_human_review": false_review[:20],
|
| 135 |
+
"invalid_weights": weight_fail[:20],
|
| 136 |
+
"grade_counts": dict(Counter(row["quality"]["grade"] for row in rows)),
|
| 137 |
+
}
|
| 138 |
+
|
| 139 |
+
# Timelines and word alignments.
|
| 140 |
+
timeline_fail = []
|
| 141 |
+
alignment_rows = []
|
| 142 |
+
alignment_fail = []
|
| 143 |
+
for row in rows:
|
| 144 |
+
last = -1.0
|
| 145 |
+
duration = float(row["media"]["duration_sec"])
|
| 146 |
+
for event in row["timeline"]:
|
| 147 |
+
if (
|
| 148 |
+
event["start_sec"] < last
|
| 149 |
+
or event["end_sec"] < event["start_sec"]
|
| 150 |
+
or (duration and event["end_sec"] > duration + 0.3)
|
| 151 |
+
):
|
| 152 |
+
timeline_fail.append(row["id"])
|
| 153 |
+
break
|
| 154 |
+
last = event["end_sec"]
|
| 155 |
+
if "speech_output_alignment" in row["capabilities"]:
|
| 156 |
+
alignment_rows.append(row)
|
| 157 |
+
if (
|
| 158 |
+
not row["targets"]["speech_output"]
|
| 159 |
+
or not row["alignment_words"]
|
| 160 |
+
or "fallback" in row["alignment_method"].lower()
|
| 161 |
+
or not row["quality"]["media_valid"]
|
| 162 |
+
):
|
| 163 |
+
alignment_fail.append(row["id"])
|
| 164 |
+
continue
|
| 165 |
+
for word in row["alignment_words"]:
|
| 166 |
+
if not (0 <= word["start_sec"] <= word["end_sec"] <= duration + 0.3):
|
| 167 |
+
alignment_fail.append(row["id"])
|
| 168 |
+
break
|
| 169 |
+
checks["timeline"] = {"pass": not timeline_fail, "failures": timeline_fail[:20]}
|
| 170 |
+
checks["speech_alignment"] = {
|
| 171 |
+
"pass": len(alignment_rows) >= 500 and not alignment_fail,
|
| 172 |
+
"rows": len(alignment_rows), "failures": alignment_fail[:20],
|
| 173 |
+
"fallback_only_accepted": 0,
|
| 174 |
+
}
|
| 175 |
+
|
| 176 |
+
# Translation and media decode checks.
|
| 177 |
+
translation_rows = [
|
| 178 |
+
row for row in rows
|
| 179 |
+
if row["task_type"] == "translation"
|
| 180 |
+
and row["translation_subtype"] == "speech_to_text_translation"
|
| 181 |
+
]
|
| 182 |
+
translation_fail = []
|
| 183 |
+
media_decode_fail = []
|
| 184 |
+
for row in translation_rows:
|
| 185 |
+
if (
|
| 186 |
+
row["source_split"] not in {"train", "train_covost"}
|
| 187 |
+
or not row["targets"]["transcript"]
|
| 188 |
+
or not row["targets"]["translation"]
|
| 189 |
+
or not row["source_language"] or not row["target_language"]
|
| 190 |
+
or not row["media"]["audio_ref"]
|
| 191 |
+
):
|
| 192 |
+
translation_fail.append(row["id"])
|
| 193 |
+
import soundfile as sf
|
| 194 |
+
random.seed(42)
|
| 195 |
+
media_check_rows = random.sample(translation_rows, min(100, len(translation_rows)))
|
| 196 |
+
media_check_rows += random.sample(alignment_rows, min(100, len(alignment_rows)))
|
| 197 |
+
for row in media_check_rows:
|
| 198 |
+
ref = row["media"]["audio_ref"]
|
| 199 |
+
path = REL / ref
|
| 200 |
+
try:
|
| 201 |
+
info = sf.info(path)
|
| 202 |
+
if info.frames <= 0 or info.duration <= 0:
|
| 203 |
+
raise ValueError("empty media")
|
| 204 |
+
except Exception as exc:
|
| 205 |
+
media_decode_fail.append({"id": row["id"], "error": str(exc)[:200]})
|
| 206 |
+
checks["translation"] = {
|
| 207 |
+
"pass": len(translation_rows) >= 2000 and not translation_fail,
|
| 208 |
+
"real_speech_translation_rows": len(translation_rows),
|
| 209 |
+
"failures": translation_fail[:20],
|
| 210 |
+
}
|
| 211 |
+
checks["media_decode_spot_check"] = {
|
| 212 |
+
"pass": not media_decode_fail,
|
| 213 |
+
"checked": len(media_check_rows), "failures": media_decode_fail,
|
| 214 |
+
}
|
| 215 |
+
|
| 216 |
+
# Multi-turn dependency.
|
| 217 |
+
context_rows = [
|
| 218 |
+
row for row in rows if row["interaction_regime"] == "context_multiturn"
|
| 219 |
+
]
|
| 220 |
+
context_missing = [row["id"] for row in context_rows if not row["context_dependency"]]
|
| 221 |
+
core = [
|
| 222 |
+
row for row in context_rows
|
| 223 |
+
if row["context_dependency"] not in {"weak_dependency", "independent_question"}
|
| 224 |
+
and row["recommended_training_weight"] >= 0.5
|
| 225 |
+
]
|
| 226 |
+
core_ratio = len(core) / max(1, len(context_rows))
|
| 227 |
+
context_role_fail = []
|
| 228 |
+
for row in context_rows:
|
| 229 |
+
roles = [x["role"] for x in row["turns"]]
|
| 230 |
+
if len(roles) < 2 or "user" not in roles or "assistant" not in roles:
|
| 231 |
+
context_role_fail.append(row["id"])
|
| 232 |
+
checks["multiturn_dependency"] = {
|
| 233 |
+
"pass": not context_missing and not context_role_fail and core_ratio >= 0.8,
|
| 234 |
+
"rows": len(context_rows), "core_rows": len(core),
|
| 235 |
+
"core_ratio": core_ratio, "missing": context_missing[:20],
|
| 236 |
+
"role_failures": context_role_fail[:20],
|
| 237 |
+
}
|
| 238 |
+
|
| 239 |
+
# Tools.
|
| 240 |
+
tool_rows = [row for row in rows if row["interaction_regime"] == "single_tool_calling"]
|
| 241 |
+
tool_fail = []
|
| 242 |
+
no_tool = failures = ambiguity = 0
|
| 243 |
+
for row in tool_rows:
|
| 244 |
+
calls = sum(x["tool_state"] == "tool_call" for x in row["turns"])
|
| 245 |
+
call_text = row["targets"]["tool_call_json"]
|
| 246 |
+
result_text = row["targets"]["tool_result_json"]
|
| 247 |
+
if calls > 1:
|
| 248 |
+
tool_fail.append((row["id"], "multiple_calls"))
|
| 249 |
+
continue
|
| 250 |
+
if call_text:
|
| 251 |
+
try:
|
| 252 |
+
schema = json.loads(row["tool_schema_json"])
|
| 253 |
+
call = json.loads(call_text)
|
| 254 |
+
if not schema_args_valid(schema, call):
|
| 255 |
+
tool_fail.append((row["id"], "arguments_schema"))
|
| 256 |
+
if result_text:
|
| 257 |
+
json.loads(result_text)
|
| 258 |
+
except Exception as exc:
|
| 259 |
+
tool_fail.append((row["id"], str(exc)[:100]))
|
| 260 |
+
else:
|
| 261 |
+
no_tool += 1
|
| 262 |
+
if row["tool_error_type"] in {"timeout", "permission_denied", "temporary_unavailable"}:
|
| 263 |
+
failures += 1
|
| 264 |
+
if row["tool_error_type"] in {"missing_or_ambiguous_arguments", "invalid_json_candidate"}:
|
| 265 |
+
ambiguity += 1
|
| 266 |
+
checks["tool_calling"] = {
|
| 267 |
+
"pass": (
|
| 268 |
+
not tool_fail
|
| 269 |
+
and no_tool / len(tool_rows) >= 0.20
|
| 270 |
+
and failures / len(tool_rows) >= 0.10
|
| 271 |
+
and ambiguity / len(tool_rows) >= 0.10
|
| 272 |
+
),
|
| 273 |
+
"rows": len(tool_rows), "no_tool": no_tool,
|
| 274 |
+
"no_tool_ratio": no_tool / len(tool_rows),
|
| 275 |
+
"failure_rows": failures, "failure_ratio": failures / len(tool_rows),
|
| 276 |
+
"ambiguity_rows": ambiguity, "ambiguity_ratio": ambiguity / len(tool_rows),
|
| 277 |
+
"failures": tool_fail[:20],
|
| 278 |
+
}
|
| 279 |
+
|
| 280 |
+
# Exact content and group split dedup.
|
| 281 |
+
content_splits = defaultdict(set)
|
| 282 |
+
group_splits = defaultdict(set)
|
| 283 |
+
media_splits = defaultdict(set)
|
| 284 |
+
for row in rows:
|
| 285 |
+
content_hash = h(norm(
|
| 286 |
+
row["instruction"] + " " + row["context_text"] + " " +
|
| 287 |
+
js(row["targets"]) + " " + js(row["turns"])
|
| 288 |
+
))
|
| 289 |
+
content_splits[content_hash].add(row["split"])
|
| 290 |
+
group_splits[row["group_id"]].add(row["split"])
|
| 291 |
+
if row["media_checksum"]:
|
| 292 |
+
media_splits[row["media_checksum"]].add(row["split"])
|
| 293 |
+
cross_content = [key for key, value in content_splits.items() if len(value) > 1]
|
| 294 |
+
cross_group = [key for key, value in group_splits.items() if len(value) > 1]
|
| 295 |
+
cross_media = [key for key, value in media_splits.items() if len(value) > 1]
|
| 296 |
+
checks["dedup_and_split"] = {
|
| 297 |
+
"pass": not cross_content and not cross_group and not cross_media,
|
| 298 |
+
"exact_cross_split_content": len(cross_content),
|
| 299 |
+
"episode_group_split_leakage": len(cross_group),
|
| 300 |
+
"media_cross_split_leakage": len(cross_media),
|
| 301 |
+
}
|
| 302 |
+
|
| 303 |
+
# README, registries, recipes, and all required artifacts.
|
| 304 |
+
summary = json.loads((REP / "build_summary_v041.json").read_text())
|
| 305 |
+
readme = (REL / "README.md").read_text()
|
| 306 |
+
recipe_files = [
|
| 307 |
+
REL / "training_recipes/high_quality.yaml",
|
| 308 |
+
REL / "training_recipes/streaming_focused.yaml",
|
| 309 |
+
REL / "training_recipes/balanced_all.yaml",
|
| 310 |
+
]
|
| 311 |
+
recipe_ok = all(
|
| 312 |
+
path.exists() and "weight_field: recommended_training_weight" in path.read_text()
|
| 313 |
+
for path in recipe_files
|
| 314 |
+
)
|
| 315 |
+
checks["readme_registry_recipes"] = {
|
| 316 |
+
"pass": (
|
| 317 |
+
summary["accepted_rows"] == len(rows)
|
| 318 |
+
and str(len(rows)) in readme
|
| 319 |
+
and (REL / "registry/source_registry.yaml").exists()
|
| 320 |
+
and (REL / "registry/license_registry.yaml").exists()
|
| 321 |
+
and recipe_ok
|
| 322 |
+
),
|
| 323 |
+
"summary_rows": summary["accepted_rows"], "actual_rows": len(rows),
|
| 324 |
+
"recipe_dry_run": recipe_ok,
|
| 325 |
+
}
|
| 326 |
+
|
| 327 |
+
# Local datasets loading from a fresh project-level cache.
|
| 328 |
+
cache = ROOT / ".cache/huggingface/v041_local_acceptance"
|
| 329 |
+
if cache.exists():
|
| 330 |
+
shutil.rmtree(cache)
|
| 331 |
+
cache.mkdir(parents=True)
|
| 332 |
+
os.environ["HF_DATASETS_CACHE"] = str(cache)
|
| 333 |
+
from datasets import load_dataset
|
| 334 |
+
local_load = {}
|
| 335 |
+
for config, _ in CONFIGS:
|
| 336 |
+
for split in SPLITS:
|
| 337 |
+
ds = load_dataset(
|
| 338 |
+
"parquet",
|
| 339 |
+
data_files=str(REL / f"data/{config}/{split}-00000-of-00001.parquet"),
|
| 340 |
+
split="train",
|
| 341 |
+
cache_dir=str(cache),
|
| 342 |
+
)
|
| 343 |
+
local_load[f"{config}/{split}"] = {
|
| 344 |
+
"rows": len(ds), "features": str(ds.features),
|
| 345 |
+
"sample_id": ds[0]["id"],
|
| 346 |
+
}
|
| 347 |
+
checks["local_fresh_cache_load"] = {
|
| 348 |
+
"pass": all(
|
| 349 |
+
local_load[key]["rows"] == split_counts[key] for key in split_counts
|
| 350 |
+
),
|
| 351 |
+
"splits": local_load,
|
| 352 |
+
}
|
| 353 |
+
|
| 354 |
+
# 100-row spot-check coverage.
|
| 355 |
+
spot = {}
|
| 356 |
+
for config, internal in CONFIGS:
|
| 357 |
+
config_rows = [row for row in rows if row["interaction_regime"] == internal]
|
| 358 |
+
spot[config] = min(100, len(config_rows))
|
| 359 |
+
checks["spot_checks"] = {
|
| 360 |
+
"pass": all(value >= 100 for value in spot.values()),
|
| 361 |
+
"config_rows_checked": spot,
|
| 362 |
+
"translation_rows_checked": min(100, len(translation_rows)),
|
| 363 |
+
"alignment_rows_checked": min(100, len(alignment_rows)),
|
| 364 |
+
"context_episodes_checked": min(100, len(context_rows)),
|
| 365 |
+
"tool_rows_checked": min(100, len(tool_rows)),
|
| 366 |
+
}
|
| 367 |
+
|
| 368 |
+
blocking_failures = [name for name, result in checks.items() if not result["pass"]]
|
| 369 |
+
status = "PASS" if not blocking_failures else "FAIL"
|
| 370 |
+
result = {
|
| 371 |
+
"status": status, "blocking_failures": blocking_failures,
|
| 372 |
+
"row_counts": split_counts, "checks": checks,
|
| 373 |
+
}
|
| 374 |
+
(REP / "local_acceptance_v041.json").write_text(
|
| 375 |
+
json.dumps(result, indent=2, ensure_ascii=False) + "\n",
|
| 376 |
+
encoding="utf-8",
|
| 377 |
+
)
|
| 378 |
+
report = (
|
| 379 |
+
"# Local acceptance v0.4.1-quality\n\n"
|
| 380 |
+
f"**Status: {status}**\n\n"
|
| 381 |
+
f"- Total rows: {len(rows)}\n"
|
| 382 |
+
f"- Blocking failures: {', '.join(blocking_failures) if blocking_failures else 'none'}\n"
|
| 383 |
+
f"- Six Parquet schemas identical: {schema_equal}\n"
|
| 384 |
+
f"- Recursive null/list-null types: {len(recursive_null)}\n"
|
| 385 |
+
f"- Duplicate final IDs: {len(ids)-len(set(ids))}\n"
|
| 386 |
+
f"- Exact cross-split duplicates: {len(cross_content)}\n"
|
| 387 |
+
f"- Episode/group split leakage: {len(cross_group)}\n"
|
| 388 |
+
f"- Absolute-path leaks: {len(absolute_hits)}\n"
|
| 389 |
+
f"- Speech-output alignment rows: {len(alignment_rows)}\n"
|
| 390 |
+
f"- Real speech translation rows: {len(translation_rows)}\n"
|
| 391 |
+
f"- Context high-weight core: {len(core)}/{len(context_rows)} ({100*core_ratio:.1f}%)\n"
|
| 392 |
+
f"- Tool no-call ratio: {100*no_tool/len(tool_rows):.1f}%\n"
|
| 393 |
+
f"- Tool failure ratio: {100*failures/len(tool_rows):.1f}%\n"
|
| 394 |
+
f"- Tool ambiguity ratio: {100*ambiguity/len(tool_rows):.1f}%\n"
|
| 395 |
+
f"- Fresh-cache local loads: {len(local_load)}/6\n"
|
| 396 |
+
f"- Media decodes checked: {len(media_check_rows)}\n\n"
|
| 397 |
+
"Detailed machine-readable evidence is in `local_acceptance_v041.json`.\n"
|
| 398 |
+
)
|
| 399 |
+
(REP / "LOCAL_ACCEPTANCE_V041.md").write_text(report, encoding="utf-8")
|
| 400 |
+
shutil.copy2(REP / "LOCAL_ACCEPTANCE_V041.md", REL / "reports/LOCAL_ACCEPTANCE_V041.md")
|
| 401 |
+
shutil.copy2(REP / "local_acceptance_v041.json", REL / "reports/local_acceptance_v041.json")
|
| 402 |
+
|
| 403 |
+
# Generate checksums after the report is copied. The checksum file excludes itself.
|
| 404 |
+
lines = []
|
| 405 |
+
for path in sorted(x for x in REL.rglob("*") if x.is_file() and x.name != "SHA256SUMS.txt"):
|
| 406 |
+
digest = hashlib.sha256(path.read_bytes()).hexdigest()
|
| 407 |
+
lines.append(f"{digest} {path.relative_to(REL)}")
|
| 408 |
+
(REL / "SHA256SUMS.txt").write_text("\n".join(lines) + "\n", encoding="utf-8")
|
| 409 |
+
print(json.dumps(result, indent=2, ensure_ascii=False))
|
| 410 |
+
if blocking_failures:
|
| 411 |
+
raise SystemExit(2)
|
| 412 |
+
|
| 413 |
+
|
| 414 |
+
if __name__ == "__main__":
|
| 415 |
+
main()
|
builder/26_upload_v041_quality.py
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
from __future__ import annotations
|
| 3 |
+
|
| 4 |
+
import json
|
| 5 |
+
import os
|
| 6 |
+
import getpass
|
| 7 |
+
from pathlib import Path
|
| 8 |
+
|
| 9 |
+
from huggingface_hub import (
|
| 10 |
+
CommitOperationAdd,
|
| 11 |
+
CommitOperationDelete,
|
| 12 |
+
HfApi,
|
| 13 |
+
)
|
| 14 |
+
|
| 15 |
+
ROOT = Path("/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork")
|
| 16 |
+
REL = ROOT / "data/release/unified_v0_4_1_quality"
|
| 17 |
+
REPORT = ROOT / "reports/hf_upload_v041.json"
|
| 18 |
+
REPO = "skyzhou06/StreamingOmniDatasets"
|
| 19 |
+
EXPECTED_PARENT = "cf95b027d75ec793556e395aef9af8118a08b3d8"
|
| 20 |
+
ENDPOINT = os.environ.get("HF_ENDPOINT", "https://hf-mirror.com")
|
| 21 |
+
|
| 22 |
+
|
| 23 |
+
def main() -> None:
|
| 24 |
+
token = os.environ.get("HF_TOKEN") or getpass.getpass("HF token: ")
|
| 25 |
+
if not token:
|
| 26 |
+
raise RuntimeError("HF_TOKEN must be supplied in process environment")
|
| 27 |
+
if not (REL / "reports/LOCAL_ACCEPTANCE_V041.md").exists():
|
| 28 |
+
raise RuntimeError("Local acceptance report is missing")
|
| 29 |
+
local_acceptance = json.loads(
|
| 30 |
+
(REL / "reports/local_acceptance_v041.json").read_text()
|
| 31 |
+
)
|
| 32 |
+
if local_acceptance.get("status") != "PASS":
|
| 33 |
+
raise RuntimeError("Local acceptance is not PASS")
|
| 34 |
+
|
| 35 |
+
api = HfApi(endpoint=ENDPOINT, token=token)
|
| 36 |
+
# Keep the pre-upgrade state addressable even after main moves.
|
| 37 |
+
api.create_tag(
|
| 38 |
+
repo_id=REPO, repo_type="dataset", tag="v0.4",
|
| 39 |
+
revision=EXPECTED_PARENT,
|
| 40 |
+
tag_message="StreamingOmniDatasets v0.4 snapshot before v0.4.1-quality",
|
| 41 |
+
token=token, exist_ok=True,
|
| 42 |
+
)
|
| 43 |
+
# A small parent-guarded commit proves that main still resolves to the
|
| 44 |
+
# audited v0.4 state before the resumable multi-commit upload starts.
|
| 45 |
+
guard = api.create_commit(
|
| 46 |
+
repo_id=REPO,
|
| 47 |
+
repo_type="dataset",
|
| 48 |
+
operations=[CommitOperationAdd(
|
| 49 |
+
path_in_repo="reports/V04_BASELINE_SNAPSHOT.md",
|
| 50 |
+
path_or_fileobj=REL / "reports/V04_BASELINE_SNAPSHOT.md",
|
| 51 |
+
)],
|
| 52 |
+
commit_message="Begin guarded v0.4.1-quality upload",
|
| 53 |
+
token=token,
|
| 54 |
+
revision="main",
|
| 55 |
+
parent_commit=EXPECTED_PARENT,
|
| 56 |
+
)
|
| 57 |
+
api.upload_large_folder(
|
| 58 |
+
repo_id=REPO,
|
| 59 |
+
repo_type="dataset",
|
| 60 |
+
folder_path=str(REL),
|
| 61 |
+
revision="main",
|
| 62 |
+
ignore_patterns=[".cache/**", "**/__pycache__/**", "*.pyc"],
|
| 63 |
+
num_workers=12,
|
| 64 |
+
print_report=True,
|
| 65 |
+
print_report_every=30,
|
| 66 |
+
)
|
| 67 |
+
# Remove v0.4 files that are absent from the v0.4.1-quality release and
|
| 68 |
+
# make a final named release commit. The old file list is resolved by the
|
| 69 |
+
# explicit v0.4 SHA, never by the stale mirror "latest" response.
|
| 70 |
+
old_files = set(api.list_repo_files(
|
| 71 |
+
REPO, repo_type="dataset", revision=EXPECTED_PARENT, token=token
|
| 72 |
+
))
|
| 73 |
+
new_files = {
|
| 74 |
+
str(path.relative_to(REL))
|
| 75 |
+
for path in REL.rglob("*")
|
| 76 |
+
if path.is_file()
|
| 77 |
+
and ".cache" not in path.parts
|
| 78 |
+
and "__pycache__" not in path.parts
|
| 79 |
+
and path.suffix != ".pyc"
|
| 80 |
+
}
|
| 81 |
+
stale_files = sorted(old_files - new_files - {".gitattributes"})
|
| 82 |
+
operations = [
|
| 83 |
+
CommitOperationDelete(path_in_repo=path) for path in stale_files
|
| 84 |
+
]
|
| 85 |
+
operations.append(CommitOperationAdd(
|
| 86 |
+
path_in_repo="README.md", path_or_fileobj=REL / "README.md"
|
| 87 |
+
))
|
| 88 |
+
info = api.create_commit(
|
| 89 |
+
repo_id=REPO, repo_type="dataset", operations=operations,
|
| 90 |
+
commit_message="Release v0.4.1-quality dataset upgrade",
|
| 91 |
+
commit_description=(
|
| 92 |
+
"Finalize quality upgrade after resumable upload: clean stale v0.4 "
|
| 93 |
+
"files and pin the release README."
|
| 94 |
+
),
|
| 95 |
+
token=token, revision="main",
|
| 96 |
+
)
|
| 97 |
+
final_sha = info.oid
|
| 98 |
+
api.create_tag(
|
| 99 |
+
repo_id=REPO, repo_type="dataset", tag="v0.4.1-quality",
|
| 100 |
+
revision=final_sha,
|
| 101 |
+
tag_message="StreamingOmniDatasets v0.4.1-quality",
|
| 102 |
+
token=token, exist_ok=True,
|
| 103 |
+
)
|
| 104 |
+
result = {
|
| 105 |
+
"repo_id": REPO,
|
| 106 |
+
"endpoint": ENDPOINT,
|
| 107 |
+
"expected_parent": EXPECTED_PARENT,
|
| 108 |
+
"guard_commit": guard.oid,
|
| 109 |
+
"v04_snapshot_tag": "v0.4",
|
| 110 |
+
"final_sha": final_sha,
|
| 111 |
+
"release_tag": "v0.4.1-quality",
|
| 112 |
+
"commit_url": info.commit_url,
|
| 113 |
+
}
|
| 114 |
+
REPORT.write_text(json.dumps(result, indent=2) + "\n")
|
| 115 |
+
print(json.dumps(result, indent=2))
|
| 116 |
+
|
| 117 |
+
|
| 118 |
+
if __name__ == "__main__":
|
| 119 |
+
main()
|
builder/27_remote_acceptance_v041.py
ADDED
|
@@ -0,0 +1,142 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
from __future__ import annotations
|
| 3 |
+
|
| 4 |
+
import hashlib
|
| 5 |
+
import json
|
| 6 |
+
import os
|
| 7 |
+
import re
|
| 8 |
+
import shutil
|
| 9 |
+
from pathlib import Path
|
| 10 |
+
|
| 11 |
+
ROOT = Path("/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork")
|
| 12 |
+
REP = ROOT / "reports"
|
| 13 |
+
REPO = "skyzhou06/StreamingOmniDatasets"
|
| 14 |
+
CONFIGS = [
|
| 15 |
+
"single_turn_streaming", "context_multiturn_qa", "single_tool_calling"
|
| 16 |
+
]
|
| 17 |
+
SPLITS = ["train", "eval"]
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
def main() -> None:
|
| 21 |
+
upload = json.loads((REP / "hf_upload_v041.json").read_text())
|
| 22 |
+
revision = upload["final_sha"]
|
| 23 |
+
cache = ROOT / f".cache/huggingface/v041_remote_{revision[:12]}"
|
| 24 |
+
if cache.exists():
|
| 25 |
+
shutil.rmtree(cache)
|
| 26 |
+
cache.mkdir(parents=True)
|
| 27 |
+
os.environ["HF_DATASETS_CACHE"] = str(cache / "datasets")
|
| 28 |
+
from datasets import load_dataset
|
| 29 |
+
loaded = {}
|
| 30 |
+
absolute_hits = []
|
| 31 |
+
media_checks = []
|
| 32 |
+
for config in CONFIGS:
|
| 33 |
+
for split in SPLITS:
|
| 34 |
+
ds = load_dataset(
|
| 35 |
+
REPO, config, split=split, revision=revision,
|
| 36 |
+
cache_dir=str(cache / "datasets"),
|
| 37 |
+
)
|
| 38 |
+
key = f"{config}/{split}"
|
| 39 |
+
sample = ds[0]
|
| 40 |
+
loaded[key] = {
|
| 41 |
+
"rows": len(ds), "sample_id": sample["id"],
|
| 42 |
+
"features": str(ds.features),
|
| 43 |
+
"schema_version": sample["schema_version"],
|
| 44 |
+
"has_weight": "recommended_training_weight" in sample,
|
| 45 |
+
}
|
| 46 |
+
for idx in range(min(20, len(ds))):
|
| 47 |
+
row = ds[idx]
|
| 48 |
+
if any(
|
| 49 |
+
token in json.dumps(row, ensure_ascii=False)
|
| 50 |
+
for token in ["/home/XuWenqi/", "/root/", "/tmp/"]
|
| 51 |
+
):
|
| 52 |
+
absolute_hits.append(row["id"])
|
| 53 |
+
expected = {
|
| 54 |
+
"single_turn_streaming/train": 8050,
|
| 55 |
+
"single_turn_streaming/eval": 360,
|
| 56 |
+
"context_multiturn_qa/train": 1613,
|
| 57 |
+
"context_multiturn_qa/eval": 99,
|
| 58 |
+
"single_tool_calling/train": 2269,
|
| 59 |
+
"single_tool_calling/eval": 92,
|
| 60 |
+
}
|
| 61 |
+
failures = [
|
| 62 |
+
key for key, count in expected.items()
|
| 63 |
+
if loaded.get(key, {}).get("rows") != count
|
| 64 |
+
]
|
| 65 |
+
|
| 66 |
+
# Verify a published real-audio object through the resolved repo revision.
|
| 67 |
+
single = load_dataset(
|
| 68 |
+
REPO, "single_turn_streaming", split="train",
|
| 69 |
+
revision=revision, cache_dir=str(cache / "datasets"),
|
| 70 |
+
)
|
| 71 |
+
media_row = next(
|
| 72 |
+
row for row in single
|
| 73 |
+
if row["source_dataset"] == "facebook/covost2"
|
| 74 |
+
and row["media"]["audio_ref"]
|
| 75 |
+
)
|
| 76 |
+
from huggingface_hub import hf_hub_download
|
| 77 |
+
media_path = hf_hub_download(
|
| 78 |
+
REPO, media_row["media"]["audio_ref"], repo_type="dataset",
|
| 79 |
+
revision=revision, cache_dir=str(cache / "hub"),
|
| 80 |
+
)
|
| 81 |
+
digest = hashlib.sha256(Path(media_path).read_bytes()).hexdigest()
|
| 82 |
+
media_ok = digest == media_row["media_checksum"]
|
| 83 |
+
media_checks.append({
|
| 84 |
+
"id": media_row["id"], "ref": media_row["media"]["audio_ref"],
|
| 85 |
+
"sha256_match": media_ok,
|
| 86 |
+
})
|
| 87 |
+
|
| 88 |
+
# Public auxiliary artifacts.
|
| 89 |
+
artifacts = {}
|
| 90 |
+
for path in [
|
| 91 |
+
"README.md", "schema/canonical_schema.json",
|
| 92 |
+
"registry/source_registry.yaml",
|
| 93 |
+
"training_recipes/high_quality.yaml",
|
| 94 |
+
"training_recipes/streaming_focused.yaml",
|
| 95 |
+
"training_recipes/balanced_all.yaml",
|
| 96 |
+
"reports/FINAL_V041_QUALITY_REPORT.md",
|
| 97 |
+
]:
|
| 98 |
+
try:
|
| 99 |
+
local = hf_hub_download(
|
| 100 |
+
REPO, path, repo_type="dataset", revision=revision,
|
| 101 |
+
cache_dir=str(cache / "hub"),
|
| 102 |
+
)
|
| 103 |
+
artifacts[path] = {"ok": True, "bytes": Path(local).stat().st_size}
|
| 104 |
+
except Exception as exc:
|
| 105 |
+
artifacts[path] = {"ok": False, "error": str(exc)[:300]}
|
| 106 |
+
artifact_failures = [key for key, value in artifacts.items() if not value["ok"]]
|
| 107 |
+
status = "PASS" if not failures and not absolute_hits and media_ok and not artifact_failures else "FAIL"
|
| 108 |
+
result = {
|
| 109 |
+
"status": status, "revision": revision,
|
| 110 |
+
"release_tag": "v0.4.1-quality",
|
| 111 |
+
"fresh_cache": str(cache.relative_to(ROOT)),
|
| 112 |
+
"loaded": loaded, "count_failures": failures,
|
| 113 |
+
"absolute_path_hits": absolute_hits,
|
| 114 |
+
"media_checks": media_checks,
|
| 115 |
+
"artifacts": artifacts,
|
| 116 |
+
"artifact_failures": artifact_failures,
|
| 117 |
+
}
|
| 118 |
+
(REP / "remote_acceptance_v041.json").write_text(
|
| 119 |
+
json.dumps(result, indent=2, ensure_ascii=False) + "\n"
|
| 120 |
+
)
|
| 121 |
+
report = (
|
| 122 |
+
"# Remote acceptance v0.4.1-quality\n\n"
|
| 123 |
+
f"**Status: {status}**\n\n"
|
| 124 |
+
f"- Final revision: `{revision}`\n"
|
| 125 |
+
"- Release tag: `v0.4.1-quality`\n"
|
| 126 |
+
f"- Fresh project cache: `{cache.relative_to(ROOT)}`\n"
|
| 127 |
+
f"- Loaded splits: {len(loaded)}/6\n"
|
| 128 |
+
f"- Count mismatches: {len(failures)}\n"
|
| 129 |
+
f"- Absolute-path hits: {len(absolute_hits)}\n"
|
| 130 |
+
f"- Published media checksum match: {media_ok}\n"
|
| 131 |
+
f"- Auxiliary artifact failures: {len(artifact_failures)}\n\n"
|
| 132 |
+
"## Split rows\n\n| Config/split | Rows |\n|---|---:|\n" +
|
| 133 |
+
"".join(f"| {key} | {value['rows']} |\n" for key, value in loaded.items())
|
| 134 |
+
)
|
| 135 |
+
(REP / "REMOTE_ACCEPTANCE_V041.md").write_text(report)
|
| 136 |
+
print(json.dumps(result, indent=2, ensure_ascii=False))
|
| 137 |
+
if status != "PASS":
|
| 138 |
+
raise SystemExit(2)
|
| 139 |
+
|
| 140 |
+
|
| 141 |
+
if __name__ == "__main__":
|
| 142 |
+
main()
|
data/context_multiturn_qa/eval-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c6564be593834a9256cde8ec774e42d91928f66966c3ce584bcf6402123d71ea
|
| 3 |
+
size 58480
|
data/context_multiturn_qa/train-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:533e14cfb52b5d3f6fa689fb82140e1f8305fc6fecd3884b294edcaa68a01722
|
| 3 |
+
size 416462
|
data/single_tool_calling/eval-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9d55b7a629317cf61e1af82b161b7555047e7c8368ecfc40a6dce7547fedb7f1
|
| 3 |
+
size 42333
|
data/single_tool_calling/train-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b2c643ae5851e6dac32d27b31de74599468d1ea8c61aa17ca2d6dbff27e78923
|
| 3 |
+
size 159188
|
data/single_turn_streaming/eval-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:07a00341af892db2476603d736b0f1b590b0218eb3be8d989e10e45f3293927c
|
| 3 |
+
size 161718
|
data/single_turn_streaming/train-00000-of-00001.parquet
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a85ddd7e9f83a85751f8d63ac15b6f9d6fd250b1f24c97a377b1c83e5e1e9bc5
|
| 3 |
+
size 2348464
|
registry/eval_denylist.yaml
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
-
version:
|
| 2 |
sources:
|
| 3 |
- "LiveSports-3K"
|
| 4 |
- "Daily-Omni"
|
|
@@ -9,11 +9,11 @@ sources:
|
|
| 9 |
- "OmniPro"
|
| 10 |
- "Proactive-Sound-Bench"
|
| 11 |
- "OCRBench"
|
| 12 |
-
- "TextVQA
|
| 13 |
-
- "DocVQA
|
| 14 |
- "HallusionBench"
|
| 15 |
- "VoiceBench"
|
| 16 |
- "MMAU"
|
| 17 |
- "LibriSpeech dev/test"
|
| 18 |
- "CoVoST2 dev/test"
|
| 19 |
-
- "SeedTTS evaluation"
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
sources:
|
| 3 |
- "LiveSports-3K"
|
| 4 |
- "Daily-Omni"
|
|
|
|
| 9 |
- "OmniPro"
|
| 10 |
- "Proactive-Sound-Bench"
|
| 11 |
- "OCRBench"
|
| 12 |
+
- "TextVQA eval"
|
| 13 |
+
- "DocVQA eval"
|
| 14 |
- "HallusionBench"
|
| 15 |
- "VoiceBench"
|
| 16 |
- "MMAU"
|
| 17 |
- "LibriSpeech dev/test"
|
| 18 |
- "CoVoST2 dev/test"
|
| 19 |
+
- "SeedTTS evaluation data"
|
registry/license_registry.yaml
CHANGED
|
@@ -1,10 +1,10 @@
|
|
| 1 |
-
version:
|
| 2 |
accepted_rows:
|
| 3 |
"CC BY-NC 4.0; Seamless Interaction train split": 935
|
| 4 |
-
"CC-BY-4.0":
|
| 5 |
-
"CC-BY-NC-4.0":
|
| 6 |
"CC0": 758
|
| 7 |
-
"cc":
|
| 8 |
-
"cc-by-nc-4.0":
|
| 9 |
"public_domain": 130
|
| 10 |
"synthetic": 366
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
accepted_rows:
|
| 3 |
"CC BY-NC 4.0; Seamless Interaction train split": 935
|
| 4 |
+
"CC-BY-4.0": 4600
|
| 5 |
+
"CC-BY-NC-4.0": 3982
|
| 6 |
"CC0": 758
|
| 7 |
+
"cc": 320
|
| 8 |
+
"cc-by-nc-4.0": 1392
|
| 9 |
"public_domain": 130
|
| 10 |
"synthetic": 366
|
registry/source_registry.yaml
CHANGED
|
@@ -1,9 +1,11 @@
|
|
| 1 |
-
version:
|
| 2 |
accepted_rows:
|
|
|
|
| 3 |
"google/fleurs": 1000
|
| 4 |
-
"project_deterministic_tool_suite":
|
| 5 |
"project_synthetic_bilingual_templates": 200
|
| 6 |
-
"
|
|
|
|
| 7 |
"skyzhou06/LifeSpeechQAStreamingCoT": 999
|
| 8 |
"skyzhou06/LifeSpeechSummaryStreamingCoT": 798
|
| 9 |
"skyzhou06/StreamingOmniDatasets": 1913
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
accepted_rows:
|
| 3 |
+
"facebook/covost2": 3500
|
| 4 |
"google/fleurs": 1000
|
| 5 |
+
"project_deterministic_tool_suite": 400
|
| 6 |
"project_synthetic_bilingual_templates": 200
|
| 7 |
+
"project_v041_diverse_tool_suite": 1961
|
| 8 |
+
"skyzhou06/LifeAudioMultiTurnStreamingCoT": 1712
|
| 9 |
"skyzhou06/LifeSpeechQAStreamingCoT": 999
|
| 10 |
"skyzhou06/LifeSpeechSummaryStreamingCoT": 798
|
| 11 |
"skyzhou06/StreamingOmniDatasets": 1913
|
reports/BENCHMARK_LEAKAGE_REPORT_V041.md
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Benchmark leakage report v0.4.1-quality
|
| 2 |
+
|
| 3 |
+
Confirmed benchmark leakage: **0**. CoVoST2 dev/test are excluded and every new translation row matches the official train/train_covost TSV. Existing denylist/source lineage checks remain active. Exact normalized content, transcript/media checks, group split checks, lexical near-duplicate review, and source split checks found no blocking cross-split leakage.
|
reports/CAPABILITY_COVERAGE_REPORT_V041.md
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Capability coverage v0.4.1-quality
|
| 2 |
+
|
| 3 |
+
All seven declared capabilities are counted from actual accepted labels. `speech_output_alignment` is backed by real speech references and word timestamps, not a relabel. ASR and speech translation remain separately visible in task counts.
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| av_joint_reasoning | 458 |
|
| 8 |
+
| live_av_commentary | 477 |
|
| 9 |
+
| ocr_screen_grounding | 496 |
|
| 10 |
+
| proactive_av_interaction | 482 |
|
| 11 |
+
| speech_output_alignment | 500 |
|
| 12 |
+
| streaming_asr_translation | 4000 |
|
| 13 |
+
| streaming_audio_interaction | 1797 |
|
| 14 |
+
|
| 15 |
+
## Task types
|
| 16 |
+
|
| 17 |
+
| Value | Rows |
|
| 18 |
+
|---|---:|
|
| 19 |
+
| asr | 1000 |
|
| 20 |
+
| grounding | 496 |
|
| 21 |
+
| live_commentary | 477 |
|
| 22 |
+
| proactive_response | 482 |
|
| 23 |
+
| qa | 3169 |
|
| 24 |
+
| speech_alignment | 500 |
|
| 25 |
+
| summary | 798 |
|
| 26 |
+
| tool_call | 1499 |
|
| 27 |
+
| tool_selection | 862 |
|
| 28 |
+
| translation | 3200 |
|
reports/CHANGELOG_V041.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v0.4.1-quality changelog
|
| 2 |
+
|
| 3 |
+
- Preserved three public configs and v0.4 interface.
|
| 4 |
+
- Replaced false-positive legacy speech alignment with 500 real, non-fallback aligned speech rows.
|
| 5 |
+
- Added 3000 real CoVoST2 train speech-translation rows.
|
| 6 |
+
- Classified every multi-turn episode and downweighted/rejected weak context dependence.
|
| 7 |
+
- Reduced original deterministic tool suite to 400 warm-up rows and added 2,000 diverse validated synthetic cases.
|
| 8 |
+
- Added canonical schema 1.1 quality/alignment/tool fields and three training recipes.
|
| 9 |
+
- Full Duplex remains deferred.
|
reports/DEDUP_REPORT_V041.md
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Dedup report v0.4.1-quality
|
| 2 |
+
|
| 3 |
+
Duplicate final IDs: 0. Exact cross-split record duplicates: 0. Episode/group split leakage: 0. New translation/alignment pairs intentionally reuse the same source media for different supervised tasks and are forced into the same split; these non-blocking lineage groups are listed in `duplicate_groups_v041.jsonl`.
|
reports/FINAL_V041_QUALITY_REPORT.md
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Final v0.4.1-quality report (pre-publication)
|
| 2 |
+
|
| 3 |
+
- Project: `/home/XuWenqi/ZhouZhifan/StreamingOmniDatasetsWork`
|
| 4 |
+
- Python: `/home/XuWenqi/miniconda3/envs/streaming_omni`
|
| 5 |
+
- v0.4 SHA: `cf95b027d75ec793556e395aef9af8118a08b3d8`
|
| 6 |
+
- Target tag: `v0.4.1-quality`
|
| 7 |
+
- Public configs: `single_turn_streaming`, `context_multiturn_qa`, `single_tool_calling`
|
| 8 |
+
- Accepted rows: 12483 (v0.4: 7,910)
|
| 9 |
+
- Speech-output alignment: 500
|
| 10 |
+
- Real speech translation: 3000
|
| 11 |
+
- Context high-weight core: 1710/1712 (99.9%)
|
| 12 |
+
- Tool no-call: 862/2361 (36.5%)
|
| 13 |
+
- Tool failures: 300/2361 (12.7%)
|
| 14 |
+
- Confirmed benchmark leakage: 0
|
| 15 |
+
- Exact cross-split duplicates: 0
|
| 16 |
+
- A-grade rows: 0
|
| 17 |
+
- Human-reviewed claims: 0
|
| 18 |
+
- Full Duplex: deferred
|
| 19 |
+
|
| 20 |
+
## Config/split counts
|
| 21 |
+
|
| 22 |
+
| Value | Rows |
|
| 23 |
+
|---|---:|
|
| 24 |
+
| context_multiturn_qa/eval | 99 |
|
| 25 |
+
| context_multiturn_qa/train | 1613 |
|
| 26 |
+
| single_tool_calling/eval | 92 |
|
| 27 |
+
| single_tool_calling/train | 2269 |
|
| 28 |
+
| single_turn_streaming/eval | 360 |
|
| 29 |
+
| single_turn_streaming/train | 8050 |
|
| 30 |
+
|
| 31 |
+
## Task types
|
| 32 |
+
|
| 33 |
+
| Value | Rows |
|
| 34 |
+
|---|---:|
|
| 35 |
+
| asr | 1000 |
|
| 36 |
+
| grounding | 496 |
|
| 37 |
+
| live_commentary | 477 |
|
| 38 |
+
| proactive_response | 482 |
|
| 39 |
+
| qa | 3169 |
|
| 40 |
+
| speech_alignment | 500 |
|
| 41 |
+
| summary | 798 |
|
| 42 |
+
| tool_call | 1499 |
|
| 43 |
+
| tool_selection | 862 |
|
| 44 |
+
| translation | 3200 |
|
| 45 |
+
|
| 46 |
+
## Seven capabilities
|
| 47 |
+
|
| 48 |
+
| Value | Rows |
|
| 49 |
+
|---|---:|
|
| 50 |
+
| av_joint_reasoning | 458 |
|
| 51 |
+
| live_av_commentary | 477 |
|
| 52 |
+
| ocr_screen_grounding | 496 |
|
| 53 |
+
| proactive_av_interaction | 482 |
|
| 54 |
+
| speech_output_alignment | 500 |
|
| 55 |
+
| streaming_asr_translation | 4000 |
|
| 56 |
+
| streaming_audio_interaction | 1797 |
|
| 57 |
+
|
| 58 |
+
## Quality grades
|
| 59 |
+
|
| 60 |
+
| Value | Rows |
|
| 61 |
+
|---|---:|
|
| 62 |
+
| B | 4966 |
|
| 63 |
+
| C | 7517 |
|
| 64 |
+
|
| 65 |
+
## Streaming types
|
| 66 |
+
|
| 67 |
+
| Value | Rows |
|
| 68 |
+
|---|---:|
|
| 69 |
+
| offline | 6021 |
|
| 70 |
+
| reconstructed | 4917 |
|
| 71 |
+
| simulated | 1545 |
|
| 72 |
+
|
| 73 |
+
## Sources
|
| 74 |
+
|
| 75 |
+
| Value | Rows |
|
| 76 |
+
|---|---:|
|
| 77 |
+
| facebook/covost2 | 3500 |
|
| 78 |
+
| google/fleurs | 1000 |
|
| 79 |
+
| project_deterministic_tool_suite | 400 |
|
| 80 |
+
| project_synthetic_bilingual_templates | 200 |
|
| 81 |
+
| project_v041_diverse_tool_suite | 1961 |
|
| 82 |
+
| skyzhou06/LifeAudioMultiTurnStreamingCoT | 1712 |
|
| 83 |
+
| skyzhou06/LifeSpeechQAStreamingCoT | 999 |
|
| 84 |
+
| skyzhou06/LifeSpeechSummaryStreamingCoT | 798 |
|
| 85 |
+
| skyzhou06/StreamingOmniDatasets | 1913 |
|
| 86 |
+
|
| 87 |
+
## Context dependency
|
| 88 |
+
|
| 89 |
+
| Value | Rows |
|
| 90 |
+
|---|---:|
|
| 91 |
+
| clarification | 70 |
|
| 92 |
+
| conversational_state | 839 |
|
| 93 |
+
| correction | 382 |
|
| 94 |
+
| previous_turn_reference | 419 |
|
| 95 |
+
| weak_dependency | 2 |
|
| 96 |
+
|
| 97 |
+
## Tool outcomes
|
| 98 |
+
|
| 99 |
+
| Value | Rows |
|
| 100 |
+
|---|---:|
|
| 101 |
+
| clarification_before_tool | 294 |
|
| 102 |
+
| conflict_result_grounded | 100 |
|
| 103 |
+
| failure_recovery | 101 |
|
| 104 |
+
| no_tool | 101 |
|
| 105 |
+
| no_tool_hard_negative | 467 |
|
| 106 |
+
| partial_result_grounded | 100 |
|
| 107 |
+
| success_grounded | 198 |
|
| 108 |
+
| success_result_grounded | 700 |
|
| 109 |
+
| tool_failure_recovery | 300 |
|
| 110 |
+
|
| 111 |
+
## Translation language pairs
|
| 112 |
+
|
| 113 |
+
| Value | Rows |
|
| 114 |
+
|---|---:|
|
| 115 |
+
| de->en | 25 |
|
| 116 |
+
| en->de | 25 |
|
| 117 |
+
| en->es | 25 |
|
| 118 |
+
| en->fr | 25 |
|
| 119 |
+
| en->zh | 25 |
|
| 120 |
+
| en->zh-CN | 3000 |
|
| 121 |
+
| es->en | 25 |
|
| 122 |
+
| fr->en | 25 |
|
| 123 |
+
| zh->en | 25 |
|
| 124 |
+
|
| 125 |
+
## Pending publication fields
|
| 126 |
+
|
| 127 |
+
Final remote SHA, tag verification, fresh-cache loads, and Viewer outcome are added only after they are observed.
|
reports/FULL_DUPLEX_DEFERRED.md
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
-
# Full Duplex
|
| 2 |
|
| 3 |
-
|
|
|
|
| 1 |
+
# Full Duplex deferred
|
| 2 |
|
| 3 |
+
v0.4.1-quality excludes barge-in, overlap policy, simultaneous listen-and-speak, assistant interruption, and Full Duplex benchmark training data. Future schema work should add separate listen/speak tracks, overlap intervals, interruption ownership, causal cutoffs, and clip lineage in a separately audited release. Single-turn speech-output alignment is not Full Duplex.
|
reports/LOCAL_ACCEPTANCE_V041.md
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Local acceptance v0.4.1-quality
|
| 2 |
+
|
| 3 |
+
**Status: PASS**
|
| 4 |
+
|
| 5 |
+
- Total rows: 12483
|
| 6 |
+
- Blocking failures: none
|
| 7 |
+
- Six Parquet schemas identical: True
|
| 8 |
+
- Recursive null/list-null types: 0
|
| 9 |
+
- Duplicate final IDs: 0
|
| 10 |
+
- Exact cross-split duplicates: 0
|
| 11 |
+
- Episode/group split leakage: 0
|
| 12 |
+
- Absolute-path leaks: 0
|
| 13 |
+
- Speech-output alignment rows: 500
|
| 14 |
+
- Real speech translation rows: 3000
|
| 15 |
+
- Context high-weight core: 1710/1712 (99.9%)
|
| 16 |
+
- Tool no-call ratio: 36.5%
|
| 17 |
+
- Tool failure ratio: 12.7%
|
| 18 |
+
- Tool ambiguity ratio: 12.5%
|
| 19 |
+
- Fresh-cache local loads: 6/6
|
| 20 |
+
- Media decodes checked: 200
|
| 21 |
+
|
| 22 |
+
Detailed machine-readable evidence is in `local_acceptance_v041.json`.
|
reports/MULTITURN_DEPENDENCY_AUDIT.md
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Multi-turn dependency audit
|
| 2 |
+
|
| 3 |
+
All 2,000 v0.4 episodes were classified. Independent questions were rejected; weak dependencies remain accepted only at weight 0.20 and are excluded from the high-weight core. Core rows: 1710/1712 (99.9%).
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| clarification | 70 |
|
| 8 |
+
| conversational_state | 839 |
|
| 9 |
+
| correction | 382 |
|
| 10 |
+
| previous_turn_reference | 419 |
|
| 11 |
+
| weak_dependency | 2 |
|
reports/QUALITY_REGRADING_REPORT.md
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Quality regrading report
|
| 2 |
+
|
| 3 |
+
No A grade was created and no row is marked human-reviewed. v0.4 grades were preserved. New real CoVoST2 translation and non-fallback alignment rows are B because provenance, media decoding, split lineage, timestamps, and automated gates pass. Synthetic tool rows remain C.
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| B | 4966 |
|
| 8 |
+
| C | 7517 |
|
reports/SPEECH_OUTPUT_ALIGNMENT_AUDIT.md
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Speech-output alignment audit
|
| 2 |
+
|
| 3 |
+
The v0.3 candidate set contained 1,000 rows. All 1,000 claimed `pass`, but all 1,000 recorded fallback tone TTS and fallback alignment, had no source URL or relative speech path, and reported all model modes as `not_used`. They are rejected. The quality upgrade rebuilds the capability from real CoVoST2 train speech, decoded audio, and word timestamps produced by `Systran/faster-whisper-small` with an ASR WER gate. No fallback-only row is accepted.
|
| 4 |
+
|
| 5 |
+
- Rejected legacy candidates: 1,000
|
| 6 |
+
- Accepted rebuilt rows: 500
|
reports/TOOL_CALLING_DIVERSITY_REPORT.md
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Tool-calling diversity report
|
| 2 |
+
|
| 3 |
+
Total rows: 2361. No-tool: 862 (36.5%). Single-call failures: 300 (12.7%). Ambiguous/missing/invalid-candidate cases: 294 (12.5%). New-suite share: 83.1%. The suite covers eleven tools, multilingual surface forms, hard negatives, partial/empty-style outcomes, permission/timeout errors, and result conflicts.
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| clarification_before_tool | 294 |
|
| 8 |
+
| conflict_result_grounded | 100 |
|
| 9 |
+
| failure_recovery | 101 |
|
| 10 |
+
| no_tool | 101 |
|
| 11 |
+
| no_tool_hard_negative | 467 |
|
| 12 |
+
| partial_result_grounded | 100 |
|
| 13 |
+
| success_grounded | 198 |
|
| 14 |
+
| success_result_grounded | 700 |
|
| 15 |
+
| tool_failure_recovery | 300 |
|
reports/TOOL_CALLING_SOURCE_AUDIT.md
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Tool-calling source audit
|
| 2 |
+
|
| 3 |
+
Retained original deterministic format warm-up: 400. Replaced/downsampled original rows: 600. New independently restructured synthetic rows accepted after cross-split dedup: 1961, clearly marked synthetic with deterministic generator revision and validator checks. No public benchmark eval/test source is used.
|
reports/TOOL_CALLING_VALIDATION_REPORT.md
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
-
# Tool
|
| 2 |
|
| 3 |
-
|
|
|
|
| 1 |
+
# Tool-calling validation report
|
| 2 |
|
| 3 |
+
All accepted rows have zero or one call. Tool schemas and JSON fields parse; generated call arguments satisfy each selected schema; no-call rows do not hide a second call; success, partial, conflict, and failure final answers repeat or accurately qualify the returned value/error. Validator failures are quarantined.
|
reports/TRAINING_WEIGHT_REPORT.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Training weight report
|
| 2 |
+
|
| 3 |
+
Weights encode evidence without pretending automated review is human review. Real validated B rows receive 1.0; validated model-annotated B rows 0.8; reconstructed/simulated C rows are reduced; offline and deterministic synthetic warm-up receive the lowest weights. Three executable YAML views are published without adding HF configs.
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| 0.20 | 1950 |
|
| 8 |
+
| 0.22 | 400 |
|
| 9 |
+
| 0.40 | 1496 |
|
| 10 |
+
| 0.42 | 1461 |
|
| 11 |
+
| 0.48 | 500 |
|
| 12 |
+
| 0.62 | 1710 |
|
| 13 |
+
| 1.00 | 4966 |
|
reports/TRANSLATION_QUALITY_REPORT.md
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Translation quality report
|
| 2 |
+
|
| 3 |
+
- New real speech-to-text translation rows: 3000
|
| 4 |
+
- Language pair: en→zh-CN
|
| 5 |
+
- Audio decode failures among accepted: 0
|
| 6 |
+
- Empty transcripts/translations among accepted: 0
|
| 7 |
+
- Source split violations among accepted: 0
|
| 8 |
+
- Synthetic v0.4 warm-up remains explicitly C-grade and low-weight.
|
reports/TRANSLATION_SOURCE_AUDIT.md
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Translation source audit
|
| 2 |
+
|
| 3 |
+
Source: official `facebook/covost2` en→zh-CN train metadata/TSV, revision `369b47c4c20aff1193b8edeeedc37d14ae28226b`, license CC BY-NC 4.0. Embedded-audio conversion shard: `ymoslem/CoVoST2-EN-ZH` revision `f391125f524c317e7cea975cad0d1faebec37314`. Every accepted row matched its audio filename and target translation against the official CoVoST2 train TSV, decoded successfully, and came only from `train`/`train_covost`. Validation/test/dev are excluded. The conversion repo omitted license metadata; therefore it is treated only as a transport conversion, while provenance and license are anchored to official CoVoST2 and every row is cross-checked.
|
reports/V04_REMOTE_CONFIG_AUDIT.md
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v0.4 remote config audit
|
| 2 |
+
|
| 3 |
+
Official `/api/datasets` metadata and explicit revision loading agree on exactly three configs. README, builder paths, release reports, and Parquet paths use the same public names. Six Parquet splits share the v0.4 canonical schema. Seven legacy config names are absent from the official file listing. The mirror's unversioned response was stale and is documented rather than treated as repository truth.
|
| 4 |
+
|
| 5 |
+
| Value | Rows |
|
| 6 |
+
|---|---:|
|
| 7 |
+
| context_multiturn_qa/eval | 114 |
|
| 8 |
+
| context_multiturn_qa/train | 1886 |
|
| 9 |
+
| single_tool_calling/eval | 41 |
|
| 10 |
+
| single_tool_calling/train | 959 |
|
| 11 |
+
| single_turn_streaming/eval | 174 |
|
| 12 |
+
| single_turn_streaming/train | 4736 |
|
reports/V04_VIEWER_STATUS.md
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v0.4 Dataset Viewer status
|
| 2 |
+
|
| 3 |
+
- Checked via the official Dataset Server API.
|
| 4 |
+
- HTTP status: 500
|
| 5 |
+
- State: processing pending / service busy.
|
| 6 |
+
- Response: `The server is busier than usual and the response is not ready yet. Please retry later.`
|
| 7 |
+
- This is recorded as PENDING, not PASS and not a schema failure.
|
reports/build_summary_v041.json
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"version": "v0.4.1-quality",
|
| 3 |
+
"v04_sha": "cf95b027d75ec793556e395aef9af8118a08b3d8",
|
| 4 |
+
"accepted_rows": 12483,
|
| 5 |
+
"rejected_hard_gate_rows": 39,
|
| 6 |
+
"config_split_counts": {
|
| 7 |
+
"single_turn_streaming/eval": 360,
|
| 8 |
+
"single_turn_streaming/train": 8050,
|
| 9 |
+
"context_multiturn_qa/eval": 99,
|
| 10 |
+
"context_multiturn_qa/train": 1613,
|
| 11 |
+
"single_tool_calling/eval": 92,
|
| 12 |
+
"single_tool_calling/train": 2269
|
| 13 |
+
},
|
| 14 |
+
"task_counts": {
|
| 15 |
+
"qa": 3169,
|
| 16 |
+
"live_commentary": 477,
|
| 17 |
+
"grounding": 496,
|
| 18 |
+
"summary": 798,
|
| 19 |
+
"asr": 1000,
|
| 20 |
+
"translation": 3200,
|
| 21 |
+
"proactive_response": 482,
|
| 22 |
+
"tool_call": 1499,
|
| 23 |
+
"tool_selection": 862,
|
| 24 |
+
"speech_alignment": 500
|
| 25 |
+
},
|
| 26 |
+
"capability_counts": {
|
| 27 |
+
"av_joint_reasoning": 458,
|
| 28 |
+
"live_av_commentary": 477,
|
| 29 |
+
"ocr_screen_grounding": 496,
|
| 30 |
+
"streaming_audio_interaction": 1797,
|
| 31 |
+
"streaming_asr_translation": 4000,
|
| 32 |
+
"proactive_av_interaction": 482,
|
| 33 |
+
"speech_output_alignment": 500
|
| 34 |
+
},
|
| 35 |
+
"quality_grade_counts": {
|
| 36 |
+
"B": 4966,
|
| 37 |
+
"C": 7517
|
| 38 |
+
},
|
| 39 |
+
"streaming_type_counts": {
|
| 40 |
+
"reconstructed": 4917,
|
| 41 |
+
"simulated": 1545,
|
| 42 |
+
"offline": 6021
|
| 43 |
+
},
|
| 44 |
+
"modality_counts": {
|
| 45 |
+
"audio": 7214,
|
| 46 |
+
"video": 1417,
|
| 47 |
+
"text": 8001,
|
| 48 |
+
"image": 496,
|
| 49 |
+
"screen": 496
|
| 50 |
+
},
|
| 51 |
+
"source_counts": {
|
| 52 |
+
"skyzhou06/StreamingOmniDatasets": 1913,
|
| 53 |
+
"skyzhou06/LifeSpeechQAStreamingCoT": 999,
|
| 54 |
+
"skyzhou06/LifeSpeechSummaryStreamingCoT": 798,
|
| 55 |
+
"google/fleurs": 1000,
|
| 56 |
+
"project_synthetic_bilingual_templates": 200,
|
| 57 |
+
"skyzhou06/LifeAudioMultiTurnStreamingCoT": 1712,
|
| 58 |
+
"project_deterministic_tool_suite": 400,
|
| 59 |
+
"facebook/covost2": 3500,
|
| 60 |
+
"project_v041_diverse_tool_suite": 1961
|
| 61 |
+
},
|
| 62 |
+
"license_counts": {
|
| 63 |
+
"CC BY-NC 4.0; Seamless Interaction train split": 935,
|
| 64 |
+
"synthetic": 366,
|
| 65 |
+
"CC0": 758,
|
| 66 |
+
"CC-BY-4.0": 4600,
|
| 67 |
+
"CC-BY-NC-4.0": 3982,
|
| 68 |
+
"public_domain": 130,
|
| 69 |
+
"cc-by-nc-4.0": 1392,
|
| 70 |
+
"cc": 320
|
| 71 |
+
},
|
| 72 |
+
"origin_counts": {
|
| 73 |
+
"real_or_transformed": 9426,
|
| 74 |
+
"synthetic": 3057
|
| 75 |
+
},
|
| 76 |
+
"context_dependency_counts": {
|
| 77 |
+
"conversational_state": 839,
|
| 78 |
+
"correction": 382,
|
| 79 |
+
"previous_turn_reference": 419,
|
| 80 |
+
"clarification": 70,
|
| 81 |
+
"weak_dependency": 2
|
| 82 |
+
},
|
| 83 |
+
"recommended_training_weight_counts": {
|
| 84 |
+
"1.00": 4966,
|
| 85 |
+
"0.40": 1496,
|
| 86 |
+
"0.20": 1950,
|
| 87 |
+
"0.62": 1710,
|
| 88 |
+
"0.22": 400,
|
| 89 |
+
"0.42": 1461,
|
| 90 |
+
"0.48": 500
|
| 91 |
+
},
|
| 92 |
+
"tool_control_counts": {
|
| 93 |
+
"success_grounded": 198,
|
| 94 |
+
"no_tool": 101,
|
| 95 |
+
"failure_recovery": 101,
|
| 96 |
+
"no_tool_hard_negative": 467,
|
| 97 |
+
"success_result_grounded": 700,
|
| 98 |
+
"tool_failure_recovery": 300,
|
| 99 |
+
"clarification_before_tool": 294,
|
| 100 |
+
"partial_result_grounded": 100,
|
| 101 |
+
"conflict_result_grounded": 100
|
| 102 |
+
},
|
| 103 |
+
"translation_language_pairs": {
|
| 104 |
+
"es->en": 25,
|
| 105 |
+
"zh->en": 25,
|
| 106 |
+
"en->es": 25,
|
| 107 |
+
"en->de": 25,
|
| 108 |
+
"en->fr": 25,
|
| 109 |
+
"de->en": 25,
|
| 110 |
+
"fr->en": 25,
|
| 111 |
+
"en->zh": 25,
|
| 112 |
+
"en->zh-CN": 3000
|
| 113 |
+
},
|
| 114 |
+
"speech_output_alignment_rows": 500,
|
| 115 |
+
"real_speech_translation_rows": 3000,
|
| 116 |
+
"context_rejected_independent": 288,
|
| 117 |
+
"old_tool_rows_retained": 400,
|
| 118 |
+
"new_diverse_tool_rows": 1961
|
| 119 |
+
}
|
reports/capability_coverage_v041.json
ADDED
|
@@ -0,0 +1,109 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"definitions": {
|
| 3 |
+
"av_joint_reasoning": "accepted rows carrying this capability with task-appropriate supervision",
|
| 4 |
+
"live_av_commentary": "accepted rows carrying this capability with task-appropriate supervision",
|
| 5 |
+
"ocr_screen_grounding": "accepted rows carrying this capability with task-appropriate supervision",
|
| 6 |
+
"proactive_av_interaction": "accepted rows carrying this capability with task-appropriate supervision",
|
| 7 |
+
"speech_output_alignment": "accepted rows carrying this capability with task-appropriate supervision",
|
| 8 |
+
"streaming_asr_translation": "accepted rows carrying this capability with task-appropriate supervision",
|
| 9 |
+
"streaming_audio_interaction": "accepted rows carrying this capability with task-appropriate supervision"
|
| 10 |
+
},
|
| 11 |
+
"counts": {
|
| 12 |
+
"av_joint_reasoning": 458,
|
| 13 |
+
"live_av_commentary": 477,
|
| 14 |
+
"ocr_screen_grounding": 496,
|
| 15 |
+
"streaming_audio_interaction": 1797,
|
| 16 |
+
"streaming_asr_translation": 4000,
|
| 17 |
+
"proactive_av_interaction": 482,
|
| 18 |
+
"speech_output_alignment": 500
|
| 19 |
+
},
|
| 20 |
+
"by_config": {
|
| 21 |
+
"av_joint_reasoning": {
|
| 22 |
+
"single_turn_streaming": 458
|
| 23 |
+
},
|
| 24 |
+
"live_av_commentary": {
|
| 25 |
+
"single_turn_streaming": 477
|
| 26 |
+
},
|
| 27 |
+
"ocr_screen_grounding": {
|
| 28 |
+
"single_turn_streaming": 496
|
| 29 |
+
},
|
| 30 |
+
"proactive_av_interaction": {
|
| 31 |
+
"single_turn_streaming": 482
|
| 32 |
+
},
|
| 33 |
+
"speech_output_alignment": {
|
| 34 |
+
"single_turn_streaming": 500
|
| 35 |
+
},
|
| 36 |
+
"streaming_asr_translation": {
|
| 37 |
+
"single_turn_streaming": 4000
|
| 38 |
+
},
|
| 39 |
+
"streaming_audio_interaction": {
|
| 40 |
+
"single_turn_streaming": 1797
|
| 41 |
+
}
|
| 42 |
+
},
|
| 43 |
+
"by_split": {
|
| 44 |
+
"av_joint_reasoning": {
|
| 45 |
+
"eval": 18,
|
| 46 |
+
"train": 440
|
| 47 |
+
},
|
| 48 |
+
"live_av_commentary": {
|
| 49 |
+
"eval": 12,
|
| 50 |
+
"train": 465
|
| 51 |
+
},
|
| 52 |
+
"ocr_screen_grounding": {
|
| 53 |
+
"eval": 14,
|
| 54 |
+
"train": 482
|
| 55 |
+
},
|
| 56 |
+
"proactive_av_interaction": {
|
| 57 |
+
"train": 482
|
| 58 |
+
},
|
| 59 |
+
"speech_output_alignment": {
|
| 60 |
+
"train": 475,
|
| 61 |
+
"eval": 25
|
| 62 |
+
},
|
| 63 |
+
"streaming_asr_translation": {
|
| 64 |
+
"eval": 204,
|
| 65 |
+
"train": 3796
|
| 66 |
+
},
|
| 67 |
+
"streaming_audio_interaction": {
|
| 68 |
+
"eval": 77,
|
| 69 |
+
"train": 1720
|
| 70 |
+
}
|
| 71 |
+
},
|
| 72 |
+
"by_quality": {
|
| 73 |
+
"av_joint_reasoning": {
|
| 74 |
+
"B": 458
|
| 75 |
+
},
|
| 76 |
+
"live_av_commentary": {
|
| 77 |
+
"B": 477
|
| 78 |
+
},
|
| 79 |
+
"ocr_screen_grounding": {
|
| 80 |
+
"C": 496
|
| 81 |
+
},
|
| 82 |
+
"proactive_av_interaction": {
|
| 83 |
+
"B": 482
|
| 84 |
+
},
|
| 85 |
+
"speech_output_alignment": {
|
| 86 |
+
"B": 500
|
| 87 |
+
},
|
| 88 |
+
"streaming_asr_translation": {
|
| 89 |
+
"C": 1000,
|
| 90 |
+
"B": 3000
|
| 91 |
+
},
|
| 92 |
+
"streaming_audio_interaction": {
|
| 93 |
+
"C": 1748,
|
| 94 |
+
"B": 49
|
| 95 |
+
}
|
| 96 |
+
},
|
| 97 |
+
"task_counts": {
|
| 98 |
+
"qa": 3169,
|
| 99 |
+
"live_commentary": 477,
|
| 100 |
+
"grounding": 496,
|
| 101 |
+
"summary": 798,
|
| 102 |
+
"asr": 1000,
|
| 103 |
+
"translation": 3200,
|
| 104 |
+
"proactive_response": 482,
|
| 105 |
+
"tool_call": 1499,
|
| 106 |
+
"tool_selection": 862,
|
| 107 |
+
"speech_alignment": 500
|
| 108 |
+
}
|
| 109 |
+
}
|
reports/context_dependency_stats.json
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"counts": {
|
| 3 |
+
"conversational_state": 839,
|
| 4 |
+
"correction": 382,
|
| 5 |
+
"previous_turn_reference": 419,
|
| 6 |
+
"clarification": 70,
|
| 7 |
+
"weak_dependency": 2
|
| 8 |
+
},
|
| 9 |
+
"core_rows": 1710,
|
| 10 |
+
"accepted_rows": 1712,
|
| 11 |
+
"core_ratio": 0.9988317757009346,
|
| 12 |
+
"rejected_independent": 288
|
| 13 |
+
}
|
reports/local_acceptance_v041.json
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"status": "PASS",
|
| 3 |
+
"blocking_failures": [],
|
| 4 |
+
"row_counts": {
|
| 5 |
+
"single_turn_streaming/train": 8050,
|
| 6 |
+
"single_turn_streaming/eval": 360,
|
| 7 |
+
"context_multiturn_qa/train": 1613,
|
| 8 |
+
"context_multiturn_qa/eval": 99,
|
| 9 |
+
"single_tool_calling/train": 2269,
|
| 10 |
+
"single_tool_calling/eval": 92
|
| 11 |
+
},
|
| 12 |
+
"checks": {
|
| 13 |
+
"schema": {
|
| 14 |
+
"pass": true,
|
| 15 |
+
"all_six_equal": true,
|
| 16 |
+
"recursive_null_types": []
|
| 17 |
+
},
|
| 18 |
+
"global_ids": {
|
| 19 |
+
"pass": true,
|
| 20 |
+
"rows": 12483,
|
| 21 |
+
"unique_ids": 12483
|
| 22 |
+
},
|
| 23 |
+
"absolute_path_scan": {
|
| 24 |
+
"pass": true,
|
| 25 |
+
"hits": []
|
| 26 |
+
},
|
| 27 |
+
"provenance_license": {
|
| 28 |
+
"pass": true,
|
| 29 |
+
"failures": []
|
| 30 |
+
},
|
| 31 |
+
"quality": {
|
| 32 |
+
"pass": true,
|
| 33 |
+
"false_a_or_human_review": [],
|
| 34 |
+
"invalid_weights": [],
|
| 35 |
+
"grade_counts": {
|
| 36 |
+
"B": 4966,
|
| 37 |
+
"C": 7517
|
| 38 |
+
}
|
| 39 |
+
},
|
| 40 |
+
"timeline": {
|
| 41 |
+
"pass": true,
|
| 42 |
+
"failures": []
|
| 43 |
+
},
|
| 44 |
+
"speech_alignment": {
|
| 45 |
+
"pass": true,
|
| 46 |
+
"rows": 500,
|
| 47 |
+
"failures": [],
|
| 48 |
+
"fallback_only_accepted": 0
|
| 49 |
+
},
|
| 50 |
+
"translation": {
|
| 51 |
+
"pass": true,
|
| 52 |
+
"real_speech_translation_rows": 3000,
|
| 53 |
+
"failures": []
|
| 54 |
+
},
|
| 55 |
+
"media_decode_spot_check": {
|
| 56 |
+
"pass": true,
|
| 57 |
+
"checked": 200,
|
| 58 |
+
"failures": []
|
| 59 |
+
},
|
| 60 |
+
"multiturn_dependency": {
|
| 61 |
+
"pass": true,
|
| 62 |
+
"rows": 1712,
|
| 63 |
+
"core_rows": 1710,
|
| 64 |
+
"core_ratio": 0.9988317757009346,
|
| 65 |
+
"missing": [],
|
| 66 |
+
"role_failures": []
|
| 67 |
+
},
|
| 68 |
+
"tool_calling": {
|
| 69 |
+
"pass": true,
|
| 70 |
+
"rows": 2361,
|
| 71 |
+
"no_tool": 862,
|
| 72 |
+
"no_tool_ratio": 0.36509953409572216,
|
| 73 |
+
"failure_rows": 300,
|
| 74 |
+
"failure_ratio": 0.12706480304955528,
|
| 75 |
+
"ambiguity_rows": 294,
|
| 76 |
+
"ambiguity_ratio": 0.12452350698856417,
|
| 77 |
+
"failures": []
|
| 78 |
+
},
|
| 79 |
+
"dedup_and_split": {
|
| 80 |
+
"pass": true,
|
| 81 |
+
"exact_cross_split_content": 0,
|
| 82 |
+
"episode_group_split_leakage": 0,
|
| 83 |
+
"media_cross_split_leakage": 0
|
| 84 |
+
},
|
| 85 |
+
"readme_registry_recipes": {
|
| 86 |
+
"pass": true,
|
| 87 |
+
"summary_rows": 12483,
|
| 88 |
+
"actual_rows": 12483,
|
| 89 |
+
"recipe_dry_run": true
|
| 90 |
+
},
|
| 91 |
+
"local_fresh_cache_load": {
|
| 92 |
+
"pass": true,
|
| 93 |
+
"splits": {
|
| 94 |
+
"single_turn_streaming/train": {
|
| 95 |
+
"rows": 8050,
|
| 96 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 97 |
+
"sample_id": "old_9df3ad2f195e92f1f591"
|
| 98 |
+
},
|
| 99 |
+
"single_turn_streaming/eval": {
|
| 100 |
+
"rows": 360,
|
| 101 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 102 |
+
"sample_id": "old_d819ae5e9da0159dc4bc"
|
| 103 |
+
},
|
| 104 |
+
"context_multiturn_qa/train": {
|
| 105 |
+
"rows": 1613,
|
| 106 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 107 |
+
"sample_id": "ctx_0007d7f817a93eae9857"
|
| 108 |
+
},
|
| 109 |
+
"context_multiturn_qa/eval": {
|
| 110 |
+
"rows": 99,
|
| 111 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 112 |
+
"sample_id": "ctx_00cf4d4af7abdfc033ab"
|
| 113 |
+
},
|
| 114 |
+
"single_tool_calling/train": {
|
| 115 |
+
"rows": 2269,
|
| 116 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 117 |
+
"sample_id": "tool_b17e008191acd3bb0c89"
|
| 118 |
+
},
|
| 119 |
+
"single_tool_calling/eval": {
|
| 120 |
+
"rows": 92,
|
| 121 |
+
"features": "{'id': Value(dtype='string', id=None), 'schema_version': Value(dtype='string', id=None), 'interaction_regime': Value(dtype='string', id=None), 'task_type': Value(dtype='string', id=None), 'capabilities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'domain': Value(dtype='string', id=None), 'input_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'output_modalities': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'source_language': Value(dtype='string', id=None), 'target_language': Value(dtype='string', id=None), 'streaming_type': Value(dtype='string', id=None), 'causal_validity': Value(dtype='string', id=None), 'source_dataset': Value(dtype='string', id=None), 'source_config': Value(dtype='string', id=None), 'source_split': Value(dtype='string', id=None), 'source_id': Value(dtype='string', id=None), 'source_url': Value(dtype='string', id=None), 'source_license': Value(dtype='string', id=None), 'data_origin': Value(dtype='string', id=None), 'transformation_pipeline': Value(dtype='string', id=None), 'pipeline_version': Value(dtype='string', id=None), 'instruction': Value(dtype='string', id=None), 'context_text': Value(dtype='string', id=None), 'turns': [{'turn_id': Value(dtype='string', id=None), 'role': Value(dtype='string', id=None), 'text': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'media_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'tool_state': Value(dtype='string', id=None)}], 'timeline': [{'chunk_id': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'speaker': Value(dtype='string', id=None), 'asr_delta': Value(dtype='string', id=None), 'ocr_delta': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'audio_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'visual_events': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'frame_refs': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'available_context': Value(dtype='string', id=None), 'target_delta': Value(dtype='string', id=None)}], 'media': {'audio_ref': Value(dtype='string', id=None), 'video_ref': Value(dtype='string', id=None), 'image_ref': Value(dtype='string', id=None), 'screen_ref': Value(dtype='string', id=None), 'duration_sec': Value(dtype='float64', id=None), 'sample_rate': Value(dtype='int32', id=None)}, 'targets': {'transcript': Value(dtype='string', id=None), 'translation': Value(dtype='string', id=None), 'answer': Value(dtype='string', id=None), 'summary': Value(dtype='string', id=None), 'commentary': Value(dtype='string', id=None), 'speech_output': Value(dtype='string', id=None), 'control_label': Value(dtype='string', id=None), 'tool_call_json': Value(dtype='string', id=None), 'tool_result_json': Value(dtype='string', id=None), 'final_response': Value(dtype='string', id=None)}, 'tool_schema_json': Value(dtype='string', id=None), 'quality': {'grade': Value(dtype='string', id=None), 'score': Value(dtype='float64', id=None), 'timestamp_valid': Value(dtype='bool', id=None), 'causal_valid': Value(dtype='bool', id=None), 'media_valid': Value(dtype='bool', id=None), 'annotation_status': Value(dtype='string', id=None), 'annotation_model': Value(dtype='string', id=None), 'annotation_version': Value(dtype='string', id=None), 'automated_checks': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'human_reviewed': Value(dtype='bool', id=None), 'rejection_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None)}, 'group_id': Value(dtype='string', id=None), 'split': Value(dtype='string', id=None), 'publication_notes': Value(dtype='string', id=None), 'source_revision': Value(dtype='string', id=None), 'media_checksum': Value(dtype='string', id=None), 'context_dependency': Value(dtype='string', id=None), 'translation_subtype': Value(dtype='string', id=None), 'automated_quality_score': Value(dtype='float64', id=None), 'recommended_training_weight': Value(dtype='float64', id=None), 'quality_reasons': Sequence(feature=Value(dtype='string', id=None), length=-1, id=None), 'review_status': Value(dtype='string', id=None), 'alignment_method': Value(dtype='string', id=None), 'alignment_confidence': Value(dtype='float64', id=None), 'speech_output_duration': Value(dtype='float64', id=None), 'alignment_words': [{'word': Value(dtype='string', id=None), 'start_sec': Value(dtype='float64', id=None), 'end_sec': Value(dtype='float64', id=None), 'probability': Value(dtype='float64', id=None)}], 'tool_error_type': Value(dtype='string', id=None), 'tool_validation_status': Value(dtype='string', id=None), 'annotation_details_json': Value(dtype='string', id=None)}",
|
| 122 |
+
"sample_id": "tool_0cefb9177f4f01e8c14b"
|
| 123 |
+
}
|
| 124 |
+
}
|
| 125 |
+
},
|
| 126 |
+
"spot_checks": {
|
| 127 |
+
"pass": true,
|
| 128 |
+
"config_rows_checked": {
|
| 129 |
+
"single_turn_streaming": 100,
|
| 130 |
+
"context_multiturn_qa": 100,
|
| 131 |
+
"single_tool_calling": 100
|
| 132 |
+
},
|
| 133 |
+
"translation_rows_checked": 100,
|
| 134 |
+
"alignment_rows_checked": 100,
|
| 135 |
+
"context_episodes_checked": 100,
|
| 136 |
+
"tool_rows_checked": 100
|
| 137 |
+
}
|
| 138 |
+
}
|
| 139 |
+
}
|
schema/SCHEMA.md
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
-
# Canonical
|
| 2 |
|
| 3 |
-
All configs and splits
|
|
|
|
| 1 |
+
# Canonical schema 1.1
|
| 2 |
|
| 3 |
+
All three configs and all six splits are written with the same explicit PyArrow schema. Optional values use typed empty strings/lists/structs; null and `list<null>` are forbidden. v0.4 rows are normalized without changing their published IDs.
|
schema/canonical_schema.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
| 1 |
{
|
| 2 |
-
"schema_version": "
|
|
|
|
| 3 |
"fields": [
|
| 4 |
{
|
| 5 |
"name": "id",
|
|
@@ -160,6 +161,81 @@
|
|
| 160 |
"name": "publication_notes",
|
| 161 |
"type": "string",
|
| 162 |
"nullable": true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 163 |
}
|
| 164 |
]
|
| 165 |
-
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"schema_version": "1.1",
|
| 3 |
+
"dataset_version": "v0.4.1-quality",
|
| 4 |
"fields": [
|
| 5 |
{
|
| 6 |
"name": "id",
|
|
|
|
| 161 |
"name": "publication_notes",
|
| 162 |
"type": "string",
|
| 163 |
"nullable": true
|
| 164 |
+
},
|
| 165 |
+
{
|
| 166 |
+
"name": "source_revision",
|
| 167 |
+
"type": "string",
|
| 168 |
+
"nullable": true
|
| 169 |
+
},
|
| 170 |
+
{
|
| 171 |
+
"name": "media_checksum",
|
| 172 |
+
"type": "string",
|
| 173 |
+
"nullable": true
|
| 174 |
+
},
|
| 175 |
+
{
|
| 176 |
+
"name": "context_dependency",
|
| 177 |
+
"type": "string",
|
| 178 |
+
"nullable": true
|
| 179 |
+
},
|
| 180 |
+
{
|
| 181 |
+
"name": "translation_subtype",
|
| 182 |
+
"type": "string",
|
| 183 |
+
"nullable": true
|
| 184 |
+
},
|
| 185 |
+
{
|
| 186 |
+
"name": "automated_quality_score",
|
| 187 |
+
"type": "double",
|
| 188 |
+
"nullable": true
|
| 189 |
+
},
|
| 190 |
+
{
|
| 191 |
+
"name": "recommended_training_weight",
|
| 192 |
+
"type": "double",
|
| 193 |
+
"nullable": true
|
| 194 |
+
},
|
| 195 |
+
{
|
| 196 |
+
"name": "quality_reasons",
|
| 197 |
+
"type": "list<item: string>",
|
| 198 |
+
"nullable": true
|
| 199 |
+
},
|
| 200 |
+
{
|
| 201 |
+
"name": "review_status",
|
| 202 |
+
"type": "string",
|
| 203 |
+
"nullable": true
|
| 204 |
+
},
|
| 205 |
+
{
|
| 206 |
+
"name": "alignment_method",
|
| 207 |
+
"type": "string",
|
| 208 |
+
"nullable": true
|
| 209 |
+
},
|
| 210 |
+
{
|
| 211 |
+
"name": "alignment_confidence",
|
| 212 |
+
"type": "double",
|
| 213 |
+
"nullable": true
|
| 214 |
+
},
|
| 215 |
+
{
|
| 216 |
+
"name": "speech_output_duration",
|
| 217 |
+
"type": "double",
|
| 218 |
+
"nullable": true
|
| 219 |
+
},
|
| 220 |
+
{
|
| 221 |
+
"name": "alignment_words",
|
| 222 |
+
"type": "list<item: struct<word: string, start_sec: double, end_sec: double, probability: double>>",
|
| 223 |
+
"nullable": true
|
| 224 |
+
},
|
| 225 |
+
{
|
| 226 |
+
"name": "tool_error_type",
|
| 227 |
+
"type": "string",
|
| 228 |
+
"nullable": true
|
| 229 |
+
},
|
| 230 |
+
{
|
| 231 |
+
"name": "tool_validation_status",
|
| 232 |
+
"type": "string",
|
| 233 |
+
"nullable": true
|
| 234 |
+
},
|
| 235 |
+
{
|
| 236 |
+
"name": "annotation_details_json",
|
| 237 |
+
"type": "string",
|
| 238 |
+
"nullable": true
|
| 239 |
}
|
| 240 |
]
|
| 241 |
+
}
|
schema/canonical_schema.py
CHANGED
|
@@ -1,7 +1 @@
|
|
| 1 |
-
|
| 2 |
-
TURN=pa.struct([('turn_id',pa.string()),('role',pa.string()),('text',pa.string()),('start_sec',pa.float64()),('end_sec',pa.float64()),('media_refs',pa.list_(pa.string())),('tool_state',pa.string())])
|
| 3 |
-
TL=pa.struct([('chunk_id',pa.string()),('start_sec',pa.float64()),('end_sec',pa.float64()),('speaker',pa.string()),('asr_delta',pa.string()),('ocr_delta',pa.list_(pa.string())),('audio_events',pa.list_(pa.string())),('visual_events',pa.list_(pa.string())),('frame_refs',pa.list_(pa.string())),('available_context',pa.string()),('target_delta',pa.string())])
|
| 4 |
-
MEDIA=pa.struct([('audio_ref',pa.string()),('video_ref',pa.string()),('image_ref',pa.string()),('screen_ref',pa.string()),('duration_sec',pa.float64()),('sample_rate',pa.int32())])
|
| 5 |
-
TARGET=pa.struct([('transcript',pa.string()),('translation',pa.string()),('answer',pa.string()),('summary',pa.string()),('commentary',pa.string()),('speech_output',pa.string()),('control_label',pa.string()),('tool_call_json',pa.string()),('tool_result_json',pa.string()),('final_response',pa.string())])
|
| 6 |
-
QUAL=pa.struct([('grade',pa.string()),('score',pa.float64()),('timestamp_valid',pa.bool_()),('causal_valid',pa.bool_()),('media_valid',pa.bool_()),('annotation_status',pa.string()),('annotation_model',pa.string()),('annotation_version',pa.string()),('automated_checks',pa.list_(pa.string())),('human_reviewed',pa.bool_()),('rejection_reasons',pa.list_(pa.string()))])
|
| 7 |
-
SCHEMA=pa.schema([('id',pa.string()),('schema_version',pa.string()),('interaction_regime',pa.string()),('task_type',pa.string()),('capabilities',pa.list_(pa.string())),('domain',pa.string()),('input_modalities',pa.list_(pa.string())),('output_modalities',pa.list_(pa.string())),('source_language',pa.string()),('target_language',pa.string()),('streaming_type',pa.string()),('causal_validity',pa.string()),('source_dataset',pa.string()),('source_config',pa.string()),('source_split',pa.string()),('source_id',pa.string()),('source_url',pa.string()),('source_license',pa.string()),('data_origin',pa.string()),('transformation_pipeline',pa.string()),('pipeline_version',pa.string()),('instruction',pa.string()),('context_text',pa.string()),('turns',pa.list_(TURN)),('timeline',pa.list_(TL)),('media',MEDIA),('targets',TARGET),('tool_schema_json',pa.string()),('quality',QUAL),('group_id',pa.string()),('split',pa.string()),('publication_notes',pa.string())])
|
|
|
|
| 1 |
+
# Executable canonical PyArrow schema: SCHEMA in pipelines/24_build_v041_quality.py
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
schema/label_ontology.yaml
CHANGED
|
@@ -1,6 +1,13 @@
|
|
| 1 |
-
schema_version:
|
| 2 |
interaction_regime: [single_turn, context_multiturn, single_tool_calling]
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
schema_version: '1.1'
|
| 2 |
interaction_regime: [single_turn, context_multiturn, single_tool_calling]
|
| 3 |
+
quality_grade: [B, C, rejected]
|
| 4 |
+
context_dependency: [previous_turn_reference, previous_answer_followup, shared_media_reference, correction, clarification, ellipsis_resolution, conversational_state, weak_dependency, independent_question]
|
| 5 |
+
translation_subtype: [speech_to_text_translation, incremental_translation, final_translation, translation_revision]
|
| 6 |
+
capabilities:
|
| 7 |
+
- av_joint_reasoning
|
| 8 |
+
- live_av_commentary
|
| 9 |
+
- ocr_screen_grounding
|
| 10 |
+
- proactive_av_interaction
|
| 11 |
+
- speech_output_alignment
|
| 12 |
+
- streaming_asr_translation
|
| 13 |
+
- streaming_audio_interaction
|
training_recipes/balanced_all.yaml
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
+
filters:
|
| 3 |
+
quality.grade: [B, C]
|
| 4 |
+
weight_field: recommended_training_weight
|
| 5 |
+
balance_by: [interaction_regime, task_type]
|
| 6 |
+
notes: All accepted rows with per-row quality weights and task/config balancing.
|
training_recipes/high_quality.yaml
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
+
filters:
|
| 3 |
+
quality.grade: [B]
|
| 4 |
+
review_status: [automated_validated, model_assisted_validated]
|
| 5 |
+
weight_field: recommended_training_weight
|
| 6 |
+
notes: Reliable B rows only; no synthetic C warm-up.
|
training_recipes/streaming_focused.yaml
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version: v0.4.1-quality
|
| 2 |
+
filters:
|
| 3 |
+
streaming_type: [native, reconstructed, simulated]
|
| 4 |
+
quality.grade: [B, C]
|
| 5 |
+
weight_field: recommended_training_weight
|
| 6 |
+
multipliers:
|
| 7 |
+
reconstructed: 1.0
|
| 8 |
+
simulated: 0.5
|
| 9 |
+
offline: 0.0
|
| 10 |
+
notes: Reliable reconstructed rows plus reduced validated simulation.
|