agentleFS
alexderzalexderz/agentic-toolbox/skills/lang-protobuf/SKILL.md

lang-protobuf

Skill5 starsChanged 47 days agoMITView on GitHub

use this when writing or reviewing *.proto files or generated stubs you are allowed to edit. generated code is usually not hand-edited. load with the host language when you also change application code.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Add fields. Do not reuse field numbers.

    line 23
  2. Very specific:

    Use optional / presence as the proto edition in the repo already does.

    line 25
  3. Distinctive:

    Keep packages stable. Compatibility is the API.

    line 27
  4. Distinctive:

    No type change of a shipped field.

    line 43
  5. Distinctive:

    Treat decoded protobuf as untrusted input in the host language (size limits, required-meaning fields validated after parse).

    line 48
  6. Distinctive:

    Do not embed secrets in proto comments committed to git.

    line 50

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Protocol Buffers

No scripts/. Proto-led change with hand-edited host code: see Algorithm. Process skills that may load with this one: language-router Load-with list.

Iron law

Fields are forever. Reserve deleted numbers. Do not hand-edit generated stubs.

Tooling / verify

Regenerate with the project's command (buf generate, protoc, etc.). Diff only the intended schema change plus the expected generated files.

Idioms a linter misses

  • Add fields. Do not reuse field numbers.
  • reserved numbers and names when removing.
  • Use optional / presence as the proto edition in the repo already does.
  • Keep packages stable. Compatibility is the API.
  • Comments say why a field exists, not what the type is.

Errors

  • Unknown fields must survive a round-trip on old clients. Do not strip them in app code.

Testing

  • Old client + new field must parse.
  • Golden encoded bytes for wire format if the repo has them.

PR review

  • No reused numbers.
  • No type change of a shipped field.
  • Generated files only from codegen.

Security

  • Treat decoded protobuf as untrusted input in the host language (size limits, required-meaning fields validated after parse).
  • Do not embed secrets in proto comments committed to git.

Always

  • Additive changes. reserved on delete. Codegen, not hand edits.

Ask first

  • Renaming a shipped field.
  • Changing a field type.
  • Breaking package rename.

Never

  • Reusing a field number.
  • Editing generated *.pb.go / *_pb2.py / *.pb.ts by hand.

Red flags

  • "I'll reuse field 3, nothing uses it"
  • "I'll just tweak the generated stub"

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.