cognitive-discovery-platform 0.8.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.
Files changed (122) hide show
  1. cognitive_discovery_platform-0.8.0/.github/CODEOWNERS +4 -0
  2. cognitive_discovery_platform-0.8.0/.github/FUNDING.yml +3 -0
  3. cognitive_discovery_platform-0.8.0/.github/ISSUE_TEMPLATE/bug_report.md +42 -0
  4. cognitive_discovery_platform-0.8.0/.github/ISSUE_TEMPLATE/config.yml +8 -0
  5. cognitive_discovery_platform-0.8.0/.github/ISSUE_TEMPLATE/feature_request.md +28 -0
  6. cognitive_discovery_platform-0.8.0/.github/PULL_REQUEST_TEMPLATE.md +8 -0
  7. cognitive_discovery_platform-0.8.0/.github/dependabot.yml +18 -0
  8. cognitive_discovery_platform-0.8.0/.github/labeler.yml +34 -0
  9. cognitive_discovery_platform-0.8.0/.github/workflows/dependabot-auto-merge.yml +16 -0
  10. cognitive_discovery_platform-0.8.0/.github/workflows/pr-automation.yml +80 -0
  11. cognitive_discovery_platform-0.8.0/.github/workflows/pypi-publish.yml +34 -0
  12. cognitive_discovery_platform-0.8.0/.github/workflows/tests.yml +46 -0
  13. cognitive_discovery_platform-0.8.0/.gitignore +165 -0
  14. cognitive_discovery_platform-0.8.0/CHANGELOG.md +173 -0
  15. cognitive_discovery_platform-0.8.0/CITATION.cff +29 -0
  16. cognitive_discovery_platform-0.8.0/CODE_OF_CONDUCT.md +25 -0
  17. cognitive_discovery_platform-0.8.0/CONTRIBUTING.md +114 -0
  18. cognitive_discovery_platform-0.8.0/LICENSE +21 -0
  19. cognitive_discovery_platform-0.8.0/PKG-INFO +488 -0
  20. cognitive_discovery_platform-0.8.0/README.md +440 -0
  21. cognitive_discovery_platform-0.8.0/ROADMAP.md +43 -0
  22. cognitive_discovery_platform-0.8.0/SECURITY.md +16 -0
  23. cognitive_discovery_platform-0.8.0/assets/logo.svg +38 -0
  24. cognitive_discovery_platform-0.8.0/benchmarks/run_benchmarks.py +252 -0
  25. cognitive_discovery_platform-0.8.0/dashboard/app.py +184 -0
  26. cognitive_discovery_platform-0.8.0/docs/CASE_STUDY_HUBBLE.md +80 -0
  27. cognitive_discovery_platform-0.8.0/docs/CASE_STUDY_QUANTUM_ML.md +78 -0
  28. cognitive_discovery_platform-0.8.0/docs/api-reference.md +227 -0
  29. cognitive_discovery_platform-0.8.0/docs/api.md +45 -0
  30. cognitive_discovery_platform-0.8.0/docs/benchmarks.md +60 -0
  31. cognitive_discovery_platform-0.8.0/docs/getting-started.md +139 -0
  32. cognitive_discovery_platform-0.8.0/docs/index.md +44 -0
  33. cognitive_discovery_platform-0.8.0/docs/maintenance.md +54 -0
  34. cognitive_discovery_platform-0.8.0/docs/research-workflows.md +78 -0
  35. cognitive_discovery_platform-0.8.0/docs/tutorials/hypothesis_demo.md +44 -0
  36. cognitive_discovery_platform-0.8.0/docs/tutorials/quantum_demo.md +31 -0
  37. cognitive_discovery_platform-0.8.0/docs/tutorials/quick_start.md +43 -0
  38. cognitive_discovery_platform-0.8.0/examples/fft2_demo.py +29 -0
  39. cognitive_discovery_platform-0.8.0/examples/hypothesis_custom_generator.py +120 -0
  40. cognitive_discovery_platform-0.8.0/examples/hypothesis_demo.py +37 -0
  41. cognitive_discovery_platform-0.8.0/examples/hypothesis_tests_demo.py +48 -0
  42. cognitive_discovery_platform-0.8.0/examples/hypothesis_with_stats_demo.py +34 -0
  43. cognitive_discovery_platform-0.8.0/examples/linalg_demo.py +53 -0
  44. cognitive_discovery_platform-0.8.0/examples/ml_and_viz_demo.py +52 -0
  45. cognitive_discovery_platform-0.8.0/examples/optimization_demo.py +26 -0
  46. cognitive_discovery_platform-0.8.0/examples/quantum_demo.py +34 -0
  47. cognitive_discovery_platform-0.8.0/examples/signals_demo.py +37 -0
  48. cognitive_discovery_platform-0.8.0/examples/stats_demo.py +32 -0
  49. cognitive_discovery_platform-0.8.0/mkdocs.yml +72 -0
  50. cognitive_discovery_platform-0.8.0/pyproject.toml +90 -0
  51. cognitive_discovery_platform-0.8.0/src/cds/__init__.py +87 -0
  52. cognitive_discovery_platform-0.8.0/src/cds/__main__.py +6 -0
  53. cognitive_discovery_platform-0.8.0/src/cds/cli.py +337 -0
  54. cognitive_discovery_platform-0.8.0/src/cds/core/__init__.py +4 -0
  55. cognitive_discovery_platform-0.8.0/src/cds/core/models.py +69 -0
  56. cognitive_discovery_platform-0.8.0/src/cds/data_analysis/__init__.py +16 -0
  57. cognitive_discovery_platform-0.8.0/src/cds/data_analysis/dataset.py +106 -0
  58. cognitive_discovery_platform-0.8.0/src/cds/data_analysis/loader.py +60 -0
  59. cognitive_discovery_platform-0.8.0/src/cds/data_analysis/transform.py +33 -0
  60. cognitive_discovery_platform-0.8.0/src/cds/data_analysis/viz.py +85 -0
  61. cognitive_discovery_platform-0.8.0/src/cds/diffeq/__init__.py +18 -0
  62. cognitive_discovery_platform-0.8.0/src/cds/diffeq/solvers.py +278 -0
  63. cognitive_discovery_platform-0.8.0/src/cds/graph/__init__.py +20 -0
  64. cognitive_discovery_platform-0.8.0/src/cds/graph/algorithms.py +240 -0
  65. cognitive_discovery_platform-0.8.0/src/cds/hypothesis/__init__.py +41 -0
  66. cognitive_discovery_platform-0.8.0/src/cds/hypothesis/evaluator.py +179 -0
  67. cognitive_discovery_platform-0.8.0/src/cds/hypothesis/generator.py +180 -0
  68. cognitive_discovery_platform-0.8.0/src/cds/math_utils/__init__.py +24 -0
  69. cognitive_discovery_platform-0.8.0/src/cds/math_utils/calculus.py +36 -0
  70. cognitive_discovery_platform-0.8.0/src/cds/math_utils/linalg.py +377 -0
  71. cognitive_discovery_platform-0.8.0/src/cds/ml/__init__.py +4 -0
  72. cognitive_discovery_platform-0.8.0/src/cds/ml/neural.py +193 -0
  73. cognitive_discovery_platform-0.8.0/src/cds/montecarlo/__init__.py +16 -0
  74. cognitive_discovery_platform-0.8.0/src/cds/montecarlo/methods.py +202 -0
  75. cognitive_discovery_platform-0.8.0/src/cds/numerical_integration/__init__.py +24 -0
  76. cognitive_discovery_platform-0.8.0/src/cds/numerical_integration/quadrature.py +348 -0
  77. cognitive_discovery_platform-0.8.0/src/cds/optimization/__init__.py +11 -0
  78. cognitive_discovery_platform-0.8.0/src/cds/optimization/minimize.py +248 -0
  79. cognitive_discovery_platform-0.8.0/src/cds/probability/__init__.py +14 -0
  80. cognitive_discovery_platform-0.8.0/src/cds/probability/distributions.py +115 -0
  81. cognitive_discovery_platform-0.8.0/src/cds/quantum/__init__.py +50 -0
  82. cognitive_discovery_platform-0.8.0/src/cds/quantum/circuit.py +73 -0
  83. cognitive_discovery_platform-0.8.0/src/cds/quantum/multi_qubit.py +235 -0
  84. cognitive_discovery_platform-0.8.0/src/cds/quantum/simulator.py +37 -0
  85. cognitive_discovery_platform-0.8.0/src/cds/scientific/__init__.py +18 -0
  86. cognitive_discovery_platform-0.8.0/src/cds/scientific/constants.py +26 -0
  87. cognitive_discovery_platform-0.8.0/src/cds/scientific/formulas.py +63 -0
  88. cognitive_discovery_platform-0.8.0/src/cds/signals/__init__.py +16 -0
  89. cognitive_discovery_platform-0.8.0/src/cds/signals/processing.py +221 -0
  90. cognitive_discovery_platform-0.8.0/src/cds/stats/__init__.py +22 -0
  91. cognitive_discovery_platform-0.8.0/src/cds/stats/descriptive.py +97 -0
  92. cognitive_discovery_platform-0.8.0/src/cds/stats/hypothesis_tests.py +392 -0
  93. cognitive_discovery_platform-0.8.0/src/cds/stats/regression.py +38 -0
  94. cognitive_discovery_platform-0.8.0/tests/__init__.py +0 -0
  95. cognitive_discovery_platform-0.8.0/tests/test_benchmarks.py +61 -0
  96. cognitive_discovery_platform-0.8.0/tests/test_cli.py +39 -0
  97. cognitive_discovery_platform-0.8.0/tests/test_cli_extended.py +97 -0
  98. cognitive_discovery_platform-0.8.0/tests/test_coverage_boost.py +403 -0
  99. cognitive_discovery_platform-0.8.0/tests/test_coverage_complete.py +239 -0
  100. cognitive_discovery_platform-0.8.0/tests/test_coverage_final.py +595 -0
  101. cognitive_discovery_platform-0.8.0/tests/test_coverage_gaps.py +329 -0
  102. cognitive_discovery_platform-0.8.0/tests/test_data_analysis.py +140 -0
  103. cognitive_discovery_platform-0.8.0/tests/test_dataset.py +82 -0
  104. cognitive_discovery_platform-0.8.0/tests/test_diffeq.py +103 -0
  105. cognitive_discovery_platform-0.8.0/tests/test_fft2.py +69 -0
  106. cognitive_discovery_platform-0.8.0/tests/test_graph.py +153 -0
  107. cognitive_discovery_platform-0.8.0/tests/test_hypothesis.py +93 -0
  108. cognitive_discovery_platform-0.8.0/tests/test_hypothesis_engine.py +62 -0
  109. cognitive_discovery_platform-0.8.0/tests/test_hypothesis_tests.py +139 -0
  110. cognitive_discovery_platform-0.8.0/tests/test_linalg_extended.py +142 -0
  111. cognitive_discovery_platform-0.8.0/tests/test_linalg_qr_cholesky.py +70 -0
  112. cognitive_discovery_platform-0.8.0/tests/test_math_utils.py +128 -0
  113. cognitive_discovery_platform-0.8.0/tests/test_ml_viz.py +55 -0
  114. cognitive_discovery_platform-0.8.0/tests/test_montecarlo.py +100 -0
  115. cognitive_discovery_platform-0.8.0/tests/test_multi_qubit.py +311 -0
  116. cognitive_discovery_platform-0.8.0/tests/test_numerical_integration.py +233 -0
  117. cognitive_discovery_platform-0.8.0/tests/test_optimization.py +117 -0
  118. cognitive_discovery_platform-0.8.0/tests/test_probability.py +162 -0
  119. cognitive_discovery_platform-0.8.0/tests/test_quantum.py +121 -0
  120. cognitive_discovery_platform-0.8.0/tests/test_scientific.py +131 -0
  121. cognitive_discovery_platform-0.8.0/tests/test_signals.py +143 -0
  122. cognitive_discovery_platform-0.8.0/tests/test_stats.py +127 -0
