Skip to main content

Wickra Darwin — evolutionary strategy search at hundreds of thousands of backtests per second

CI codecov PyPI License: MIT OR Apache-2.0

Wickra Darwin — Python


Part of the Wickra ecosystem: — for Python. pip install wickra-darwin — prebuilt wheels for Linux, macOS and Windows, nothing to compile.

Python bindings for the Wickra evolutionary strategy search, built with PyO3 and maturin. A Darwin handle is driven over a JSON boundary, so a fixed seed yields the byte-identical search as every other Wickra Darwin binding.

Install

pip install wickra-darwin

Pre-built wheels ship for Linux, macOS and Windows — there is nothing to compile and no C library to track down.

Quick start

import json
from wickra_darwin import Darwin

spec = {
    "seed": 1, "population": 8, "generations": 3,
    "mutation_rate": 0.2, "crossover_rate": 0.6, "fitness": "sharpe",
    "search_space": {
        "indicators": [{"name": "rsi", "param_ranges": [{"min": 2, "max": 30, "step": 1}]}],
        "rules": "single_threshold", "max_conditions": 1,
    },
    "elitism": 1, "top": 5,
}

darwin = Darwin(json.dumps(spec))
data = {"BTCUSDT": [ { "time": 1700000000, "open": 100, "high": 101, "low": 99, "close": 100.5, "volume": 10 } ]}
report = json.loads(darwin.command(json.dumps({"cmd": "evolve", "data": data})))
print(report["best"])

Surface

  • Darwin(spec_json) — construct a search handle from an EvolveSpec JSON ("{}" defers configuration to a later set_spec). Raises ValueError on an invalid spec.
  • Darwin.command(cmd_json) — apply a command envelope ({"cmd":"...", ...}) and return the response JSON. Commands: set_spec, evolve, best, version. Raises RuntimeError on a command failure.
  • Darwin.version() — the library version.

Determinism

The search's PRNG lives only in the Rust core; this binding forwards the command string verbatim, so a given seed produces the byte-identical report here and in every other binding — the exact cross-language golden invariant.

Benchmark

Every binding forwards to the same data-driven Rust core, so what this one adds is the call overhead of PyO3, not a different result. The core's throughput is measured by the repository's benchmark suite and the nightly bench.yml run; the numbers, the machine and how to reproduce them are in the repository BENCHMARKS.md.

Documentation

The full guide, the spec reference and the API documentation live in the main repository and the documentation site:

