lca0503's picture
Preprocessed translation dataset with final prompts
f1b34c9
|
Raw History Blame Contribute Delete
5.88 kB
metadata
dataset_info:
  config_name: source
  features:
    - name: id
      dtype: string
    - name: dataset
      dtype: string
    - name: source_text
      dtype: string
    - name: source_language
      dtype: string
    - name: target_language
      dtype: string
    - name: constraint_source
      dtype: string
    - name: target_length
      dtype: int64
    - name: rhyme
      struct:
        - name: finals
          list: string
        - name: id
          dtype: int64
    - name: boundary_mask
      dtype: string
    - name: required_word_boundaries
      list: int64
    - name: boundary_unit
      dtype: string
    - name: messages
      list:
        - name: content
          dtype: string
        - name: role
          dtype: string
    - name: prompt
      dtype: string
    - name: reference
      struct:
        - name: id
          dtype: string
        - name: scope
          dtype: string
        - name: text
          dtype: string
        - name: type
          dtype: string
  splits:
    - name: validation
      num_bytes: 14267180
      num_examples: 4011
    - name: test
      num_bytes: 14272721
      num_examples: 4006
  download_size: 15765741
  dataset_size: 28539901
configs:
  - config_name: source
    data_files:
      - split: validation
        path: source/validation-*
      - split: test
        path: source/test-*
license: cc-by-nc-sa-4.0
tags:
  - lyrics
  - controllable-generation
language:
  - en
  - zh
task_categories:
  - translation

ControllableLyricTranslation

English → Mandarin text-LLM inputs derived from LongshenOu/lyric-trans-en2zh-data, released with ControllableLyricTranslation. This derivative packages the released data_parallel corpus by default, with prompts and supplied controls. A custom corpus can be explicitly selected. The upload pipeline keeps this repository private.

Load

Log in with hf auth login, using an account with access to this repository.

from datasets import load_dataset

data = load_dataset("lca0503/ControllableLyricTranslation", name="source", token=True)
row = data["test"][0]
prompt = row["prompt"]  # Complete input for a text LLM.
messages = row["messages"]  # Alternative for a chat API; use one input form.
reference = row["reference"]  # Keep separate for evaluation.

Configurations and splits

Each processed control protocol is uploaded as a separate configuration. Only configurations and splits that were actually processed are present on the Hub. The default shell command uses source and available validation/test splits. Training data is processed only when explicitly requested.

Configuration Input controls
source Supplied controls declared to come from the source
target Supplied reference-derived controls; these expose target properties
none Source-text-only baseline without length, rhyme or boundary controls

The uploader keeps these protocols separate. It does not construct controls from references or verify the declared origin of external constraint files. val and valid split names are normalized to validation. Other split names are retained. Different corpora in the archive are not automatically combined. The inspected release has 4,011 validation rows and 4,006 test rows in data_parallel; the generated repository metadata gives the actual uploaded sizes.

Fields

Field Meaning
id Stable identity including the source split and row number
source_text English lyrics
prompt Complete ready-to-use text: system instructions, a blank line, then the input JSON
messages System/user messages for the text LLM
target_length Requested Chinese character count, or null
rhyme Supplied rhyme ID and possible finals; ID 0 disables rhyme control
boundary_mask, required_word_boundaries A 1 requires a word boundary after that output character; positions start at 1
constraint_source source, target, or none
reference Supplied translation with scope="line"

Local paths, duplicate split/row metadata and processing diagnostics are excluded from the dataset; full diagnostics remain in local JSONL files and reports.

The opening instruction retains “Write the draft into a Chinese line…” from the local template; no Chinese draft is required. Dataset-specific rules describe supplied text controls. The reference wording is excluded from both prompt and messages. These contain the same instructions and input; choose the form supported by your LLM interface.

Evaluation and limitations

References can support translation comparison. Measure requested length, rhyme and word boundaries separately. Scores using target controls have access to reference-derived properties and must be reported separately from source or none results. A zero boundary-mask bit means unconstrained, not forbidden.

These text files do not supply audio, pitches, note durations, musical rests, or note alignment. The pipeline does not infer musical features from text or synthesize singing. The released parallel Chinese references are stored in reverse character order and are restored before export. Its boundary masks are already in forward order and are preserved. Custom input files support explicit reference/mask reversal overrides. The target protocol uses the release's constraints/reference/ files.

Sources and license

Credit Ou, Ma, Kan and Wang's Songs Across Borders: Singable and Controllable Neural Lyric Translation (ACL 2023). The authors specify CC BY-NC-SA 4.0 for their data and models in the project README. This derivative preserves that data license. Repository metadata records the schemas and counts generated from the uploaded splits.