debugging-recompositions

debugging-recompositions is a skill for Claude Code, Codex from skydoves/compose-performance-skills. It costs 163 tokens per session (3,825 once invoked), scanned A, original, Apache-2.0.

A guide to finding and explaining recompositions in Jetpack Compose, where screen-building code runs again after inputs change. It uses Android Studio’s Layout Inspector and optional runtime tracing to show counts and change reasons.

In plain words
What is it for?
Use it when a screen updates more often than expected, skips less than expected, or becomes slow during scrolling and animation. It helps decide whether to investigate unstable data, remembered lambdas, or state reads in the wrong rendering phase.
Why use it?
It makes invisible repeated work visible and helps distinguish changed, unchanged, uncertain, static, and unknown inputs. It identifies the cause without claiming to fix it automatically.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when a screen updates more often than expected, skips less than expected, or becomes slow during scrolling and animation. It helps decide whether to investigate unstable data, remembered lambdas, or state reads in the wrong rendering phase.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/skydoves/compose-performance-skills/debugging-recompositions
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 skydoves/compose-performance-skills --skill debugging-recompositions
Clone the repo
git clone --depth 1 https://github.com/skydoves/compose-performance-skills

Made for: Claude Code, 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 debugging-recompositions

README.md
[![agentmods](https://agentmods.dev/badge/skills/skydoves/compose-performance-skills/debugging-recompositions/github.svg)](https://agentmods.dev/skills/skydoves/compose-performance-skills/debugging-recompositions)
Your own site
<a href="https://agentmods.dev/skills/skydoves/compose-performance-skills/debugging-recompositions"><img src="https://agentmods.dev/badge/skills/skydoves/compose-performance-skills/debugging-recompositions/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for debugging-recompositions

Your own site · 80×15
<a href="https://agentmods.dev/skills/skydoves/compose-performance-skills/debugging-recompositions"><img src="https://agentmods.dev/badge/skills/skydoves/compose-performance-skills/debugging-recompositions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 163 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,825 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.00163 $0.03825
Opus 5.5 $0.00065 $0.01530
Sonnet 5.5 $0.00033 $0.00765
Haiku 4.5 $0.00016 $0.00382

Measured 3mo ago against content hash 29088ac7525f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

debugging-recompositions 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 3mo 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.

recomposition/debugging-recompositions/SKILL.md · 216 lines

How it starts

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

Debugging Recompositions — make the invisible visible, then map status to action

Recomposition is invisible by default. A composable that re-runs sixty times a second to redraw an animation looks identical in source to one that should re-run zero times when its parent ticks. Three layers of instrumentation make it visible: Layout Inspector recomposition counts and skip counts (Android Studio, debug build), Layout Inspector Argument Change Reasons (Hedgehog and later, per-parameter Changed / Unchanged / Uncertain / Static / Unknown classifications), and runtime @TraceRecomposition from compose-stability-analyzer for release / R8 / real-device measurement.

This skill is the diagnostic layer. It does not fix recompositions; it tells the developer which composable is recomposing and which parameter is responsible. Once the param is named, the fix lives in a sibling skill — stability for unstable types, strong skipping for lambda capture, or phase deferral for state reads in the wrong phase.

When to use this skill

  • The developer says "this should be skipping but it's not" or "this re-runs every time the parent ticks".
  • The developer wants to count recompositions of a specific composable to confirm a fix worked.
  • The developer asks what "Uncertain", "Unknown", "Static", or "Unchanged" means in the Layout Inspector recomposition reasons panel.
  • A PR claims a stability or strong-skipping fix; the reviewer needs to confirm the recomposition actually went away in release.
  • The user mentions "recomposition count", "Layout Inspector", "Argument Change Reasons", "Hedgehog", "@TraceRecomposition", or "why is this recomposing".

When NOT to use this skill

  • The composable is recomposing because of an unstable type — once this skill names the offender, the actual fix is in ../../stability/diagnosing-compose-stability/SKILL.md and ../../stability/stabilizing-compose-types/SKILL.md.
  • The composable is recomposing because of a lambda capture or non-skippable scope — fix work lives in ../using-strong-skipping-correctly/SKILL.md.
  • The composable is recomposing because a state read happened in the wrong phase (Composition vs Layout vs Draw) — fix work lives in ../deferring-state-reads/SKILL.md.
  • The team needs a CI gate against future regressions — use ../../stability/enforcing-stability-in-ci/SKILL.md.

Read the full file on GitHub · 216 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. 3mo ago First seen · 216 lines · 163 tokens per session scan A 29088ac7525f

Subscribe to this mod's changes

debugging-recompositions is a skill published in the GitHub repository skydoves/compose-performance-skills (536 stars, last pushed 5mo ago), licensed Apache-2.0. It adds 163 tokens to every session and 3,825 once invoked, about $0.0007 per session on Opus 5.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-08-30.

Related

debugging-recompositions compared with skills from other repositories

debugging-recompositions next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
debugging-recompositionsskydoves/compose-performance-skillsSkill5365mo agoApache-2.0A163Claude Code, Codex
compose-performancechrisbanes/skillsSkill1.2k2d agoApache-2.0A42Claude Code
media-playback-footgunsmaxrave-dev/kotlin-footgunsSkill2.9k1mo agoGPL-3.0A58Claude Code
webview-footgunsmaxrave-dev/kotlin-footgunsSkill2.9k1mo agoGPL-3.0A58Claude Code
compose-stability-diagnosticsashtanko/compose-android-templateSkill145d agoMITA43Claude Code, Codex
claude-android-ninjaDrjacky/claude-android-ninjaSkill1432mo agoApache-2.0A123Claude Code, Codex
compose-recomposition-performanceashtanko/compose-android-templateSkill145d agoMITA78Claude Code, Codex