--- language: - en - zh task_categories: - text-to-image size_categories: - n<1K license: other license_name: mixed-source-literary-texts license_link: LICENSE.md pretty_name: LongLongTextBench (LLTB) tags: - benchmark - text-rendering - long-text - ocr configs: - config_name: default default: true data_files: - split: test path: - text_prompts.jsonl - text_prompts_zh.jsonl - config_name: en data_files: - split: test path: text_prompts.jsonl - config_name: zh data_files: - split: test path: text_prompts_zh.jsonl --- # LongLongTextBench (LLTB) **English** | [简体中文](README_zh.md) LLTB is a benchmark from the [MOSS-Image](https://github.com/OpenMOSS/MOSS-Image) project for rendering long English and Chinese passages in generated images. It contains **240 prompts**: 120 English and 120 Chinese, each asking for a page with a title, author, and literary excerpt. We follow the evaluation setup of [X-Omni's LongText-Bench](https://huggingface.co/datasets/X-Omni/LongText-Bench): generate four images per prompt and measure text coverage with OCR. ## Dataset | Language | Length group | Prompts | Target text length | Unit | |---|---|---:|---:|---| | English | short | 40 | 69–93 | words | | English | medium | 40 | 191–246 | words | | English | long | 40 | 470–570 | words | | Chinese | short | 40 | 330–393 | characters | | Chinese | medium | 40 | 923–1,078 | characters | | Chinese | long | 40 | 1,284–1,601 | characters | Lengths count the normalized title, author, and passage used for scoring. Each language/length group contains 20 `classical` and 20 `modern` excerpts. The 240 prompts come from 80 excerpts, each presented at three lengths. ## Load ```bash pip install datasets ``` ```python from datasets import load_dataset ds = load_dataset("OpenMOSS-Team/LongLongTextBench", "default", split="test") prompt = ds[0]["prompt"] ground_truth = ds[0]["gt_text"] ``` The `default`, `en`, and `zh` configurations contain 240, 120, and 120 rows in their `test` splits. | Field | Meaning | |---|---| | `prompt_id`, `sample_id` | Numeric and descriptive task identifiers | | `language` | `en` or `zh` | | `style` | `classical` or `modern` | | `length` | `short`, `medium`, or `long` | | `prompt` | Full generation input, including instructions and line breaks | | `gt_text` | Target title, author, and passage for scoring | | `text` | A one-element list containing `gt_text` | | `text_length`, `text_length_unit` | Normalized target length and unit (`word` or `character`) | | `title`, `author` | Title and author attribution | ## Generate With Python 3.10+ and Pillow, run from the repository root: ```bash python evaluation/bench.py export --output jobs.jsonl --n-samples 4 --seed 42 python evaluation/local_inference.py --adapter my_adapter:generate \ --jobs jobs.jsonl --images images ``` Export produces 960 jobs with the full prompt, image dimensions, seed, and output filename. Provide `generate(*, prompt, seed, width, height)` in `my_adapter.py`, returning a PIL image. Generation uses 1024×1024 canvases; outputs are saved as `images//samples/.png`, with both IDs padded to five digits. ## Evaluate Use a CUDA-compatible PyTorch/torchvision environment and a local [Qwen2.5-VL-7B-Instruct](https://huggingface.co/Qwen/Qwen2.5-VL-7B-Instruct) checkpoint: ```bash python -m pip install -r evaluation/requirements.txt python evaluation/bench.py check --images images --n-samples 4 python evaluation/bench.py score \ --images images --output score \ --ocr-model /path/to/Qwen2.5-VL-7B-Instruct \ --workers 1 --n-samples 4 ``` OCR processes RGB images resized to 1024×1024 with LANCZOS and uses a maximum of 4,096 output tokens. Coverage matches normalized target and OCR text as multisets: English uses words and Chinese uses characters. Repeated units count up to their frequency in the target text. ```text matched = sum_u min(count_target(u), count_ocr(u)) group coverage = sum_image(matched) / sum_image(target_units) Mean-6 = mean(EN-short, EN-medium, EN-long, ZH-short, ZH-medium, ZH-long) ``` The main result is `score/summary.json` → `macro_overall_mean6`, the mean of the six language/length group scores. Scores range from 0 to 1. Per-image OCR and scores are saved in `score/en/results.jsonl` and `score/zh/results.jsonl`. See [evaluation usage](evaluation/README.md) for additional options. ## Citation If you use LLTB, please cite the [MOSS-Image technical report](https://arxiv.org/abs/2610.23374): ```bibtex @misc{ai2026mossimagetechnicalreport, title={MOSS-Image Technical Report}, author={MOSI. AI}, year={2026}, eprint={2610.23374}, archivePrefix={arXiv}, primaryClass={cs.CV}, url={https://arxiv.org/abs/2610.23374}, } ``` ## License Evaluation tools use [Apache-2.0](CODE_LICENSE), including the bundled [X-Omni license](evaluation/vendor/X-Omni-LICENSE). Text attribution and license scope are described in [LICENSE.md](LICENSE.md).