Wickra Darwin ships native bindings for Python, Node.js, WASM and Rust, plus a C ABI hub that any C-capable language (C, C++, C#, Go, Java, R) links against — all forwarding to the same data-driven, unsafe-forbidden Rust core.

Security

Found a security issue? Please don't open a public issue. Report it privately via the repository's Security tab ("Report a vulnerability") or email support@wickra.org with a subject line starting [wickra security]. Full policy: https://github.com/wickra-lib/wickra-darwin/blob/main/SECURITY.md.

Disclaimer

Wickra Darwin is a research tool, provided "as is" without warranty of any kind. Evolutionary search optimises a fitness objective over historical data — a strong in-sample fitness is not evidence of out-of-sample performance, and overfitting is the default outcome, not the exception. Nothing here is financial advice; any strategy you deploy is your responsibility, and trading carries risk of loss.

License

Licensed under either of Apache-2.0 or MIT at your option.

Metadata

Release files for wickra-darwin 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for wickra-darwin 0.1.3
File Size Uploaded
wickra_darwin-0.1.3.tar.gz 48.9 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for wickra-darwin 0.1.3
File
wickra_darwin-0.1.3-cp39-abi3-win_arm64.whl CPython 3.9 abi3 Windows ARM64 Details
wickra_darwin-0.1.3-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details
wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_x86_64.whl CPython 3.9 abi3 Linux musl 1.2+ x86-64 Details
wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_aarch64.whl CPython 3.9 abi3 Linux musl 1.2+ ARM64 Details
wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 abi3 Linux glibc 2.17+ x86-64 Details
wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.9 abi3 Linux glibc 2.17+ ARM64 Details
wickra_darwin-0.1.3-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
wickra_darwin-0.1.3-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details

Total release size: 6.4 MB

Release files / wickra_darwin-0.1.3.tar.gz

Download URL wickra_darwin-0.1.3.tar.gz
Size 48.9 kB
Tags Source
SHA-256 checksum
How to use checksums
a8553dcb4aacbd671e0ecdb15ca7dc0f7ccc867e9a85ef8d13c38d24f77be3dd
BLAKE2b-256 checksum
How to use checksums
1ea156b0a5718942a6bd7d3c2cea04700e1fce8651466f632632e9ace3c22702
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-win_arm64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-win_arm64.whl
Size 624.0 kB
Tags CPython 3.9 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
30338668134150b96d45988947e3ffcb2fd6cf3ca9dbbd82b5f29c1a27013b1e
BLAKE2b-256 checksum
How to use checksums
99b878e28da229813c11e3f8076b8477dd6786dcb24501d701bec9bb524048e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-win_amd64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-win_amd64.whl
Size 706.8 kB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
e0f297d532b605a4c30167e9a09a16ac639d96de640efb1e95be17935d203d37
BLAKE2b-256 checksum
How to use checksums
3e8519bae4dc49f7567ec6fbfc7d872459fe72b02b8a753b028fd2d3068bceb6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_x86_64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_x86_64.whl
Size 1.1 MB
Tags CPython 3.9 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
8715275663966e982420edcfb988139d59175bd279dd6b3088dd3d49bd1904e4
BLAKE2b-256 checksum
How to use checksums
e6fd3d202e1f19f35f4b48b5778a4e2fc8deea105b7307eef5abeef57d47bc1d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_aarch64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-musllinux_1_2_aarch64.whl
Size 935.9 kB
Tags CPython 3.9 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
bab46e8df560f11274809a674b14ceae24288ec9aa51d3d64cbe3bc0c7756102
BLAKE2b-256 checksum
How to use checksums
64072f361cbe11004852249afec680b2969e9a372a20c8e436b9388ebd3134f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 840.6 kB
Tags CPython 3.9 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
9e30ae4d7c5486db2773765668a82e305433d70058522afbe7aabb5b8ba9aacd
BLAKE2b-256 checksum
How to use checksums
b026281199da45651f52035c8df7c88e2517c393051ff56be5a7784b80ef608a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 757.0 kB
Tags CPython 3.9 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
619cac35b8d9a34aab289be689d4dd6a3633957acc4971e7806da69ba54915cb
BLAKE2b-256 checksum
How to use checksums
5ed02d06ffc7554e8f1f8388b7b640822bfcaa9268e8d5d35d041998f2f4b0be
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-macosx_11_0_arm64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-macosx_11_0_arm64.whl
Size 687.2 kB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
79a3c9b76c7a0fc73cd361d2cbd2a1139a86fd782a0aaf7a7abf4366b2124ebc
BLAKE2b-256 checksum
How to use checksums
87e7fa71cf01b9b3a84319a0006142f317bcda2a81180acdbc97d0461845d559
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / wickra_darwin-0.1.3-cp39-abi3-macosx_10_12_x86_64.whl

Download URL wickra_darwin-0.1.3-cp39-abi3-macosx_10_12_x86_64.whl
Size 792.5 kB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
c8630a022e63e8c65bffda74a7c176241a30142c44f66f8df1625ae5f69bdeeb
BLAKE2b-256 checksum
How to use checksums
dd2a900e73bf60aff8a1b8e18d2f96cde587c2d53d37aa56bb63d730cbd50588
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release history Release notifications | RSS feed

0.2.0

9 release files

0.1.5

9 release files

0.1.4

9 release files

This release

0.1.3 This release

9 release files

0.1.2

9 release files

0.1.1

9 release files

0.1.0

9 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page