PhoenixKitAI.Translatable adapter for a publishing GROUP's display name —
the second publishing resource on PhoenixKitAI's generic translation
pipeline (posts ride PhoenixKitPublishing.AITranslatable).
Resource identity
resource_type is "publishing_group"; resource_uuid is the group row's
uuid (exposed on the public group map as "uuid" for exactly this).
Fields
One translatable field: %{"name" => primary name} — lowercase to match a
{{name}} prompt placeholder (PhoenixKitAI's substitution is
case-sensitive). put_translation/4 merges the translated name into the
group's data["name_i18n"] map, capped to the same max length the primary
name column enforces.
Concurrency
Unlike posts (one content ROW per language), every language shares the ONE
group row's name_i18n JSONB — so the merge re-reads the row FOR UPDATE
(the projects/catalogue adapters' pattern): concurrent per-language jobs
serialize on the row lock and each merges against the latest committed map,
never dropping a sibling language.
Audit + events
Each merged language logs publishing.group.updated (mode "auto", actor
from the pipeline opts, locale-agnostic metadata). No :group_updated
PubSub broadcast is emitted per merge — see log_translated/3 for why.
Summary
Functions
The resource-type key this adapter registers under.