sa-sv-duality 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sa_sv_duality-1.0.0/.github/ISSUE_TEMPLATE/bug_report.md +35 -0
- sa_sv_duality-1.0.0/.github/ISSUE_TEMPLATE/feature_request.md +29 -0
- sa_sv_duality-1.0.0/.github/PULL_REQUEST_TEMPLATE.md +31 -0
- sa_sv_duality-1.0.0/.github/workflows/ci.yml +63 -0
- sa_sv_duality-1.0.0/.github/workflows/release.yml +118 -0
- sa_sv_duality-1.0.0/.gitignore +22 -0
- sa_sv_duality-1.0.0/.pre-commit-config.yaml +17 -0
- sa_sv_duality-1.0.0/.zenodo.json +33 -0
- sa_sv_duality-1.0.0/CHANGELOG.md +20 -0
- sa_sv_duality-1.0.0/CONTRIBUTING.md +49 -0
- sa_sv_duality-1.0.0/LICENSE +21 -0
- sa_sv_duality-1.0.0/PKG-INFO +208 -0
- sa_sv_duality-1.0.0/README.md +173 -0
- sa_sv_duality-1.0.0/README_QUICKSTART.md +71 -0
- sa_sv_duality-1.0.0/RELEASE_GUIDE.md +44 -0
- sa_sv_duality-1.0.0/contracts/example_full.yaml +57 -0
- sa_sv_duality-1.0.0/contracts/example_minimal.yaml +12 -0
- sa_sv_duality-1.0.0/contracts/runtime.schema.yaml +152 -0
- sa_sv_duality-1.0.0/docs/cli.md +88 -0
- sa_sv_duality-1.0.0/docs/index.md +48 -0
- sa_sv_duality-1.0.0/docs/templates.md +111 -0
- sa_sv_duality-1.0.0/docs/zenodo.md +66 -0
- sa_sv_duality-1.0.0/mkdocs.yml +44 -0
- sa_sv_duality-1.0.0/pyproject.toml +91 -0
- sa_sv_duality-1.0.0/scripts/validate_runtime.py +209 -0
- sa_sv_duality-1.0.0/src/diamond_setup/__init__.py +4 -0
- sa_sv_duality-1.0.0/src/diamond_setup/_types.py +13 -0
- sa_sv_duality-1.0.0/src/diamond_setup/cli.py +183 -0
- sa_sv_duality-1.0.0/src/diamond_setup/preset.py +84 -0
- sa_sv_duality-1.0.0/src/diamond_setup/templates/__init__.py +13 -0
- sa_sv_duality-1.0.0/src/diamond_setup/templates/genesis.py +84 -0
- sa_sv_duality-1.0.0/src/diamond_setup/templates/minimal.py +171 -0
- sa_sv_duality-1.0.0/src/diamond_setup/validator.py +67 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/__init__.py +37 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/action_entropy.py +153 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/benchmark.py +159 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/cli.py +167 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/constants.py +31 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/duality_relation.py +138 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/lagrangian_bridge.py +175 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/network_routing.py +155 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/q4_sav_map.py +152 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/system.py +237 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/variational.py +144 -0
- sa_sv_duality-1.0.0/src/sa_sv_duality/volume_entropy.py +121 -0
- sa_sv_duality-1.0.0/tests/__init__.py +0 -0
- sa_sv_duality-1.0.0/tests/test_cli.py +120 -0
- sa_sv_duality-1.0.0/tests/test_preset.py +90 -0
- sa_sv_duality-1.0.0/tests/test_runtime_contract.py +177 -0
- sa_sv_duality-1.0.0/tests/test_sa_sv_duality.py +340 -0
- sa_sv_duality-1.0.0/tests/test_validator.py +54 -0
- sa_sv_duality-1.0.0/uv.lock +1243 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Bug report
|
|
3
|
+
about: Report something that isn't working as expected
|
|
4
|
+
title: "[BUG] "
|
|
5
|
+
labels: bug
|
|
6
|
+
assignees: ""
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Description
|
|
10
|
+
|
|
11
|
+
A clear and concise description of the bug.
|
|
12
|
+
|
|
13
|
+
## Steps to reproduce
|
|
14
|
+
|
|
15
|
+
1. ...
|
|
16
|
+
2. ...
|
|
17
|
+
3. ...
|
|
18
|
+
|
|
19
|
+
## Expected behavior
|
|
20
|
+
|
|
21
|
+
What you expected to happen.
|
|
22
|
+
|
|
23
|
+
## Actual behavior
|
|
24
|
+
|
|
25
|
+
What actually happened (include full error messages / tracebacks if any).
|
|
26
|
+
|
|
27
|
+
## Environment
|
|
28
|
+
|
|
29
|
+
- Package version: (`pip show <package-name>` or `git describe --tags`)
|
|
30
|
+
- Python version:
|
|
31
|
+
- OS:
|
|
32
|
+
|
|
33
|
+
## Additional context
|
|
34
|
+
|
|
35
|
+
Anything else relevant — logs, screenshots, related issues.
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Feature request
|
|
3
|
+
about: Suggest a new feature, module, or enhancement
|
|
4
|
+
title: "[FEATURE] "
|
|
5
|
+
labels: enhancement
|
|
6
|
+
assignees: ""
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Summary
|
|
10
|
+
|
|
11
|
+
A clear and concise description of the feature.
|
|
12
|
+
|
|
13
|
+
## Motivation
|
|
14
|
+
|
|
15
|
+
Why is this needed? What problem does it solve, or what new capability
|
|
16
|
+
does it enable within the GenesisAeon ecosystem?
|
|
17
|
+
|
|
18
|
+
## Proposed approach
|
|
19
|
+
|
|
20
|
+
How might this be implemented? (Sketches, pseudocode, references to
|
|
21
|
+
related GenesisAeon packages or Diamond Interface methods are welcome.)
|
|
22
|
+
|
|
23
|
+
## Alternatives considered
|
|
24
|
+
|
|
25
|
+
Any alternative approaches you've thought about.
|
|
26
|
+
|
|
27
|
+
## Additional context
|
|
28
|
+
|
|
29
|
+
Links to relevant papers, prior discussion, or related issues/PRs.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
## Summary
|
|
2
|
+
|
|
3
|
+
What does this PR do, in one or two sentences?
|
|
4
|
+
|
|
5
|
+
## Related issue(s)
|
|
6
|
+
|
|
7
|
+
Closes #...
|
|
8
|
+
|
|
9
|
+
## Type of change
|
|
10
|
+
|
|
11
|
+
- [ ] Bug fix
|
|
12
|
+
- [ ] New feature
|
|
13
|
+
- [ ] Breaking change (Diamond Interface or other public API)
|
|
14
|
+
- [ ] Documentation
|
|
15
|
+
- [ ] Tooling / CI / release process
|
|
16
|
+
- [ ] Dependency update
|
|
17
|
+
|
|
18
|
+
## Checklist
|
|
19
|
+
|
|
20
|
+
- [ ] Tests added/updated and passing locally (`pytest`)
|
|
21
|
+
- [ ] `CHANGELOG.md` updated under `## [Unreleased]`
|
|
22
|
+
- [ ] Documentation updated (README, docstrings, notebooks if relevant)
|
|
23
|
+
- [ ] If this changes `run_cycle` / `get_crep_state` / `get_utac_state` /
|
|
24
|
+
`get_phase_events` / `to_zenodo_record`: noted as a breaking change
|
|
25
|
+
and version bump plan described above
|
|
26
|
+
- [ ] If this touches scientific claims/predictions: sources cited and
|
|
27
|
+
speculative vs. validated status is clear
|
|
28
|
+
|
|
29
|
+
## Additional notes
|
|
30
|
+
|
|
31
|
+
Anything reviewers should know.
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: ["main", "master", "claude/**"]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: ["main", "master"]
|
|
8
|
+
|
|
9
|
+
concurrency:
|
|
10
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
11
|
+
cancel-in-progress: true
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
lint:
|
|
15
|
+
name: Lint (ruff + mypy)
|
|
16
|
+
runs-on: ubuntu-latest
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
- uses: actions/setup-python@v5
|
|
20
|
+
with:
|
|
21
|
+
python-version: "3.11"
|
|
22
|
+
- name: Install dev dependencies
|
|
23
|
+
run: pip install -e ".[dev]"
|
|
24
|
+
- name: Run ruff
|
|
25
|
+
run: ruff check src tests
|
|
26
|
+
- name: Run mypy
|
|
27
|
+
run: mypy src
|
|
28
|
+
|
|
29
|
+
test:
|
|
30
|
+
name: Tests (Python ${{ matrix.python-version }})
|
|
31
|
+
runs-on: ubuntu-latest
|
|
32
|
+
strategy:
|
|
33
|
+
fail-fast: false
|
|
34
|
+
matrix:
|
|
35
|
+
python-version: ["3.11", "3.12"]
|
|
36
|
+
steps:
|
|
37
|
+
- uses: actions/checkout@v4
|
|
38
|
+
- uses: actions/setup-python@v5
|
|
39
|
+
with:
|
|
40
|
+
python-version: ${{ matrix.python-version }}
|
|
41
|
+
- name: Install dependencies
|
|
42
|
+
run: pip install -e ".[dev]"
|
|
43
|
+
- name: Run pytest with coverage
|
|
44
|
+
run: pytest --cov=src --cov-report=xml
|
|
45
|
+
- name: Upload coverage
|
|
46
|
+
if: matrix.python-version == '3.11'
|
|
47
|
+
uses: codecov/codecov-action@v4
|
|
48
|
+
with:
|
|
49
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
50
|
+
files: coverage.xml
|
|
51
|
+
|
|
52
|
+
docs:
|
|
53
|
+
name: Docs (mkdocs --strict)
|
|
54
|
+
runs-on: ubuntu-latest
|
|
55
|
+
steps:
|
|
56
|
+
- uses: actions/checkout@v4
|
|
57
|
+
- uses: actions/setup-python@v5
|
|
58
|
+
with:
|
|
59
|
+
python-version: "3.11"
|
|
60
|
+
- name: Install dev and docs dependencies
|
|
61
|
+
run: pip install -e ".[dev,docs]"
|
|
62
|
+
- name: Build docs
|
|
63
|
+
run: mkdocs build --strict
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*.*.*"
|
|
7
|
+
- "v*.*.*-rc*"
|
|
8
|
+
- "v*.*.*-alpha*"
|
|
9
|
+
- "v*.*.*-beta*"
|
|
10
|
+
|
|
11
|
+
permissions:
|
|
12
|
+
contents: write
|
|
13
|
+
id-token: write # for PyPI trusted publishing, if configured
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
build:
|
|
17
|
+
name: Build distribution
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
with:
|
|
22
|
+
fetch-depth: 0
|
|
23
|
+
|
|
24
|
+
- name: Set up Python
|
|
25
|
+
uses: actions/setup-python@v5
|
|
26
|
+
with:
|
|
27
|
+
python-version: "3.12"
|
|
28
|
+
|
|
29
|
+
- name: Install build tooling
|
|
30
|
+
run: python -m pip install --upgrade pip build
|
|
31
|
+
|
|
32
|
+
- name: Build sdist and wheel
|
|
33
|
+
run: python -m build
|
|
34
|
+
|
|
35
|
+
- name: Upload build artifacts
|
|
36
|
+
uses: actions/upload-artifact@v4
|
|
37
|
+
with:
|
|
38
|
+
name: dist
|
|
39
|
+
path: dist/
|
|
40
|
+
|
|
41
|
+
test:
|
|
42
|
+
name: Run test suite
|
|
43
|
+
runs-on: ubuntu-latest
|
|
44
|
+
steps:
|
|
45
|
+
- uses: actions/checkout@v4
|
|
46
|
+
|
|
47
|
+
- name: Set up Python
|
|
48
|
+
uses: actions/setup-python@v5
|
|
49
|
+
with:
|
|
50
|
+
python-version: "3.12"
|
|
51
|
+
|
|
52
|
+
- name: Install package with dev/test extras
|
|
53
|
+
run: |
|
|
54
|
+
python -m pip install --upgrade pip
|
|
55
|
+
if python -c "import tomllib" 2>/dev/null; then :; fi
|
|
56
|
+
pip install -e ".[dev]" 2>/dev/null || pip install -e ".[test]" 2>/dev/null || pip install -e "."
|
|
57
|
+
pip install pytest pytest-cov
|
|
58
|
+
|
|
59
|
+
- name: Run tests
|
|
60
|
+
run: pytest -q || pytest -q --no-header
|
|
61
|
+
|
|
62
|
+
publish-canary:
|
|
63
|
+
name: Publish canary (TestPyPI + pre-release)
|
|
64
|
+
needs: [build, test]
|
|
65
|
+
if: contains(github.ref_name, '-rc') || contains(github.ref_name, '-alpha') || contains(github.ref_name, '-beta')
|
|
66
|
+
runs-on: ubuntu-latest
|
|
67
|
+
environment: testpypi
|
|
68
|
+
steps:
|
|
69
|
+
- uses: actions/download-artifact@v4
|
|
70
|
+
with:
|
|
71
|
+
name: dist
|
|
72
|
+
path: dist/
|
|
73
|
+
|
|
74
|
+
- name: Publish to TestPyPI
|
|
75
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
76
|
+
with:
|
|
77
|
+
repository-url: https://test.pypi.org/legacy/
|
|
78
|
+
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
|
|
79
|
+
skip-existing: true
|
|
80
|
+
|
|
81
|
+
- name: Create GitHub pre-release
|
|
82
|
+
uses: softprops/action-gh-release@v2
|
|
83
|
+
with:
|
|
84
|
+
files: dist/*
|
|
85
|
+
prerelease: true
|
|
86
|
+
generate_release_notes: true
|
|
87
|
+
|
|
88
|
+
publish-production:
|
|
89
|
+
name: Publish production (PyPI + release + Zenodo archive)
|
|
90
|
+
needs: [build, test]
|
|
91
|
+
if: ${{ !contains(github.ref_name, '-rc') && !contains(github.ref_name, '-alpha') && !contains(github.ref_name, '-beta') }}
|
|
92
|
+
runs-on: ubuntu-latest
|
|
93
|
+
environment: pypi
|
|
94
|
+
steps:
|
|
95
|
+
- uses: actions/download-artifact@v4
|
|
96
|
+
with:
|
|
97
|
+
name: dist
|
|
98
|
+
path: dist/
|
|
99
|
+
|
|
100
|
+
- name: Publish to PyPI
|
|
101
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
102
|
+
with:
|
|
103
|
+
password: ${{ secrets.PYPI_API_TOKEN }}
|
|
104
|
+
skip-existing: true
|
|
105
|
+
|
|
106
|
+
- name: Create GitHub Release
|
|
107
|
+
uses: softprops/action-gh-release@v2
|
|
108
|
+
with:
|
|
109
|
+
files: dist/*
|
|
110
|
+
prerelease: false
|
|
111
|
+
generate_release_notes: true
|
|
112
|
+
|
|
113
|
+
# NOTE: Zenodo archival of this GitHub Release happens automatically
|
|
114
|
+
# IF this repo has Zenodo-GitHub integration enabled at
|
|
115
|
+
# https://zenodo.org/account/settings/github/ (a per-repo, per-owner
|
|
116
|
+
# OAuth toggle on zenodo.org — cannot be set from a workflow file).
|
|
117
|
+
# Once enabled, every GitHub Release like this one mints/updates a
|
|
118
|
+
# Zenodo DOI automatically using the .zenodo.json metadata in this repo.
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
3
|
+
rev: v0.6.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: ruff
|
|
6
|
+
args: [--fix]
|
|
7
|
+
- id: ruff-format
|
|
8
|
+
|
|
9
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
10
|
+
rev: v4.6.0
|
|
11
|
+
hooks:
|
|
12
|
+
- id: trailing-whitespace
|
|
13
|
+
- id: end-of-file-fixer
|
|
14
|
+
- id: check-yaml
|
|
15
|
+
- id: check-toml
|
|
16
|
+
- id: check-merge-conflict
|
|
17
|
+
- id: debug-statements
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "sa-sv-duality — P36: S_A / S_V Entropy Duality - GenesisAeon Package 36 - Standalone Foundational Module",
|
|
3
|
+
"description": "<p>S_A / S_V Entropy Duality - GenesisAeon Package 36 - Standalone Foundational Module</p><p>Part of the <strong>GenesisAeon</strong> ecosystem (P36, domain: mathematical physics / entropy duality (foundational)).</p><p>See <a href=\"https://github.com/GenesisAeon/sa-sv-duality\">github.com/GenesisAeon/sa-sv-duality</a> for source, documentation, and reproducibility notebooks.</p>",
|
|
4
|
+
"creators": [
|
|
5
|
+
{
|
|
6
|
+
"name": "Römer, Johann",
|
|
7
|
+
"affiliation": "Independent Researcher / MOR Research Collective"
|
|
8
|
+
}
|
|
9
|
+
],
|
|
10
|
+
"license": "MIT",
|
|
11
|
+
"upload_type": "software",
|
|
12
|
+
"access_right": "open",
|
|
13
|
+
"keywords": [
|
|
14
|
+
"GenesisAeon",
|
|
15
|
+
"P36",
|
|
16
|
+
"mathematical physics / entropy duality (foundational)",
|
|
17
|
+
"UTAC",
|
|
18
|
+
"CREP",
|
|
19
|
+
"open science"
|
|
20
|
+
],
|
|
21
|
+
"related_identifiers": [
|
|
22
|
+
{
|
|
23
|
+
"identifier": "10.5281/zenodo.19645351",
|
|
24
|
+
"relation": "isPartOf",
|
|
25
|
+
"resource_type": "publication-article",
|
|
26
|
+
"scheme": "doi"
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
"version": "1.0.0",
|
|
30
|
+
"communities": [
|
|
31
|
+
{ "identifier": "genesisaeon" }
|
|
32
|
+
]
|
|
33
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
## [1.0.0] - 2026
|
|
11
|
+
### Added
|
|
12
|
+
- Initial v1.0.0 release as part of the GenesisAeon ecosystem-wide 1.0.0
|
|
13
|
+
milestone.
|
|
14
|
+
- Standardized release tooling: `.zenodo.json`, GitHub Actions release
|
|
15
|
+
workflow (`.github/workflows/release.yml`), `RELEASE_GUIDE.md`,
|
|
16
|
+
`CONTRIBUTING.md`, issue/PR templates.
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
- Project metadata (`pyproject.toml`) normalized: version bumped from
|
|
20
|
+
0.1.0 to 1.0.0.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
Thanks for your interest in contributing to this GenesisAeon ecosystem
|
|
4
|
+
package!
|
|
5
|
+
|
|
6
|
+
## Getting started
|
|
7
|
+
|
|
8
|
+
1. Fork and clone the repository.
|
|
9
|
+
2. Create a virtual environment: `python -m venv .venv && source .venv/bin/activate`
|
|
10
|
+
(or `.venv\Scripts\activate` on Windows).
|
|
11
|
+
3. Install in editable mode with dev dependencies:
|
|
12
|
+
`pip install -e ".[dev]"` (or `.[test]` if `dev` extras don't exist).
|
|
13
|
+
4. Run the test suite: `pytest`.
|
|
14
|
+
|
|
15
|
+
## Code style
|
|
16
|
+
|
|
17
|
+
- Format with `ruff format` and lint with `ruff check`.
|
|
18
|
+
- Type-check with `mypy` where the package uses type hints.
|
|
19
|
+
- Keep functions documented with docstrings (Google or NumPy style,
|
|
20
|
+
whichever this repo already uses).
|
|
21
|
+
|
|
22
|
+
## Diamond Interface packages
|
|
23
|
+
|
|
24
|
+
If this package implements the GenesisAeon Diamond Interface
|
|
25
|
+
(`run_cycle`, `get_crep_state`, `get_utac_state`, `get_phase_events`,
|
|
26
|
+
`to_zenodo_record`), any change to these methods' signatures or return
|
|
27
|
+
shapes is a **breaking change** and requires a MAJOR version bump (see
|
|
28
|
+
`RELEASE_GUIDE.md`).
|
|
29
|
+
|
|
30
|
+
## Pull requests
|
|
31
|
+
|
|
32
|
+
- One logical change per PR.
|
|
33
|
+
- Add or update tests for any behavioral change.
|
|
34
|
+
- Update `CHANGELOG.md` under an `## [Unreleased]` section.
|
|
35
|
+
- Fill out the PR template (`.github/PULL_REQUEST_TEMPLATE.md`).
|
|
36
|
+
|
|
37
|
+
## Reporting issues
|
|
38
|
+
|
|
39
|
+
Please use the issue templates in `.github/ISSUE_TEMPLATE/` — they help us
|
|
40
|
+
triage bug reports vs. feature requests quickly.
|
|
41
|
+
|
|
42
|
+
## Scientific claims
|
|
43
|
+
|
|
44
|
+
This is part of a research framework. If your contribution touches any
|
|
45
|
+
scientific model, prediction, or benchmark (e.g. CREP `Γ` values, UTAC
|
|
46
|
+
parameters, falsifiable predictions), please:
|
|
47
|
+
- Cite the source (paper, dataset, or prior GenesisAeon Zenodo record).
|
|
48
|
+
- Clearly mark speculative vs. validated claims, consistent with this
|
|
49
|
+
repo's existing `DISCLAIMER.md` (if present).
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 JohannRömer
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: sa-sv-duality
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: S_A / S_V Entropy Duality - GenesisAeon Package 36 - Standalone Foundational Module
|
|
5
|
+
Project-URL: Homepage, https://github.com/GenesisAeon/sa-sv-duality
|
|
6
|
+
Project-URL: Repository, https://github.com/GenesisAeon/sa-sv-duality
|
|
7
|
+
Project-URL: Zenodo, https://doi.org/10.5281/zenodo.17472834
|
|
8
|
+
Author: Johann Roemer - MOR Research Collective
|
|
9
|
+
License: MIT
|
|
10
|
+
License-File: LICENSE
|
|
11
|
+
Keywords: CREP,GenesisAeon,UTAC,duality,entropy,mathematical-physics
|
|
12
|
+
Classifier: Development Status :: 3 - Alpha
|
|
13
|
+
Classifier: Intended Audience :: Science/Research
|
|
14
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
15
|
+
Classifier: Programming Language :: Python :: 3
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
18
|
+
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
19
|
+
Requires-Python: >=3.11
|
|
20
|
+
Requires-Dist: numpy>=1.26.0
|
|
21
|
+
Requires-Dist: pyyaml>=6.0
|
|
22
|
+
Requires-Dist: rich>=13.7.0
|
|
23
|
+
Requires-Dist: scipy>=1.12.0
|
|
24
|
+
Requires-Dist: typer>=0.12.0
|
|
25
|
+
Provides-Extra: dev
|
|
26
|
+
Requires-Dist: mypy>=1.10.0; extra == 'dev'
|
|
27
|
+
Requires-Dist: pre-commit>=3.7.0; extra == 'dev'
|
|
28
|
+
Requires-Dist: pytest-cov>=5.0.0; extra == 'dev'
|
|
29
|
+
Requires-Dist: pytest>=8.0.0; extra == 'dev'
|
|
30
|
+
Requires-Dist: ruff>=0.6.0; extra == 'dev'
|
|
31
|
+
Provides-Extra: docs
|
|
32
|
+
Requires-Dist: mkdocs-material>=9.5.0; extra == 'docs'
|
|
33
|
+
Requires-Dist: mkdocs>=1.6.0; extra == 'docs'
|
|
34
|
+
Description-Content-Type: text/markdown
|
|
35
|
+
|
|
36
|
+
# sa-sv-duality
|
|
37
|
+
|
|
38
|
+
**S_A / S_V Entropy Duality** -- GenesisAeon Package 36
|
|
39
|
+
|
|
40
|
+
[](https://github.com/GenesisAeon/sa-sv-duality/actions/workflows/ci.yml)
|
|
41
|
+
[](https://www.python.org)
|
|
42
|
+
[](LICENSE)
|
|
43
|
+
[](https://doi.org/10.5281/zenodo.17472834)
|
|
44
|
+
|
|
45
|
+
Standalone foundational module implementing the duality between **Action Entropy** (S_A)
|
|
46
|
+
and **Volume Entropy** (S_V) -- the mathematical core underlying diffusive routing (P30),
|
|
47
|
+
the unified GenesisAeon Lagrangian, and the AFET field equations.
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
## The Duality
|
|
52
|
+
|
|
53
|
+
```
|
|
54
|
+
S_A = integral of sigma_s(H,Gamma) dt (entropy produced along a path)
|
|
55
|
+
S_V = -integral p(H) ln p(H) dH (Shannon entropy of state distribution)
|
|
56
|
+
|
|
57
|
+
S_A * S_V = const (along the optimal UTAC trajectory)
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
**Lagrangian interpretation:**
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
L = T - V + Phi(H) + Gamma(C,R,E,P)
|
|
64
|
+
^^^^^^^^^^ ^^^^^^^^^^^^^
|
|
65
|
+
S_A coupling S_V coupling
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
The variational principle `delta(S_A - lambda * S_V) = 0` reproduces the UTAC ODE --
|
|
69
|
+
this is the deepest formulation of the GenesisAeon dynamics.
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## Installation
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
pip install sa-sv-duality
|
|
77
|
+
# or
|
|
78
|
+
uv tool install sa-sv-duality
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
## Usage
|
|
82
|
+
|
|
83
|
+
### CLI
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
# Run a full S_A/S_V cycle (Gamma = 0.251, sigma = 2.2)
|
|
87
|
+
sav run
|
|
88
|
+
|
|
89
|
+
# Custom parameters
|
|
90
|
+
sav run --gamma 0.46 --sigma 2.2 --duration 20
|
|
91
|
+
|
|
92
|
+
# Show S_A, S_V for all 16 Q4 states
|
|
93
|
+
sav q4-map
|
|
94
|
+
|
|
95
|
+
# Find the optimal entropy path through Q4 state space
|
|
96
|
+
sav route 0 15 --lambda 1.0
|
|
97
|
+
|
|
98
|
+
# Run benchmarks
|
|
99
|
+
sav benchmark
|
|
100
|
+
sav benchmark --fast
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Python API
|
|
104
|
+
|
|
105
|
+
```python
|
|
106
|
+
from sa_sv_duality import SAVDuality, ActionEntropy, VolumeEntropy, Q4SAVMap
|
|
107
|
+
|
|
108
|
+
# Full Diamond interface
|
|
109
|
+
system = SAVDuality(gamma=0.251, sigma=2.2)
|
|
110
|
+
result = system.run_cycle(duration_years=10.0)
|
|
111
|
+
print(result["S_A"], result["S_V"], result["duality_constant"])
|
|
112
|
+
|
|
113
|
+
# CREP state
|
|
114
|
+
print(system.get_crep_state()) # {"C": ..., "R": ..., "E": ..., "P": ..., "Gamma": 0.251}
|
|
115
|
+
|
|
116
|
+
# Q4 entropy map
|
|
117
|
+
q4 = system.q4_entropy_map() # {0: (S_A, S_V), ..., 15: (S_A, S_V)}
|
|
118
|
+
|
|
119
|
+
# Optimal path through Q4 space (= diffusive routing from P30)
|
|
120
|
+
path = system.optimal_path(start=0, end=15)
|
|
121
|
+
|
|
122
|
+
# Zenodo-compatible record
|
|
123
|
+
record = system.to_zenodo_record()
|
|
124
|
+
|
|
125
|
+
# Lower-level components
|
|
126
|
+
ae = ActionEntropy()
|
|
127
|
+
t, H = ae.generate_trajectory(H0=0.1, T=10.0)
|
|
128
|
+
S_A = ae.integrate(H.tolist(), times=t.tolist())
|
|
129
|
+
|
|
130
|
+
sv = VolumeEntropy()
|
|
131
|
+
S_V = sv.from_trajectory(H.tolist())
|
|
132
|
+
print(S_A * S_V) # duality constant
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
## Module Structure
|
|
136
|
+
|
|
137
|
+
```
|
|
138
|
+
src/sa_sv_duality/
|
|
139
|
+
__init__.py -- public API
|
|
140
|
+
constants.py -- Phi, sigma_UTAC, Gamma_universal, Q4 constants
|
|
141
|
+
action_entropy.py -- S_A = integral sigma_s(H,Gamma) dt
|
|
142
|
+
volume_entropy.py -- S_V = -integral p*ln(p) + Q4 discrete entropies
|
|
143
|
+
duality_relation.py -- S_A * S_V conservation + hyperbola geometry
|
|
144
|
+
lagrangian_bridge.py -- Phi(H) = S_A coupling, Gamma = S_V coupling
|
|
145
|
+
variational.py -- delta(S_A - lambda*S_V) = 0 solver
|
|
146
|
+
q4_sav_map.py -- (S_A, S_V) for all 16 Q4 states
|
|
147
|
+
network_routing.py -- SAV-optimal routing via modified Dijkstra
|
|
148
|
+
system.py -- Diamond interface (run_cycle, CREP/UTAC state)
|
|
149
|
+
cli.py -- `sav` CLI
|
|
150
|
+
benchmark.py -- Package 36 benchmark targets
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
## Q4 State Entropy Map
|
|
154
|
+
|
|
155
|
+
Each of the 16 Q4 states (4-bit encoding of C/R/E/P activation) carries
|
|
156
|
+
a characteristic (S_A, S_V) pair:
|
|
157
|
+
|
|
158
|
+
| State | Bits | S_V | Meaning |
|
|
159
|
+
|-------|------|--------|----------------------------|
|
|
160
|
+
| 0 | 0000 | 0.000 | No active channels |
|
|
161
|
+
| 1 | 0001 | 0.693 | C only (coherence) |
|
|
162
|
+
| 15 | 1111 | 1.609 | All channels active |
|
|
163
|
+
|
|
164
|
+
S_V ordering: monotone non-decreasing with number of active bits.
|
|
165
|
+
S_A ordering: depends on effective Gamma of each state.
|
|
166
|
+
|
|
167
|
+
## Benchmark Targets (from Feldtheorie Preprint)
|
|
168
|
+
|
|
169
|
+
| Target | Expected | Tolerance |
|
|
170
|
+
|---------------------------------|----------|-----------|
|
|
171
|
+
| duality_constant_stability | True | -- |
|
|
172
|
+
| routing_improvement_vs_dijkstra | 10% | +/-8% |
|
|
173
|
+
| q4_entropy_ordering | True | -- |
|
|
174
|
+
| lagrangian_consistency | True | -- |
|
|
175
|
+
| variational_minimum | True | -- |
|
|
176
|
+
|
|
177
|
+
## Connection to Other Packages
|
|
178
|
+
|
|
179
|
+
| Package | Connection |
|
|
180
|
+
|---------|-----------|
|
|
181
|
+
| P30 diffusive-routing | route = argmin S_A + argmax S_V |
|
|
182
|
+
| P31 vrig-cosmological | v_RIG = information-geometric speed in S_A/S_V space |
|
|
183
|
+
| P32 beta-clustering | beta_domain proportional to S_A/S_V ratio |
|
|
184
|
+
| P34 afet-tensions | H0_eff(beta) driven by S_A / S_V hierarchy |
|
|
185
|
+
| P37 eml-utac-bridge | EML operator encodes L = T-V + S_A + S_V |
|
|
186
|
+
| P38 phi-validator | Phi^(1/3) scaling in S_A/S_V Q4 entropy ratios |
|
|
187
|
+
|
|
188
|
+
## Development
|
|
189
|
+
|
|
190
|
+
```bash
|
|
191
|
+
git clone https://github.com/GenesisAeon/sa-sv-duality.git
|
|
192
|
+
cd sa-sv-duality
|
|
193
|
+
uv sync --dev
|
|
194
|
+
uv run pytest
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## Citation
|
|
198
|
+
|
|
199
|
+
[](https://doi.org/10.5281/zenodo.PLACEHOLDER)
|
|
200
|
+
|
|
201
|
+
DOI will be assigned automatically on first GitHub Release once
|
|
202
|
+
Zenodo–GitHub integration is enabled for this repo.
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
**Reference:** Johann Roemer * MOR Research Collective * Mai 2026
|
|
207
|
+
DOI: [10.5281/zenodo.17472834](https://doi.org/10.5281/zenodo.17472834)
|
|
208
|
+
UTAC v1.0: [10.5281/zenodo.17472834](https://doi.org/10.5281/zenodo.17472834)
|