engine-adapter-scaffold
Skill2 starsChanged 5 months agoApache-2.0View on GitHub
Scaffolds a new MCP server wrapping an external engine (KiCad, ngspice, Renode, PlatformIO…) with the standard import/export/validate tool contract, round-trip test harness, and engine-status.md entry. Use when onboarding any new engine.
In this repository9 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- context-syncSkill
- deploy-sanitySkill
- file-issueSkill
- ir-schema-guardSkill
- issue-triageSkill
- pick-issueSkill
- reap-staleSkill
- tdd-cycleSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 0 are distinctive, and 3 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.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Every engine gets one package: packages/mcp-<engine>, an MCP server speaking IR.
- Very specific: line 32
Every produced document is stamped provenance: { source: "mcp-<engine>", at: ISO }.
- Very specific: line 41
Update .context/engine-status.md status row + .context/architecture.md if the engine adds a new capability class.
≈ “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.
Files
engine-adapter-scaffold
Every engine gets one package: packages/mcp-<engine>, an MCP server speaking IR.
Layout to generate
packages/mcp-<engine>/
├── package.json # name @openbench/mcp-<engine>, deps: @openbench/ir-schema, @modelcontextprotocol/sdk
├── tsconfig.json # extends ../../tsconfig.base.json
├── src/
│ ├── index.ts # public API: importNative, exportNative, validate (pure functions)
│ ├── server.ts # MCP server registering the tools (thin wrapper over index.ts)
│ └── <engine>/ # engine-specific parsing/serialization
└── test/
├── contract.test.ts # THE round-trip contract: import(export(doc)) toEqual doc
└── fixtures/ # real native-format samples (checked in, small)The standard tool contract (non-negotiable)
import(nativeFormat) -> IR document(s)— never throws raw engine errors; returns structured{ ok, documents | errors }.export(IR document) -> nativeFormatvalidate(IR document) -> { valid, errors: [{ path, message }] }— delegates to@openbench/ir-schemathen adds engine-specific constraints.- Every produced document is stamped
provenance: { source: "mcp-<engine>", at: ISO }.
Order of work (TDD)
- Red: contract.test.ts with a minimal fixture → commit.
- Green: parser/serializer until round-trip holds.
- Lossy fields discovered → document them in
.context/engine-status.md(same PR; the reviewer gate enforces this forpackages/mcp-*changes). - MCP server.ts last — it is a thin adapter over tested pure functions.
- Update
.context/engine-status.mdstatus row +.context/architecture.mdif the engine adds a new capability class.
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.

