ancient-processor 4.0.1__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 (167) hide show
  1. ancient_processor-4.0.1/.gitattributes +12 -0
  2. ancient_processor-4.0.1/.github/dependabot.yml +17 -0
  3. ancient_processor-4.0.1/.github/pull_request_template.md +16 -0
  4. ancient_processor-4.0.1/.github/workflows/ci.yml +266 -0
  5. ancient_processor-4.0.1/.github/workflows/pages.yml +56 -0
  6. ancient_processor-4.0.1/.github/workflows/release.yml +146 -0
  7. ancient_processor-4.0.1/.gitignore +43 -0
  8. ancient_processor-4.0.1/CHANGELOG.md +979 -0
  9. ancient_processor-4.0.1/CONTRIBUTING.md +126 -0
  10. ancient_processor-4.0.1/LICENSE +21 -0
  11. ancient_processor-4.0.1/MANIFEST.in +14 -0
  12. ancient_processor-4.0.1/PKG-INFO +285 -0
  13. ancient_processor-4.0.1/README.md +245 -0
  14. ancient_processor-4.0.1/THIRD_PARTY_NOTICES.md +35 -0
  15. ancient_processor-4.0.1/docs/acceptance.md +216 -0
  16. ancient_processor-4.0.1/docs/release-plan.md +125 -0
  17. ancient_processor-4.0.1/docs/system-design.md +523 -0
  18. ancient_processor-4.0.1/docs/ui-wizard.md +616 -0
  19. ancient_processor-4.0.1/pyproject.toml +129 -0
  20. ancient_processor-4.0.1/setup.cfg +4 -0
  21. ancient_processor-4.0.1/setup.py +34 -0
  22. ancient_processor-4.0.1/src/ancient_processor.egg-info/PKG-INFO +285 -0
  23. ancient_processor-4.0.1/src/ancient_processor.egg-info/SOURCES.txt +165 -0
  24. ancient_processor-4.0.1/src/ancient_processor.egg-info/dependency_links.txt +1 -0
  25. ancient_processor-4.0.1/src/ancient_processor.egg-info/entry_points.txt +2 -0
  26. ancient_processor-4.0.1/src/ancient_processor.egg-info/requires.txt +14 -0
  27. ancient_processor-4.0.1/src/ancient_processor.egg-info/scm_file_list.json +161 -0
  28. ancient_processor-4.0.1/src/ancient_processor.egg-info/scm_version.json +8 -0
  29. ancient_processor-4.0.1/src/ancient_processor.egg-info/top_level.txt +1 -0
  30. ancient_processor-4.0.1/src/super_processor/__init__.py +53 -0
  31. ancient_processor-4.0.1/src/super_processor/__main__.py +5 -0
  32. ancient_processor-4.0.1/src/super_processor/_core.pyi +23 -0
  33. ancient_processor-4.0.1/src/super_processor/_core.pyx +127 -0
  34. ancient_processor-4.0.1/src/super_processor/cli.py +1145 -0
  35. ancient_processor-4.0.1/src/super_processor/diagnose.py +193 -0
  36. ancient_processor-4.0.1/src/super_processor/doctor.py +296 -0
  37. ancient_processor-4.0.1/src/super_processor/encoders.py +101 -0
  38. ancient_processor-4.0.1/src/super_processor/estimators.py +570 -0
  39. ancient_processor-4.0.1/src/super_processor/file_dialog.py +111 -0
  40. ancient_processor-4.0.1/src/super_processor/gemini.py +1684 -0
  41. ancient_processor-4.0.1/src/super_processor/gpu_heat.py +147 -0
  42. ancient_processor-4.0.1/src/super_processor/jobs.py +268 -0
  43. ancient_processor-4.0.1/src/super_processor/look.py +132 -0
  44. ancient_processor-4.0.1/src/super_processor/models.py +278 -0
  45. ancient_processor-4.0.1/src/super_processor/plan.py +143 -0
  46. ancient_processor-4.0.1/src/super_processor/plans.py +366 -0
  47. ancient_processor-4.0.1/src/super_processor/preview.py +233 -0
  48. ancient_processor-4.0.1/src/super_processor/probe.py +459 -0
  49. ancient_processor-4.0.1/src/super_processor/progress.py +108 -0
  50. ancient_processor-4.0.1/src/super_processor/py.typed +1 -0
  51. ancient_processor-4.0.1/src/super_processor/qa.py +150 -0
  52. ancient_processor-4.0.1/src/super_processor/recipe.py +313 -0
  53. ancient_processor-4.0.1/src/super_processor/reframe.py +345 -0
  54. ancient_processor-4.0.1/src/super_processor/regions.py +173 -0
  55. ancient_processor-4.0.1/src/super_processor/render.py +154 -0
  56. ancient_processor-4.0.1/src/super_processor/review.py +901 -0
  57. ancient_processor-4.0.1/src/super_processor/segment_loop.py +494 -0
  58. ancient_processor-4.0.1/src/super_processor/segments.py +895 -0
  59. ancient_processor-4.0.1/src/super_processor/shot_plan.py +816 -0
  60. ancient_processor-4.0.1/src/super_processor/shots.py +578 -0
  61. ancient_processor-4.0.1/src/super_processor/span_sr.py +429 -0
  62. ancient_processor-4.0.1/src/super_processor/stability.py +286 -0
  63. ancient_processor-4.0.1/src/super_processor/templates.py +396 -0
  64. ancient_processor-4.0.1/src/super_processor/treatments.py +342 -0
  65. ancient_processor-4.0.1/src/super_processor/upscale.py +2434 -0
  66. ancient_processor-4.0.1/src/super_processor/validator.py +355 -0
  67. ancient_processor-4.0.1/src/super_processor/wizard.py +1972 -0
  68. ancient_processor-4.0.1/src/super_processor/wizard_pages.py +1192 -0
  69. ancient_processor-4.0.1/src/super_processor/worker.py +325 -0
  70. ancient_processor-4.0.1/tests/conftest.py +55 -0
  71. ancient_processor-4.0.1/tests/loop_driver.py +70 -0
  72. ancient_processor-4.0.1/tests/test_api_key_store.py +181 -0
  73. ancient_processor-4.0.1/tests/test_audio_mux.py +249 -0
  74. ancient_processor-4.0.1/tests/test_cli.py +36 -0
  75. ancient_processor-4.0.1/tests/test_core.py +40 -0
  76. ancient_processor-4.0.1/tests/test_diagnose_plan.py +515 -0
  77. ancient_processor-4.0.1/tests/test_doctor.py +279 -0
  78. ancient_processor-4.0.1/tests/test_estimators.py +471 -0
  79. ancient_processor-4.0.1/tests/test_faults.py +34 -0
  80. ancient_processor-4.0.1/tests/test_frame_alignment.py +311 -0
  81. ancient_processor-4.0.1/tests/test_gemini.py +885 -0
  82. ancient_processor-4.0.1/tests/test_gemini_live.py +67 -0
  83. ancient_processor-4.0.1/tests/test_gemini_video.py +697 -0
  84. ancient_processor-4.0.1/tests/test_gpu_blend.py +271 -0
  85. ancient_processor-4.0.1/tests/test_gpu_codec.py +552 -0
  86. ancient_processor-4.0.1/tests/test_gpu_heat.py +220 -0
  87. ancient_processor-4.0.1/tests/test_gpu_strength.py +58 -0
  88. ancient_processor-4.0.1/tests/test_hwdecode.py +173 -0
  89. ancient_processor-4.0.1/tests/test_job_cli.py +127 -0
  90. ancient_processor-4.0.1/tests/test_jobs.py +184 -0
  91. ancient_processor-4.0.1/tests/test_kept_duration.py +48 -0
  92. ancient_processor-4.0.1/tests/test_look.py +344 -0
  93. ancient_processor-4.0.1/tests/test_packaging.py +49 -0
  94. ancient_processor-4.0.1/tests/test_pass_through.py +572 -0
  95. ancient_processor-4.0.1/tests/test_plan_cli.py +107 -0
  96. ancient_processor-4.0.1/tests/test_plan_io.py +98 -0
  97. ancient_processor-4.0.1/tests/test_plan_pick.py +83 -0
  98. ancient_processor-4.0.1/tests/test_plan_revise.py +56 -0
  99. ancient_processor-4.0.1/tests/test_plan_score.py +86 -0
  100. ancient_processor-4.0.1/tests/test_preview_encode.py +227 -0
  101. ancient_processor-4.0.1/tests/test_preview_window.py +53 -0
  102. ancient_processor-4.0.1/tests/test_probe.py +214 -0
  103. ancient_processor-4.0.1/tests/test_product_flow.py +174 -0
  104. ancient_processor-4.0.1/tests/test_progress.py +129 -0
  105. ancient_processor-4.0.1/tests/test_recipe.py +55 -0
  106. ancient_processor-4.0.1/tests/test_reframe.py +240 -0
  107. ancient_processor-4.0.1/tests/test_regions.py +534 -0
  108. ancient_processor-4.0.1/tests/test_render_argv.py +153 -0
  109. ancient_processor-4.0.1/tests/test_render_choose.py +297 -0
  110. ancient_processor-4.0.1/tests/test_review_server.py +239 -0
  111. ancient_processor-4.0.1/tests/test_segment_apply.py +202 -0
  112. ancient_processor-4.0.1/tests/test_segment_bounds.py +55 -0
  113. ancient_processor-4.0.1/tests/test_segment_cli.py +223 -0
  114. ancient_processor-4.0.1/tests/test_segment_ffmpeg.py +44 -0
  115. ancient_processor-4.0.1/tests/test_segment_groups.py +34 -0
  116. ancient_processor-4.0.1/tests/test_segment_labels.py +88 -0
  117. ancient_processor-4.0.1/tests/test_segment_loop.py +571 -0
  118. ancient_processor-4.0.1/tests/test_segment_loop_wizard.py +600 -0
  119. ancient_processor-4.0.1/tests/test_segment_merge.py +58 -0
  120. ancient_processor-4.0.1/tests/test_segment_notes.py +80 -0
  121. ancient_processor-4.0.1/tests/test_segment_review.py +183 -0
  122. ancient_processor-4.0.1/tests/test_segment_sample.py +63 -0
  123. ancient_processor-4.0.1/tests/test_segment_samples_io.py +119 -0
  124. ancient_processor-4.0.1/tests/test_segment_score.py +44 -0
  125. ancient_processor-4.0.1/tests/test_segment_split.py +58 -0
  126. ancient_processor-4.0.1/tests/test_sentence.py +24 -0
  127. ancient_processor-4.0.1/tests/test_shot_plan.py +648 -0
  128. ancient_processor-4.0.1/tests/test_shots.py +528 -0
  129. ancient_processor-4.0.1/tests/test_span_gpu.py +171 -0
  130. ancient_processor-4.0.1/tests/test_stability.py +601 -0
  131. ancient_processor-4.0.1/tests/test_templates.py +178 -0
  132. ancient_processor-4.0.1/tests/test_timing_safety.py +520 -0
  133. ancient_processor-4.0.1/tests/test_treatments.py +162 -0
  134. ancient_processor-4.0.1/tests/test_upscale.py +1698 -0
  135. ancient_processor-4.0.1/tests/test_validator.py +199 -0
  136. ancient_processor-4.0.1/tests/test_vmaf.py +80 -0
  137. ancient_processor-4.0.1/tests/test_wizard.py +103 -0
  138. ancient_processor-4.0.1/tests/test_wizard_api.py +390 -0
  139. ancient_processor-4.0.1/tests/test_wizard_cli.py +149 -0
  140. ancient_processor-4.0.1/tests/test_wizard_edges.py +447 -0
  141. ancient_processor-4.0.1/tests/test_wizard_flow_steps.py +365 -0
  142. ancient_processor-4.0.1/tests/test_wizard_full_flow.py +280 -0
  143. ancient_processor-4.0.1/tests/test_wizard_hardening.py +276 -0
  144. ancient_processor-4.0.1/tests/test_wizard_media.py +240 -0
  145. ancient_processor-4.0.1/tests/test_wizard_media_routes.py +106 -0
  146. ancient_processor-4.0.1/tests/test_wizard_navigation.py +441 -0
  147. ancient_processor-4.0.1/tests/test_wizard_note_scale.py +456 -0
  148. ancient_processor-4.0.1/tests/test_wizard_pages.py +138 -0
  149. ancient_processor-4.0.1/tests/test_wizard_render_steps.py +252 -0
  150. ancient_processor-4.0.1/tests/test_wizard_safety.py +326 -0
  151. ancient_processor-4.0.1/tests/test_worker.py +654 -0
  152. ancient_processor-4.0.1/uv.lock +1826 -0
  153. ancient_processor-4.0.1/web/index.html +19 -0
  154. ancient_processor-4.0.1/web/package-lock.json +1937 -0
  155. ancient_processor-4.0.1/web/package.json +26 -0
  156. ancient_processor-4.0.1/web/scripts/a11y.mjs +96 -0
  157. ancient_processor-4.0.1/web/src/App.tsx +79 -0
  158. ancient_processor-4.0.1/web/src/LiveWizard.tsx +1284 -0
  159. ancient_processor-4.0.1/web/src/StaticShell.tsx +150 -0
  160. ancient_processor-4.0.1/web/src/api.ts +440 -0
  161. ancient_processor-4.0.1/web/src/main.tsx +15 -0
  162. ancient_processor-4.0.1/web/src/styles.css +490 -0
  163. ancient_processor-4.0.1/web/src/vite-env.d.ts +10 -0
  164. ancient_processor-4.0.1/web/tests/api.test.mjs +482 -0
  165. ancient_processor-4.0.1/web/tests/proxy.test.mjs +98 -0
  166. ancient_processor-4.0.1/web/tsconfig.json +21 -0
  167. ancient_processor-4.0.1/web/vite.config.ts +18 -0
