Recently Written · git

subrep-android

Subrep on Android: live captions of the sound of the phone, made on the phone by Whisper, shared by link.

git clone https://github.com/equwal/subrep-android

Log | Files | Refs


app/src/main/AndroidManifest.xml (2017 bytes)

1 <?xml version="1.0" encoding="utf-8"?>
2 <manifest xmlns:android="http://schemas.android.com/apk/res/android">
3 
4     <!-- The captions go to the share relay, and the speech model comes from Hugging Face. The cloud hours and the cloud captions come from subread.space. The sound leaves the phone only for the cloud captions. -->
5     <uses-permission android:name="android.permission.INTERNET" />
6     <!-- Android asks for this permission for the sound of other apps too, not only for the microphone. -->
7     <uses-permission android:name="android.permission.RECORD_AUDIO" />
8     <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
9     <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PROJECTION" />
10     <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MICROPHONE" />
11     <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
12 
13     <!-- SubRead Overlay shows the captions over the player. The app must be able to see it. -->
14     <queries>
15         <package android:name="space.subread.overlay" />
16     </queries>
17 
18     <application
19         android:allowBackup="true"
20         android:icon="@drawable/icon"
21         android:label="@string/app_name"
22         android:supportsRtl="true"
23         android:theme="@android:style/Theme.DeviceDefault.Light.NoActionBar">
24 
25         <activity
26             android:name=".MainActivity"
27             android:exported="true"
28             android:launchMode="singleTop">
29             <intent-filter>
30                 <action android:name="android.intent.action.MAIN" />
31                 <category android:name="android.intent.category.LAUNCHER" />
32             </intent-filter>
33         </activity>
34 
35         <!-- Captures the sound, runs Whisper, and keeps the relay connection while the user is in the player. -->
36         <service
37             android:name=".CaptureService"
38             android:exported="false"
39             android:foregroundServiceType="mediaProjection|microphone" />
40     </application>
41 </manifest>