sonde
CLAUDE.md2 starsChanged 8 months agoMITView on GitHub
sonde: precision instrumentation that continuously measures AI usage and reports conditions in real-time. Rust statusline binary (Phase 1), macOS menu bar app in Swift (Phase 2).
- Reads credentials
In this repository20 other files it gives its agents.
- ai-native-cliSkill
- api-documentationSkill
- api-security-best-practicesSkill
- architectureSkill
- bash-proSkill
- clean-codeSkill
- code-review-excellenceSkill
- debugging-strategiesSkill
- documentationSkill
- github-actions-templatesSkill
- git-pr-workflows-pr-enhanceSkill
- ios-developerSkill
- performance-optimizerSkill
- rust-async-patternsSkill
- rust-proSkill
- security-auditSkill
- swiftui-expert-skillSkill
- systematic-debuggingSkill
- test-driven-developmentSkill
- testing-patternsSkill
The file
We split this CLAUDE.md into the rules it gives an agent
7 rules. About 0 are common, 0 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 12
All config structs: #[derive(Debug, Deserialize, Default)], all fields pub Option<T>
- Very specific: line 16
Never use ? operator where a warning is needed -- use explicit match
- Very specific: line 22
Create src/modules/{name}.rs with pub fn render(ctx: &Context, cfg: &SondeConfig) -> Option<String>
- Very specific: line 23
Add match arm in src/modules/mod.rs
- Very specific: line 53
Test fixtures in tests/fixtures/
- Very specific: line 55
Use rstest for parameterized tests
- Very specific: line 56
Use assert_cmd for CLI integration tests
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md 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
sonde — Claude Code Instructions
What this project is
sonde: precision instrumentation that continuously measures AI usage and reports conditions in real-time. Rust statusline binary (Phase 1), macOS menu bar app in Swift (Phase 2).
Non-negotiable code patterns
- Module interface:
pub fn render(ctx: &Context, cfg: &SondeConfig) -> Option<String> - All config structs:
#[derive(Debug, Deserialize, Default)], all fieldspub Option<T> - Context struct: all
Option<T>, NOdeny_unknown_fields(forward-compatible) - Disabled flag -> silent
None(no warning) - Missing data -> explicit
match+tracing::warn!+None - Never use
?operator where a warning is needed -- use explicitmatch - stdout owned ONLY by
main.rs; all diagnostics viatracing::*to stderr - OAuth token: NEVER written to disk, cache, stdout, or stderr
Adding a new module (2 files max)
- Create
src/modules/{name}.rswithpub fn render(ctx: &Context, cfg: &SondeConfig) -> Option<String> - Add match arm in
src/modules/mod.rs
File ownership rules
- stdin reading:
src/context.rsONLY - stdout writing:
src/main.rsONLY - HTTP calls:
src/usage_api.rsONLY (OAuth) andsrc/promo.rsONLY (PromoClock) - Credential access:
src/platform.rsONLY - Cache I/O:
src/cache.rsONLY - Config parsing:
src/config.rsONLY - ANSI styling:
src/ansi.rsONLY
Key APIs
Claude Code OAuth usage endpoint
GET https://api.anthropic.com/api/oauth/usage Authorization: Bearer {token} anthropic-beta: oauth-2025-04-20
PromoClock API
GET https://promoclock.co/api/status
Credential locations
- macOS:
security find-generic-password -s "Claude Code-credentials" -w - Linux:
~/.claude/.credentials.json - Linux fallback:
secret-tool lookup service "Claude Code-credentials"
Testing
echo '{"model":{"display_name":"Opus"}}' | cargo runto test- Test fixtures in
tests/fixtures/ - Mock HTTP calls in tests -- never hit real APIs
- Use
rstestfor parameterized tests - Use
assert_cmdfor CLI integration tests
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.

