easyeda-mcp-pro / easyeda-bridge-extension
AGENTS.md67 starsChanged 10 days agoMITView on GitHub
These instructions apply to easyeda-bridge-extension/** and supplement the repository root AGENTS.md. This workspace package executes inside the EasyEDA Pro/browser runtime. It is the boundary that translates validated server requests into EasyEDA API calls and returns runtime/read-back evidence. Read these before material changes: Keep the loader/runtime shell small. - src/index.ts owns socket/runtime lifecycle and should change only when that lifecycle requires it. - EasyEDA operation behavior belongs in the dispatcher/domain operation modules rather than growing the loader. - Development hot-swap is…
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,774 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository11 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .github/AGENTS.mdAGENTS.md
- easyeda-component-reviewSkill
- easyeda-professional-layoutSkill
- easyeda-component-reviewSkill
- easyeda-professional-layoutSkill
- component-searchSkill
- design-validationSkill
- easyeda-component-reviewSkill
- easyeda-professional-layoutSkill
- easyeda-workflowSkill
The file
We split this AGENTS.md into the rules it gives an agent
12 rules. About 0 are common, 8 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
4
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
- Distinctive: line 11
Read these before material changes:
- Distinctive: line 21
Keep the loader/runtime shell small.
- Very specific: line 36
Do not broaden local ws:// to LAN/public hosts for convenience.
- Distinctive: line 44
Use documented/verified EasyEDA Pro API surfaces and explicit runtime capability checks.
- Very specific: line 49
Do not silently reinterpret native undefined, missing state, or stale runtime objects as successful mutation.
- Distinctive: line 53
Keep unsupported operations fail-closed rather than inventing raw or undocumented API fallbacks.
- Very specific: line 77
Do not hand-edit generated dist/ output or the packaged .eext artifact.
- Distinctive: line 88
When compatibility-sensitive EasyEDA API behavior changes:
- Distinctive: line 90
use a disposable project for live mutation evidence.
- Distinctive: line 92
verify persisted state through the established read-back path.
- Distinctive: line 93
do not promote contract-only evidence into a live compatibility claim.
- Very specific: line 100
Before handoff or PR creation, run the root pnpm verify contract.
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.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
EasyEDA Bridge Extension Instructions
These instructions apply to easyeda-bridge-extension/** and supplement the repository root
AGENTS.md.
Boundary
This workspace package executes inside the EasyEDA Pro/browser runtime. It is the boundary that translates validated server requests into EasyEDA API calls and returns runtime/read-back evidence.
Read these before material changes:
docs/SAFETY_MODEL.mddocs/security-architecture.mddocs/EXTENSION_RELAY_PROTOCOL.mddocs/REMOTE_MCP_MODES.mdCONTRIBUTING.md
Loader and dispatcher responsibilities
Keep the loader/runtime shell small.
src/index.tsowns socket/runtime lifecycle and should change only when that lifecycle requires it.- EasyEDA operation behavior belongs in the dispatcher/domain operation modules rather than growing the loader.
- Development hot-swap is a development mechanism, not a production authorization bypass.
- Marketplace/production builds must preserve the repository's production hot-swap restrictions.
Connection policy
The local cleartext WebSocket boundary is intentionally narrow.
- Local
ws://connectivity stays on the fixed OS loopback host and bounded bridge port range enforced bysrc/connection-policy.ts. - Do not broaden local
ws://to LAN/public hosts for convenience. - Remote relay connectivity uses its authenticated secure transport; do not implement remote access by weakening local bridge restrictions.
- Preserve bounded reconnect, heartbeat, liveness, payload, and pairing behavior.
- Extension-originated echoed heartbeats are not proof that the server is alive.
EasyEDA API and mutation safety
- Use documented/verified EasyEDA Pro API surfaces and explicit runtime capability checks.
- APIs marked beta or version-sensitive must fail explicitly when unavailable.
- Validate all deterministic preconditions before the first mutation when possible.
- Preserve
confirmWrite, preview/apply, transaction, rollback, and read-back semantics established by the server/tool contract. - Do not silently reinterpret native
undefined, missing state, or stale runtime objects as successful mutation. - Timeout/disconnect during mutation means outcome unknown until read back; never blind-retry a non-idempotent write.
- Keep unsupported operations fail-closed rather than inventing raw or undocumented API fallbacks.
Local and remote mutation paths
Local bridge execution and remote relay execution must preserve equivalent tool safety semantics.
Remote approval is additional to local design-mutation confirmation. The extension must not accept a remote mutation/export merely because the same operation would be locally callable.
Build and package contract
The extension is a private workspace package whose distributable artifact is packaged into the repository release.
Use repository-owned commands:
pnpm typecheck:extension
pnpm test:extension
pnpm build:extension
pnpm verify:extension
pnpm check:extension-sizeDo not hand-edit generated dist/ output or the packaged .eext artifact. Regenerate through the
workspace scripts.
Bundle-size ratchets are policy, not a convenience target. Move them only with an intentional, measured change and preserve the hard package ceiling.
Live evidence
Mocked extension tests validate contracts but do not prove behavior in a particular EasyEDA Pro build.
When compatibility-sensitive EasyEDA API behavior changes:
- use a disposable project for live mutation evidence;
- record the exact EasyEDA/runtime version and implementation revision;
- verify persisted state through the established read-back path;
- do not promote contract-only evidence into a live compatibility claim.
Verification
During extension iteration, run focused extension tests plus the workspace checks above and
pnpm verify:fast.
Before handoff or PR creation, run the root pnpm verify contract.
Definition of done
An extension change is complete only when browser/runtime lifecycle, transport policy, EasyEDA API behavior, mutation safety, read-back evidence, tests, package verification, and compatibility claims remain aligned.
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.

