Skip to main content

Replacement for Step Functions — YAML DSL, code gen, and visual tooling for Lambda Durable Functions

Project description

RSF — Replacement for Step Functions

PyPI version CI License

A complete Python toolkit for defining, visualizing, generating, deploying, and debugging AWS Lambda Durable Functions workflows — with full AWS Step Functions feature parity.

What is RSF?

RSF replaces AWS Step Functions with a local-first developer experience built on AWS Lambda Durable Functions (launched at re:Invent 2025). Define workflows in YAML, generate deployment-ready Python code, and inspect executions with a visual debugger — no hosted orchestration service required.

rsf_version: "1.0"
StartAt: ProcessOrder
States:
  ProcessOrder:
    Type: Task
    Next: NotifyCustomer
  NotifyCustomer:
    Type: Task
    End: true

Features

  • YAML/JSON DSL — All 8 ASL state types, 39 comparison operators, 18 intrinsic functions, 5-stage I/O pipeline
  • Python Code Generation — Lambda Durable Functions SDK code from your workflow definition, with handler stubs that are never overwritten
  • Terraform Generation — Complete Lambda + IAM + CloudWatch infrastructure with auto-derived permissions
  • ASL Importer — Migrate existing Step Functions workflows to RSF in minutes
  • Visual Graph Editor — React-based editor with bidirectional YAML/graph sync and ELK auto-layout
  • Execution Inspector — Time machine scrubbing, live SSE updates, structural JSON diffs
  • CLI Toolchainrsf init, rsf generate, rsf validate, rsf deploy, rsf import, rsf ui, rsf inspect

Screenshots

Graph Editor Execution Inspector
Graph Editor Execution Inspector

Quickstart

Install

pip install rsf

Create a project

rsf init my-workflow
cd my-workflow
Created project: my-workflow/

  + my-workflow/workflow.yaml
  + my-workflow/handlers/__init__.py
  + my-workflow/handlers/example_handler.py
  + my-workflow/pyproject.toml
  + my-workflow/.gitignore
  + my-workflow/tests/__init__.py
  + my-workflow/tests/test_example.py

Edit workflow.yaml to define your states, then generate code.

Generate code

rsf generate
Generated: orchestrator.py
  Created: handlers/validate_order.py
  Created: handlers/process_payment.py
  Created: handlers/send_confirmation.py

Summary: orchestrator written, 3 handler(s) created, 0 skipped.

Deploy

rsf deploy
Code generated: orchestrator.py + 3 handler(s) (0 skipped)
Terraform generated: 6 file(s) in terraform (0 skipped)

Running terraform init...
Running terraform apply...

Deploy complete

Inspect executions

rsf inspect

Opens the execution inspector at http://localhost:8001

Architecture

┌──────────────────────────────────────────────────┐
│                    RSF CLI                        │
│  init · generate · validate · deploy · import    │
│  ui · inspect                                    │
├──────────────────────────────────────────────────┤
│                                                  │
│  ┌──────────┐  ┌──────────┐  ┌──────────┐      │
│  │ DSL Core │  │ Code Gen │  │ Terraform│      │
│  │ Pydantic │  │  Jinja2  │  │   HCL    │      │
│  └──────────┘  └──────────┘  └──────────┘      │
│                                                  │
│  ┌──────────┐  ┌──────────┐  ┌──────────┐      │
│  │   ASL    │  │  Graph   │  │Inspector │      │
│  │ Importer │  │  Editor  │  │  + SSE   │      │
│  └──────────┘  └──────────┘  └──────────┘      │
│                                                  │
├──────────────────────────────────────────────────┤
│              React UI (Vite + xyflow)            │
│        Graph Editor  ·  Execution Inspector      │
└──────────────────────────────────────────────────┘

Documentation

Full documentation is available at the docs site:

Technical Stack

Layer Technology
DSL Models Pydantic v2 (discriminated unions)
Code Generation Jinja2 templates
Infrastructure Terraform HCL generation
CLI Typer + Rich
Web Backend FastAPI (REST, WebSocket, SSE)
React UI React 19 + @xyflow/react + Zustand + Monaco Editor
Graph Layout ELK.js (Sugiyama algorithm)
Testing pytest (441+ tests) + vitest (52 tests)

Requirements

  • Python 3.12+ (SDK requires 3.13+)
  • Node.js 18+ (for UI development)
  • AWS account with Lambda Durable Functions enabled (for deployment)

Development

# Clone and install
git clone https://github.com/pgdad/rsf-python.git
cd rsf-python
pip install -e ".[dev]"

# Run tests
pytest

# Run UI tests
cd ui && npm test

# Start dev server (graph editor + inspector)
rsf ui --dev

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rsf-3.14.tar.gz (3.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rsf-3.14-py3-none-any.whl (773.6 kB view details)

Uploaded Python 3

File details

Details for the file rsf-3.14.tar.gz.

File metadata

  • Download URL: rsf-3.14.tar.gz
  • Upload date:
  • Size: 3.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for rsf-3.14.tar.gz
Algorithm Hash digest
SHA256 3004a0379bd29bdd262f6e4a8f780d74c69c771fb0f614c8a260e858c2bf22ca
MD5 de00d13647c4714e9b868156904e2ddb
BLAKE2b-256 c3e4dc3c680bd1e9e08dc543926c8a1bd3b7377f8c57ac9a3d8e195abfc0864a

See more details on using hashes here.

Provenance

The following attestation bundles were made for rsf-3.14.tar.gz:

Publisher: release.yml on pgdad/rsf-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rsf-3.14-py3-none-any.whl.

File metadata

  • Download URL: rsf-3.14-py3-none-any.whl
  • Upload date:
  • Size: 773.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for rsf-3.14-py3-none-any.whl
Algorithm Hash digest
SHA256 f536ec0b6f5d2a9a56be54fb9c5c55437ef5fe408d9fed789ce9ab3a1c2c24d5
MD5 d93d3f15652b5bc43633ed0ac4002f07
BLAKE2b-256 f80fe2c10321b913987ea5322495ccedca1851a29454b6430527eec998b1652b

See more details on using hashes here.

Provenance

The following attestation bundles were made for rsf-3.14-py3-none-any.whl:

Publisher: release.yml on pgdad/rsf-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page