Repository navigation
Conversation
Append a regional English spelling instruction to Fluid Intelligence cleanup prompts when the stored preference is en-US, en-GB, en-AU, or en-CA. Default remains automatic, so existing users are unchanged.
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
[Medium impact] The change reaches dictation cleanup settings and prompt paths. The scope mismatch must be resolved before merging; the new spelling picker also needs search support. SummaryAdds a stored English spelling preference and connects it to dictation cleanup prompts.
Reviews (4) · Last reviewed commit: "Add an English spelling picker to dictat..." · Reviewed by Greptile |
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 58c9474ffd
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| self.applyingEnglishSpellingPreference( | ||
| to: self.promptResolution(for: mode, appBundleID: appBundleID).systemPrompt | ||
| ) |
There was a problem hiding this comment.
Limit the spelling suffix to dictation mode
When a regional preference is stored, this also modifies Edit Mode prompts: RewriteModeService.callLLM calls this getter with .edit at Sources/Fluid/Services/RewriteModeService.swift:260. Every regional suffix includes “Keep the original language and meaning; do not translate”, so an Edit Mode request to translate selected text now conflicts with a higher-priority system instruction. Apply the cleanup suffix only when mode.normalized == .dictate so a dictation spelling preference does not constrain unrelated writing operations.
Useful? React with 👍 / 👎.
FluidVoice PR build readyDownload FluidVoice-PR-1332-ec1c4ae441f7 The artifact contains the ad-hoc-signed app ZIP, Xcode archive, build manifest, and installation instructions. It expires 5 days after the build. Install the app
This build has its own app identity, so its permissions are separate from the release version of FluidVoice. |
Apply the regional spelling suffix only when the prompt mode is dictation, so Edit Mode can still translate. Pass the stored preference on private dictation requests and apply it to Fluid Intelligence prompts.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8bbbc7a06f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
The editor's "Test prompt" sends combinedDraftPrompt as the override system prompt, which skipped the regional spelling instruction that saved dictation profiles get. Decorate the draft with the same mode-aware helper so the preview matches the saved profile; Edit Mode drafts stay unchanged.
|
@mvanhorn thanks for the changes - we probably need a picker on the app ? allow users to select what their language preference is and pass that onto the post processing ? |
Show a Spelling dropdown under Cleanup style so users can choose Automatic, American, British, Australian or Canadian spelling. The choice is stored in englishSpellingPreference, which dictation post-processing already reads.
|
Added in ec1c4ae: a Spelling picker in Settings, right under Cleanup style for primary dictation, with Automatic, American (en-US), British (en-GB), Australian (en-AU) and Canadian (en-CA). It saves to the same englishSpellingPreference setting that dictation post-processing already reads, so the choice flows straight into the cleanup prompt. The type now has allCases and displayName for the picker, with assertions in Tests/EnglishSpellingPreferenceTests.swift. |
| description: "Keyboard shortcut or mouse button" | ||
| ) | ||
| self.dictationPromptPicker(for: .primary) | ||
| self.englishSpellingPicker() |
There was a problem hiding this comment.
This adds a spelling picker even though the PR description explicitly excludes settings pickers and SwiftUI changes. It violates the repository requirement to keep Swift changes within the stated scope. Resolve this before merging: move the picker to a separate UI change, or agree on the expanded scope and update the description.
Rule Used: What: Ensure macOS Swift PR changes match the stated scope, don’t introduce unrelated UI/UX/theming work, and don’t risk breaking existing features. Why: Keeps reviews focused, prevents scope creep (especially UI/UX), and avoids regressions or inc... (source)
Prompt To Fix With AI
This is a comment left during a code review.
Path: Sources/Fluid/UI/SettingsView.swift
Line: 2040
Comment:
**Picker exceeds stated scope**
This adds a spelling picker even though the PR description explicitly excludes settings pickers and SwiftUI changes. It violates the repository requirement to keep Swift changes within the stated scope. Resolve this before merging: move the picker to a separate UI change, or agree on the expanded scope and update the description.
**Rule Used:** What: Ensure macOS Swift PR changes match the stated scope, don’t introduce unrelated UI/UX/theming work, and don’t risk breaking existing features. Why: Keeps reviews focused, prevents scope creep (especially UI/UX), and avoids regressions or inc... ([source](https://app.greptile.com/-/switch-tenant?tenant=altic&next=%2Fcustom-context%3Fmemory%3Dc54a31bd-761f-45ed-8fcb-a3cb1158d02e))
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
| description: "Keyboard shortcut or mouse button" | ||
| ) | ||
| self.dictationPromptPicker(for: .primary) | ||
| self.englishSpellingPicker() |
There was a problem hiding this comment.
Search misses spelling preference
The new picker appears only under Shortcuts, but SettingsSearchIndex has no entry or regional search terms for it. Users searching “spelling” cannot reach this control and may instead see the unrelated screen-context setting. Add a search entry and a matching settingsSearchTarget so users can find the preference by name.
Knowledge Base Used: Settings and onboarding
Prompt To Fix With AI
This is a comment left during a code review.
Path: Sources/Fluid/UI/SettingsView.swift
Line: 2040
Comment:
**Search misses spelling preference**
The new picker appears only under Shortcuts, but `SettingsSearchIndex` has no entry or regional search terms for it. Users searching “spelling” cannot reach this control and may instead see the unrelated screen-context setting. Add a search entry and a matching `settingsSearchTarget` so users can find the preference by name.
**Knowledge Base Used:** [Settings and onboarding](https://app.greptile.com/-/switch-tenant?tenant=altic&next=%2Fcustom-context%2Fknowledge-base%2Faltic-dev%2Ffluidvoice%2F-%2Fdocs%2Fsettings-and-onboarding.md)
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.
Description
Dictation cleanup currently follows US spelling even when Apple Speech is set to
en-AUoren-GB, because that locale picker is ASR-only. This change adds a stored English spelling preference (automatic,en-US,en-GB,en-AU,en-CA) and appends a short instruction to the Fluid Intelligence / dictation cleanup system prompt.automaticis the default, so existing users keep current behavior. The Apple Speech locale picker is unchanged. There is no new settings screen, picker, or SwiftUI view; this PR is the preference type, persistence, and prompt plumbing for #492.Type of Change
Related Issue or Discussion
Closes #492
Testing
Standalone Foundation tests compiled with
swiftc(notxcrun, not the Xcode suite) on Linux.Command:
Expected before this change: compile fails because
Sources/Fluid/Persistence/EnglishSpellingPreference.swiftis missing.Actual before this change:
Expected after this change:
PASS: 47 English spelling preference assertions. Default/unknown stored values stayautomaticand leave a sample cleanup prompt unchanged.en-GB/en-AUinstructions mention British / Australian spelling and colour/organise/centre.en-USmentions American spelling and color/organize/center. Applying appends the instruction to the default dictation cleanup body and is idempotent.Actual after this change:
Verified with that standalone
swiftcscript on Linux (Debian 13, Swift 6.4.2,x86_64). Independently re-run at 6:09 AM PT, America/Los_Angeles: 47 assertions, EXIT 0. Not tested on an Intel Mac or an Apple Silicon Mac. The Xcode test suite, SwiftLint, and SwiftFormat were not run here.swiftlint --strict --config .swiftlint.yml Sources Tests Package.swiftswiftformat --config .swiftformat Sourcessh Tests/run_english_spelling_preference_tests.sh(47 assertions, Linuxswiftc)Screenshots / Video
Animated replay of real captured command output, not a live UI recording. The capture shows the cleanup prompt for
automatic, thenen-AUanden-GB(colour, organise, centre), and the passing test run.Notes
Default is
automatic, so cleanup prompts stay as they are until a regional value is stored. No new UI. The Apple Speech locale picker is still ASR-only and is not changed by this preference. Backup/restore includes the new key the same way asselectedAppleSpeechLocaleIdentifier; older backups without the key keep the current value.Local tooling helped draft the change. The implementation and tests were reviewed in full.
The contribution requirements are mandatory. PRs that do not follow CONTRIBUTING.md will not be reviewed or merged until they comply, and may be closed.