cache-architecture
Skill11 starsChanged 24 days agoMITView on GitHub
Cache storage locations, permissions, context scoping, isolation rules, and lifecycle management in quota-axi.
- Reads credentials
1 other project uses a version of this.
Adopted by
Most recently taken up by
- karanmrn/karanagentskillsword for word, first seen Nov 29, 2026
Other versions1 project uses a version of this.
Word for word · 1
- karanmrn/karanagentskills★ 11100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository155 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- 14-day stale PR closeSkill
- AhoySkill
- api-and-interface-designSkill
- architectSkill
- arenaSkill
- ask-mattSkill
- audit-agent-worktreesSkill
- automate-meSkill
- axiSkill
- babysit-prSkill
- benchmark-checklistSkill
- blast-radiusSkill
- broSkill
- browser-testing-with-devtoolsSkill
- chief-of-staffSkill
- chrome-devtools-axiSkill
- ci-cd-and-automationSkill
- claude-handoffSkill
- codebase-designSkill
- code-review-and-qualitySkill
- code-reviewSkill
- code-simplificationSkill
- compact-adviserSkill
- constraint-driven-developmentSkill
- context-engineeringSkill
- correctSkill
- councilSkill
- create-formal-verification-skillSkill
- create-verification-skillSkill
- debugging-and-error-recoverySkill
- delegate-to-modelSkill
- deprecation-and-migrationSkill
- diagnosing-bugsSkill
- documentation-and-adrsSkill
- domain-modelingSkill
- doubt-driven-developmentSkill
- figure-it-outSkill
- file-prSkill
- frontend-ui-engineeringSkill
- full-sendSkill
- full-stopSkill
- gh-axiSkill
- git-guardrails-claude-codeSkill
- git-workflow-and-versioningSkill
- gnhfSkill
- grillingSkill
- grill-meSkill
- grill-with-docsSkill
- handoffSkill
- hill-climbSkill
- howSkill
- idea-refineSkill
- implementSkill
- implement-specSkill
- improve-codebase-architectureSkill
- incremental-implementationSkill
- interrogateSkill
- interview-meSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 18
Strict Prohibition: Never persist raw HTTP responses, headers, authorization bearers, refresh tokens, API keys, or browser cookies.
- Distinctive: line 38
Skip on Unconfirmed: If a reading cannot confirm context identity (e.g.
- Very specific: line 46
Non-fresh or empty reads: Only readings with state.status: "fresh", at least one window, and a source other than cache are written …
- Very specific: line 59
Must have 0600 permissions.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Quota Cache Architecture & Context Scoping
This document details the disk caching architecture, file permissions, context-scoping mechanism, and data retention policies implemented in src/cache.ts.
Cache Storage & Security
- Path:
~/.cache/quota-axi/quotas.json, or$XDG_CACHE_HOME/quota-axi/quotas.jsonifXDG_CACHE_HOMEis set. - File Permissions: Cache files and parent directories must be created with strict
0600(read/write by owner only) and0700permissions. - Normalized Data Only: Cache records contain only normalized, non-secret quota snapshot structures.
- Strict Prohibition: Never persist raw HTTP responses, headers, authorization bearers, refresh tokens, API keys, or browser cookies.
Context-Scoped Providers (CONTEXT_SCOPED_PROVIDERS)
To prevent cross-account or cross-environment cache poisoning, providers whose identity is configuration-dependent or slot-shared are enrolled in CONTEXT_SCOPED_PROVIDERS in src/cache.ts:
- Enrolled Providers: See
CONTEXT_SCOPED_PROVIDERSinsrc/cache.tsfor the current set. - Context Identifiers: Snapshots carry an opaque SHA-256 context identifier derived from the answering configuration:
- Claude: Hashed profile and credential-storage selection.
claudeCredentialContextIdappends an env marker so environment-token readings cannot be served as stale cache for stored-token accounts. - Kimi: Home path plus the slot and base URL resolved from
config.toml(never the file contents, which contain keys). Prevents mainland China snapshots from serving as global fallbacks. - Command Code: Winning source plus the account identity validated by
whoami. - MiniMax: Answering credential source plus deployment host.
- ElevenLabs: Credential source plus a one-way SHA-256 digest of the answering API key.
- Devin: Answering source, the first-party host it was sent to, and a one-way SHA-256 digest of the answering API key; the key never enters the cache.
- Muse: Answering source plus a one-way SHA-256 digest of the credential that answered (the Muse CLI's stored OAuth access token or an exported
META_API_KEY); a since-refreshed token is a cache miss, never a cross-attribution between accounts. - Codex: Hashed ChatGPT account ID stored by the specific credential that produced the reading (resolving collisions between lone discovered lanes and Pi entries).
- Claude: Hashed profile and credential-storage selection.
- Fallback Verification: Stale cache fallback rejects legacy unstamped snapshots or snapshots whose context ID does not match the active configuration.
- Codex exception: Codex stamps are optional at write time, but stale serving requires ownership.
readCachedCodexProviderwithholds an unstamped snapshot, and withholds a snapshot whose stored account id is not among the ids the failed reading's tried credentials actually named; a sibling never probed does not vouch for it, and a transient failure is vouched for only by its own credential. A reading whose tried credentials name no account establishes nothing and is withheld from stale fallback. Contract: README Cache. - Skip on Unconfirmed: If a reading cannot confirm context identity (e.g. unreadable configuration), quota-axi skips both writing to cache and clearing the cache slot.
Cache Lifecycle & Exclusions
The following fields and statuses are never cached:
- Non-fresh or empty reads: Only readings with
state.status: "fresh", at least one window, and a source other thancacheare written (toCacheProvider); every other status and every cache-served report is skipped.failedis an attempt status, not a providerstate.status. - Stale reads: Stale data is never re-persisted as fresh.
- Account identities: Explicit
accountobjects are scrubbed before writing. - Source attempts: The report's
attemptslist and attempt diagnostic logs are excluded. - Derived pace & runway:
pace,runway, and selection signals are dynamic derivations computed fromgeneratedAtvs current time. They must never be frozen into cache.
PHI-safe job counts (jobs.sampled / completed / failed / other) are stored with the snapshot the same way credits is. A snapshot that never carried jobs stays without them; prompts, URLs, ids, and account identity never enter the cache. Higgsfield is excluded from --max-age fresh reuse (excludeFromFreshReuse), matching Muse: a CLI login switch is not a traced file, and the status payload has no stable non-email account discriminator.
Keychain Access Markers
- Stored alongside the cache directory in
~/.cache/quota-axi/. - Must have
0600permissions. - Filename is keyed by a hash of the selected service and account name. Contains no secret material.
- Permits non-prompting subsequent Keychain value reads once an initial grant is confirmed.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

