diff --git a/CHANGELOG.md b/CHANGELOG.md index 203e195..1604527 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,11 @@ user-facing notes live in [`docs/updates/`](docs/updates/) (English and ## Unreleased +## 2.2.1 — 2026-10-13 + +The first stable release of the 2.2 line (2.2.0b1 was a pre-release): everything +below was added since 2.1.4, the notebook runtime of 2.2.0b1 included. + ### Removed - Re-Studio, the reverse-engineering studio (the `Re-mode` workspace of the @@ -16,6 +21,14 @@ user-facing notes live in [`docs/updates/`](docs/updates/) (English and ### Added +- Modeling: `scale`, affine `transform`, signed `offset`, `draft`, tapered and + until-limited extrusions and multisection sweeps are recorded features, and + boolean results can keep every output of a set operation; graph nodes keep + ordered input references so a replay selects the same entities. +- `tools/research/build123dftc`: an execution-based build123d to FTC converter + (isolated tracing, exact profile reconstruction, generated notebooks and + assemblies) with independent geometry and STEP acceptance. It is research + tooling, not part of the installed package. - Editor: light mode. The editor follows the system theme and a button in the header cycles system, light and dark (remembered); the 3D viewport, edges, grid, axes and the code editor switch with it, in place, without reloading @@ -64,6 +77,11 @@ user-facing notes live in [`docs/updates/`](docs/updates/) (English and ### Changed +- Volumes and centres of mass integrate NURBS by knot spans (Gauss-Kronrod) + instead of the fixed-order routine: exact for rational patches (a sewn + 80 mm cube measures 512000 mm3, the old routine overshot by ~19 mm3) and + safe on affine-transformed trims. A degenerate blend result now measures 0 + and is still reported as `BlendVolumeViolation`. - The cell cache is per cell: an entry is stored under a digest of the local modules, child notebooks and input files *that cell* depends on (and what the cells it reads from depend on), no longer one digest for the whole notebook. A diff --git a/README.md b/README.md index 9bdc4d6..ad8d5cd 100644 --- a/README.md +++ b/README.md @@ -149,10 +149,10 @@ the full crank cycle sweeps clean in the same sim · --- -## Update Notes (2.2) +## Update Notes (2.2.1) -> **Release notice:** Pre-release (beta). Validate generated definitions, -> assembly constraints, and manufacturing geometry before production use. +> Validate generated definitions, assembly constraints, and manufacturing +> geometry before production use. - **New editor.** `sca edit` is part of the SDK now (`pip install "simplecadapi[editor]"`). It runs a workspace's notebooks in a marimo kernel @@ -199,7 +199,7 @@ in a compact public API for creating solids, applying features, tagging semantic intent, querying topology, exporting manufacturing files, and translating recorded models into FreeCAD workflows. -Package: `simplecadapi` on PyPI (the 2.2 line is pre-release; 2.1.4 is the latest stable). +Current release: `simplecadapi==2.2.1`. ## What It Provides @@ -714,6 +714,7 @@ and the [STEP reconstruction workflow](docs/skill/references/workflows/step-reco ## Documentation +- 2.2.1 update notes: [`docs/updates/2.2.1.md`](docs/updates/2.2.1.md) - 2.1.3b1 update notes: [`docs/updates/2.1.3b1.md`](docs/updates/2.1.3b1.md) - 2.1.2 update notes: [`docs/updates/2.1.2.md`](docs/updates/2.1.2.md) - 2.1.1 update notes: [`docs/updates/2.1.1.md`](docs/updates/2.1.1.md) diff --git a/README.zh-CN.md b/README.zh-CN.md index 00af8ec..161501c 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -133,9 +133,9 @@ CalculiX 静力 FEM(边界面按保真的 `interface.*` 标签选取,仿真 --- -## 更新日志(2.2) +## 更新日志(2.2.1) -> **版本提示:** 预发布(beta)。投入生产前请验证生成的定义、装配约束和制造几何。 +> 投入生产前请验证生成的定义、装配约束和制造几何。 - **新编辑器。** `sca edit` 现在是 SDK 的一部分(`pip install "simplecadapi[editor]"`)。它用 SDK 自己的 cell 执行器在 marimo 内核里运行工作 @@ -173,7 +173,7 @@ CalculiX 静力 FEM(边界面按保真的 `interface.*` 标签选取,仿真 SimpleCADAPI 是一个基于 OCP 的 Python CAD SDK,提供清晰的函数式建模操作和可重放的模型图。它在 OpenCascade 几何内核之上提供精简的公共 API,可用于创建实体、应用特征、添加语义标签、查询拓扑、导出制造文件,以及将记录的模型转换为 FreeCAD 工作流。 -包:PyPI 上的 `simplecadapi`(2.2 系列为预发布;2.1.4 是最新稳定版)。 +当前版本:`simplecadapi==2.2.1`。 ## 核心能力 @@ -599,6 +599,7 @@ uv run --extra fem python examples/ap242_gmsh_volume_mesh/run_calculix.py ## 文档 +- 2.2.1 更新说明:[`docs/updates/2.2.1.zh-CN.md`](docs/updates/2.2.1.zh-CN.md) - 2.1.3b1 更新说明:[`docs/updates/2.1.3b1.zh-CN.md`](docs/updates/2.1.3b1.zh-CN.md) - 2.1.2 更新说明:[`docs/updates/2.1.2.zh-CN.md`](docs/updates/2.1.2.zh-CN.md) - 2.1.1 更新说明:[`docs/updates/2.1.1.zh-CN.md`](docs/updates/2.1.1.zh-CN.md) diff --git a/docs/skill/SKILL.md b/docs/skill/SKILL.md index 8d52b23..9cd131c 100644 --- a/docs/skill/SKILL.md +++ b/docs/skill/SKILL.md @@ -4,9 +4,9 @@ description: Build, assemble, inspect, reconstruct, and export parametric CAD mo license: Apache-2.0 metadata: project: simplecadapi - version: 2.2.0b1 + version: 2.2.1 package-name: simplecadapi - package-version: 2.2.0b1 + package-version: 2.2.1 --- # SimpleCAD SDK Skill diff --git a/docs/updates/2.2.1.md b/docs/updates/2.2.1.md new file mode 100644 index 0000000..826db0d --- /dev/null +++ b/docs/updates/2.2.1.md @@ -0,0 +1,37 @@ +# 2.2.1 Update Notes + +The first stable release of the 2.2 line. It brings the code-first editor, the +notebook runtime of 2.2.0b1 and the agent landing path to a stable version. + +## Editor: `sca edit` + +- A web editor over a directory of notebooks, part of the SDK + (`pip install "simplecadapi[editor]"`). It runs the notebooks in a marimo + kernel with the SDK's own cell executor, previews the live model straight + from the solids, and shares one per-cell cache with `sca run`. +- Parameters from `# ---- params ----` cells (an optional `# ui:` comment picks + the control); local modules (shared dimensions) have their own view. +- Picking a solid, face, edge or vertex writes a `scad.ql` selection cell + (`selected_`, `selected_item`) into the notebook; edits autosave; a cell + reference can be copied for a coding agent; `sca snapshot` shows an agent what + the person sees. A log dock reports what ran and what failed. +- Light and dark themes (follows the system, with a manual switch). +- **Re-Studio is removed**: the reverse-engineering studio (`Re-mode` of the + standalone sca-web-editor) is gone; `sca edit` replaces the standalone editor. + +## Landing path for agents + +`docs/landing.md` is the script an agent follows to install the SDK and its +skill and to open an example in the editor. `sca example u_link` copies the +bundled workspace; `sca skill where` shows where the skill is installed. The +wheel now carries the built editor UI, the skill sources and the example. + +## Modeling + +`scale`, affine `transform`, signed `offset`, `draft`, tapered and +until-limited extrusion and multisection sweep are recorded features. Volumes +and centres of mass integrate NURBS by knot spans, which is exact for rational +patches. A build123d to FTC converter is included under +`tools/research/build123dftc` (research tooling). + +See the [changelog](../../CHANGELOG.md) for the complete list. diff --git a/docs/updates/2.2.1.zh-CN.md b/docs/updates/2.2.1.zh-CN.md new file mode 100644 index 0000000..614193a --- /dev/null +++ b/docs/updates/2.2.1.zh-CN.md @@ -0,0 +1,32 @@ +# 2.2.1 更新说明 + +2.2 系列的第一个稳定版。它把 code-first 编辑器、2.2.0b1 的 notebook 运行时和面向 +agent 的落地路径带到稳定版本。 + +## 编辑器:`sca edit` + +- 面向一个 notebook 目录的网页编辑器,是 SDK 的一部分 + (`pip install "simplecadapi[editor]"`)。它用 SDK 自己的 cell 执行器在 marimo + 内核里运行 notebook,直接由实体生成实时预览,并与 `sca run` 共用一份逐 cell 缓存。 +- 参数来自 `# ---- params ----` cell(可用 `# ui:` 注释选择控件);本地模块(共用 + 尺寸)有独立视图。 +- 点选实体、面、边或顶点会向 notebook 写入一个 `scad.ql` 选择 cell + (`selected_`、`selected_item`);编辑自动保存;可复制 cell 引用交给 coding + agent;`sca snapshot` 让 agent 看到用户所见。底部日志面板显示运行了什么、哪里失败。 +- 浅色与深色主题(跟随系统,可手动切换)。 +- **Re-Studio 已移除**:逆向工程 studio(独立 sca-web-editor 的 `Re-mode`)不再存在, + 独立编辑器由 `sca edit` 取代。 + +## 面向 agent 的落地路径 + +`docs/landing.md` 是 agent 安装 SDK 和 skill、并在编辑器里打开示例时遵循的脚本。 +`sca example u_link` 复制内置工作区;`sca skill where` 显示 skill 的安装位置。wheel +现在包含已构建的编辑器 UI、skill 源码和示例。 + +## 建模 + +`scale`、仿射 `transform`、带符号 `offset`、`draft`、带锥度和直到限定的拉伸、多截面 +扫掠都成为可记录的特征。体积与质心按节点区间积分 NURBS,对有理曲面是精确的。 +`tools/research/build123dftc` 下附带 build123d 到 FTC 的转换器(研究工具)。 + +完整列表见[更新日志](../../CHANGELOG.md)。 diff --git a/pyproject.toml b/pyproject.toml index c905f0e..91a9e5e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "simplecadapi" -version = "2.2.0b1" +version = "2.2.1" description = "A simplified OCP-native CAD modeling Python API" readme = "README.md" license = { file = "LICENSE" } diff --git a/uv.lock b/uv.lock index 55fd8de..7d795ef 100644 --- a/uv.lock +++ b/uv.lock @@ -3227,7 +3227,7 @@ wheels = [ [[package]] name = "simplecadapi" -version = "2.2.0b1" +version = "2.2.1" source = { editable = "." } dependencies = [ { name = "cadquery-ocp" },