solidity-engineer
Use when an org role acts as Solidity engineer and must ship gas-efficient, audit-ready EVM contracts: tokens, upgradeable proxies and DeFi on L1 and L2s. Covers checks-effects-interactions, reentrancy guards, OpenZeppelin bases, storage packing and custom errors.
- License 许可
- Apache-2.0
- 所属仓库
- monoes/monomind
- 最近更新
- 2026-11-14
- Stars
- ★ 23
- Forks
- 2
01 前言 Front Matter
- name
- solidity-engineer
- tags
- [ "engineering", "security", "blockchain" ]
- tools
- [ "monograph_query", "monograph_context", "monograph_impact" ]
- source
- https://github.com/monoes/monomind
- license
- Apache-2.0
- description
- Use when an org role acts as Solidity engineer and must ship gas-efficient, audit-ready EVM contracts: tokens, upgradeable proxies and DeFi on L1 and L2s. Covers checks-effects-interactions, reentrancy guards, OpenZeppelin bases, storage packing and custom errors.
03 SKILL.md 正文
Solidity Engineer — Best Practices
Focus
Writes and ships EVM smart contracts — gas-efficient, security-first, and audit-ready — for token standards, upgradeable proxies, and DeFi protocols across Ethereum and L2 chains.
Best practices
- Follow checks-effects-interactions on every function that makes an external call; update state before calling out.
- Use
call{value:}("")with a reentrancy guard instead oftransfer()/send()for ETH transfers. - Build on OpenZeppelin's audited base contracts rather than reinventing access control, tokens, or proxies.
- Pack struct fields and storage variables to minimize slot usage; cache storage reads in memory inside loops.
- Prefer custom errors over
requirestrings — cheaper to deploy and cheaper to revert. - Mark functions
external(notpublic) when never called internally; useimmutable/constantfor values that never change. - Emit an event on every state-changing function so off-chain indexers can reconstruct state.
- Plan upgrade paths (UUPS, transparent proxy, or beacon) from day one — never reorder or remove existing storage slots.
Common pitfalls
- Using
tx.originfor authorization instead ofmsg.sender. - Trusting external contract return values or oracle spot prices without staleness/sanity checks.
- Iterating over unbounded on-chain arrays — a DoS vector once the array grows.
- Shipping without a Foundry fuzz/invariant suite, then discovering an edge case in production.
- Leaving
initialize()unprotected on an upgradeable contract, letting an attacker front-run initialization.
Tools & techniques
- Foundry for unit, fuzz, and invariant testing;
forge snapshotfor gas regression tracking. - Slither and Mythril static analysis as a mandatory pre-audit gate — fix or document every finding.
- NatSpec on every public/external function; zero compiler warnings on strict settings.
- Chainlink or TWAP oracles instead of spot AMM reserves for any price-dependent logic.
- CREATE2 for deterministic cross-chain deployment addresses.
04 同仓库更多 Skills
isms-audit-expert
Use when planning or running an ISO 27001 ISMS audit: risk-based audit schedules, Annex A control assessment, Statement of Applicability and nonconformities. Auditor-side procedures, versus compliance-auditor, which is org role guidance across SOC 2, HIPAA and PCI-DSS.
instrument-data-to-allotrope
Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV. Use this skill when scientists need to standardize instrument data for LIMS systems, data lakes, or downstream analysis. Supports auto-detection of instrument types. Outputs include full ASM JSON, flattened CSV for easy import, and exportable Python code for data engineers. Common triggers include converting instrument files, standardizing lab data, preparing data for upload to LIMS/ELN systems, or generating parser code for production pipelines.
experiment-designer
Use when planning a product A/B or multivariate test: If/Then/Because hypotheses, primary and guardrail metrics, sample size and MDE, ICE prioritization. For logging and reproducing ML runs use experiment-tracker; for scientific study design use experimental-design.
digest
Generate a daily or weekly digest of activity across all connected sources. Use when catching up after time away, starting the day and wanting a summary of mentions and action items, or reviewing a week's decisions and document updates grouped by project.
design-critique
Get structured design feedback on usability, hierarchy, and consistency. Trigger with "review this design", "critique this mockup", "what do you think of this screen?", or when sharing a Figma link or screenshot for feedback at any stage from exploration to final polish.
deployment-pipeline-design
Use when architecting a multi-stage CI/CD pipeline with approval gates, SAST and DAST scans, environment promotion, canary rollout and automated rollback. Design-level; for concrete Dockerfile and health check patterns use deployment-patterns.