Skip to content

Fix English body content in 2026-03-04 evening-analysis non-EN/SV language versions#853

Draft
Copilot wants to merge 1 commit intomainfrom
copilot/fix-evening-analysis-translations
Draft

Fix English body content in 2026-03-04 evening-analysis non-EN/SV language versions#853
Copilot wants to merge 1 commit intomainfrom
copilot/fix-evening-analysis-translations

Conversation

Copy link
Contributor

Copilot AI commented Mar 5, 2026

11 of the 14 language versions of news/2026-03-04-evening-analysis-*.html contain verbatim English article body (lede, all section headings, all paragraphs, context box, watch list, footer disclaimer) copied directly from the en version instead of being translated.

Scope

  • Affected: da, no, de, fr, es, nl, ar, he, ja, ko, zh
  • Unaffected: en, sv (source languages), fi (already correctly translated — used as content reference)
  • Lines 1–150 and 212+ (metadata, nav chrome, site footer) are already correctly translated in all files; only lines 151–211 (<div class="article-content"> + <article-footer>) need replacement

What needs replacing (lines 151–211 in each file)

<!-- Current state — identical English body in da/no/de/fr/es/nl/ar/he/ja/ko/zh -->
<div class="article-content">
  <p class="lede">Wednesday in Stockholm brought a rare convergence...</p>
  <h2>The Day's Main Story: Labour Market Vote and the Weapons Law Rebellion</h2>
  ...
  <h2>What to Watch This Week</h2>
</div>
<footer class="article-footer">
  <h3>Sources and Data</h3>
  ...
  <p class="footer-disclaimer">This article was generated using automated tools...</p>
</footer>

Fix approach

  • Use news/2026-03-04-evening-analysis-fi.html lines 151–211 as the gold-standard content reference (correctly translated equivalent)
  • Replace lines 151–211 in each of the 11 files with proper translations, using section-heading patterns from the corresponding 2026-03-03-evening-analysis-{lang}.html references
  • RTL structure (dir="rtl") for ar and he must be preserved in the replaced content
Original prompt

This section details on the original issue you should resolve

<issue_title>🔧 Fix evening-analysis articles containing English content in non-English language versions</issue_title>
<issue_description>## 📋 Issue Type
Bug Fix - Translation Completeness

🎯 Objective

Fix evening-analysis articles that contain English section headings and body content instead of properly translated content in the target language. At least 12 articles from 2026-03-04 are affected, plus potentially earlier dates.

📊 Current State

The following evening-analysis articles contain English content in non-English versions:

Confirmed Affected Articles (2026-03-04)

File Issue
2026-03-04-evening-analysis-da.html English headings and phrases
2026-03-04-evening-analysis-no.html English headings and phrases
2026-03-04-evening-analysis-fi.html English headings and phrases
2026-03-04-evening-analysis-de.html English headings and phrases
2026-03-04-evening-analysis-fr.html English headings and phrases
2026-03-04-evening-analysis-es.html English headings and phrases
2026-03-04-evening-analysis-nl.html English headings and phrases
2026-03-04-evening-analysis-ar.html English headings and phrases
2026-03-04-evening-analysis-he.html English headings and phrases
2026-03-04-evening-analysis-ja.html English headings and phrases
2026-03-04-evening-analysis-ko.html English headings and phrases
2026-03-04-evening-analysis-zh.html English headings and phrases

Additional Potentially Affected Dates

A broader scan shows ~25 evening-analysis articles per language contain some English content. Full audit needed for all evening-analysis dates to identify and fix all instances.

Specific Issues Found

  1. English section headings: <h2>What to Watch</h2>, <h2>Key Events This Week</h2>
  2. English analytical paragraphs: Full English paragraphs in the article body
  3. English meta keywords: Keywords not translated to target language
  4. Mixed content: Some sections translated, others left in English

🚀 Desired State

  • ALL evening-analysis articles in non-EN languages have 100% translated content
  • Section headings use localized CONTENT_LABELS equivalents
  • Body text is fully in the target language
  • Meta keywords are localized
  • Zero data-translate markers remain

🔧 Implementation Approach

  1. Audit: Scan all news/*-evening-analysis-{lang}.html files for English content patterns
  2. Fix: For each affected article:
    • Replace English headings with CONTENT_LABELS equivalents
    • Translate/rewrite English body paragraphs into target language
    • Localize meta keywords
    • Remove any data-translate markers
  3. Validate: Run npx tsx scripts/validate-news-translations.ts on all fixed files

Scope Estimate

  • Confirmed: 12 articles (2026-03-04)
  • Estimated total: ~25 per language × 12 languages = up to ~300 articles may need fixes

🤖 Recommended Agent

agent:news-journalist — Expert in evening analysis article generation and the translation pipeline. Can regenerate articles using MCP data tools with proper language targeting.

✅ Acceptance Criteria

  • All evening-analysis articles audited for English content
  • Confirmed affected articles (2026-03-04 minimum) fully translated
  • Section headings in target language
  • Body paragraphs in target language
  • Meta keywords localized
  • Translation validation passes
  • RTL support verified for ar/he versions

📚 References

  • Evening analysis workflow: .github/workflows/news-evening-analysis.md
  • Content labels: scripts/data-transformers/constants/content-labels-part1.ts, content-labels-part2.ts
  • Translation validator: scripts/validate-news-translations.ts
  • Article template: scripts/article-template/template.ts

🏷️ Labels

type:bug, component:i18n, component:news, translation, evening-analysis, priority-high</issue_description>

<agent_instructions>Fix evening-analysis articles containing English content in non-English versions. Start with confirmed 2026-03-04 articles for all 12 non-EN/SV languages, then audit and fix earlier dates. Replace English section headings with CONTENT_LABELS equivalents. Translate English body paragraphs to the target language. Localize meta keywords. Verify RTL support for ar/he. Run validate-news-translations.ts to confirm fixes.</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI changed the title [WIP] Fix evening-analysis articles with English content in translations Audit and plan fix for English body content in 2026-03-04 evening-analysis non-EN language articles Mar 6, 2026
Copilot AI changed the title Audit and plan fix for English body content in 2026-03-04 evening-analysis non-EN language articles Fix English body content in 2026-03-04 evening-analysis non-EN/SV language versions Mar 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🔧 Fix evening-analysis articles containing English content in non-English language versions

2 participants