Flan-T5-Large-HTR
Outputs are synthetic reconstructions. They are a model's estimate of pre-2018-style scientific prose given an LLM rewrite. They are not the original text and not evidence of human authorship or of AI use. Do not use this model for AI-text detection, authorship attribution, grading, or academic-integrity decisions, and do not present its output as human-written.
Part of UQO Working Paper WP-AI-0002, "Human Text Reconstruction: Learning the Inverse of LLM-Induced Transformations in Scientific Writing"
(Simon-Pierre Boucher, Université du Québec en Outaouais, 2026). Try it at https://htr.spboucher.ai (model id flan-t5-large-htr).
| Field | Value |
|---|---|
| Family | hf-seq2seq (pretrained backbone fine-tuned on the HTR pairs (STRAP-style inverse paraphrase)) |
| Parameters | 783,150,080 |
| Base model | google/flan-t5-large |
| Speed (Apple M4 Pro GPU, greedy) | ≈1.5 s per paragraph, ≈6 s for 3 000 characters (greedy, Apple GPU) |
| Exported | 2026-11-10 |
What it does
Given a paragraph of scientific prose that a large language model has rewritten, the model produces a passage closer to the
register of the pre-2018 human original: it reverses part of the LLM's lexical and stylistic transformation while keeping numbers,
citations (as [[C1]]/⟦C1⟧ placeholders), equations and URLs unchanged. Gains are measured against the identity baseline
(returning the input unchanged), which is itself a strong baseline because reconstruction from a paraphrase is non-identifiable.
Results (paired differences vs identity, chrF++, ± 1.96 SE)
| Split | Δ chrF++ vs identity (B0) |
|---|---|
| Validation (3 000 pairs) | +2.04 ± 0.15 |
| Test (15 649 pairs) — exploratory | +1.79 ± 0.07 |
| Held-out disciplines (physics, earth sciences; 2 493) | +1.27 ± 0.18 |
| Held-out period (books < 1900; 2 574) | +1.09 ± 0.14 |
Preservation on the test split: number recall 0.986, placeholder (citation/equation/URL) exactness 0.992. Pangram 4.1 detector sensitivity (54 test passages; input rewrites 46 % flagged): 54/54 labelled Human, mean AI-likelihood 0.0. This measures one commercial detector's behaviour on a 54-passage sample. A low AI-likelihood is not evidence of human authorship, and HTR must not be used to evade AI-text detection or for integrity decisions.
Training data
Fine-tuned on the same 72 698 validated Haiku rewrite → original pairs (Medium stage of WP-AI-0002, same document-safe splits), context given as a text prefix; placeholders spelled [[C1]] for the pretrained tokenizer. The originals are rights-verified scientific passages published before 2018 (PMC Open Access, CC BY economics and finance journals, arXiv, public-domain books, NCBI Bookshelf, OpenStax); the rewrites were produced by Claude Haiku 5.5 (Anthropic) with five prompt variants. The pairs are not released. Caveat (pretrained backbone): its pretraining corpus may contain pre-2018 scientific text; the paper's memorisation audits cover only the HTR training pairs.
How to use
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
tok = AutoTokenizer.from_pretrained("spboucher04/flan-t5-large-htr"); model = AutoModelForSeq2SeqLM.from_pretrained("spboucher04/flan-t5-large-htr")
text = "reconstruct: <disc:economics> <era:2010s> <role:results> <src:local> " + rewritten_passage # metadata prefix; citations as [[C1]]
out = model.generate(**tok(text, return_tensors="pt", truncation=True, max_length=512), max_new_tokens=512)
print(tok.decode(out[0], skip_special_tokens=True))
T5's vocabulary cannot encode <, ~, ±, →, ≤ or Greek letters (they become <unk>); the HTR inference code
(htr.inference.backbones.HFSeq2SeqReconstructor, served at htr.spboucher.ai) replaces them by [[S1]]… placeholders and restores them.
Limitations and intended use
- Research on how LLM rewriting transforms scientific prose, stylometric analysis, benchmarking inverse-paraphrase models, and drafting suggestions that must be checked by the author. Not for AI-text detection, authorship attribution or integrity decisions.
- The model can change meaning; the inference code returns warnings when numbers, citations, negations or hedges differ from the input.
- Trained on English scientific prose of 60–400 words; other genres and languages are out of scope.
- Pretrained backbone: its pretraining corpus may contain pre-2018 scientific text; memorisation controls cover only the HTR training pairs (see the paper's threats-to-validity section).
- Reads at most 512 tokens (about 2 000 characters): longer inputs are truncated and a warning is returned.
- System B2 of the paper (fine-tuned pretrained encoder–decoder baseline).
Licence
Weights: CC BY-NC 4.0 — non-commercial research use (the training pairs include CC BY-NC sources and LLM outputs). Base model: google/flan-t5-large under its own licence.
Citation
@techreport{boucher2026htr,
title = {Human Text Reconstruction: Learning the Inverse of LLM-Induced Transformations in Scientific Writing},
author = {Boucher, Simon-Pierre},
institution = {Université du Québec en Outaouais},
series = {UQO Working Papers}, number = {AI-0002}, year = {2026}
}