Skip to content

Add language selection and live voice transcription on iOS and Android - #146

Merged
tiensonqin merged 3 commits into
mainfrom
devin/1793801624-live-voice-transcription
Nov 4, 2026
Merged

tiensonqin merged 3 commits into
mainfrom
devin/1793801624-live-voice-transcription

Conversation

@tiensonqin

@tiensonqin tiensonqin commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Keep the recording UI simple: remember the transcription toggle and selected language, show language selection before recording, and display live partial/final text while recording.
  • Feed saved audio and on-device transcription from the same microphone stream. Replace iOS post-recording analysis with AVAudioEngine + SpeechAnalyzer, and Android file replay with AudioRecord + AAC encoding + ML Kit streaming recognition.
  • Move Android capture into a microphone foreground service with a wake lock so the session can continue when the activity backgrounds or the screen locks. Preserve the existing iOS background-audio entitlement.
  • Prepare/download the selected language model before capture; preserve recorded audio if transcription fails and keep the existing asset/transcript import flow.

Validation

  • Full iOS simulator app build, signing and native-runtime export verification passed.
  • Existing Swift Testing suite: 111 tests passed (custom app-host runner; no swift test).
  • Full Android assembleDebug including the native core, unit tests (84), and lintDebug passed.
  • OCaml core: 1,294 tests passed. Android JNI boundary and native-packaging checks passed.
  • Capture localization generation/check passed for all 25 locales.

Real microphone transcription, model installation on supported hardware, backgrounding and actual device lock-screen behavior still need device validation. Live iOS transcription requires iOS 26 and a supported device; Android transcription depends on ML Kit's on-device availability. No UI/lock-screen E2E claims are made by the build and unit-test results.

Link to Devin session: https://app.devin.ai/sessions/ed65e199ce3a442a87f5f63e02234d69
Open in Devin Desktop: https://app.devin.ai/desktop/session/ed65e199ce3a442a87f5f63e02234d69?variant=devin
Requested by: @tiensonqin


🟢 Devin fixed all 2 findings · Follow Devin's work

Devin Review

@devin-ai-integration

Copy link
Copy Markdown

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 2 findings. Devin automatically fixed all 2 findings.

Fixed by Devin (2)
  • Activity recreation deletes active recordings — An Activity destruction during capture used to cancel the service and delete its file. Destruction now detaches only the permission request. Recording operations and pending completion live in an Activity-independent session scope, and the restored runtime resumes saving only into the original graph/target. The save/import handoff cannot be interrupted by runtime disposal. Android full build, 84 existing unit tests and lint passed.
  • Orphaned recording blocks future recordings — Reworked request ownership so the recreated runtime always observes the pending session, even when another graph (or no graph) is restored. Cancel now reaches the common completion/cleanup path rather than leaving recordingRequest orphaned. Graph identity is checked only when attaching a non-null asset; a mismatched graph reports an error with the retained audio path instead of importing into the wrong graph. Android full build, unit tests and lint passed.

View findings in Devin Review · Follow Devin's work

Devin Review

@tiensonqin
tiensonqin merged commit feefede into main Nov 4, 2026
3 of 4 checks passed
@tiensonqin
tiensonqin deleted the devin/1793801624-live-voice-transcription branch November 4, 2026 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant