Metadata-Version: 2.4
Name: syft-serve
Version: 0.3.2
Summary: Generic FastAPI server process management and deduplication
Project-URL: Homepage, https://github.com/OpenMined/syft-serve
Project-URL: Repository, https://github.com/OpenMined/syft-serve
Project-URL: Documentation, https://docs.syft-serve.org
Author-email: OpenMined <info@openmined.org>
License: Apache-2.0
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
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
Requires-Python: >=3.9
Requires-Dist: fastapi>=0.115.5
Requires-Dist: httpx>=0.25.0
Requires-Dist: jupyter-dark-detect>=0.1.0
Requires-Dist: psutil>=5.9.0
Requires-Dist: pydantic>=2.0.0
Requires-Dist: requests>=2.31.0
Requires-Dist: starlette>=0.41.2
Requires-Dist: tabulate>=0.9.0
Requires-Dist: urllib3>=2.5.0
Requires-Dist: uvicorn[standard]>=0.24.0
Provides-Extra: dev
Requires-Dist: black>=23.0.0; extra == 'dev'
Requires-Dist: mypy>=1.0.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.21.0; extra == 'dev'
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
Requires-Dist: pytest-mock>=3.10.0; extra == 'dev'
Requires-Dist: pytest-xdist>=3.0.0; extra == 'dev'
Requires-Dist: pytest>=7.0.0; extra == 'dev'
Requires-Dist: ruff>=0.1.0; extra == 'dev'
Description-Content-Type: text/markdown

# syft-serve

[![PyPI](https://img.shields.io/pypi/v/syft-serve.svg)](https://pypi.org/project/syft-serve/)
[![Python](https://img.shields.io/pypi/pyversions/syft-serve.svg)](https://pypi.org/project/syft-serve/)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Docs](https://img.shields.io/badge/docs-latest-brightgreen.svg)](https://openmined.github.io/syft-serve/)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![Ruff](https://img.shields.io/badge/linter-ruff-FCC21B.svg)](https://github.com/astral-sh/ruff)
[![OpenMined](https://img.shields.io/badge/by-OpenMined-blue.svg)](https://github.com/OpenMined)

**Self-hosting should be effortless**

Turn any Python function into a self-hosted server in one line. No DevOps required.

```python
import syft_serve as ss
import requests

def hello():
    return "Hi!"

server = ss.create("my_api", {"/": hello})

requests.get(server.url).text  # "Hi!"
```

## Installation

```bash
pip install syft-serve
```

## Why syft-serve?

☁️ **The cloud isn't yours** - Not your computer, not your control  
🏠 **Yours is inconvenient** - Self-hosting means wrestling with configs  
✨ **Convenience is possible** - Self-hosting should be a 1-liner

## What it does

```python
# You write:
server = ss.create("my_api", {"/predict": my_function})

# Behind the scenes:
# ✓ Spins up isolated Python environment
# ✓ Installs your dependencies safely  
# ✓ Generates production-ready FastAPI code
# ✓ Manages server process lifecycle
# ✓ Streams logs for easy debugging
# ✓ Cleans up everything when done

# No orphan processes. No port conflicts. No hassle.
```

## See It In Action

<div align="center">
  <a href="https://github.com/OpenMined/syft-serve">
    <img src="https://github.com/OpenMined/syft-serve/blob/main/docs/syft_serve_demo_rounded.gif?raw=true" alt="syft-serve Demo" width="700" />
  </a>
</div>

## Documentation

📖 **[Full documentation and examples](https://openmined.github.io/syft-serve/)**

See interactive tutorials, videos, and complete API reference.

## License

Apache 2.0 - see [LICENSE](LICENSE) file for details.