Metadata-Version: 2.4
Name: sim-plugin-comsol
Version: 0.1.7
Summary: COMSOL Multiphysics driver for sim-cli, distributed as an out-of-tree plugin
Project-URL: Homepage, https://github.com/svd-ai-lab/sim-plugin-comsol
Project-URL: Repository, https://github.com/svd-ai-lab/sim-plugin-comsol
Project-URL: Issues, https://github.com/svd-ai-lab/sim-plugin-comsol/issues
Project-URL: Changelog, https://github.com/svd-ai-lab/sim-plugin-comsol/blob/main/CHANGELOG.md
Author: svd-ai-lab
License-Expression: Apache-2.0
License-File: LICENSE
License-File: LICENSE-NOTICE.md
Keywords: cae,comsol,multiphysics,plugin,sim-cli,simulation
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: Microsoft :: Windows
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.10
Requires-Dist: mph<2.0,>=1.2
Requires-Dist: sim-cli-core>=0.3
Provides-Extra: test
Requires-Dist: build>=1.0; extra == 'test'
Requires-Dist: pytest>=7; extra == 'test'
Description-Content-Type: text/markdown

# sim-plugin-comsol

[COMSOL Multiphysics](https://www.comsol.com) driver for [sim-cli](https://github.com/svd-ai-lab/sim-cli), distributed as an out-of-tree plugin via Python `entry_points`.

The COMSOL solver and its `mph` Python binding are not bundled — you supply them yourself. See [LICENSE-NOTICE.md](LICENSE-NOTICE.md).

## Install

```bash
pip install sim-plugin-comsol
```

After install, sim-cli auto-discovers the driver:

```bash
sim drivers | grep comsol
sim run --solver comsol path/to/script.py
```

You can also install through sim-cli's plugin command:

```bash
sim plugin install sim-plugin-comsol
```

For realtime-visible COMSOL Desktop collaboration on Windows, use the
standalone attach helper:

```powershell
sim-comsol-attach open --json --timeout 120
sim-comsol-attach exec --file step.java --json
```

## How it works

The plugin registers via three entry-point groups:

```toml
[project.entry-points."sim.drivers"]
comsol = "sim_plugin_comsol:ComsolDriver"

[project.entry-points."sim.skills"]
comsol = "sim_plugin_comsol:skills_dir"

[project.entry-points."sim.plugins"]
comsol = "sim_plugin_comsol:plugin_info"
```

`sim.drivers` exposes the driver class; `sim.skills` exposes a directory
of skill files bundled inside the wheel; `sim.plugins` exposes plugin
metadata for discovery.

## Develop

```bash
git clone https://github.com/svd-ai-lab/sim-plugin-comsol
cd sim-plugin-comsol
uv sync
uv run pytest
```

## License

Apache-2.0. See [LICENSE](LICENSE) and [LICENSE-NOTICE.md](LICENSE-NOTICE.md).
