Comprehensive proof plan for the remaining Phase 3 lemmas (the
String-level universal round-trip). Covers:
· Current state — Phase 1, 2, length bounds, token-level
universal, atomic decide witnesses, foundation tokenize lemmas.
· The obstacle — Lean 4.30 String is UTF-8 ByteArray-backed,
so `s.push c ++ xs.asString = s ++ (c :: xs).asString` is
not definitionally true.
· Two solution paths:
A. Refactor `readIdent`/`readStrLit` to `List Char`
accumulators (~20 line refactor + ~470 lines proof).
B. Import Mathlib's structural String lemmas (~500 lines
proof, no refactor).
· Lemma-by-lemma proof plan with statements, sketches, and
line-count estimates for each of the 7 lemmas.
· Recommendation: Path A — stays in Lean core, decouples all
future Phase 3 proofs from String internals.
Estimated effort: 2–3 focused days for either path.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>