sob-ft-text-json
收藏资源简介:
该数据集是一个基于suneeldk/text-json源数据集映射得到的独立微调语料库,专为JSON提取任务设计,采用SOB(Schema-Oriented Benchmark)格式。原始数据包含2000个样本,每个样本经过转换后,将原本打包在单个文本字段中的输入、模式、输出拆分为四个独立字段:context(输入文本)、question(固定的提取指令)、json_schema(转换为JSON Schema Draft 7的模式)、ground_truth(验证后的JSON输出)。此外,还根据SOB论文规则计算了schema_complexity(简单/中等/困难),并保留了source_dataset字段以记录来源。所有空列(如candidate_response、validated_output等)已被移除。数据集适用于微调语言模型以执行基于模式的JSON提取任务。
SOB-FT-Text-JSON is an independent fine-tuning corpus mapped from the suneeldk/text-json source dataset. This dataset is specifically designed for JSON extraction tasks, using the SOB (Schema-Oriented Benchmark) format. The original data contains 2000 samples. After transformation, each sample splits the input, schema, and output originally packed in a single text field into four independent fields: context (input text), question (fixed extraction instruction), json_schema (schema converted to JSON Schema Draft 7), and ground_truth (validated JSON output). In addition, schema_complexity (simple/medium/hard) is calculated according to the SOB paper rules, and the source_dataset field is retained to record the source. All empty columns (such as candidate_response, validated_output, etc.) have been removed. The dataset is suitable for fine-tuning language models to perform schema-based JSON extraction tasks.
SOB-FT-Text-JSON 数据集概述
基本信息
- 许可证:Apache-2.0
- 语言:英语(en)
- 标签:json-extraction、sob、fine-tuning
- 来源数据集:suneeldk/text-json
数据集说明
该数据集是从 suneeldk/text-json 映射而来的独立语料库,专门用于 SOB(Schema-Oriented Benchmark)格式的 JSON 抽取任务微调。
与源数据集的差异
格式转换
| 维度 | 源数据集 | 本数据集 |
|---|---|---|
| 格式 | 单一打包的 text 字段 |
16 列 SOB 架构(移除空列) |
| 结构 | ### Input: / ### Schema: / ### Output: 混合在单个字符串 |
拆分为 context、question、json_schema、ground_truth |
| Schema | 紧凑伪架构(如 `"field": "string | null"`) |
| 问题 | 嵌入在打包文本中 | 标准 SOB 抽取提示词 |
| 行数 | 2,000 | 2,000(字符过滤默认 ≤16k) |
| 来源信息 | 无 | source_dataset=suneeldk/text-json,record_id=text-json-{idx} |
列映射关系
| SOB 列名 | 来源 |
|---|---|
context |
### Input: 的正文 |
question |
固定的抽取指令 |
json_schema |
### Schema: 转换后的 Draft 7 格式 |
ground_truth |
### Output: 中验证过的 JSON |
schema_complexity |
根据 SOB 论文规则评定(easy/medium/hard) |
source_dataset |
suneeldk/text-json |
全空保留列(如 candidate_response、validated_output 等)已被删除。
数据重建与合并命令
重新生成数据集
bash python3 merge_text_json.py --dry-run python3 merge_text_json.py
合并到抽取语料库
bash python3 merge_ft_corpus.py --corpus mariem123kfg/sob-ft-text-json --source-prefix suneeldk/text-json