@@ -0,0 +1,4 @@
1
+ # CODEOWNERS file
2
+ # See https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners
3
+
4
+ * @Furox88
@@ -0,0 +1,3 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: [Furox88]
@@ -0,0 +1,42 @@
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
+ ## Describe the bug
10
+ A clear and concise description of what the bug is.
11
+
12
+ ## To reproduce
13
+ Steps to reproduce the behavior:
14
+ 1. Run `...`
15
+ 2. Call `...`
16
+ 3. See error
17
+
18
+ ```python
19
+ # Minimal reproducible example
20
+ import cds
21
+ ...
22
+ ```
23
+
24
+ ## Expected behavior
25
+ What you expected to happen.
26
+
27
+ ## Actual behavior / traceback
28
+ ```
29
+ Paste the full error or unexpected output here.
30
+ ```
31
+
32
+ ## Environment
33
+ - CDS version: `cds --version` →
34
+ - Python version:
35
+ - OS:
36
+ - How installed: `pip install cognitive-discovery-platform` / from source / other
37
+
38
+ ## Module / function affected
39
+ e.g. `cds.quantum`, `cds.numerical_integration.simpson`, `cds.cli`
40
+
41
+ ## Additional context
42
+ Anything else relevant.
@@ -0,0 +1,8 @@
1
+ blank_issues_enabled: false
2
+ contact_links:
3
+ - name: 💬 Ask a question / discussion
4
+ url: https://github.com/Furox88/cognitive-discovery-system/discussions
5
+ about: For usage questions, ideas, and general discussion — please use Discussions instead of opening an issue.
6
+ - name: 📖 Documentation
7
+ url: https://furox88.github.io/cognitive-discovery-system/
8
+ about: Read the docs, tutorials, and API reference before filing a bug.
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: Feature request
3
+ about: Suggest a new module, function, or improvement
4
+ title: "[FEATURE] "
5
+ labels: enhancement
6
+ assignees: ''
7
+ ---
8
+
9
+ ## Problem
10
+ What problem does this feature solve? What are you trying to do that CDS doesn't let you do today?
11
+
12
+ ## Proposed solution
13
+ Describe the feature/module you'd like. A short API sketch helps a lot:
14
+
15
+ ```python
16
+ import cds
17
+ # Ideal usage:
18
+ result = cds.<module>.<function>(...)
19
+ ```
20
+
21
+ ## Which module(s)?
22
+ e.g. `cds.quantum`, `cds.numerical_integration`, a brand-new module, CLI, docs...
23
+
24
+ ## Alternatives considered
25
+ Have you tried any workarounds? Are there other libraries that do this?
26
+
27
+ ## Additional context
28
+ Links to papers, references, or related issues.
@@ -0,0 +1,8 @@
1
+ ## What does this PR do?
2
+
3
+ ## How was it tested?
4
+
5
+ ## Checklist
6
+ - [ ] Tests pass (`pytest`)
7
+ - [ ] Linting passes (`ruff check`)
8
+ - [ ] CHANGELOG updated (if applicable)
@@ -0,0 +1,18 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "github-actions"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "weekly"
7
+ labels:
8
+ - "dependencies"
9
+ - "github-actions"
10
+ commit-message-prefix: "ci"
11
+ - package-ecosystem: "pip"
12
+ directory: "/"
13
+ schedule:
14
+ interval: "weekly"
15
+ labels:
16
+ - "dependencies"
17
+ - "python"
18
+ commit-message-prefix: "deps"
@@ -0,0 +1,34 @@
1
+ # Labeler config for auto-labeling PRs based on paths
2
+ # See https://github.com/actions/labeler
3
+
4
+ ci:
5
+ - .github/workflows/**
6
+
7
+ docs:
8
+ - docs/**
9
+ - README.md
10
+ - CONTRIBUTING.md
11
+ - CHANGELOG.md
12
+ - examples/**
13
+
14
+ cli:
15
+ - src/cds/cli.py
16
+ - tests/test_cli.py
17
+
18
+ hypothesis:
19
+ - src/cds/hypothesis/**
20
+ - examples/hypothesis*.py
21
+ - tests/test_hypothesis*.py
22
+
23
+ core:
24
+ - src/cds/core/**
25
+ - src/cds/__init__.py
26
+
27
+ tests:
28
+ - tests/**
29
+ - pytest.ini
30
+ - pyproject.toml
31
+
32
+ dependencies:
33
+ - pyproject.toml
34
+ - setup_repo.sh
@@ -0,0 +1,16 @@
1
+ name: Dependabot Auto Merge
2
+
3
+ on:
4
+ pull_request:
5
+ types: [opened, synchronize, reopened]
6
+
7
+ jobs:
8
+ auto-merge:
9
+ runs-on: ubuntu-latest
10
+ if: ${{ github.actor == 'dependabot[bot]' }}
11
+ steps:
12
+ - name: Enable auto-merge for Dependabot PRs
13
+ run: gh pr merge --auto --squash "$PR_URL"
14
+ env:
15
+ PR_URL: ${{github.event.pull_request.html_url}}
16
+ GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
@@ -0,0 +1,80 @@
1
+ name: PR Automation
2
+
3
+ on:
4
+ pull_request:
5
+ types: [opened, synchronize, reopened, labeled]
6
+ workflow_dispatch:
7
+ inputs:
8
+ pr_number:
9
+ description: 'PR number to run automation for'
10
+ required: true
11
+ type: string
12
+
13
+ jobs:
14
+ labeler:
15
+ if: github.event_name == 'pull_request'
16
+ runs-on: ubuntu-latest
17
+ permissions:
18
+ contents: read
19
+ pull-requests: write
20
+ steps:
21
+ - uses: actions/labeler@v5
22
+ with:
23
+ repo-token: "${{ secrets.GITHUB_TOKEN }}"
24
+
25
+ review-checklist:
26
+ runs-on: ubuntu-latest
27
+ # Runs on label 'needs-review' or manual dispatch
28
+ if: |
29
+ (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'needs-review')) ||
30
+ github.event_name == 'workflow_dispatch'
31
+ steps:
32
+ - uses: actions/github-script@v7
33
+ with:
34
+ script: |
35
+ const { owner, repo } = context.repo;
36
+ let prNumber = context.issue ? context.issue.number : null;
37
+
38
+ if (context.eventName === 'workflow_dispatch') {
39
+ prNumber = parseInt('${{ inputs.pr_number }}');
40
+ }
41
+
42
+ if (!prNumber) {
43
+ console.log('No PR number provided');
44
+ return;
45
+ }
46
+
47
+ // Avoid duplicate comments
48
+ const { data: comments } = await github.rest.issues.listComments({
49
+ owner, repo, issue_number: prNumber
50
+ });
51
+
52
+ const hasChecklist = comments.some(c =>
53
+ c.body.includes('PR Review Checklist') && c.user.type === 'Bot'
54
+ );
55
+
56
+ if (hasChecklist) {
57
+ console.log('Review checklist comment already exists');
58
+ return;
59
+ }
60
+
61
+ const checklist = `## PR Review Checklist
62
+
63
+ Maintainer quick checklist for this PR:
64
+
65
+ - [ ] Tests added or updated where needed
66
+ - [ ] Documentation updated (README, docstrings, examples)
67
+ - [ ] No unnecessary dependencies added
68
+ - [ ] Code follows project style (run ruff locally)
69
+ - [ ] CHANGELOG updated if user-facing
70
+
71
+ Feel free to ping the maintainer for review.`;
72
+
73
+ await github.rest.issues.createComment({
74
+ owner,
75
+ repo,
76
+ issue_number: prNumber,
77
+ body: checklist
78
+ });
79
+
80
+ console.log(`Posted review checklist for PR #${prNumber}`);
@@ -0,0 +1,34 @@
1
+ name: PyPI Publish
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - 'v*'
7
+
8
+ permissions:
9
+ contents: read
10
+
11
+ jobs:
12
+ build-n-publish:
13
+ name: Build and publish Python 🐍 distributions 📦 to PyPI
14
+ runs-on: ubuntu-latest
15
+ environment: pypi
16
+ permissions:
17
+ contents: read
18
+ id-token: write
19
+
20
+ steps:
21
+ - uses: actions/checkout@v4
22
+ - name: Set up Python
23
+ uses: actions/setup-python@v5
24
+ with:
25
+ python-version: "3.10"
26
+
27
+ - name: Install pypa/build
28
+ run: python -m pip install build
29
+
30
+ - name: Build a binary wheel and a source tarball
31
+ run: python -m build
32
+
33
+ - name: Publish package distributions to PyPI
34
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,46 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [ main ]
6
+ pull_request:
7
+ branches: [ main ]
8
+
9
+ jobs:
10
+ test:
11
+ runs-on: ubuntu-latest
12
+ strategy:
13
+ matrix:
14
+ python-version: ["3.10", "3.11", "3.12"]
15
+
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+ - name: Set up Python ${{ matrix.python-version }}
19
+ uses: actions/setup-python@v5
20
+ with:
21
+ python-version: ${{ matrix.python-version }}
22
+
23
+ - name: Install dependencies
24
+ run: |
25
+ python -m pip install --upgrade pip
26
+ pip install ".[test,dev,docs]"
27
+
28
+ - name: Lint with Ruff
29
+ run: ruff check .
30
+
31
+ - name: Type check with Mypy
32
+ run: mypy src/
33
+
34
+ - name: Run tests with pytest
35
+ run: pytest tests/ --cov=cds --cov-report=xml
36
+
37
+ - name: Upload coverage to Codecov
38
+ if: matrix.python-version == '3.12'
39
+ uses: codecov/codecov-action@v4
40
+ with:
41
+ files: ./coverage.xml
42
+ fail_ci_if_error: false
43
+ token: ${{ secrets.CODECOV_TOKEN }}
44
+
45
+ - name: Build documentation
46
+ run: mkdocs build
@@ -0,0 +1,165 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ *.manifest
31
+ *.spec
32
+
33
+ # Installer logs
34
+ pip-log.txt
35
+ pip-delete-this-directory.txt
36
+
37
+ # Unit test / coverage reports
38
+ htmlcov/
39
+ .tox/
40
+ .nox/
41
+ .coverage
42
+ .coverage.*
43
+ .cache
44
+ nosetests.xml
45
+ coverage.xml
46
+ *.cover
47
+ *.py,cover
48
+ .hypothesis/
49
+ .pytest_cache/
50
+ cover/
51
+
52
+ # Translations
53
+ *.mo
54
+ *.pot
55
+
56
+ # Django stuff
57
+ *.log
58
+ local_settings.py
59
+ db.sqlite3
60
+ db.sqlite3-journal
61
+
62
+ # Flask stuff
63
+ instance/
64
+ .webassets-cache
65
+
66
+ # Scrapy stuff
67
+ .scrapy
68
+
69
+ # Sphinx documentation
70
+ docs/_build/
71
+
72
+ # PyBuilder
73
+ .pybuilder/
74
+ target/
75
+
76
+ # Jupyter Notebook
77
+ .ipynb_checkpoints
78
+
79
+ # IPython
80
+ profile_default/
81
+ ipython_config.py
82
+
83
+ # pyenv
84
+ .python-version
85
+
86
+ # pipenv
87
+ Pipfile.lock
88
+
89
+ # poetry
90
+ poetry.lock
91
+
92
+ # pdm
93
+ .pdm.toml
94
+ .pdm-python
95
+ .pdm-build/
96
+
97
+ # PEP 582
98
+ __pypackages__/
99
+
100
+ # Celery stuff
101
+ celerybeat-schedule
102
+ celerybeat.pid
103
+
104
+ # SageMath parsed files
105
+ *.sage.py
106
+
107
+ # Environments
108
+ .env
109
+ .venv
110
+ env/
111
+ venv/
112
+ ENV/
113
+ env.bak/
114
+ venv.bak/
115
+
116
+ # Spyder project settings
117
+ .spyderproject
118
+ .spyproject
119
+
120
+ # Rope project settings
121
+ .ropeproject
122
+
123
+ # mkdocs documentation
124
+ /site
125
+
126
+ # mypy
127
+ .mypy_cache/
128
+ .dmypy.json
129
+ dmypy.json
130
+
131
+ # Pyre type checker
132
+ .pyre/
133
+
134
+ # pytype static type analyzer
135
+ .pytype/
136
+
137
+ # Cython debug symbols
138
+ cython_debug/
139
+
140
+ # IDEs
141
+ .idea/
142
+ .vscode/
143
+ *.swp
144
+ *.swo
145
+ *~
146
+
147
+ # OS
148
+ .DS_Store
149
+ Thumbs.db
150
+
151
+ # Project specific
152
+ *.tmp
153
+ *.bak
154
+ results/
155
+ outputs/
156
+ chains_*/
157
+ data/real/
158
+ data/external/
159
+ *.zip
160
+ *.tar.gz
161
+ *.tgz
162
+
163
+ # CDS specific (future)
164
+ .cds/
165
+ *.hypo.json
@@ -0,0 +1,173 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ ## [Unreleased]
6
+
7
+ ## [0.8.0] - 2026-06-16
8
+
9
+ ### Fixed
10
+ - **`adaptive_simpson` hang on NaN/divergent integrands**: when the integrand produced `NaN` (e.g. `float("nan")` or a divergent integrand), the Lyness error estimate `diff` was `NaN`, making `abs(diff) <= 15*eps` always `False`. The recursion then branched down to `max_depth`, making up to `2**max_depth` calls and effectively hanging the suite (the test ran for 10+ minutes). Added an early-exit: if `diff` is `NaN`, the subinterval stops recursing so the `NaN` propagates to the top-level `RuntimeError` guard. The previously hanging test `test_divergent_integrand_raises` now passes in <0.2 s. Full suite runtime dropped from 10 min (timeout) to ~19 s, and test coverage reached **100%** (570 tests).
11
+
12
+ ### Changed
13
+ - README badges and stats updated: tests **565 → 570**, coverage **99% → 100%**.
14
+
15
+ ## [0.7.0] - 2026-06-16
16
+
17
+ ### Added
18
+ - **Numerical Integration** (`cds.numerical_integration`): Deterministic quadrature module with `trapezoid`, `simpson` (1/3), `simpson_38` (3/8), `romberg` (Richardson extrapolation), `gaussian_quadrature` (Gauss-Legendre), and `adaptive_simpson` (recursive adaptive). Complements the stochastic integration in `cds.montecarlo` and the ODE solvers in `cds.diffeq`. Gauss-Legendre nodes/weights are derived and cached; exact for polynomials up to degree 2n−1. Backed by 36 new tests (Newton-Cotes 1722, Simpson 1743, Romberg 1955, Gauss 1814, Lyness 1969).
19
+ - Top-level `cds.numerical_integration` export registered in package `__init__` and `__all__`.
20
+
21
+ ### Changed
22
+ - README module table, module count (14 → 15), architecture tree, and test badge (440+ → 565) updated to reflect the new module. `docs/api.md` and `docs/api-reference.md` now document `cds.numerical_integration`.
23
+ - Version bumped to 0.7.0 (pyproject.toml, src/cds/__init__.py, CITATION.cff, README, docs/index.md).
24
+
25
+ ### Fixed
26
+ - **Public API**: `rz_gate` was missing from the `cds.quantum` package exports (`__init__.py` / `__all__`) despite being documented and tested. Now importable via `from cds.quantum import rz_gate`.
27
+ - **Documentation accuracy**: `lu_decomposition` return type corrected across docs from `(L, U)` to `(P, L, U)` (the implementation uses partial pivoting, PA = LU), and the misleading "Doolittle" label removed.
28
+ - **Consistency sweep**: aligned test-count and coverage references across README, CLI (`cds info`), `docs/index.md`, `getting-started.md`, `CONTRIBUTING.md`, `ROADMAP.md`, and `benchmarks.md`. Coverage now reported as **99%** (previously stale 97% / 92%); test count reported as **565** (previously stale 350/380/440). Resolved the quantum speedup contradiction in `benchmarks.md` (61.1x → 60.3x, matching the visual proof and the actual 0.41s/0.0068s ratio). Added missing `cds.scientific` and `cds.probability` sections to `docs/api.md`.
29
+ - **api-reference.md vs source-code audit**: corrected 15 discrepancies — fixed `QuantumRegister.normalize()` return type (None, not QuantumRegister); fixed `cds.scientific` constants list (removed phantom `epsilon_0`/`mu_0`, added `hbar`/`pi`/`e_math`); added missing `rk45` (diffeq), `DataSet`/`plot_bar`/`plot_line` (data_analysis), `QuantumGate`/`Qubit` (quantum), and 6 hypothesis exports (`Domain`, `Hypothesis`, `HypothesisStatus`, `HypothesisGenerator`, `HypothesisEvaluator`, `EvaluationResult`); aligned parameter names across optimization (`h`, `h_base`, `state`, `grad_f`), stats (`data`), math_utils (`h_base`, `point`), scientific (`n_moles`, `temperature`, `volume`), and hypothesis (`research_question`). Added missing `numerical_integration` module to CLI `cds info` panel.
30
+ - **Error messages**: replaced 11 generic/internal messages with actionable guidance across `linalg` (5), `signals` (3), and `stats` (3). Internal helper names (`gammp`/`gammq`) replaced with mathematical domain descriptions. Parameters, offending values, and fix suggestions now included where applicable. All existing `pytest.raises(match=...)` substring assertions preserved.
31
+ - **ROADMAP**: all v0.7.0 checkboxes marked complete.
32
+
33
+ ## [0.6.0] - 2026-06-14
34
+
35
+ ### Added
36
+ - **Machine Learning** (`cds.ml`): Pure Python Neural Networks with `MLP` and `Layer` abstractions. Support for Adam-based training and common activation functions.
37
+ - **Interactive Dashboard**: Streamlit-based web dashboard for real-time scientific exploration, including a live Hypothesis Engine and Quantum Circuit Simulator.
38
+ - **Improved Monte Carlo**: Parallelized Multi-Core Monte Carlo engines for faster π estimation and integration.
39
+ - **Data Analysis Viz**: ASCII-based line plotting directly in the terminal via `cds plot`.
40
+
41
+ ### Changed
42
+ - **Numerical Core**: Refactored `math_utils` with O(N³) pure-Python Partial Pivoting LU decomposition, improving stability and performance for linear systems and determinants.
43
+ - **Optimization**: Vectorized machine learning optimizers for improved training efficiency.
44
+ - **Test Coverage**: Achieved **92%+ code coverage** with 350 tests.
45
+ - **CLI Refresh**: `cds info` now displays a comprehensive status panel with 14 core modules and platform health info.
46
+ - Version bumped to 0.6.0 (pyproject.toml, src/cds/__init__.py, README, CLI info).
47
+
48
+ ## [0.3.0] - 2026-06-13
49
+
50
+ ### Added
51
+ - `docs/research-workflows.md` — guidance on using CDS in real research and discovery pipelines: combining hypothesis generation with stats/optimization/Monte Carlo, implementing custom `HypothesisGenerator` implementations, and embedding modules in larger scripts.
52
+ - `CITATION.cff` at repository root for standard academic citation of the platform in research papers and pipelines.
53
+ - `examples/hypothesis_custom_generator.py` — a small runnable demonstration of supplying a custom implementation of the HypothesisGenerator Protocol for a toy domain.
54
+
55
+ ### Changed
56
+ - All references to the test suite updated to exactly **350 tests** (README, docs, CONTRIBUTING.md, CLI).
57
+ - `docs/benchmarks.md` refreshed with fresh micro-benchmark timings (hypothesis generation ~0.1 ms for n=3, stats operations, quantum primitives, optimization).
58
+ - Cleaned Codecov placeholder comment from README (badge remains; live data requires connecting the repo on codecov.io).
59
+ - Version bumped to 0.3.0 (pyproject.toml, src/cds/__init__.py, README alpha notice, CLI info/status).
60
+ - Cross-references to the new research workflows documentation added throughout README, getting-started, and CONTRIBUTING.
61
+ - GitHub repository description and topics updated via gh for better visibility (topics include pure-python, scientific-computing, hypothesis-generation, etc.).
62
+
63
+ ## [0.2.0] - 2026-06-13
64
+
65
+ ### Added
66
+ - `cds hypothesis` command for quick demos of the hypothesis generation module.
67
+ - `examples/hypothesis_demo.py` runnable example for the cognitive/hypothesis features.
68
+ - GitHub community files: PR template, issue templates, CI workflow, FUNDING.yml, CODEOWNERS.
69
+ - Basic CLI smoke tests (`tests/test_cli.py`).
70
+ - **CLI**: New `cds modules` command that lists all available scientific modules in a clear table; improved `--version` / `-v` flag and help discoverability.
71
+ - **Public API**: Cleaner top-level package exports and documentation.
72
+ - **Hypothesis module**: Improved module and generator documentation for better clarity on providing custom generators.
73
+ - **Developer experience**: Replaced the placeholder setup script with a working one-command development setup (creates venv, installs the package, runs tests).
74
+ - **Documentation**: Added a short Vision section, expanded CONTRIBUTING.md with module/CLI/hypothesis guidance, and updated quick-start examples.
75
+
76
+ ### Changed
77
+ - General improvements to documentation and usability.
78
+ - README now includes live CI badge and reference to the new hypothesis demo.
79
+
80
+ ### Previous (from initial push)
81
+ - **2-D FFT** (`cds.signals`): `fft2` / `ifft2` via row-column decomposition (Cooley-Tukey 1965)
82
+ - **Hypothesis testing** (`cds.stats`): one-sample & two-sample t-tests (pooled / Welch),
83
+ chi-square goodness-of-fit and independence, one-way ANOVA, with exact distribution
84
+ tail functions (`t_sf`, `chi2_sf`, `f_sf`) built on regularized incomplete gamma/beta
85
+ functions (Student 1908, Pearson 1900, Fisher 1925; Numerical Recipes §6.1–6.4)
86
+ - **Linear algebra** (`cds.math_utils`): QR decomposition via Householder reflections
87
+ (Householder 1958) and Cholesky decomposition (Benoît/Cholesky 1924)
88
+ - New runnable demos: `examples/fft2_demo.py`, `examples/hypothesis_tests_demo.py`,
89
+ `examples/linalg_demo.py`
90
+ - Project logo/banner (`assets/logo.svg`)
91
+ - Test suite expanded to **350 tests** (see CI)
92
+
93
+ ## [0.1.0] - 2026-06-09
94
+
95
+ ### Added
96
+ - **Quantum computing** (`cds.quantum`)
97
+ - Single-qubit gates: Hadamard, Pauli-X/Y/Z, phase, Rz rotation
98
+ - Multi-qubit register with state vector simulation
99
+ - Two-qubit gates: CNOT, CZ, SWAP
100
+ - Three-qubit gate: Toffoli (CCNOT)
101
+ - Bell state and GHZ state preparation
102
+ - Entanglement detection via concurrence
103
+ - Measurement with shot-based sampling
104
+ - **Optimization** (`cds.optimization`)
105
+ - Gradient descent minimization
106
+ - Newton-Raphson root finding
107
+ - Adam optimizer (adaptive learning rate)
108
+ - Golden section line search
109
+ - **Signal processing** (`cds.signals`)
110
+ - Discrete Fourier Transform (DFT)
111
+ - Fast Fourier Transform (Cooley-Tukey radix-2)
112
+ - Linear convolution
113
+ - Power spectrum computation
114
+ - Frequency-domain low-pass filter
115
+ - **Probability** (`cds.probability`)
116
+ - Gaussian, uniform, exponential PDF
117
+ - Binomial and Poisson PMF
118
+ - Uniform random sampling
119
+ - **Statistics** (`cds.stats`)
120
+ - Mean, median, variance, standard deviation
121
+ - Pearson correlation coefficient
122
+ - Linear regression with R² and prediction
123
+ - **Numerical math** (`cds.math_utils`)
124
+ - Derivatives (central difference)
125
+ - Integrals (Simpson's rule)
126
+ - Gradient computation
127
+ - Matrix multiplication, transpose, determinant
128
+ - LU decomposition (partial pivoting)
129
+ - Linear system solver (forward/back substitution)
130
+ - Matrix inverse
131
+ - Eigenvalue computation (power iteration — Von Mises 1929)
132
+ - Gram-Schmidt orthonormalization
133
+ - **Graph theory** (`cds.graph`)
134
+ - Breadth-first search (BFS)
135
+ - Depth-first search (DFS)
136
+ - Dijkstra's shortest path algorithm (1959)
137
+ - Kruskal's minimum spanning tree (1956)
138
+ - Topological sort (Kahn's algorithm)
139
+ - Cycle detection (DFS coloring)
140
+ - **Monte Carlo methods** (`cds.montecarlo`)
141
+ - π estimation (unit-circle method)
142
+ - Monte Carlo integration
143
+ - Buffon's needle experiment (1777)
144
+ - 1D and 2D random walks
145
+ - **Differential equations** (`cds.diffeq`)
146
+ - Euler's method (1768)
147
+ - Classical 4th-order Runge-Kutta (RK4)
148
+ - Explicit midpoint method (2nd-order RK)
149
+ - System solver for coupled ODEs
150
+ - **Data analysis** (`cds.data_analysis`)
151
+ - CSV file loader
152
+ - Normalization, z-score standardization
153
+ - Moving average
154
+ - **Scientific computing** (`cds.scientific`)
155
+ - Physical constants (c, G, h, k_B, N_A, R, etc.)
156
+ - Kinetic energy, gravitational force, wave frequency
157
+ - Ideal gas law, photon energy, Schwarzschild radius
158
+ - De Broglie wavelength, escape velocity
159
+ - **Hypothesis generation** (`cds.hypothesis`)
160
+ - prompt templates for hypothesis work
161
+ - Offline placeholder generator for demos
162
+ - **CLI** (`cds` command)
163
+ - `cds constants` — list physical constants
164
+ - `cds calc` — interactive physics calculator
165
+ - `cds hypothesize` — generate hypotheses
166
+ - Core data models (`cds.core.models`)
167
+ - 350 tests with pytest
168
+ - Example scripts in `examples/`
169
+ - API reference documentation (`docs/api-reference.md`)
170
+ - Performance benchmarks (`docs/benchmarks.md`)
171
+ - Contributing guidelines, Code of Conduct, Security policy
172
+ - Issue and PR templates
173
+ - Getting started documentation