You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(sections): send title keys for recommendation rows and the old trending default - #3729
Stacked on #3728, which is stacked on #3727. Review and merge those first.
Related issue: N/A
Validation tasks: none affected (every title stays the same)
Recommendation rows on the Discover and For You screens reach clients with English titles only, such as "Highly Rated in Your Library", "Recently Added" and "Because you enjoy Crime", so a translated client can't show them in the user's language. Separately, servers set up before the default home rows were reworked still have a "Trending on Server" home row that #3727's backfill missed, because it lists only today's defaults. This change keys both.
Approach
RecommendationRow (getDiscover, getForYouMain, listForYouRows, getRecommendationSection) carries the optional title_key and title_args that section reads gain in #3727, while the title is one the server words. That covers For You, taste-cluster rows (home.section.becauseYouEnjoy, with the cluster's genres), Picked from your history, Profiles Like You Enjoyed, Popular, Recently Added, Highly Rated and genre rows. A title in any other wording, such as one cached by an older build, carries no key. The key is derived in the v2 adapter, so the empty For You fallback is keyed too.
A new migration keys home rows of the trending type whose title is still "Trending on Server". Renamed rows, and rows of other types that share the text, stay unkeyed. Its down step is a no-op.
The field and capability docs now say clients act on title_key whenever it is present; section_title_keys is informational. /api/v1 bodies and the Jellyfin surface are unchanged.
Validation
A Postgres test drives the real recommendations handler and reader through the v2 router. Discover, For You main (including its empty fallback), and the top-rated, recently-added and genre sections return their keys and arguments. It failed before this change.
A table test covers each wording, older wordings and mismatched row types.
A migration test checks that only the old default's rows are keyed. Removing the type and library conditions makes it fail.
On a sandbox upgraded from an existing database: the trending row and every recommendation row carried their keys, a rename cleared the trending key, and /api/v1 was unchanged. This ran before the rebase onto current main; the rebase applied without conflicts.
Rebased onto current main: the generated-contract checks, the focused package tests and this stack's Postgres pins pass. The full pre-PR gate and every scripts/ci/db-contracts.txt test passed against a freshly migrated scratch database on the previous rebase, apart from two real-FFmpeg tests that fail the same way on main with that host's FFmpeg 6.1.1.
Not covered live: cluster rows need a taste profile; the unit table and the Postgres test cover them.
Evidence
Captured end to end on a sandbox running this stack with the web translation stack merged in, before and after: "Trending on Server" translated in Spanish and Arabic, and the API responses carrying the recommendation row keys. The web For You page still shows its headings in English, because the web app doesn't read these keys yet (follow-up). The page names both builds.
Migration: one UPDATE on page_sections limited to the old default's rows. Down is a no-op.
Additive fields only.
Checklist
I read and can explain the complete diff.
This pull request addresses one concern.
Each test this pull request adds meets "Decide what to test" in CONTRIBUTING.md.
The Evidence section shows every change a user can see, or says there is none.
Follow-ups
The translation catalog needs the five new home.section.* keys before a client reads title_key on recommendation rows. The web, Android, Apple and Roku translation stacks then read the fields on Discover and For You.
Server text that is still English: the Requests discover row titles, recipe preset names (including "Top Picks Today"), task names, transcode preset names and plugin descriptions.
Adversarial review: a plan round with gpt-6.1-sol (xhigh) keyed the empty For You fallback, narrowed the migration to the old default's rows, and fixed the field docs. claude-opus-5-5 (high) moved key derivation out of the handlers and dropped an unreachable key. A local high-effort code review fixed two docs errors. An adversarial round with gpt-6.1-sol found nothing. A background gpt-6.1-sol (xhigh) review of f7ef06d1f6 found nothing.
Add title_key and title_args to recommendation rows and key legacy Trending on Server rows
Recommendation rows now embed SectionTitleKey, so responses from discover, For You, and recommendation-section reads can carry a translation key and arguments. A shared recommendationRow builder derives the key from row type and label via recommendations.ForYouRow.TitleKey in recommendations.go
TitleKey in titles.go adds mappings for cluster rows labeled For You, Because you enjoy labels, and the similar-users label
Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).
Recommendation API responses now include title localization metadata for supported rows. API contracts document the metadata, and a migration assigns a title key to matching default trending sections.
Changes: Recommendation title localization
Layer / File(s)
Summary
Title metadata API contracts contracts/api/v2/openapi.json, web/src/api/v2/schema.ts, docs/architecture/api-contract.md, docs/catalog-api.md, internal/apiv2/home.go, internal/apiv2/library_views.go
API schemas and documentation describe title keys and optional title arguments for recommendation rows. They state that clients use a title key whenever it is present.
Additional recommendation row types map to title keys, including genre arguments where needed. API responses and fixtures include the metadata, with tests covering title mappings and response endpoints.
The migration assigns a title key to matching unkeyed default trending sections. Its test checks matching and non-matching rows after migration up and down.
The documentation can mislead writers about when a title change clears localization metadata. Clarify the condition; the remaining risk is bounded.
Architecture risk: Low · up to a4a97
The change affects 6 systems.
Changed systems:internal, contracts, docs, migrations, scripts, web
Architecture concerns
No architecture-level concerns identified.
Review details
Systems and components
observed — internal (service) was modified; 7 changed files map to changed impact.
observed — contracts (api) was modified; 4 changed files map to changed impact.
observed — docs (service) was modified; 2 changed files map to changed impact.
observed — migrations (service) was modified; 2 changed files map to changed impact.
Before / after behavior
observed — Modified behavior in contracts/api/v2/fixtures/get_discover_ok.json: The fixture’s cluster item now includes the localization key home.section.becauseYouEnjoy and title arguments containing the genre Crime.
observed — Modified behavior in contracts/api/v2/fixtures/get_for_you_main_ok.json: The fixture adds title_key and title_args containing the Crime genre.
observed — Modified behavior in contracts/api/v2/fixtures/list_for_you_rows_ok.json: The fixture adds localization metadata to the row: the title key home.section.becauseYouEnjoy and title arguments specifying the Crime genre.
observed — Modified behavior in contracts/api/v2/openapi.json: The title_key description now includes generated recommendation-row names and says clients act on the key whenever present, replacing the prior getHomeCapabilities capability condition.
Pre-merge checks: 5
Check name
Status
Explanation
Title check
The title "feat(sections): send title keys for recommendation rows and the old trending default" matches the main change. The PR adds optional title_key and title_args to v2 RecommendationRow response…
Description check
The description states the problem, approach, validation, risks, and follow-ups. It explains that Discover and For You recommendation rows reach clients with English-only titles, and that a migration …
Docstring Coverage
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "feat(sections): send title keys for recommendation rows and the old trending default" matches the main change. The PR adds optional title_key and title_args to v2 RecommendationRow responses and adds a migration that keys legacy 'Trending on Server' home rows. The title is specific and concise, though it is long at 84 characters and uses a conventional-commit prefix.
Full details: Description check
Explanation
The description states the problem, approach, validation, risks, and follow-ups. It explains that Discover and For You recommendation rows reach clients with English-only titles, and that a migration keys legacy 'Trending on Server' rows. The changes in the raw summary (recommendation-row title keys, title_args, fixtures, docs, and the migration) match these claims.
Full details: Docstring Coverage
Explanation
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 4 functions across 8 files. (1 skipped: 1 unsupported.)
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
silo-triageBot
added
the
size/L
200–499 added + deleted lines (all files); change volume, not priority.
label
Nov 9, 2026
silo-triageBot
added
api-v2
API v2 / Huma migration program (epic #135); long-running, stacked by phase
enhancement
New feature or request
impact: polish
Annoyance, cosmetic, or nice-to-have
priority: P2
Limited scope, workaround exists, or polish
stacked
Base is another open PR; merge in stack order named in the body
triaged
High-confidence review completed; does not mean fixed, validated, or accepted for release.
labels
Nov 9, 2026
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 1 remain after this review.
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Review info
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: 4800de71-0dd1-476a-a1b9-bfadb5499641
Commits
Reviewing files that changed from the base of the PR and between 7a660e4 and a4a9733.
Files selected for processing: 1
docs/catalog-api.md
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.
…rending default
The v2 recommendation reads (getDiscover, getForYouMain, listForYouRows,
getRecommendationSection) answered RecommendationRow with only an English
title, so a translated client showed "Highly Rated in Your Library",
"Recently Added" or "Because you enjoy Crime" in English. RecommendationRow
now carries title_key and title_args while the title is one the server words:
the main For You row, taste-cluster rows (home.section.becauseYouEnjoy with
the comma-separated genres), Picked from your history, Profiles Like You
Enjoyed, Popular, Recently Added, Highly Rated and genre rows. The key comes
from the row's type and exact wording, so a title cached in older wording
carries none. /api/v1 bodies are unchanged.
Servers set up before the default home rows were reworked still store the
"Trending on Server" row, which the title-key backfill left out. A migration
keys those rows (home.section.trendingOnServer): home rows of the trending
type whose title is still that exact text. Down leaves keys in place.
The title_key field description and the section_title_keys capability now
say clients act on title_key whenever it is present.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
… catalogs on Apple (#1078)
* chore(settings): regenerate the settings bindings at manifest revision 28
Vendors the settings contract and regenerates SettingKeys.generated.swift
from Silo-Server/silo-server#3723, where ui.app_language and its
app_languages options arrive at revision 28. Revision 27 added
watch_party.guest_control_policy, which the Apple apps do not read yet.
The copy also picks up playback.show_marker_source and
playback.show_marker_confidence (revision 24).
* feat(i18n): apply the profile's app language on iOS, tvOS and macOS
The apps now read ui.app_language and show it at once: the root sets
\.locale (the device locale with its language replaced, so region and
hour cycle stay) and \.layoutDirection. A tag the build doesn't ship
follows the device; matching is the system's own (es-MX -> es,
zh-CN -> zh-Hans, zh-TW -> nothing).
The profile's language and the system per-app language are one knob.
Silo also writes the app's own AppleLanguages, with a ledger of what it
wrote and what was there before, so a profile without a language restores
the user's value. A change the user then makes in system settings
(iOS Settings > Silo > Language, macOS per-app language) is written back
as this device's profile_device value instead of being overwritten.
General settings on iOS and macOS and the tvOS General pane get an App
Language picker: Match Device, each shipped language by its own name, and
a stored tag the build doesn't ship, kept as itself. It saves at profile
scope and clears this device's own row so the choice applies here.
Every Silo request, Top Shelf's included, sends Accept-Language with the
language on screen, which the App Group also holds for Top Shelf.
AppLanguage.string(_:) resolves catalog strings outside views and
AppLanguage.isolated(_:) wraps titles in FSI/PDI. A CI guard blocks
lookups that use the process language instead.
project.yml turns on string catalog symbols and turns off compiler
extraction, ahead of the generated catalog. The platform selector's
build-input snapshot and seal are updated for that change.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* fix(i18n): keep app-language saves and write-backs on their own profile
Found in review of the app-language change:
- A picker save that finishes after a profile switch no longer touches
the new profile's picker, error or the ledger.
- Reads already in flight, and refreshes that land during a save, no
longer reconcile against the half-saved state, so Match Device clears
the app's own language instead of restoring an older one.
- The system-choice write-back keeps retryable answers (408, 409, 401,
5xx, 429) pending through the existing write-failure classifier, and a
newer system change replaces a choice still unsent.
- The tvOS picker sheet refuses another choice while a save is running.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* fix(i18n): don't lose a system language change that races a save
Found in the second review round:
- A system language change made while its write-back is in flight, even
back to Silo's own value, is written back next instead of being lost to
the value just sent. A change made during a read goes first too.
- A profile switch during a picker save now loads the new profile once the
save ends, instead of leaving it without a read.
- The picker waits while a system choice is being written back, and hides
while one is pending, so a pick can't lose to an older write.
- A write-back the server refuses for good hands the language back to the
profile, keeping the user's value as the one to come back to.
- The tvOS sheet shows its saving note only while saving.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* feat(i18n): set up the generated string catalog in the Apple apps
Adds the sync script that writes the String Catalog from silo-translations,
the hand-kept permission-prompt catalogs, the project settings for
generated symbols and the CI hook. The generated catalog itself lands in
the PR's last commit.
* feat(i18n): translate server-written text by catalog key
Section titles, problem details and settings-manifest labels come from
the server in English. They now show the catalog's translation when the
language on screen translates the key, and the server's text otherwise.
English always shows exactly what the server sent.
- Sections decode title_key and title_args (leniently: a malformed value
shows the title rather than failing the row) and carry them through
every copy. Home, library, Watch Together and See All pages resolve
the title where they read \.locale, so a language switch re-renders it.
The value of a key's one placeholder is filled in; any other shape
shows the server's title.
- Problem details try the first field error's error.field.<code>, then
error.<type>, then the server's detail (D33), wherever the app shows a
server detail: the shared error description, the permission-denied
message, request errors and profile creation.
- The manifest's "not set" labels for audio, subtitle and metadata
language use settingsManifest.<key>.unsetLabel.
AppLanguage.isolated now isolates only in right-to-left languages (D28).
docs/i18n.md describes the call-site pattern for extraction work.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* fix(i18n): keep subtitle fallback on the device's languages
Applying the app language writes the app's own AppleLanguages, and
Locale.preferredLanguages follows it, so subtitle fallback (used when
the system caption settings name no language) would have picked the app
language instead of the device's (D31).
Silo now records the list the device resolves just before its first
write. While the app value is Silo's own, the fallback reads the global
list, or that record where the global list isn't readable (a fresh
simulator has none). A per-app language the user chose themselves still
counts, as before.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* fix(i18n): close gaps found in review of the catalog groundwork
- Profile creation translated the first field error's code while it
showed another field's detail; the shown field's code is used now.
- The collections sheet showed a 501 problem's detail untranslated.
- The settings screens that show the manifest's "not set" labels read
\.locale, so the labels follow a language switch on panes that stay
open (tvOS, iPad).
- Subtitle fallback over a per-app language the user chose before
Silo's own keeps the list recorded before Silo wrote, as it did then.
The ownership check is shared, and the device-list test no longer
repeats the code's branches.
- Rows in the development language skip language matching.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* fix(i18n): keep the user's own app language for subtitles; count argument slots
- Over a per-app language the user chose before Silo's, subtitle
fallback returns that choice (the ledger's baseline) instead of a list
recorded at an earlier override, which could be stale: Silo can take
over a value it didn't write.
- serverText counted every percent sign as an argument, so a translation
with a literal percent and no placeholder, or one that repeats its
placeholder, fell back to English. It now counts distinct positional
slots.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* chore(i18n): vendor the sync script and its file list from silo-translations 7c500c0
scripts/sync-translations is byte-identical to silo-translations
tools/sync-translations.sh at 7c500c0, which refuses to install anything
but this platform's generated outputs.
* fix(i18n): load the switched-to profile's language after a failed write-back
A profile switch during a write-back skipped its read while the write
ran. A successful write ran the refresh again; a failed one returned,
leaving the new profile's language unloaded and the picker hidden until
the next refresh. Run it again either way.
Found by the adversarial review.
* fix(i18n): translate recommendation row titles from their title keys
Discover rows carry title_key and title_args like home sections
(Silo-Server/silo-server#3729), but the decoder dropped them, so the
rows' titles stayed English. Decode them leniently and pass them on.
Found by the adversarial review.
* fix(i18n): name the app language on the notification display request
Every Silo request sends Accept-Language with the language on screen,
but the notification service extension builds its own request and
can't reach AppLanguage. It now reads the tag the app stores in the
shared defaults.
Found by the adversarial review.
* ci(i18n): skip the private catalog check on pull requests from forks
GitHub withholds secrets from pull requests opened from forks, so the
catalog check couldn't download the private silo-translations release
and failed every such pull request. It now skips there with a notice;
the push to main checks the catalog after merge, and a pull request
from this repository still fails without the token. The check also
covers the permission-prompt catalogs, which are generated output now.
Found by review (Codex, Kody).
* chore(i18n): generate the catalogs from silo-translations 2026.11.09-7c500c0
Generated output only: scripts/sync-translations --version
2026.11.09-7c500c0. The string catalog and the three permission-prompt
catalogs (now listed in .silo-translations-files) carry English and the
seven shipped languages, with every key the rest of this stack reads.
---------
Co-authored-by: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
api-v2API v2 / Huma migration program (epic #135); long-running, stacked by phaseenhancementNew feature or requestimpact: polishAnnoyance, cosmetic, or nice-to-havepriority: P2Limited scope, workaround exists, or polishsize/L200–499 added + deleted lines (all files); change volume, not priority.stackedBase is another open PR; merge in stack order named in the bodytriagedHigh-confidence review completed; does not mean fixed, validated, or accepted for release.
1 participant
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Stacked on #3728, which is stacked on #3727. Review and merge those first.
Related issue: N/A
Validation tasks: none affected (every title stays the same)
Recommendation rows on the Discover and For You screens reach clients with English titles only, such as "Highly Rated in Your Library", "Recently Added" and "Because you enjoy Crime", so a translated client can't show them in the user's language. Separately, servers set up before the default home rows were reworked still have a "Trending on Server" home row that #3727's backfill missed, because it lists only today's defaults. This change keys both.
Approach
RecommendationRow(getDiscover,getForYouMain,listForYouRows,getRecommendationSection) carries the optionaltitle_keyandtitle_argsthat section reads gain in #3727, while the title is one the server words. That covers For You, taste-cluster rows (home.section.becauseYouEnjoy, with the cluster's genres), Picked from your history, Profiles Like You Enjoyed, Popular, Recently Added, Highly Rated and genre rows. A title in any other wording, such as one cached by an older build, carries no key. The key is derived in the v2 adapter, so the empty For You fallback is keyed too.A new migration keys home rows of the trending type whose title is still "Trending on Server". Renamed rows, and rows of other types that share the text, stay unkeyed. Its down step is a no-op.
The field and capability docs now say clients act on
title_keywhenever it is present;section_title_keysis informational./api/v1bodies and the Jellyfin surface are unchanged.Validation
/api/v1was unchanged. This ran before the rebase onto currentmain; the rebase applied without conflicts.main: the generated-contract checks, the focused package tests and this stack's Postgres pins pass. The full pre-PR gate and everyscripts/ci/db-contracts.txttest passed against a freshly migrated scratch database on the previous rebase, apart from two real-FFmpeg tests that fail the same way onmainwith that host's FFmpeg 6.1.1.Evidence
Captured end to end on a sandbox running this stack with the web translation stack merged in, before and after: "Trending on Server" translated in Spanish and Arabic, and the API responses carrying the recommendation row keys. The web For You page still shows its headings in English, because the web app doesn't read these keys yet (follow-up). The page names both builds.
Evidence: https://evidence.siloserver.org/r/silo-server/pr-3729/
Risks
UPDATEonpage_sectionslimited to the old default's rows. Down is a no-op.Checklist
Follow-ups
home.section.*keys before a client readstitle_keyon recommendation rows. The web, Android, Apple and Roku translation stacks then read the fields on Discover and For You.AI Disclosure
f7ef06d1f6found nothing.🤖 Generated with Claude Code
Note
Add
title_keyandtitle_argsto recommendation rows and key legacy Trending on Server rowsSectionTitleKey, so responses from discover, For You, and recommendation-section reads can carry a translation key and arguments. A sharedrecommendationRowbuilder derives the key from row type and label viarecommendations.ForYouRow.TitleKeyin recommendations.goTitleKeyin titles.go adds mappings for cluster rows labeled For You, Because you enjoy labels, and the similar-users labelhome.section.trendingOnServeron legacy home rows with the exact title "Trending on Server" and an emptytitle_keytitle_keyvalues; check rows matched by the migration's type, title, and empty-key conditionsMacroscope summarized 39ef634.