LangMatch

Can Classical Chinese (Wényán) serve as a natural-language compression prompt for LLMs? A controlled study of the quality–cost tradeoff. Visit project site · View on GitHub

Exploratory · May 2026 · reported like a short paper, but too small to publish — findings are preliminary, not a formal result.

LangMatch — does a more compressed prompt language buy a better quality–cost frontier?

1 · Background

LLM inference cost scales with context length: longer prompts mean more tokens, higher latency, and more context pressure. Prompt-compression research shows that shrinking the input while preserving behaviour is a real efficiency lever. A second line of work shows tokenizers are not language-fair — the same meaning costs a different number of tokens in different languages — and cross-lingual prompting shows the prompt language changes not just token count but the model's behaviour, reasoning path, and format compliance.

Classical Chinese is exceptionally dense: heavy ellipsis, high information density, terse grammar. That makes it an intuitive candidate for a “natural-language compression prompt.” But the intuition does not settle two things: (1) is Wényán actually cheaper under the tokenizer, and (2) if it is, does task success survive?

2 · Objective & research questions

The key comparison is not “which language is shorter,” but: under fixed tasks and fixed model backends, does a more compressed prompt language produce a better quality–cost frontier? Only the language of the system prompt changes; the task is held constant.

  • RQ1 — Under semantic equivalence, does a Wényán system prompt reliably reduce input tokens?
  • RQ2 — Does any token saving come at the cost of success rate / instruction-following / accuracy?
  • RQ3 — Do differences come mainly from tokenizer segmentation, or from style-induced behaviour change?
  • RQ4 — Does the effect reproduce across model families (open vs. closed)?

3 · Related work

  • Ancient-Chinese LLMs (C3Bench, TongGu, Fuxi, WenyanGPT) treat Classical Chinese as a first-class, separately-modelled language — but focus on understanding / generation, not token efficiency.
  • Cross-lingual prompting shows the prompt language shifts model behaviour, reasoning, and format compliance — not just surface tokens.
  • Token tax / tokenizer fairness shows the same information costs differently across languages — language itself is a cost variable.
  • Prompt compression (LLMLingua, Selective Context) proves shrinking prompts is valuable — but via algorithmic compression, not by exploiting a language's own expressive density.

These four lines have never been combined into one testable question: can Classical Chinese act as a natural-language compression prompt? LangMatch is that controlled test — it does not train a new Wényán model, it evaluates Wényán as a system-prompt language under strict variable control.

4 · Experiment design

Three functionally-equivalent system-prompt modes — same task, same models, same output budget; only the prompt language changes:

base — compact English

You are a helpful assistant. Follow the user's instructions carefully. Except for code and direct quotations, keep explanations and narration concise. Avoid colloquial filler. Eliminate redundancy and aim for compact, clear expression.

zh_compact — Modern Chinese

你是一个有帮助的助手。请严格遵循用户要求。除代码和直接指令外,所有解释与叙述都尽量写得简洁。禁止口语化赘述,删繁就简,要求表达精炼、意思清楚。

wy — Classical Chinese (Wényán)

汝为善应人问之助手,当谨循其命。凡码与引文外,释理叙事宜从简。禁绝白话冗词,务求辞约义明。

  • Models: gpt-4o, gpt-5.4, qwen3-1.7b, qwen3-4b — API and local (Transformers) backends under one pipeline
  • Benchmarks: IFEval (instruction-following), MATH-500 (text-only subset, final-answer accuracy), MMLU-Pro
  • Metrics: prompt / completion / total tokens; benchmark Score or SR; and Score per 1k tokens as the efficiency axis
  • Budget & auditing: a unified 2048-token output budget with per-run token accounting; the runner records configured_max_tokens, finish_reason, and usage, so truncation is detected rather than silently scored
Manifest (fixed task subsets)
  → run all task × prompt-mode × model combinations
  → raw results.jsonl + per-run summaries
  → cross-run aggregation into matrix reports
  → Pareto frontier plots (score vs. total tokens)

Rigor note. An early pilot used tight caps (IFEval 192, MATH-500 64, MMLU-Pro 8) and produced truncation artifacts — most sharply, gpt-5.4 / IFEval returned empty visible output while still consuming the full completion budget, making the model look weak. The main matrix was rerun at 2048, which cleared the artifacts for gpt-4o, gpt-5.4, and qwen3-4b (0 cap-hits); qwen3-1.7b retains 4 cap-hits (finish_reason=length) and is read cautiously. All numbers below are the corrected 2048 rerun.

