Liquid Glass and Apple Music touches for the Spotify iOS app. A GPL-3.0 fork of spoti.pw 0.21.1.
C
fix: Anthropic presets Haiku 4.5 and Sonnet 4.6, Gemini defaults to 3.6 Flash
My-Name-Is-Jeff604512d14684
diff --git a/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.h b/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.hindex ac96451d..151738bb 100644--- a/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.h+++ b/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.h@@ -33,7 +33,7 @@ NSArray<SGModRow *> *SGOnDeviceTranslatorRows(void);@property (nonatomic, copy, readonly) NSString *by, *model;@property (nonatomic, readonly) NSDate *made; // nil: not known+ (instancetype)by:(NSString *)by model:(NSString *)model made:(NSDate *)made;-@property (nonatomic, readonly) NSString *name; // "Gemini (gemini-flash-latest)", "Translate on iPhone", "Unknown"+@property (nonatomic, readonly) NSString *name; // "Gemini (gemini-3.6-flash)", "Translate on iPhone", "Unknown"@property (nonatomic, readonly) BOOL deletable; // made by an AI provider, or by no one known@enddiff --git a/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.m b/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.mindex 5e74b3dd..23bef6e0 100644--- a/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.m+++ b/tweak/Sources/Shared/LyricsTranslation/LyricsTranslation.m@@ -82,7 +82,7 @@ static NSMutableURLRequest *geminiRequest(NSString *model, NSString *prompt, NSSNSMutableDictionary *config = [@{@"responseMimeType": @"application/json",@"responseSchema": @{@"type": @"ARRAY", @"items": @{@"type": @"STRING"}}} mutableCopy];// Gemini 3 thinks at length by default, which a whole song's translation does not need and which made it- // slow enough to time out. Plain: a model behind gemini-flash-latest that does not know the field.+ // slow enough to time out. Plain: a model named in Other… that does not know the field.if (!plain) config[@"thinkingConfig"] = @{@"thinkingLevel": @"low"};NSMutableURLRequest *request = post([NSString stringWithFormat:@"https://generativelanguage.googleapis.com/v1beta/models/%@:generateContent", model],@{@"contents": @[@{@"parts": @[@{@"text": prompt}]}], @"safetySettings": safety, @"generationConfig": config});@@ -183,8 +183,9 @@ static const SGAIProvider kProviders[] = {{@"gemini", @"Gemini", @"Google", @"Vitrine.Gemini",@"Translate with Gemini sends the song's lyrics to Google, on your own key from Google AI Studio. The key stays on this iPhone.",@"Answer with a JSON array of the {count} translations as strings.",- // gemini-flash-latest follows each Flash release; Google gives two weeks' notice of a breaking change.- {@"gemini-flash-latest", @"gemini-3.6-flash", @"gemini-3.5-flash-lite"}, {@"Flash (latest)", @"3.6 Flash", @"3.5 Flash-Lite"},+ // A pinned id first, the one users report working. gemini-flash-latest follows each Flash release, preview+ // ones included, with notice only by email to the key's owner, so it is offered but not the default.+ {@"gemini-3.6-flash", @"gemini-3.5-flash-lite", @"gemini-flash-latest"}, {@"3.6 Flash", @"3.5 Flash-Lite", @"Flash (latest)"},YES, {@"thinking"}, geminiRequest, geminiAnswer},{@"openai", @"OpenAI-compatible", nil, @"Vitrine.OpenAI",@"Sends the song's lyrics to the server below: OpenAI's own unless you name another, such as OpenRouter, or an "@@ -195,8 +196,10 @@ static const SGAIProvider kProviders[] = {{@"anthropic", @"Anthropic", @"Anthropic", @"Vitrine.Anthropic",@"Translate with Anthropic sends the song's lyrics to Anthropic, on your own key from the Claude Console. The key stays on this iPhone.",kLinesFormat,- // The cheapest current model first: the reason a model is picked at all is what translating costs.- {@"claude-haiku-5-5", @"claude-sonnet-5-5", @"claude-opus-5-5"}, {@"Haiku 5.5", @"Sonnet 5.5", @"Opus 5.5"},+ // The cheapest first: the reason a model is picked at all is what translating costs. Not the 5.5 models,+ // whose safety classifiers stop at lyrics with a refusal; Other… still names any model. Haiku 4.5 has no+ // effort, so its first request comes back once and is sent plain.+ {@"claude-haiku-4-5", @"claude-sonnet-4-6"}, {@"Haiku 4.5", @"Sonnet 4.6"},NO, {@"output_config", @"effort", @"json_schema"}, anthropicRequest, anthropicAnswer},};static const NSUInteger kProviderCount = sizeof(kProviders) / sizeof(kProviders[0]);