// translate_negation_gate.el - EN -> ES/PT translation of the poem's negation // lines. The bar (Aug-13 python reference): // l11 "You never fought the ocean." -> "Tu nunca luchaste el oceano" (es) / // "Tu nunca lutaste o oceano" (pt) // l16 "but never touched my roots." -> "...nunca toco los raices" / // "...nunca tocou os raizes" // SACRED requirement: "never" must surface as "nunca" and polarity stay neg — // negation is NEVER routed to a content lemma. fn tg_line(text: String) -> String { let spec: [String] = parse_spec(text) let pol: String = slots_get(spec, "polarity") let negw: String = slots_get(spec, "neg_word") let pred: String = slots_get(spec, "predicate") let pat: String = slots_get(spec, "patient") let es: String = translate_line(text, "es") let pt: String = translate_line(text, "pt") let out: String = "EN: " + text + "\n" let out = out + " spec: pol=" + pol + " neg_word=" + negw + " pred=" + pred + " patient=" + pat + "\n" let out = out + " ES: " + es + "\n" let out = out + " PT: " + pt + "\n" // SACRED check: if source is negative, "nunca" must appear in both surfaces. let es_ok: String = "n/a" if str_eq(pol, "neg") { let es_ok = "NUNCA-LOST" if str_contains(es, "nunca") { let es_ok = "nunca-ok" } } let out = out + " negation[es]: " + es_ok + "\n" return out } fn run_translate_negation_gate() -> String { let rep: String = "==== ELP EN->ES/PT translation — negation lines ====\n" // Negation lines (SACRED nunca must hold): let rep = rep + tg_line("You never fought the ocean.") let rep = rep + tg_line("but never touched my roots.") let rep = rep + tg_line("I never saw the breaking.") // Affirmative controls: let rep = rep + tg_line("You waited like the shoreline.") let rep = rep + tg_line("I broke against your truth.") return rep } println(run_translate_negation_gate())