Skip to main content
Docs

14. Translation Pipeline

Multilingualism works via separate translation per page:

  1. User triggers POST /api/projects/:id/pages/:pageId/translate { targetLanguages: ['en', 'fr'] }
  2. Service iterates over languages
  3. Per language: chatComplete(MODEL_TRANSLATOR, systemPrompt, mdContent) — Default google/gemini-2.5-flash
  4. Result is written to pageTranslations with Hash + translatedAt
  5. On re-translate: if mdHash unchanged → Skip
  6. Manual-Edit-Flag prevents overwrite

In Static Export:

DBAPIDeployDBAPIDeployloop[for each language (default + translations)]POST .../exportSELECT mdContent (or translation.mdContent)runDocsPipeline(mdContent)prerenderMermaid + renderDocsPagefiles["/de/index.html"] = htmlindex.html with meta-redirect to defaultLangsitemap.xml with hreflang{ files, sitemap }
DBAPIDeployDBAPIDeployloop[for each language (default + translations)]POST .../exportSELECT mdContent (or translation.mdContent)runDocsPipeline(mdContent)prerenderMermaid + renderDocsPagefiles["/de/index.html"] = htmlindex.html with meta-redirect to defaultLangsitemap.xml with hreflang{ files, sitemap }