everything-claude-code-mobile: Skill for Claude Code

.opencode/skills/mobile-compaction/SKILL.md

mobile-compaction is a skill for Claude Code, OpenCode from ahmed3elshaer/everything-claude-code-mobile. It costs 22 tokens per session (1,399 once invoked), scanned A, original, MIT.

A way to shorten the working context for a large Android codebase while keeping the details relevant to the current module or architecture layer.

In plain words
What is it for?
It helps concentrate on one feature module, such as authentication, or one layer, such as the user interface or data layer, during large refactors.
Why use it?
It reduces clutter when a project or conversation contains more information than can be kept in focus at once.

Skill for Claude CodeOpenCode

Written for Claude Code and OpenCode: shipped in a Claude Code plugin, but also installed under .opencode/.

This is ahmed3elshaer/everything-claude-code-mobile's own configuration. It tells Claude Code and OpenCode how to work on everything-claude-code-mobile itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything everything-claude-code-mobile configures →

Part of the everything-claude-code-mobile plugin — 46 skills, 35 commands, 27 agents, 2 hooks, 3 MCP servers shipped together

Reuse

Borrowing it

Nothing to install: this file belongs to ahmed3elshaer/everything-claude-code-mobile. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/ahmed3elshaer/everything-claude-code-mobile/main/.opencode/skills/mobile-compaction/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/ahmed3elshaer/everything-claude-code-mobile

Made for: Claude Code, OpenCode.

Or install everything-claude-code-mobile, the plugin that ships this one along with the rest of its 46 skills, 35 commands, 27 agents, 2 hooks, 3 MCP servers.

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 mobile-compaction

README.md
[![agentmods](https://agentmods.dev/badge/skills/ahmed3elshaer/everything-claude-code-mobile/mobile-compaction.svg)](https://agentmods.dev/skills/ahmed3elshaer/everything-claude-code-mobile/mobile-compaction)
Your own site
<a href="https://agentmods.dev/skills/ahmed3elshaer/everything-claude-code-mobile/mobile-compaction"><img src="https://agentmods.dev/badge/skills/ahmed3elshaer/everything-claude-code-mobile/mobile-compaction.svg" alt="Measured on agentmods" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,399 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.
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.00022 $0.01399
Opus 5 $0.00011 $0.00700
Sonnet 5 $0.00004 $0.00280
Haiku 4.5 $0.00002 $0.00140

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

Security

Grade A, and why

mobile-compaction 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.

.opencode/skills/mobile-compaction/SKILL.md · 258 lines

How it starts

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

Mobile Compaction Skill

Strategic context compaction for large Android projects to optimize token usage while preserving critical information.

When to Compact

Compact context when:

  • Token usage exceeds 100,000
  • Working on large refactors spanning many files
  • Switching between unrelated features
  • Session becomes unfocused
  • Context contains resolved discussions

Compaction Strategies

1. Module-Level Compaction

Focus on a single Android module:

/compact --module=feature:auth

What happens:

  • Retain: All files in feature:auth module
  • Summarize: Other modules to high-level description
  • Drop: Resolved discussions about other modules

Use when: Deep work on a specific feature

2. Layer-Based Compaction

Focus on architecture layer:

/compact --layer=ui
/compact --layer=data
/compact --layer=domain

What happens:

Layer Retain Summarize
UI Composables, ViewModels, navigation Repository details, data models
Data Repositories, data sources, models Compose code, UI state
Domain Use cases, domain models Implementation details

Use when: Working on cross-cutting concerns in a layer

3. Build Variant Focus

Narrow to specific build variant:

/compact --variant=debug

What happens:

  • Retain: Debug-specific configurations, test code
  • Summarize: Release configurations, ProGuard rules

Use when: Debugging or test development

4. Test Isolation

Compact around failing tests:

/compact --test=AuthViewModelTest
/compact --test-failing

What happens:

  • Retain: Test file, related source files
  • Summarize: Unrelated test discussions
  • Drop: Resolved test fix discussions

Use when: Fixing specific test failures

5. Pattern-Based Compaction

Compact based on architectural patterns:

/compact --pattern=compose
/compact --pattern=mvi
/compact --pattern=koin

What happens:

  • Retain: Files matching the pattern
  • Summarize: Non-matching files to pattern names only

Read the full file on GitHub · 258 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 · 258 lines · 22 tokens per session scan A 0e71fff102e3

Subscribe to this mod's changes

mobile-compaction is a skill published in the GitHub repository ahmed3elshaer/everything-claude-code-mobile (66 stars, last pushed 2mo ago), licensed MIT. It adds 22 tokens to every session and 1,399 once invoked, about $0.0001 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.

Related

Other skills, from other repositories

SKILL

This document provides a comprehensive technical reference for KSensor, a Kotlin Multiplatform (KMP) library designed for observing device sensors and system states on Android and iOS.

ShadAdman/KSensor · 0 tokens

compose-animations

Use when writing or reviewing Jetpack Compose motion: visibility enter/exit, animating one property toward a target, color or size transitions, multiple properties from one state, switching composable content, or choosing between AnimatedVisibility, animateAsState, rememberTransition, AnimatedContent, and Crossfade.

chrisbanes/skills · 64 tokens

compose-focus-navigation

Use when writing or reviewing Jetpack Compose UI for TV, keyboard, desktop, accessibility focus, D-pad navigation, FocusRequester, focusProperties, key events, or initial focus behavior.

chrisbanes/skills · 41 tokens

compose-state-and-effects

Use when writing or reviewing Jetpack Compose state ownership, remember state, state hoisting, screen state holders, LaunchedEffect, DisposableEffect, SideEffect, Flow collection, navigation, snackbar, analytics, or focus requests.

chrisbanes/skills · 50 tokens

compose-component-design

Use when designing or reviewing reusable Jetpack Compose component APIs with modifier parameters, root layout placement, caller-provided variable content, primitive content parameters, optional content, or boolean shape flags.

chrisbanes/skills · 41 tokens

compose-performance

Use when investigating Jetpack Compose recomposition cost, compiler stability reports, skippability, unstable parameters, frame-rate State reads, cross-phase snapshot back-writing, or @ReadOnlyComposable contracts.

chrisbanes/skills · 42 tokens