---
description: Python via .NET project guidance
globs: "**/*.py"
alwaysApply: false
---

# Aspose.Slides for Python via .NET

Use these instructions for this platform only. Read the project's existing instructions and dependency files first. Keep its current package version unless the task requires a change. Confirm API names against this platform's documentation; bindings are not interchangeable.

## Setup

Use an isolated Python environment and the `aspose.slides` package. Import it as `aspose.slides`, and use its Python properties and enum names. Use a `with` block for `Presentation`. Follow the operating-system dependency instructions; do not substitute the Python via Java package.

## Install for a local test

With an isolated Python environment active, install the verified version:

```sh
python -m pip install aspose.slides==26.10.0
```

These pinned versions reproduce the example below. Preserve an existing project's dependency choices unless the user asks to change them.

## Minimal example

After installation, run this as `starter.py` in your configured project. It creates `hello.pptx` in the working directory. Use a scratch directory so an existing file is not replaced.

```python
import aspose.slides as slides

with slides.Presentation() as presentation:
    shape = presentation.slides[0].shapes.add_auto_shape(
        slides.ShapeType.RECTANGLE, 50, 50, 500, 80
    )
    shape.text_frame.text = "Hello, Aspose.Slides!"
    presentation.save("hello.pptx", slides.export.SaveFormat.PPTX)
```

Verified on 2026-11-18: Windows x64, Python 3.12, aspose.slides 26.10.0. The program ran and the saved file contained one slide with the expected text. This evaluation-mode check does not prove licensed output or other operating systems.

## License

Evaluation mode is suitable for a local smoke test and can add watermarks or other limits. If the user supplies a valid license, follow the [licensing guide](https://docs.aspose.com/slides/python-net/licensing/) before creating presentations. Read the license from a private local location accessible to the process. Never put license contents, keys, or personal paths in instructions, source control, or logs.

## Verify the change

Before expanding a change, create a small presentation, save it to a new file, and open the result. Check the requested content, slide count, and formatting. Build and run the exact code against the installed package; report any missing runtime or dependency instead of claiming it was tested.

Keep input files local unless the user permits sharing them. Write output to a new file and preserve the original. Report what ran, the versions used, and any checks that remain.

## Sources

- [Documentation](https://docs.aspose.com/slides/python-net/)
- [API reference](https://reference.aspose.com/slides/python-net/)
- [Installation](https://docs.aspose.com/slides/python-net/installation/)
- [Licensing](https://docs.aspose.com/slides/python-net/licensing/)
