dotnet-logger-message-design

dotnet-logger-message-design is a skill for Claude Code, Codex from Arasz/ai-raccoon. It costs 86 tokens per session (1,407 once invoked), scanned A, original, MIT.

A design and testing guide for structured log messages in .NET, Microsoft's platform for C# applications. It covers reusable logger methods, event identifiers, message parameters, and assertions against captured log records.

In plain words
What is it for?
Use it when adding or reviewing .NET log lines, assigning event IDs, logging collections or per-item details, and writing FakeLogger-based tests for level, ID, and message content.
Why use it?
Logging can become inconsistent, allocate unnecessary strings, or promise details that it does not actually record. These rules help keep messages distinguishable and make their contents testable.

Skill for Claude CodeCodex

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

Good fit Use it when adding or reviewing .NET log lines, assigning event IDs, logging collections or per-item details, and writing FakeLogger-based tests for level, ID, and message content.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/arasz/ai-raccoon/dotnet-logger-message-design
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 Arasz/ai-raccoon --skill dotnet-logger-message-design
Clone the repo
git clone --depth 1 https://github.com/Arasz/ai-raccoon

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 dotnet-logger-message-design

README.md
[![agentmods](https://agentmods.dev/badge/skills/arasz/ai-raccoon/dotnet-logger-message-design/github.svg)](https://agentmods.dev/skills/arasz/ai-raccoon/dotnet-logger-message-design)
Your own site
<a href="https://agentmods.dev/skills/arasz/ai-raccoon/dotnet-logger-message-design"><img src="https://agentmods.dev/badge/skills/arasz/ai-raccoon/dotnet-logger-message-design/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 dotnet-logger-message-design

Your own site · 80×15
<a href="https://agentmods.dev/skills/arasz/ai-raccoon/dotnet-logger-message-design"><img src="https://agentmods.dev/badge/skills/arasz/ai-raccoon/dotnet-logger-message-design.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 86 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,407 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.00086 $0.01407
Opus 5.5 $0.00034 $0.00563
Sonnet 5.5 $0.00017 $0.00281
Haiku 4.5 $0.00009 $0.00141

Measured yesterday against content hash 05bc5e9ef16c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

dotnet-logger-message-design 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 yesterday.

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.

.ai-badger/skills/dotnet-workload/references/dotnet-logger-message-design/SKILL.md · 50 lines

How it starts

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

dotnet-logger-message-design

Design and test [LoggerMessage] logging that stays inside the high-performance invariant (nested static partial Log, explicit EventIds, no string interpolation at call sites) while actually delivering what the help text/docs promise.

Trigger

  • Adding a new log line to a service that uses the nested Log class pattern.
  • A finding like "feature promises to log X but logs only counts" — designing the detail-logging fix.
  • Writing tests that assert log records (EventId, level, message contents).

Design rules

  1. [LoggerMessage] templates cannot format collections. An IReadOnlyList<string> parameter renders as its type name. Pre-join at the call site: string.Join(", ", reasons) — that is a parameter build, NOT interpolation, so it satisfies the no-interpolation invariant. One small allocation, fine off the hot path.
  2. EventIds: allocate from the class's next free id in its own range (event ids are scoped per logger category — cross-class reuse is benign, same-category collisions are not). One EventId per (message shape, level) pair; if the same shape is logged at two levels, write two [LoggerMessage] methods.
  3. Per-item detail logs: one structured message per item, not one giant aggregated string — each item becomes filterable/greppable in structured sinks. Gate detail logging by mode/level when the ops line should stay counts-only; volume math decides the level (e.g. a 30-min interval loop can afford Information; a per-request loop cannot).
  4. Don't widen records to feed logs. Before designing "log the score", check the record exposes it. Adding a field to a record an MCP tool / API serializes directly ripples into the wire contract (additive JSON, but still a contract change needing tool tests + docs). Prefer logging the existing explanatory data (e.g. a reasons list encodes the score breakdown) and the rank position.
  5. Reuse existing truncation. If the domain layer already truncates a preview (e.g. 300 chars) for the API response, log that field as-is — don't add a second, smaller truncation constant just for logs.
  6. Promise surfaces decide implement-vs-correct-docs. When help text / README / class doc comments all promise behavior X but the code logs counts only, count the promising surfaces: with N surfaces promising X and one missing implementation, implementing X is usually cheaper and more honest than correcting N surfaces. Re-verify every cited file:line in the finding first — findings mis-cite (a finding may cite a docs line that never promised the behavior; the promise often lives in CLI help, README, and the class doc comment instead).

Read the full file on GitHub · 50 lines

Files

What ships with it

1 file 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.

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. yesterday First seen · 50 lines · 86 tokens per session scan A 05bc5e9ef16c

Subscribe to this mod's changes

dotnet-logger-message-design is a skill published in the GitHub repository Arasz/ai-raccoon (7 stars, last pushed today), licensed MIT. It adds 86 tokens to every session and 1,407 once invoked, about $0.0003 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-12-05.

Related

dotnet-logger-message-design compared with skills from other repositories

dotnet-logger-message-design next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
dotnet-logger-message-designArasz/ai-raccoonSkill7todayMITA86Claude Code, Codex
http-client-migrationGen-Verse/PAST-BenchSkill404mo agoApache-2.0A14Claude Code, Codex
dotnet-pinvokerootcastleco/rei-skillsSkill115d agononeA119Claude Code, Codex
azure-eventgrid-dotnetrootcastleco/rei-skillsSkill115d agononeA80Claude Code, Codex
directory-build-organizationrootcastleco/rei-skillsSkill115d agononeA142Claude Code, Codex
avalonia-viewmodels-zafirorootcastleco/rei-skillsSkill115d agononeA26Claude Code, Codex
Cursor rules for Aspnet AbpAmariahAK/atlarix-skillsSkill02mo agoApache-2.0A7Claude Code, Codex