software-android-native

software-android-native is a skill for Codex from vasilyu1983/AI-Agents-public. It costs 38 tokens per session (8,088 once invoked), scanned A, original, MIT.

A guide to building native Android apps with Kotlin, Jetpack Compose, and traditional Android Views when needed. It covers app state, asynchronous work, and automated tests.

In plain words
What is it for?
Use it to build or review Android screens, ViewModels, Kotlin coroutines and flows, Compose tests, and connections between Compose and older Views.
Why use it?
It gives developers practical choices for structuring modern Android code and handling common issues such as duplicate submissions and changing UI state.

Skill for Codex

Written for Codex: agents/openai.yaml present. Also seen: mentions CLAUDE.md; mentions Claude Code; mentions AGENTS.md.

Good fit Use it to build or review Android screens, ViewModels, Kotlin coroutines and flows, Compose tests, and connections between Compose and older Views.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/vasilyu1983/ai-agents-public/software-android-native
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add vasilyu1983/AI-Agents-public --skill software-android-native
Clone the repo
git clone --depth 1 https://github.com/vasilyu1983/AI-Agents-public

Made for: Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for software-android-native

README.md
[![agentmods](https://agentmods.dev/badge/skills/vasilyu1983/ai-agents-public/software-android-native.svg)](https://agentmods.dev/skills/vasilyu1983/ai-agents-public/software-android-native)
Your own site
<a href="https://agentmods.dev/skills/vasilyu1983/ai-agents-public/software-android-native"><img src="https://agentmods.dev/badge/skills/vasilyu1983/ai-agents-public/software-android-native.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 8,088 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00038 $0.08088
Opus 5 $0.00019 $0.04044
Sonnet 5 $0.00008 $0.01618
Haiku 4.5 $0.00004 $0.00809

Measured 4d ago against content hash 99764796a310, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

software-android-native scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

frameworks/shared-skills/skills/software-android-native/SKILL.md · 340 lines

How it starts

The opening of the file, as written. The whole thing — 340 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Native Android Development

Use this skill for native Android work only. It is the default shared-skill entrypoint for Compose-first Android apps targeting API 28+, bounded rewrites from older codebases, and agent-assisted workflows in Android Studio, Codex, and Claude Code.

Quick Reference

Task Default Picks Notes
State & UI
New UI screens Jetpack Compose Views interop only where existing mature flows or third-party SDKs require it
Observable state ViewModel + StateFlow (Kotlin 2.x) Replaces LiveData for new code
Async work Kotlin Coroutines + Flow Dispatchers.IO for blocking, Dispatchers.Default for CPU; structured concurrency preferred
Unit/integration tests JUnit 5 + Turbine Turbine for Flow testing; JUnit 5 for coroutine lifecycle
UI tests Compose Testing APIs (ComposeTestRule) Espresso only for Views interop or legacy screens
State machine discipline
Submit guard if (_uiState.value is Loading) return Prevents double-tap duplicate submissions in ViewModel
Auto-reset transitions viewModelScope.launch { delay(500); _uiState.value = Idle } Input ready for next action without manual UI reset
Minimal sealed classes Remove states that can't happen anymore Dead sealed subclasses produce dead when branches and mislead future readers
Networking & resilience
Network reachability ConnectivityManager + NetworkCallback wrapped in StateFlow Publish isConnected; disable submit buttons when offline; observe in collectAsStateWithLifecycle
DI & architecture
Dependency injection Hilt @HiltViewModel, @Inject constructor, @Module + @InstallIn
Local persistence Room + KSP Prefer @Upsert over separate insert/update; KSP replaces KAPT
Background work WorkManager + CoroutineWorker Deferrable, constraint-aware background processing
Agent tooling & build
Agent tooling (in Android Studio) Android Studio Gemini assistant Built-in coding agent surface
Agent tooling (outside IDE) Gradle CLI + ADB Terminal-first build, install, launch, and inspection
Build command ./gradlew assembleDebug Or specific module: ./gradlew :app:assembleDebug
Install command adb install -r app/build/outputs/apk/debug/app-debug.apk -r replaces existing without clearing data
Launch command adb shell am start -n com.example.app/.MainActivity Verify package and component name from manifest
Emulator management avdmanager, emulator CLI Headless: emulator -avd Name -no-window -no-audio for CI
Logcat adb logcat -s TAG:V Filter by tag; adb logcat *:E for errors only
Screenshot adb exec-out screencap -p > screenshot.png Fast visual proof from emulator or device
Compose patterns
LazyColumn / LazyRow Always provide key in items(key = { it.id }) Prevents recomposition bugs on list mutation
Canvas drawing Canvas(modifier) { drawScope -> ... } with DrawScope Use drawLine, drawCircle, drawArc, drawPath
Canvas gestures Modifier.pointerInput(Unit) { detectTapGestures / detectDragGestures } Compute hit targets from coordinates, not invisible tap areas
Type-safe navigation @Serializable route classes + NavHost (Navigation 2.9+) Compile-time route safety; replaces string-based routes
Animations animateFloatAsState, Animatable, InfiniteTransition Choose based on one-shot vs continuous vs interruptible
derivedStateOf remember { derivedStateOf { ... } } For computed state that depends on frequently changing sources
Side effects LaunchedEffect, DisposableEffect, SideEffect LaunchedEffect(key) for coroutine work; DisposableEffect for cleanup
Modifier order Padding before background vs after changes result Modifier chain is sequential; order is layout-significant
Modifier.testTag Modifier.testTag("submit_button") Required for Compose test node finders
Snackbar SnackbarHostState + SharedFlow from ViewModel Collect events in LaunchedEffect; never use Toast for important feedback
Billing & payments
BillingClient Play Billing Library 8+ (v9.x current as of 2026-07-11; v8+ mandatory for all new apps/updates by 2026-08-31, extension to 2026-11-01) Initialize in Application.onCreate or Hilt singleton; verify current minimum at developer.android.com/google/play/billing/release-notes
Acknowledge purchases acknowledgePurchase() within 3 days Unacknowledged purchases auto-refund after 3 days
Subscription offers ProductDetails.subscriptionOfferDetails Base plan, offer phases (free trial, introductory price)
Promotional offers Developer-determined offers in Play Console Configure offer eligibility; apply via BillingFlowParams.SubscriptionUpdateParams
Consumables consumeAsync() after backend confirms Prevents re-granting; consume only after server receipt
Adaptive layouts
Window size classes WindowSizeClass from material3-window-size-class Compact, Medium, Expanded; branch layout in Composable
List-detail pane ListDetailPaneScaffold (Material3 adaptive) Canonical two-pane pattern for tablets and foldables
Navigation suite NavigationSuiteScaffold Auto-switches between bottom nav, rail, and drawer by size class
Foldable support WindowInfoTracker (Jetpack Window) Detect fold posture, hinge bounds; adapt layout for table-top mode
Auth & push
Credential Manager CredentialManager API (Jetpack) Unified passkeys, passwords, and federated sign-in
Biometric auth BiometricPrompt (AndroidX) canAuthenticate() check first; BIOMETRIC_STRONG for crypto
Push notifications FCM (FirebaseMessaging) onNewToken for registration; onMessageReceived for data messages
Notification channels NotificationChannel (API 26+) Must create before posting; group related channels with NotificationChannelGroup
Deep links Compose Navigation deep links navDeepLink { uriPattern = "app://..." } on route; App Links require assetlinks.json
collectAsStateWithLifecycle stateFlow.collectAsStateWithLifecycle() Lifecycle-aware collection; prevents updates when app is backgrounded
Strong Skipping (Kotlin 2.x)
UI state instance identity Split state into @Immutable slices; hoist derived lists to ViewModel Strong Skipping Mode compares unstable params by reference; a fresh copy() per frame defeats skipping
LazyListScope lambdas val onClick = remember(id) { { vm.onClick(id) } } Lambda memoization from Strong Skipping only applies inside @Composablenot inside items { }
Main-thread UI mutation Do blocking work under withContext(Dispatchers.IO), assign _uiState.value = ... outside that block Off-main state mutation surfaces as CalledFromWrongThreadException or ConcurrentModificationException in SnapshotStateObserver

Read the full file on GitHub · 340 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 340 lines · 38 tokens per session scan A 99764796a310

Subscribe to this mod's changes

software-android-native is a skill published in the GitHub repository vasilyu1983/AI-Agents-public (86 stars, last pushed 6d ago), licensed MIT. It adds 38 tokens to every session and 8,088 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.