Amethyst is an Android client for Nostr, a social network protocol that lets people control their own social activity and connections. People use it to read and publish Nostr content, follow accounts, and exchange encrypted direct messages from Android and other supported platforms. The catalogue add-ons support workflows for developing or operating the client.
Borrowing it
Nothing to install: this file belongs to vitorpamplona/amethyst. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/vitorpamplona/amethyst/main/.claude/skills/account-state/SKILL.mdgit clone --depth 1 https://github.com/vitorpamplona/amethystWrote 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.
[](https://agentmods.dev/skills/vitorpamplona/amethyst/account-state)<a href="https://agentmods.dev/skills/vitorpamplona/amethyst/account-state"><img src="https://agentmods.dev/badge/skills/vitorpamplona/amethyst/account-state/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.
<a href="https://agentmods.dev/skills/vitorpamplona/amethyst/account-state"><img src="https://agentmods.dev/badge/skills/vitorpamplona/amethyst/account-state.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00133 | $0.02023 |
| Opus 5 | $0.00067 | $0.01012 |
| Sonnet 5 | $0.00027 | $0.00405 |
| Haiku 4.5 | $0.00013 | $0.00202 |
Grade A, and why
account-state 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 10d 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.
How it starts
The opening of the file, as written. The whole thing — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Account & Local Cache State
The backbone of Amethyst's client state: one Account per signed-in user, plus the singleton LocalCache that holds every Note and User the client has seen.
When to Use This Skill
- Working on
amethyst/src/main/java/com/vitorpamplona/amethyst/model/Account.kt - Working on
amethyst/src/main/java/com/vitorpamplona/amethyst/model/LocalCache.kt - Adding a new account-scoped setting (mutes, bookmarks, custom relay lists, private lists)
- Reading/writing user metadata (
User) or note state (Note) - Deciding whether to query
LocalCachevs subscribe to anAccountStateFlow
Mental Model
Relay frame ──► LocalCache.insertOrUpdateNote() ──► LocalCacheFlow emits change
│
▼
Account state objects pin the relevant addressable notes
│
▼
State-object `.flow` updates (kind3FollowList, nip65RelayList, muteList, …)
│
▼
ViewModels collect
│
▼
Composables render
LocalCache is the event store. Account is the derived per-user view (follow list, relays, mutes, emojis, bookmarks, etc.). UI listens to the .flow of Account's state objects, not directly to LocalCache, except for note-level rendering.
Key Files
Account.kt (singleton-per-session)
class Account(...)— holds 50+ state objects, one per feature, each wired to a specific Nostr kind:kind3FollowList = Kind3FollowListState(...)← NIP-02 ContactList (kind 3)nip65RelayList = Nip65RelayListState(...)← NIP-65 RelayList (kind 10002), plus siblingsdmRelayList,searchRelayList,blockedRelayList,trustedRelayList,proxyRelayList,broadcastRelayList,indexerRelayList, …muteList = MuteListState(...)← NIP-51 MuteList (kind 10000)bookmarkState = BookmarkListState(...)← NIP-51 Bookmarks (kind 10003), pluslabeledBookmarkLists,pinState,interestSets,peopleLists,followLists,hashtagList,geohashList,communityList,emoji,blossomServers, …- Derived/merged views:
hiddenUsers,allFollows,homeRelays,outboxRelays,dmRelays,notificationRelays,trustedRelays, and thelive*FollowListsPerRelayoutbox loaders.
- The pattern: each
XStateclass pins its addressable note viacache.getOrCreateAddressableNote(address)(a long-term reference so GC/eviction can't drop it), exposesval flow: StateFlow<…>derived from the note's metadata flow (decrypted through a per-featureDecryptionCache, with backup fallback fromAccountSettings,stateIn(scope, Eagerly, …)), and offers suspend mutation helpers (e.g.MuteListState.hideUser(pubkey)) that build the updated signed event. Consumers readaccount.muteList.flow, never a rawMutableStateFlowonAccount. - Encrypted lists pair the state object with a
DecryptionCachesibling (muteListDecryptionCache,peopleListDecryptionCache, …) so NIP-44 decryption results are cached per event. - UI reads via
collectAsStateWithLifecycleon Android andcollectAsStateon Desktop. - Sibling files per feature live alongside:
AccountSettings.kt,AccountSyncedSettings.kt, plus per-NIP state classes undermodel/nip02FollowLists/,model/nip51Lists/,model/nip65RelayList/, etc.
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 10d ago First seen · 101 lines · 133 tokens per session scan A acd2ab51e1ca
account-state is a skill published in the GitHub repository vitorpamplona/amethyst (1,597 stars, last pushed today), licensed MIT. It adds 133 tokens to every session and 2,023 once invoked, about $0.0007 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-08-30.
Other skills, from other repositories
android-leak-expert
Expert guide for detecting, profiling, and resolving memory leaks in Android apps (Java, Kotlin, Compose, JNI). Use when analyzing memory usage, profiling heap dumps, fixing out-of-memory (OOM) issues, checking Compose lifecycle flow collections, resolving WebView/Handler leaks, or configuring LeakCanary. Triggers…
sceneview
Build 3D and AR apps with the SceneView SDK in Jetpack Compose, SwiftUI (iOS/macOS/visionOS via SceneViewSwift), Web (Filament.js), Flutter and React Native. Use whenever the user asks for "3D in Compose", "AR with ARCore in Compose", a model viewer, or any cross-platform 3D/AR app where the dependency is…
sceneview-web
Build 3D and WebXR (AR/VR) experiences in the browser with SceneView for Web — Filament.js (WebGL2/WASM) wrapped in a Kotlin/JS DSL and a plain-JavaScript API on window.sceneview. Use whenever the user asks for "3D in the browser", "a web model viewer", "WebXR AR/VR", or any browser 3D/AR app where the dependency is…
to-plan
Use when one ready GitHub issue or an in-chat task needs a repository-aware implementation plan for a later implementation workflow.
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.
netwatch
Network monitoring and security audit. Use when: user asks to scan network, check open ports, network audit, who's on wifi, check connection, port scan, firewall check, network status, or network security. Don't use when: user asks about crypto transactions (use solana tools) or web search (use research skill).