# imageworks/pystring

C++ functions matching the interface and behavior of python string methods with std::string

Repository: https://github.com/imageworks/pystring
Canonical: https://ross.abutalabs.com/products/pystring
Language: C++
License: BSD-3-Clause
License Family: permissive
Last push: 2026-06-13T23:25:41+00:00

## Health v2 (maintenance only)
Score: 86/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 87, release rhythm 76, longevity 100
- inputs: {"age_days": 5613, "days_push": 81, "days_rel": 81, "gap_med": 63, "n_releases_24m": 2}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1089, forks 167 (observed 2026-08-28T04:03:32.700002+00:00)

## What it is
Pystring is a collection of C++ functions that replicate the interface and behavior of Python's string class methods using std::string, without requiring a Python interpreter. It was originally developed at Sony Pictures Imageworks and is useful in mixed C++/Python environments.

## Use cases
- use python-style string methods in C++ code
- find and slice strings like python's str.find and slicing
- port python string manipulation logic to C++
- share string handling behavior between C++ and python codebases
- perform string operations missing from the C++ standard library

## When to choose
- you need python-compatible string semantics in a C++ project
- your codebase mixes C++ and python and needs consistent string behavior
- you want lightweight string utilities with no python interpreter dependency

## When to avoid
- you need unicode-aware string operations beyond std::string's capabilities
- you prefer modern C++ standard library or range-based string utilities
- you need a full string class rather than free functions

## Facets
- artifact type: library
- maturity: stable
- function: parser, developer-tools
- domain: developer-tools, programming-languages, cross-platform
- platform: cpp, cross-platform
- tags: string-manipulation, python-compatibility, std-string, header-only

## Member repositories
- imageworks/pystring (main) score 86

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:32.700002+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-30T06:49:18.049580+00:00, confidence not recorded.
  - readme: https://github.com/imageworks/pystring (fetched 2026-08-28T04:03:32.700002+00:00, sha b77a625b6b94)
- Data as of 2026-08-30T08:39:29.467469+00:00.
