Metadata-Version: 2.4
Name: mgi_prepall
Version: 0.0.1
Summary: Python SDK for compiling protocols for the MGI PrepALL workstation.
Author-email: Yang Meng <yangmeng1@mgi-tech.com>
Maintainer-email: Yang Meng <yangmeng1@mgi-tech.com>
License: Apache-2.0
Keywords: pipette,lab,automation,liquid handler,pcr,protocols,workstation,mgi,prepall
Classifier: Development Status :: 4 - Beta
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering
Classifier: Intended Audience :: Science/Research
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pydantic>=2.7.1
Dynamic: license-file

# mgi_prepall Protocol API

`mgi_prepall` is a Python SDK that compiles a lab procedure (liquid handling, module control, gripper moves) into a `ProtocolDefinition` JSON for the PrepALL workstation.

A minimal protocol script:

```python
from mgi_prepall import Context

metadata = {
    "protocolName": "hello",
    "author": "me",
    "description": "",
}

def run(ctx: Context) -> None:
    ctx.init(
        lane1="plateRack", lane2="plateRack",
        lane3="plateRack", lane4="trashAndPCR",
        useTrashBin=True, trashBinType="B",
    )
    pipette = ctx.load_pipette("p1000_flex8")
    tips = ctx.load_labware("mgi_prepall_plate_carrier_low_adapter", "1-1") \
              .load_labware("mgi_96_filtertiprack_200ul", code="T1")
    src  = ctx.load_labware("mgi_prepall_plate_carrier_low_adapter", "1-2") \
              .load_labware("mgi_96_well_plate", code="P1")
    dst  = ctx.load_labware("mgi_prepall_plate_carrier_low_adapter", "1-3") \
              .load_labware("mgi_96_well_plate", code="P2")

    pipette.transfer(50.0, (src, "A1"), (dst, "A1"), tiprack=tips)
```

Compile to JSON:

```bash
python -m mgi_prepall my_protocol.py -o my_protocol.json
```

## Documentation

- **[Getting Started](getting_started.md)** — full walkthrough of a first protocol
- **[API Reference](api/index.md)** — every public class and method
- **[Examples](examples.md)** — index of the 8 demo scripts under `mgi_prepall/examples/`
