KatInterview

Design a Multi-Locale String Delivery System

System DesignModel answer
MediumModel answerSystem Designlocalizationinternationalizationcontent delivery

Last updated

Design a system that serves translated strings to clients worldwide, handling locale resolution, variables, plurals, live updates, fallback, and offline support.

The Problem

Your company ships a product to users across dozens of countries. Every string a user sees must be translated, formatted correctly for their locale, and updatable by the content team without waiting for a new app release.

Design the system that makes this work end to end.

What the system must do

  • Resolve the right translation for a given locale, including both language and region (e.g., pt-BR vs pt-PT).
  • Interpolate dynamic values (names, counts, prices) into translated strings safely.
  • Apply language-specific plural rules so that, for example, Russian and Arabic get the correct grammatical forms for quantities.
  • Format dates, numbers, and currencies according to locale conventions.
  • Fall back gracefully when a translation is absent, rather than crashing or showing a key name to the user.
  • Allow the content or localization team to push copy edits that users see without an app release.
  • Support clients that start up with no network connection.
  • Switch the active locale at runtime without restarting the application.

Constraints and assumptions

  • Translation source-of-truth is human-authored. A default-language bundle (typically English) ships inside the application binary.
  • Clients — web, iOS, Android — all consume the same translation catalog.
  • Strings may contain placeholders like {userName} or {count}.
  • Legal or regulatory strings may not be allowed to fall back; the system should support flagging them.
  • The team needs an approval and rollback workflow, not raw file drops.

Expected scope

This is an open-ended design question. Walk through your architecture from catalog schema to client rendering. Cover the translation workflow, bundle publication, client caching strategy, and how you handle failure modes. Interviewers will probe missing-key detection, formatting edge cases, and how copy changes reach users quickly and safely.

Clarifying questions worth raising

Before diving in, a strong candidate asks:

  • What is the acceptable propagation delay for an approved copy change — seconds, minutes, hours?
  • Which client versions must remain compatible with the same catalog?
  • Are there strings that must block on translation completion before a feature ships?
  • Who owns approval, and is there a rollback window?
  • Does the system need to support copy experiments (A/B testing within one locale)?

Hints

Hint 1

Start with the catalog schema: how you name keys and structure locale identifiers shapes everything downstream. Think about what information a client needs to render a string versus what only the pipeline needs.

Hint 2

Separate the question of how a bundle gets from the server to the client from the question of how it gets from disk into memory. Offline startup, cache invalidation, and live switching are three different problems with different solutions.

Hint 3

Work through failure modes explicitly: what happens when the CDN is unreachable, when a placeholder is missing from the translated string, and when a translation was approved but contains a layout-breaking string 3x longer than the English source?