科研 Skill
硬件成本核算与采购
cost-and-sourcing
Prices a hardware product at multiple volumes with one-time vs per-unit cost, landed cost per country, and sourcing leads. Use to estimate unit cost before a pitch.
SKILL.md
Cost and sourcing
You work out what the product costs to make at each order size, and where every part and process comes from. Every number keeps its source. Talk to the user in their language.
The goal is not one magic number. It is a table that shows:
- why one unit costs hundreds of dollars and ten thousand units cost tens;
- which three or four lines drive the cost;
- which numbers are verified and which are still estimates;
- which quotes to ask for next.
Prerequisites
Run commands from inside this skill's own directory (the folder containing this SKILL.md), since script and reference paths below (such as scripts/foo.py) are written relative to it, not to the project root.
Inputs
hw/bom.csv: the canonical BOM (columns in CONVENTIONS.md §5).electronics-researcherfills in the price breaks.hw/brief.md: target markets, launch quantities and target retail price.hw/pcb/: board count, layers, size, sides, joint count and hidden-joint parts (QFN, BGA, LGA).hw/mech/: enclosure parts, materials, finishes and inserts.hw/power/: the battery, catalog or custom.hw/compliance.md: certification costs (owned bycompliance-planner; you read them and never re-estimate them).hw/roadmap.md: which build stage (EVT/DVT/PVT) uses which process (owned byprototype-roadmap).
Outputs
hw/cost/manufacturing.json: the inputs of the cost model. Start fromtemplates/manufacturing.example.json.hw/cost/model.json,hw/cost/cost.mdandhw/cost/cost.svg: written byscripts/cost_model.py. Incost.mdthe script rewrites only the block between<!-- cost_model:begin -->and<!-- cost_model:end -->. Write your analysis outside the markers, and it survives every re-run. The chart title states the conclusion againsttargets.unit_cost.hw/cost/rfq.md: the quotes to request, built fromtemplates/rfq.md.hw/cost/sourcing.md: where to buy each part or process, with the authorized channel, MOQ, lead time and second source.
Procedure
-
Read the BOM and check that it can be costed. Every line needs a full orderable MPN with its packaging suffix, a quantity, at least one price break and an evidence tag.
- If prices are missing, ask
electronics-researcherto fill them. Do not invent a price. - A part with no price stays in the model with a warning.
- If prices are missing, ask
-
Model the PCBA from the assembler's published tariff, not from a guess. Count three things per board:
- solder joints (pins plus exposed pads);
- unique part types (each one has a loading fee);
- hidden-joint parts that need X-ray.
Put them in the
pcbablock. The example template holds one quick-turn tariff as published on its date. Re-check it before use, and replace it with a real quote once Gerbers exist. -
Write every other cost as a line with a value per tier. Classify each line by how it behaves (section "Cost structure"): recurring, per order, or one-time (NRE).
- Give every value as a
[low, high]range unless it is a quote. - Tag every line
verified: <source, date>,estimate: <basis>orassumption.
- Give every value as a
-
Use the right process for each tier. The same part is made differently at 10 and at 10,000 units. For example, an enclosure goes SLA → urethane casting → rapid aluminum tool → hardened steel. Each process brings its own NRE (
from_tier/to_tier). Seereferences/cost-reference.md. -
Run the model:
python3 scripts/cost_model.py --mfg hw/cost/manufacturing.json --out hw/cost --svgThe script applies three rules:
- Part attrition: the assembler's extra parts per feeder.
- MOQ: below the MOQ you pay for the whole MOQ or for paid samples, whichever is cheaper.
- Yield loss: scrapped units still cost their parts.
It writes the tables, the top cost drivers per tier and the share of cost that rests on verified figures. Test the script with
python3 scripts/test_cost_model.py. -
Add landed cost for each market in the brief. Use the method in
references/landed-cost.md: duty and tax multiplier on CIF, courier versus formal import, FX as a dated assumption. Destination rules change often. Every rule carries a date and the word "verify". -
Read the result like an engineer and write
cost.mdaround the script's tables, outside the generated-block markers. Put the brief's unit-cost goals intargets.unit_cost, so each tier readsmet,not provenornot met. Use the landed recurring row for the cost of one more imported unit, and the incl. NRE row for the launch budget. Answer these questions:- At which order size does NRE stop dominating?
- Which single part or process is the biggest lever? (A memory chip or a custom battery often outweighs everything else.)
- What does the launch batch really cost per unit, with certifications spread over it?
- What is the gap to the target retail price? A retail price usually needs to be about 3–5× the landed cost to leave room for the channel and the margin. Label this as a rule of thumb.
-
Write
sourcing.md. For each BOM line, list:- the authorized distributors that stock it;
- the MOQ and reel size;
- the lead time;
- a second source;
- anything long-lead to buy now.
For each process (PCB, PCBA, molding, cell, metal parts, packaging, final assembly), list 2–4 established vendors from
references/suppliers.md. -
Write
rfq.md. List every estimate that moves the total by more than about 5%. For each one, say what to send, to whom, and which number the quote will close. Order the list by impact.
Cost structure
| Kind | Behaves like | Examples | In the model |
|---|---|---|---|
| Recurring | paid for every unit | parts at the tier price; bare boards; PCBA per-joint and X-ray fees; molded parts; battery; magnets, membranes, cord; packaging; final assembly, programming and test labor; freight | recurring, BOM, pcba variable |
| Per order (batch) | paid on every production order, spread over that order | PCBA setup, stencil, feeder loading, fixtures, handling; molding run setup and color change; plating lot charge; prototype board lot | per_order, pcba batch |
| One-time (NRE) | paid once per design revision | mold tools; stamping dies; photo-etch phototools; test and programming fixtures; custom cell tooling; certifications (radio, EMC, safety, Bluetooth qualification, IP rating, UN38.3); packaging dies; design services | nre |
| Yield loss | a percentage on recurring | scrapped and reworked units; cosmetic rejects on clear parts (10–30% early) | yield_loss_pct |
| Landed | a multiplier on recurring plus freight | duties, import taxes, broker fees | landed |
Keep engineering salaries, marketing, warranty reserve and retail margin out of the unit cost. Say in the report that they are excluded.
Sourcing rules
- Buy production parts only from authorized channels. These are the manufacturer, its franchised distributors (DigiKey, Mouser, Arrow, Avnet, Future, TME, Farnell/Newark, and LCSC for parts it is franchised for), or the EMS's own purchasing.
- A broker or marketplace is a last resort, for prototypes, and only with traceability.
- Counterfeit and remarked parts come from brokers.
- Respect the reel. Prices at 1k and 10k assume full reels. Cut tape and small quantities cost more and carry an assembler surcharge. Check that the tier price you use matches the packaging suffix of the MPN.
- Plan attrition. Assemblers consume extra parts per feeder. For 0201/0402 passives, order at least 20 extra, or 5%.
- Buy long-lead parts early. Any part with a lead time over 12 weeks, or with stock below one production run, goes in
sourcing.mdunder "buy now".- For prototypes, buy enough for EVT and DVT at once.
- A part that is "early sampling" or NRND at the manufacturer is a design risk. Hand it back to
specs-engineer. Do not hide it with a price.
- Second-source passives by value, not by MPN. Approve 2–3 brands per value and package (for example Murata, Samsung, TDK, Yageo for MLCCs). Single-source an IC only when no pin-compatible alternative exists, and say so.
- Consign or turnkey. For quick-turn turnkey assembly, check that the assembler's library stocks your exact parts. Consign the rest: ship them to the assembler, labelled, with spares.
- Use established vendors only. Never recommend an unknown company found through a marketplace. Check that a vendor still operates (some well-known startups have closed). Verify each vendor's current status before recommending it.
Gate
Cost and sourcing pass when all of these are true:
- Every BOM line has a price at every tier, or an explicit warning.
- Every line in
manufacturing.jsonhas an evidence tag. cost.mdstates the share of cost resting on verified figures at the launch tier.rfq.mdcovers every estimate that moves the total by more than about 5%.- The total at the launch quantity, with certifications, is stated next to the target retail price.
Taste and pitfalls
- Never present an estimate as a quote. "About $3–8 for final assembly at 1k (estimate, China box-build range)" is honest. "$5" is not.
- Don't let one line hide inside a total. A single 4 Gbit NAND or a custom cell can be half of the recurring cost. Call it out by name, with its share.
- A custom battery below its MOQ is expensive. At 100 units you either pay for 2,000 cells or for paid samples. The model shows it, and you say it.
- Certifications are paid before the first sale, even for a "small" launch batch. Spread them over the launch batch and show that number. It is usually the uncomfortable one.
- Tooling dominates at 1k. At 1,000 units, NRE is often about half the total. Do not quote the 10k recurring cost as "the cost".
- Clear and cosmetic parts have high scrap. Budget it in
yield_loss_pctor in the part price. - Use the tariff's real breakpoints. PCBA X-ray and fixture fees step with quantity. A smooth curve is wrong at 5 and at 100 units.
- Date every price and every tax rule. Duties, de minimis thresholds and courier regimes change, sometimes within months.
- Tables are aligned and readable. Right-align numbers, keep units in the header, and use one currency per table. Never show more than 3 significant figures for an estimate.
References
Read these when the step needs them:
| File | Read when |
|---|---|
references/cost-reference.md | you need typical, dated figures for PCB, PCBA, molding, metal parts, batteries, final assembly, packaging and certification lines |
references/landed-cost.md | you compute landed cost or explain import taxes for a destination |
references/suppliers.md | you name vendors for a part or process |
references/manufacturing-json.md | you write or debug hw/cost/manufacturing.json |
templates/rfq.md | you write hw/cost/rfq.md |
templates/manufacturing.example.json, templates/bom.example.csv | you start a new model; they are a complete fictional example that runs |
示例提示词
帮我算一下这款产品在不同产量下的单台成本和采购渠道。
所属插件
安装该插件会一并获得同领域的 63 个 Skill / MCP。
同插件的其他科研 Skill
- ANDES电力系统动态仿真Runs ANDES power-system dynamic studies via PowerMCP: power flow, eigenvalue analysis, and time-domain simulation. Use for damping, stability, or oscillation-mode questions.
- 电池选型与电源预算Builds an evidence-tagged power budget and sizes a manufacturable battery with pouch outline, seals, and derating. Use when sizing runtime, mAh, charging, or supply rails.
- FPGA比特流生成与烧录Generates a Xilinx FPGA bitstream and programs it over JTAG, or burns an MCS image into flash for power-on boot. Use when flashing a board or diagnosing boot failures.
- 硬件项目发布包组装Assembles a hardware release package (fab files, BOM/CPL, carts, assembly guide, hashed manifest) and runs a ready-to-build gate. Use before ordering prototypes.
- 时钟域交叉风险审查Audits clock-domain-crossing risk on an FPGA design and applies the smallest safe synchronizer or constraint fix. Use to resolve CDC violations before sign-off.
- 硬件产品认证合规规划Plans certifications a hardware product needs per target market (FCC, CE/RED, UKCA, battery/radio rules), with cost and lead-time estimates. Use before PCB or enclosure tooling.
- Vivado XDC时序约束编写Authors a Vivado XDC timing constraint set from scratch: clocks, I/O delays, and timing exceptions. Use first, before timing closure, on a design with no or incomplete constraints.
- N-1/N-2应急违规处置Playbook for N-1/N-2 contingency violations: ranks contingencies and proposes preventive and corrective actions. Use after a study shows voltage or thermal problems.
- 潮流计算不收敛诊断Playbook for power-flow convergence failures in PSS/E, PSLF, PowerWorld, pandapower, PyPSA, surge, or OpenDSS. Use when a case diverges or fails to solve.
- RTL仿真覆盖率收敛Measures RTL simulation code coverage and iteratively closes it toward a target by adding testbench stimulus. Use for a sign-off-grade coverage report.
- 配电网DER接纳能力治理Playbook for distribution DER hosting-capacity limits: voltage rise, reverse flow, and thermal limits from PV and storage. Use to estimate how much DER a feeder can host.
- 电子电路设计与审查Designs, audits, or corrects an electronic circuit from a brief, schematic, or netlist, checking power domains, reset sequencing, and ratings. Use for circuit review.
- 硬件可制造性红队审查Red-team audit that fix-loops a hardware project to ready-to-build, re-deriving parts, rails, battery physics, and cost. Use for a reality check before committing to a design.
- 电力系统动态稳定处置Playbook for dynamic stability problems: poor damping, angle instability, or sustained oscillations from eigenvalue or time-domain studies. Use after an unstable study result.
- Egret电力市场调度优化Runs Egret market/operations optimization (DC-OPF, AC-OPF, unit commitment) via PowerMCP. Use for cheapest dispatch, unit commitment, or congestion checks.
- 电子元器件选型核查Researches electronic components against primary sources: part numbers, datasheet limits, lifecycle, stock, and price breaks, one dossier per part. Use to verify or source a BOM.
- EMC电磁兼容预测试Plans grounding, shielding, and filtering for EMC/EMI, and runs an emissions pre-scan with a root-cause fix sequence. Use before a lab test or after a failed EMI scan.
- 产品外壳参数化建模Designs a hardware enclosure as parametric CAD with STEP/STL/GLB output, a DFM check, and Blender assembly validation. Use when designing a case or checking fit.
- 电网频率响应问题处置Playbook for frequency problems: low inertia, high RoCoF, weak primary response, or UFLS risk after loss of the largest unit. Use when a study flags frequency issues.
- FPGA RTL到比特流全流程Drives a Xilinx FPGA design end to end through RTL, simulation, synthesis, implementation, and bitstream, gated at every stage. Use to run the complete build flow in one pass.
- 硬件产品全流程总协调Leads a physical electronic product from idea to a doable design, coordinating specs, parts, battery, PCB, enclosure, render, and cost sub-skills. Use starting a hardware product.
- 硬件原理图与BOM审查Reviews hardware projects: checks schematics against datasheets, pin connections, and firmware-to-hardware alignment across KiCad/Altium files. Use for a design alignment check.
- FPGA ILA在线逻辑调试Inserts an Integrated Logic Analyzer, programs the board, arms a trigger, and reads captured waveforms on real FPGA hardware. Use when sim passes but the board fails.
- 新能源并网影响评估Playbook for screening the grid impact of a new generator, storage, or large-load interconnection. Use to check whether a given MW can connect and what upgrades it needs.
常见问题
硬件成本核算与采购能做什么?
Prices a hardware product at multiple volumes with one-time vs per-unit cost, landed cost per country, and sourcing leads. Use to estimate unit cost before a pitch。
如何安装硬件成本核算与采购?
在科搭 Codar 左侧点击「插件」,在「组件」页签搜索「硬件成本核算与采购」并安装;在 Claude Code 或 Codex 中可以发送本页的安装提示词,或下载 Skill 包后解压到 ~/.claude/skills 或 ~/.codex/skills。
硬件成本核算与采购需要哪些权限?
该科研 Skill没有声明额外权限;执行具体操作时仍由 Agent 按自身规则请求确认。
硬件成本核算与采购经过官方审核吗?
是。SpeedSkills 收录的每个版本都会记录内容摘要与权限声明,当前版本已通过安全审核。