Find, evaluate, and download common purchasable CAD parts from step.parts, including named off-the-shelf actuators, servos, motors, electronics boards, connecto
复制下面这句话,粘贴给 Claude Code、Codex、Cursor 等 AI 编程工具,它会读取安装说明并在你确认后完成安装。
请阅读 https://ai.atlankj.com/install/asset/gh-step-parts-b531a22e461d ,按照其中的说明把「step-parts」安装到你(当前 AI 工具)中。执行前先告诉我将运行的命令和写入的位置,等我确认。
查看 AI 将读取的安装说明正在读取 GitHub 原文…
内容来自 GitHub 原始文件,由原作者维护。在 GitHub 查看
Provenance: maintained in earthtojake/text-to-cad. Use the installed local skill files as the runtime source of truth; the repository link is only for provenance and release review.
Use the hosted step.parts machine endpoints instead of scraping HTML or relying on local repository files. Treat https://api.step.parts as the canonical API origin and https://www.step.parts as the site/static-asset origin unless the user provides a different hosted mirror. Network/DNS failures are inconclusive: if api.step.parts cannot be reached from the sandbox, retry once with network permission before reporting a miss or using placeholder geometry. Do not describe a part as unavailable unless the API was reachable and returned no relevant candidates.
When a CAD assembly includes named off-the-shelf actuators, servos, motors, electronics boards, connectors, or other purchasable components, search step.parts before creating simplified placeholder geometry. For named servos, motors, and actuators, search both exact model strings and common aliases/vendor spellings before giving up. For example, STS3215 may also appear as ST3215, 3215, Waveshare Feetech ST3215, or under family=feetech. If the API was reachable and no exact or near-exact match is available, record the search miss and then use a documented envelope or simplified stand-in.
q for fuzzy tokens, standards, aliases, dimensions, source/product URLs, and attribute names/values.category, family, standard, or tag when the user gives an exact facet./v1/parts and inspect items, total, and facets. For actuator model numbers, retry likely aliases, dropped letters, vendor names, and relevant family facets before treating an empty result as a miss.id, name, standard, and key attributes before choosing. If one result clearly matches, return the selected record details without downloading unless the user asked for a local STEP file.stepUrl, then verify the file with the record's sha256 when present.After completing step.parts work that creates or updates a local .step or .stp file, you must ALWAYS hand the explicit file path to $cad-viewer when that skill is installed. $cad-viewer must start CAD Viewer if it is not already running and return link(s) to the relevant created or updated file(s); if $cad-viewer is unavailable or startup fails, report that instead of silently omitting the handoff.
Use scripts/download_step_part.py for deterministic search, download, and checksum verification:
python scripts/download_step_part.py "M3 socket head 12" --download
python scripts/download_step_part.py --id iso4762_socket_head_cap_screw_m3x12 --download
python scripts/download_step_part.py "bearing 608zz" --limit 5
Useful options:
--origin: override https://api.step.parts only when the user provides another hosted API origin.--tag, --category, --family, --standard: repeatable facet filters.--out-dir: destination directory for downloads. It defaults to the system temp directory, so pass it whenever the file should survive in the project.--filename: rename the one downloaded file; rejected together with --all.--limit, --page: search page size (default 10, API cap 500) and 1-based page.--all: with --download, download every result on the returned page as individual STEP downloads.--overwrite: replace an existing output file. Without it, an existing destination is refused rather than overwritten.The script prints JSON to stdout. For searches, it prints matched records. For downloads, it prints saved file paths, checksums, and source URLs. Failures print a one-line plain-text message to stderr and exit 1.
Read references/step-parts-api.md when you need endpoint details, field meanings, or query semantics. Prefer:
/v1/parts for filtered search with absolute asset URLs./v1/parts/{id} for one enriched record.stepUrl for STEP downloads./v1/catalog/parts.index.json for a compact discovery index./v1/catalog/schema for field and family attribute meanings./v1/openapi.json when generating a client or tool.M3 SHCS 12 before adding exact family and standard filters.tag, category, family, and standard fields are ANDed together. Use exact facets to narrow within known categories, then rank manually by name and attributes.ISO 4762, ISO4762, or the exact standard.designation.attributes object contains family-specific facts such as thread, lengthMm, bore1Mm, material, profileSeries, slotSizeMm, and dimensions in millimeters.https://www.step.parts; STEP URLs are environment-aware and may resolve to GitHub LFS media in production. Use catalog/API stepUrl for downloads.