---
title: machine
sidebar_label: machine
sidebar_position: 1
---

> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lium.io/llms.txt
> Use this file to discover all available pages before exploring further.

<!-- Generated by scripts/generate_sdk_reference.py. Do not edit directly. -->

# machine

```python
from lium.sdk import machine
```

Defined in `lium.sdk.decorators`.

```python
def machine(
    machine: str,
    template_id: Optional[str] = None,
    cleanup: bool = True,
    requirements: Optional[Sequence[str]] = None
):
```

Decorator to execute a function on a remote Lium machine.

Creates a new pod, sends function source code and executes it remotely,
returns the result, and optionally cleans up the pod.

**Arguments:**
 - **machine:**  Machine type (e.g., "1xH200", "1xA100")
 - **template_id:**  Docker template ID (optional, uses default if not specified)
 - **cleanup:**  Whether to delete the pod after execution (default: True)
 - **requirements:**  Optional iterable of pip-installable packages to install on the pod
