Skip to main content

GEPA-aware DAPO reinforcement learning with optional Global Response Normalization

Project description

gepa-dapo-grn

gepa-dapo-grn is a standalone reinforcement learning engine for research workflows. It is GEPA-shaped but GEPA-agnostic, providing DAPO optimization, curriculum tracking, safety controls, and optional Global Response Normalization (GRN) without coupling to any external GEPA repositories.

What this library is

  • Standalone RL engine with a stable public API under gepa_dapo_grn.*.
  • GEPA-shaped but GEPA-agnostic: feedback is just structured reward/tag dictionaries.
  • Supports DAPO + curriculum + safety + GRN with conservative defaults and GRN disabled unless explicitly enabled.

Install

pip install gepa-dapo-grn

Optional extras:

  • gepa-dapo-grn[hf] adds HuggingFace integration helpers.
  • gepa-dapo-grn[dev] installs test and formatting tools.

Minimal example (CPU-safe)

from gepa_dapo_grn import (
    DAPOTrainer,
    DAPOConfig,
    RewardMixerConfig,
    GEPAFeedback,
)

# minimal fake feedback example
fb = GEPAFeedback(
    rewards={"truth": 1.0, "harm": -0.5},
    tags={},
    meta={"task_id": "demo"},
    abstained=False,
)

Public API

Public API is defined by __init__.py exports. Anything not exported there is considered internal and may change without notice.

What this library intentionally does NOT do

  • ship datasets
  • provide prompt logic
  • implement scoring logic
  • encode opinions on ethics or safety policy

Versioning policy

This project follows semantic versioning:

  • 0.x.y while interfaces are still evolving
  • bump minor for interface changes
  • bump patch for bugfixes only

See CHANGELOG.md for release notes.

PyPI publishing checklist

  1. Install build and upload tooling:

    pip install build twine
    
  2. Build artifacts:

    python -m build
    
  3. Check distributions:

    twine check dist/*
    
  4. Upload to TestPyPI first:

    twine upload --repository testpypi dist/*
    
  5. Install from TestPyPI to validate:

    pip install -i https://test.pypi.org/simple/ gepa-dapo-grn
    
  6. Upload to PyPI:

    twine upload dist/*
    

License

MIT (see LICENSE).

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

gepa_dapo_grn-0.1.0.tar.gz (18.0 kB view details)

Uploaded Source

Built Distribution

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

gepa_dapo_grn-0.1.0-py3-none-any.whl (18.4 kB view details)

Uploaded Python 3

File details

Details for the file gepa_dapo_grn-0.1.0.tar.gz.

File metadata

  • Download URL: gepa_dapo_grn-0.1.0.tar.gz
  • Upload date:
  • Size: 18.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for gepa_dapo_grn-0.1.0.tar.gz
Algorithm Hash digest
SHA256 cae30dcad2e00a4a752077aafa13e81fd6e4ba660b43a9ce61909a7f5b6d3999
MD5 cb4d20c0f77da2cedd1a285e2576e7cb
BLAKE2b-256 e97708737a383732b9b06a39d6c68fbdb71a8cfee063c5ad1d789fce93e586d4

See more details on using hashes here.

File details

Details for the file gepa_dapo_grn-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: gepa_dapo_grn-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 18.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for gepa_dapo_grn-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2df67686c7133d765de185af2b2d4f767abe6e71a3f7259dffdb81d440b4b1a2
MD5 366fa6636d08e8834ecf59c396aef7fb
BLAKE2b-256 8b63be3a8395de838d48ee4c52f7f5fe23d460b01fff6b951364fb1b66734bdb

See more details on using hashes here.

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