A follow-up 3-run study holds the language fixed (base / zh / wy) and instead varies the interaction setting — explicit_process (visible reasoning), hidden (think but don't show), compact_visible (brief visible reasoning) — to separate the effect of prompt language from that of reasoning visibility.

5 · Results

5.1 Main matrix (2048-token budget)

Overall, aggregated across benchmarks (each point one model × prompt-mode combination):

ModelPromptNScorePrompt TokCompletion TokTotal TokScore/1k
gpt-4obase590.593182.9337.12220.052.696
gpt-4ozh_compact590.627200.9329.59230.532.720
gpt-4owy590.576187.9332.86220.802.610
gpt-5.4base590.729181.9354.64236.583.081
gpt-5.4zh_compact590.746199.9349.05248.982.995
gpt-5.4wy590.763186.9345.15232.083.286
qwen3-1.7bbase590.339197.85127.00324.851.044
qwen3-1.7bzh_compact590.271203.85125.20329.050.824
qwen3-1.7bwy590.254197.85228.12425.970.597
qwen3-4bbase590.441197.85121.95319.801.378
qwen3-4bzh_compact590.475203.8569.98273.831.733
qwen3-4bwy590.475197.8598.71296.561.600

gpt-5.4 is the strongest model overall, and its earlier weak IFEval showing was confirmed to be a truncation artifact, not a real deficit. zh_compact is the most stable prompt family (best for gpt-4o, ties best for qwen3-4b); wy is a conditional gain — the single strongest overall mode on gpt-5.4.

Pareto-style score vs. total tokens, per benchmark (click any figure for full size):

IFEval: score vs. total token tradeoff

IFEval — qwen3-4b hits the same score at the lowest token cost; gpt-5.4's wy variant is its cheapest.

MATH-500: score vs. total token tradeoff

MATH-500 — preferences split by model: gpt-4o favours zh_compact, gpt-5.4 favours wy.

MMLU-Pro: score vs. total token tradeoff

MMLU-Pro — zh_compact holds up as the robust default.

IFEval

After removing the cap artifact, gpt-5.4 reaches 1.000 SR under all three modes; qwen3-4b also saturates. On this benchmark high-capacity models satisfy the task under multiple prompt languages.

ModelPromptNScorePrompt TokCompletion TokTotal TokScore/1k
gpt-4obase110.90992.45182.36274.823.308
gpt-4ozh_compact110.909110.45141.82252.273.604
gpt-4owy110.81897.45161.45258.913.160
gpt-5.4base111.00091.45269.36360.822.771
gpt-5.4zh_compact111.000109.45239.09348.552.869
gpt-5.4wy111.00096.45218.18314.643.178
qwen3-1.7bbase110.909101.00314.55415.552.188
qwen3-1.7bzh_compact110.909107.00319.91426.912.129
qwen3-1.7bwy111.000101.00391.45492.452.031
qwen3-4bbase111.000101.00177.82278.823.587
qwen3-4bzh_compact111.000107.00129.64236.644.226
qwen3-4bwy111.000101.00151.73252.733.957

MATH-500

The headline split: zh_compact is best for gpt-4o, while wy is best for gpt-5.4 — Wényán becomes a real quality–cost contender on capable models and concise reasoning tasks. qwen3-4b's best score is under wy, while zh_compact stays slightly cheaper.

ModelPromptNScorePrompt TokCompletion TokTotal TokScore/1k
gpt-4obase240.542146.795.29152.083.562
gpt-4ozh_compact240.708164.795.46170.254.161
gpt-4owy240.583151.794.71156.503.727
gpt-5.4base240.625145.795.88151.674.121
gpt-5.4zh_compact240.667163.796.00169.793.926
gpt-5.4wy240.708150.796.00156.794.518
qwen3-1.7bbase240.208158.2178.12236.330.882
qwen3-1.7bzh_compact240.083164.2123.54187.750.444
qwen3-1.7bwy240.000158.21120.92279.120.000
qwen3-4bbase240.250158.21155.62313.830.797
qwen3-4bzh_compact240.250164.21108.46272.670.917
qwen3-4bwy240.292158.21165.50323.710.901

MMLU-Pro

The most conservative benchmark: it does not reward Wényán as clearly. Once truncation is removed, gpt-5.4 is uniformly strong across modes; gpt-4o still prefers base, qwen3-4b still prefers zh_compact — a model-task interaction that survived the rerun.

ModelPromptNScorePrompt TokCompletion TokTotal TokScore/1k
gpt-4obase240.500260.542.38262.921.902
gpt-4ozh_compact240.417278.542.29280.831.484
gpt-4owy240.458265.542.08267.621.713
gpt-5.4base240.708259.545.00264.542.678
gpt-5.4zh_compact240.708277.545.00282.542.507
gpt-5.4wy240.708264.545.00269.542.628
qwen3-1.7bbase240.208281.8889.92371.790.560
qwen3-1.7bzh_compact240.167287.88137.62425.500.392
qwen3-1.7bwy240.167281.88260.46542.330.307
qwen3-4bbase240.375281.8862.67344.541.088
qwen3-4bzh_compact240.458287.884.17292.041.569
qwen3-4bwy240.417281.887.62289.501.439

5.2 LangMatch 3-run (interaction settings)

Language fixed; interaction setting varied. Overall SR vs. tokens under explicit, hidden, and compact-visible reasoning (IFEval panels are missing-data placeholders in this export, not negative results):

explicit_process / overall: score vs. token tradeoff

Explicit reasoning — gpt-5.4 + wy is the standout point.

hidden / overall: score vs. token tradeoff

Hidden reasoning — mainly shifts points left (cheaper), not up.

compact_visible / overall: score vs. token tradeoff

Compact-visible — a middle ground between cost and score.

explicit_process

ModelSettingNSRPrompt TokCompletion TokTotal Tok
gpt-4obase480.688205.67488.21693.88
gpt-4owy480.708241.58342.77584.35
gpt-4ozh480.688232.52543.54776.06
gpt-5.4base480.646204.67180.90385.56
gpt-5.4wy480.833240.58337.83578.42
gpt-5.4zh480.667231.52206.10437.62
qwen3-4bbase480.583215.541180.711396.25
qwen3-4bwy480.396232.061014.481246.54
qwen3-4bzh480.646216.901149.191366.08

hidden

ModelSettingNSRPrompt TokCompletion TokTotal Tok
gpt-4obase480.562207.178.38215.54
gpt-4owy480.438240.3821.83262.21
gpt-4ozh480.479229.298.44237.73
gpt-5.4base480.625206.1711.02217.19
gpt-5.4wy480.604239.3811.29250.67
gpt-5.4zh480.604228.2918.60246.90
qwen3-4bbase480.667217.041017.151234.19
qwen3-4bwy480.438229.38899.081128.46
qwen3-4bzh480.646214.211002.831217.04

compact_visible

ModelSettingNSRPrompt TokCompletion TokTotal Tok
gpt-4obase480.667225.67151.27376.94
gpt-4owy480.646268.42135.17403.58
gpt-4ozh480.688252.12164.65416.77
gpt-5.4base480.583224.6712.35237.02
gpt-5.4wy480.833267.42114.50381.92
gpt-5.4zh480.562251.1216.90268.02
qwen3-4bbase480.708235.54842.601078.15
qwen3-4bwy480.479254.08824.711078.79
qwen3-4bzh480.667236.00713.25949.25

gpt-5.4 + wy is the standout under both explicit_process and compact_visible (SR 0.833); hidden mainly reduces cost rather than raising scores; qwen3-4b shows no stable Wényán advantage.

Full result reports:

6 · Takeaways

  • Prompt-language effects are real, but strongly model- and task-dependent.
  • zh_compact is the most robust default across closed and open families.
  • wy is a serious candidate on strong models — its gains on gpt-5.4 survive the corrected rerun, and it is best on gpt-5.4 / MATH-500 — but it is not universal.
  • In the 3-run view, reasoning visibility matters alongside language; hidden is a cost-reduction setting, not a score-maximizing one.

Working conclusion: Classical Chinese functions as a conditional prompt-compression strategy, not a universal one — worth switching on per model, not by default.

7 · Rigor & limitations

  • The 2048 rerun cleared truncation artifacts for gpt-4o, gpt-5.4, and qwen3-4b; qwen3-1.7b still has 4 cap-hits and is interpreted cautiously.
  • Token counts come from source-native backends (openai for GPT logs, transformers for qwen logs) — read them within-model, not as tokenizer-identical across providers.
  • Prompt modes are functionally close but not perfectly translation-aligned; a style-vs-density confound is mitigated by including the Modern-Chinese compact control (zh_compact), not fully eliminated.

Early-stage — findings are preliminary observations, not a formal result.