@@ -0,0 +1,12 @@
1
+ * text=auto eol=lf
2
+
3
+ *.bat text eol=crlf
4
+ *.cmd text eol=crlf
5
+ *.ps1 text eol=crlf
6
+ *.pyx linguist-language=Cython
7
+
8
+ *.gif binary
9
+ *.ico binary
10
+ *.jpg binary
11
+ *.png binary
12
+ *.whl binary
@@ -0,0 +1,17 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: pip
4
+ directory: /
5
+ schedule:
6
+ interval: weekly
7
+ groups:
8
+ development-dependencies:
9
+ dependency-type: development
10
+
11
+ - package-ecosystem: github-actions
12
+ directory: /
13
+ schedule:
14
+ interval: weekly
15
+ groups:
16
+ github-actions:
17
+ patterns: ["*"]
@@ -0,0 +1,16 @@
1
+ ## Summary
2
+
3
+ <!-- Explain what changed and why. -->
4
+
5
+ ## Validation
6
+
7
+ - [ ] `python -m ruff format --check .`
8
+ - [ ] `python -m ruff check .`
9
+ - [ ] `python -m mypy`
10
+ - [ ] `python -m pytest`
11
+ - [ ] `python -m build`
12
+ - [ ] Documentation updated when applicable
13
+
14
+ ## Risk
15
+
16
+ <!-- Note compatibility, performance, packaging, or media-quality risks. -->
@@ -0,0 +1,266 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: ["main"]
6
+ pull_request:
7
+ workflow_dispatch:
8
+
9
+ permissions:
10
+ contents: read
11
+
12
+ concurrency:
13
+ group: ci-${{ github.workflow }}-${{ github.ref }}
14
+ cancel-in-progress: true
15
+
16
+ env:
17
+ PIP_DISABLE_PIP_VERSION_CHECK: "1"
18
+
19
+ jobs:
20
+ quality:
21
+ name: Quality
22
+ runs-on: ubuntu-latest
23
+ steps:
24
+ - name: Check out repository
25
+ uses: actions/checkout@v7
26
+ with:
27
+ fetch-depth: 0
28
+
29
+ - name: Set up Python
30
+ uses: actions/setup-python@v7
31
+ with:
32
+ python-version: "3.14"
33
+ cache: pip
34
+ cache-dependency-path: pyproject.toml
35
+
36
+ - name: Install project
37
+ run: |
38
+ python -m pip install --upgrade pip
39
+ python -m pip install -e ".[dev]"
40
+
41
+ - name: Check formatting
42
+ run: python -m ruff format --check .
43
+
44
+ - name: Lint
45
+ run: python -m ruff check .
46
+
47
+ - name: Type-check
48
+ run: python -m mypy
49
+
50
+ test:
51
+ name: Test (${{ matrix.os }}, Python ${{ matrix.python }})
52
+ runs-on: ${{ matrix.os }}
53
+ strategy:
54
+ fail-fast: false
55
+ matrix:
56
+ os: [ubuntu-latest, macos-latest, windows-latest]
57
+ python: ["3.10", "3.12", "3.14"]
58
+ steps:
59
+ - name: Check out repository
60
+ uses: actions/checkout@v7
61
+ with:
62
+ fetch-depth: 0
63
+
64
+ - name: Set up Python
65
+ uses: actions/setup-python@v7
66
+ with:
67
+ python-version: ${{ matrix.python }}
68
+ cache: pip
69
+ cache-dependency-path: pyproject.toml
70
+
71
+ - name: Install FFmpeg
72
+ if: runner.os == 'Linux'
73
+ run: |
74
+ sudo apt-get update
75
+ sudo apt-get install -y ffmpeg
76
+
77
+ - name: Install FFmpeg
78
+ if: runner.os == 'macOS'
79
+ run: brew install ffmpeg
80
+
81
+ - name: Install FFmpeg
82
+ if: runner.os == 'Windows'
83
+ shell: pwsh
84
+ run: |
85
+ $ErrorActionPreference = 'Continue'
86
+ $installed = $false
87
+ for ($attempt = 1; $attempt -le 4; $attempt++) {
88
+ choco install ffmpeg -y --no-progress
89
+ $env:Path = [System.Environment]::GetEnvironmentVariable('Path','Machine') + ';' +
90
+ [System.Environment]::GetEnvironmentVariable('Path','User')
91
+ if (Get-Command ffmpeg -ErrorAction SilentlyContinue) {
92
+ $installed = $true
93
+ break
94
+ }
95
+ Start-Sleep -Seconds (8 * $attempt)
96
+ }
97
+ if (-not $installed) {
98
+ throw 'ffmpeg not available after Chocolatey retries'
99
+ }
100
+ $ffmpegPath = (Get-Command ffmpeg).Source
101
+ $ffmpegDir = Split-Path -Parent $ffmpegPath
102
+ Add-Content -Path $env:GITHUB_PATH -Value $ffmpegDir
103
+ ffmpeg -version
104
+
105
+ - name: Install project
106
+ run: |
107
+ python -m pip install --upgrade pip
108
+ python -m pip install -e ".[dev]"
109
+
110
+ # Never inject Gemini_API_Test here — live calls run only in gemini-live.
111
+ - name: Run unit tests
112
+ run: python -m pytest -m "not gemini_live"
113
+
114
+ - name: Smoke-test console entry point
115
+ run: super-processor self-test --sample-size 1000
116
+
117
+ - name: Smoke-test doctor when FFmpeg is available
118
+ run: super-processor doctor --json
119
+
120
+ frontend:
121
+ name: Frontend regressions and build
122
+ runs-on: ubuntu-latest
123
+ steps:
124
+ - name: Check out repository
125
+ uses: actions/checkout@v7
126
+
127
+ - name: Set up Node
128
+ uses: actions/setup-node@v7
129
+ with:
130
+ node-version: "22"
131
+ cache: npm
132
+ cache-dependency-path: web/package-lock.json
133
+
134
+ - name: Install, test, and build frontend
135
+ working-directory: web
136
+ run: |
137
+ npm ci
138
+ npm test
139
+ npm run build
140
+
141
+ gemini-live:
142
+ name: Gemini live API
143
+ runs-on: ubuntu-latest
144
+ needs: [quality]
145
+ steps:
146
+ - name: Check out repository
147
+ uses: actions/checkout@v7
148
+ with:
149
+ fetch-depth: 0
150
+
151
+ - name: Set up Python
152
+ uses: actions/setup-python@v7
153
+ with:
154
+ python-version: "3.14"
155
+ cache: pip
156
+ cache-dependency-path: pyproject.toml
157
+
158
+ - name: Install project
159
+ run: |
160
+ python -m pip install --upgrade pip
161
+ python -m pip install -e ".[dev]"
162
+
163
+ - name: Require Gemini_API_Test on main pushes
164
+ if: github.event_name == 'push' && github.ref == 'refs/heads/main'
165
+ env:
166
+ GEMINI_API_KEY: ${{ secrets.Gemini_API_Test }}
167
+ run: |
168
+ if [ -z "$GEMINI_API_KEY" ]; then
169
+ echo "Repository secret Gemini_API_Test is missing or empty"
170
+ exit 1
171
+ fi
172
+
173
+ # List multimodal models with usable RPM (limit != 0), probe until one
174
+ # accepts generateContent, then pin SUPER_PROCESSOR_GEMINI_MODEL for tests.
175
+ - name: Discover Gemini model with usable RPM
176
+ id: gemini_model
177
+ env:
178
+ GEMINI_API_KEY: ${{ secrets.Gemini_API_Test }}
179
+ run: |
180
+ if [ -z "$GEMINI_API_KEY" ]; then
181
+ echo "GEMINI_API_KEY empty; skipping model discovery"
182
+ echo "skipped=true" >> "$GITHUB_OUTPUT"
183
+ exit 0
184
+ fi
185
+ python - <<'PY'
186
+ import os
187
+ from pathlib import Path
188
+
189
+ from super_processor.gemini import GeminiClient, GeminiError
190
+
191
+ client = GeminiClient()
192
+ infos = client.list_model_infos()
193
+ candidates = client.candidate_models(refresh=True)
194
+ print(f"listed={len(infos)} candidates={candidates}")
195
+ for info in infos:
196
+ if info.name in candidates:
197
+ print(
198
+ f" {info.name} rpm={info.rpm_used}/{info.rpm_limit} "
199
+ f"methods={list(info.methods)}"
200
+ )
201
+ if not candidates:
202
+ raise SystemExit("No multimodal Gemini models with usable RPM")
203
+ try:
204
+ picked = client.pick_working_model()
205
+ except GeminiError as exc:
206
+ raise SystemExit(f"No Gemini model accepted a probe call: {exc}") from exc
207
+ print(f"picked={picked}")
208
+ with Path(os.environ["GITHUB_ENV"]).open("a", encoding="utf-8") as handle:
209
+ handle.write(f"SUPER_PROCESSOR_GEMINI_MODEL={picked}\n")
210
+ handle.write(
211
+ "SUPER_PROCESSOR_GEMINI_CANDIDATES="
212
+ + ",".join(client.candidate_models())
213
+ + "\n"
214
+ )
215
+ with Path(os.environ["GITHUB_OUTPUT"]).open("a", encoding="utf-8") as handle:
216
+ handle.write(f"model={picked}\n")
217
+ handle.write("skipped=false\n")
218
+ PY
219
+
220
+ - name: Run live Gemini structured-output tests
221
+ if: steps.gemini_model.outputs.skipped != 'true'
222
+ env:
223
+ GEMINI_API_KEY: ${{ secrets.Gemini_API_Test }}
224
+ run: >
225
+ python -m pytest tests/test_gemini_live.py
226
+ -m gemini_live -v --cov-fail-under=0
227
+
228
+ package:
229
+ name: Build distributions
230
+ needs: [quality, test, frontend, gemini-live]
231
+ runs-on: ubuntu-latest
232
+ steps:
233
+ - name: Check out repository
234
+ uses: actions/checkout@v7
235
+ with:
236
+ fetch-depth: 0
237
+
238
+ - name: Set up Python
239
+ uses: actions/setup-python@v7
240
+ with:
241
+ python-version: "3.14"
242
+ cache: pip
243
+ cache-dependency-path: pyproject.toml
244
+
245
+ - name: Install build tools
246
+ run: |
247
+ python -m pip install --upgrade pip
248
+ python -m pip install build twine
249
+
250
+ - name: Build source and wheel distributions
251
+ run: python -m build
252
+
253
+ - name: Check distribution metadata
254
+ run: python -m twine check dist/*
255
+
256
+ - name: Install and smoke-test wheel
257
+ run: |
258
+ python -m pip install --force-reinstall dist/*.whl
259
+ super-processor self-test --sample-size 1000
260
+
261
+ - name: Upload distributions
262
+ uses: actions/upload-artifact@v7
263
+ with:
264
+ name: python-distributions
265
+ path: dist/
266
+ if-no-files-found: error
@@ -0,0 +1,56 @@
1
+ name: Pages
2
+
3
+ on:
4
+ push:
5
+ branches: ["main"]
6
+ pull_request:
7
+ workflow_dispatch:
8
+
9
+ permissions:
10
+ contents: read
11
+ pages: write
12
+ id-token: write
13
+
14
+ concurrency:
15
+ group: pages-${{ github.ref }}
16
+ cancel-in-progress: true
17
+
18
+ jobs:
19
+ build:
20
+ name: Build static shell
21
+ runs-on: ubuntu-latest
22
+ steps:
23
+ - name: Check out repository
24
+ uses: actions/checkout@v7
25
+
26
+ - name: Set up Node
27
+ uses: actions/setup-node@v7
28
+ with:
29
+ node-version: "22"
30
+ cache: npm
31
+ cache-dependency-path: web/package-lock.json
32
+
33
+ - name: Install and build
34
+ working-directory: web
35
+ run: |
36
+ npm ci
37
+ npm run build
38
+
39
+ - name: Upload Pages artifact
40
+ if: github.event_name == 'push' && github.ref == 'refs/heads/main'
41
+ uses: actions/upload-pages-artifact@v5
42
+ with:
43
+ path: web/dist
44
+
45
+ deploy:
46
+ name: Deploy GitHub Pages
47
+ if: github.event_name == 'push' && github.ref == 'refs/heads/main'
48
+ needs: build
49
+ runs-on: ubuntu-latest
50
+ environment:
51
+ name: github-pages
52
+ url: ${{ steps.deployment.outputs.page_url }}
53
+ steps:
54
+ - name: Deploy
55
+ id: deployment
56
+ uses: actions/deploy-pages@v5
@@ -0,0 +1,146 @@
1
+ name: Release
2
+
3
+ on:
4
+ push:
5
+ tags: ["v*"]
6
+
7
+ permissions:
8
+ contents: read
9
+
10
+ env:
11
+ CIBW_BUILD: "cp310-* cp311-* cp312-* cp313-* cp314-*"
12
+ CIBW_SKIP: "*-musllinux_* *-win32"
13
+ CIBW_TEST_COMMAND: "python -m pytest {project}/tests -o addopts="
14
+ CIBW_TEST_REQUIRES: "pytest>=8.3"
15
+ PIP_DISABLE_PIP_VERSION_CHECK: "1"
16
+
17
+ jobs:
18
+ sdist:
19
+ name: Build source distribution
20
+ runs-on: ubuntu-latest
21
+ steps:
22
+ - name: Check out tagged source
23
+ uses: actions/checkout@v7
24
+ with:
25
+ fetch-depth: 0
26
+
27
+ - name: Set up Python
28
+ uses: actions/setup-python@v7
29
+ with:
30
+ python-version: "3.14"
31
+
32
+ - name: Build source distribution
33
+ run: |
34
+ python -m pip install --upgrade pip
35
+ python -m pip install build
36
+ python -m build --sdist
37
+
38
+ - name: Test source distribution
39
+ run: |
40
+ python -m pip install dist/*.tar.gz
41
+ super-processor self-test --sample-size 1000
42
+
43
+ - name: Upload source distribution
44
+ uses: actions/upload-artifact@v7
45
+ with:
46
+ name: source-distribution
47
+ path: dist/*.tar.gz
48
+ if-no-files-found: error
49
+
50
+ wheels:
51
+ name: Build wheels (${{ matrix.os }})
52
+ runs-on: ${{ matrix.os }}
53
+ strategy:
54
+ fail-fast: false
55
+ matrix:
56
+ os: [ubuntu-latest, macos-latest, windows-latest]
57
+ steps:
58
+ - name: Check out tagged source
59
+ uses: actions/checkout@v7
60
+ with:
61
+ fetch-depth: 0
62
+
63
+ - name: Set up Python
64
+ uses: actions/setup-python@v7
65
+ with:
66
+ python-version: "3.14"
67
+
68
+ - name: Install cibuildwheel
69
+ run: |
70
+ python -m pip install --upgrade pip
71
+ python -m pip install "cibuildwheel>=2.22,<4"
72
+
73
+ - name: Build and test wheels
74
+ run: python -m cibuildwheel --output-dir wheelhouse
75
+
76
+ - name: Upload wheels
77
+ uses: actions/upload-artifact@v7
78
+ with:
79
+ name: wheels-${{ matrix.os }}
80
+ path: wheelhouse/*.whl
81
+ if-no-files-found: error
82
+
83
+ github-release:
84
+ name: Publish GitHub Release
85
+ needs: [sdist, wheels]
86
+ runs-on: ubuntu-latest
87
+ permissions:
88
+ contents: write
89
+ steps:
90
+ - name: Download source distribution
91
+ uses: actions/download-artifact@v8
92
+ with:
93
+ name: source-distribution
94
+ path: dist
95
+
96
+ - name: Download wheels
97
+ uses: actions/download-artifact@v8
98
+ with:
99
+ pattern: wheels-*
100
+ path: dist
101
+ merge-multiple: true
102
+
103
+ - name: Set up Python
104
+ uses: actions/setup-python@v7
105
+ with:
106
+ python-version: "3.14"
107
+
108
+ - name: Verify release artifacts
109
+ run: |
110
+ python -m pip install twine
111
+ python -m twine check dist/*
112
+
113
+ - name: Create GitHub Release
114
+ uses: softprops/action-gh-release@v3
115
+ with:
116
+ files: dist/*
117
+ generate_release_notes: true
118
+ fail_on_unmatched_files: true
119
+
120
+ pypi:
121
+ name: Publish to PyPI
122
+ if: ${{ vars.PYPI_PUBLISH == 'true' }}
123
+ needs: [github-release]
124
+ runs-on: ubuntu-latest
125
+ environment:
126
+ name: pypi
127
+ url: https://pypi.org/p/ancient-processor
128
+ permissions:
129
+ contents: read
130
+ id-token: write
131
+ steps:
132
+ - name: Download source distribution
133
+ uses: actions/download-artifact@v8
134
+ with:
135
+ name: source-distribution
136
+ path: dist
137
+
138
+ - name: Download wheels
139
+ uses: actions/download-artifact@v8
140
+ with:
141
+ pattern: wheels-*
142
+ path: dist
143
+ merge-multiple: true
144
+
145
+ - name: Publish distributions
146
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,43 @@
1
+ # Python bytecode and caches
2
+ __pycache__/
3
+ *.py[cod]
4
+ .pytest_cache/
5
+ .mypy_cache/
6
+ .ruff_cache/
7
+ .coverage
8
+ .coverage.*
9
+ coverage.xml
10
+ htmlcov/
11
+
12
+ # Virtual environments
13
+ .venv*/
14
+ venv/
15
+ env/
16
+
17
+ # Packaging and compiled extensions
18
+ build/
19
+ dist/
20
+ *.egg-info/
21
+ *.so
22
+ *.pyd
23
+ *.dylib
24
+ src/super_processor/_core.c
25
+ src/super_processor/_core.html
26
+ src/super_processor/_version.py
27
+
28
+ # Local dogfood artifacts
29
+ .dogfood/
30
+
31
+ # Local SeedVR2 checkout, venv, and weights
32
+ .seedvr/
33
+
34
+ # Static wizard shell
35
+ web/node_modules/
36
+ web/dist/
37
+
38
+ # Editors and operating systems
39
+ .DS_Store
40
+ .idea/
41
+ .vscode/
42
+ *.swp
43
+ *~