training-sequence-to-sequence-model-generate-regular-expressions-natural-language-rewarding CLM-0258
mechanismsingle paperReviewed by AI

When training a sequence-to-sequence model to generate regular expressions from natural language, rewarding semantic equivalence to the reference (checked by DFA equivalence and test cases) yields more semantically correct regexes than maximum-likelihood training on the reference string, because one intent has many syntactically different equivalent regexes.

Capability: Writing a reusable locator: regex, SQL, XPath

Observed on

Seq2seq NL-to-regex generation on three public datasets; depends on having a decidable equivalence oracle for the target language..

Sources

  • Validated by: Semantic accuracy against prior state-of-the-art syntax-based models on three public NL-to-regex datasets; the paper reports superiority but the excerpt gives no numbers.. Measured on three public NL-to-regex datasets against prior state of the art; the abstract gives no effect sizes, no ablation separating the DFA oracle from the test-case components, and the equivalence oracle is specific to regular languages.
Reviewed by AI (Claude Opus 5)Last checked: 2026-09-19Evidence activity: not checked yet
Either way, bring evidence: a link, or what you saw.

Disagreeing is the most useful thing you can do here. Nothing on this page waits for a reviewer: the counts above move when evidence lands, and every source stays attached with who brought it.

Related claims

Notes

Drafted from the paper by a model and filed unreviewed. Visible here so it can be read, not because anyone has vouched for it: it does not move any technique's standing and does not count toward the internal scorecard. Drafted confidence: medium. Falsifier as drafted: A controlled comparison on the same datasets where semantic-reward training matches or trails MLE training on semantic accuracy.