# pvieito/PythonKit

Swift framework to interact with Python.

Repository: https://github.com/pvieito/PythonKit
Canonical: https://ross.abutalabs.com/products/pythonkit
Language: Swift
License: Apache-2.0
License Family: permissive
Last push: 2026-07-08T11:25:47+00:00

## Health v2 (maintenance only)
Score: 73/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 91, release rhythm 35, longevity 100
- inputs: {"age_days": 3118, "days_push": 56, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2219, forks 246 (observed 2026-08-28T04:06:27.371795+00:00)

## What it is
PythonKit is a Swift framework that lets Swift code interact with the Python runtime, importing Python modules and calling Python objects dynamically. It loads the Python library at runtime and is configurable via environment variables like PYTHON_VERSION and PYTHON_LIBRARY.

## Use cases
- call python code from swift
- import python modules in a swift app
- use python libraries like numpy from swift
- embed python interpreter in swift application
- bridge swift and python on macos or linux

## When to choose
- you are building in Swift and need Python's ecosystem
- you want dynamic Python interop without code generation
- you target Apple platforms or Linux with Swift Package Manager

## When to avoid
- you need static typing or compile-time safety for the Python API
- you want to call Swift from Python rather than the other way around
- your project cannot ship or link a Python runtime

## Facets
- artifact type: framework
- maturity: active
- function: sdk, interpreter
- domain: programming-languages, developer-tools, cross-platform
- platform: cross-platform
- tags: python-interop, swift-package-manager, language-bridge, swift, macos, linux, ios

## Member repositories
- pvieito/PythonKit (main) score 73

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:27.371795+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:45:52.596094+00:00, confidence not recorded.
  - readme: https://github.com/pvieito/PythonKit (fetched 2026-08-28T04:06:27.371795+00:00, sha 93fa78b8958d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
