Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 98 additions & 0 deletions .github/workflows/erdos625-value-upgrade-program.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: Erdős 625 value-upgrade research program

on:
pull_request:
paths:
- "625/research/**"
- ".github/workflows/erdos625-value-upgrade-program.yml"
workflow_dispatch:

concurrency:
group: erdos625-value-upgrade-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
research-dossier-check:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5

- name: Compile the coefficient ledger
run: python -m py_compile 625/research/erdos625_value_upgrade_constants.py

- name: Run the coefficient ledger
run: python 625/research/erdos625_value_upgrade_constants.py

- name: Run the coefficient ledger with optimization
run: python -O 625/research/erdos625_value_upgrade_constants.py

- name: Check theorem-dossier structure and status markers
run: |
python - <<'PY'
from pathlib import Path

md = Path("625/research/ERDOS625_VALUE_UPGRADE_PROGRAM_2026-07-26.md")
tex = Path("625/research/ERDOS625_VALUE_UPGRADE_THEOREMS.tex")
readme = Path("625/research/README.md")

for path in (md, tex, readme):
if not path.is_file():
raise SystemExit(f"missing required research file: {path}")

md_text = md.read_text(encoding="utf-8")
tex_text = tex.read_text(encoding="utf-8")

md_markers = (
"Public chronology and claim scope",
"Current proof frontier",
"New theorem target I: remove the midpoint loss",
"High-upside extension: slowly growing support",
"Largest follow-up target: prove the matching upper bound",
"Recommended publication architecture",
)
tex_markers = (
r"\begin{theorem}[Phase-resolved full-sequence gap]",
r"\begin{conjecture}[Near-root placement theorem]",
r"\begin{conjecture}[Balance stability]",
r"\begin{conjecture}[Slow-support gap]",
r"\begin{program}[Full upper bound]",
)

missing_md = [marker for marker in md_markers if marker not in md_text]
missing_tex = [marker for marker in tex_markers if marker not in tex_text]
if missing_md:
raise SystemExit(f"missing Markdown markers: {missing_md}")
if missing_tex:
raise SystemExit(f"missing TeX markers: {missing_tex}")

if r"o\!left" in md_text or r"o\!left" in tex_text:
raise SystemExit(r"known TeX typo remains: o\!left")

if tex_text.count(r"\begin{document}") != 1:
raise SystemExit("TeX file must have exactly one begin{document}")
if tex_text.count(r"\end{document}") != 1:
raise SystemExit("TeX file must have exactly one end{document}")

# Lightweight brace check that ignores escaped braces.
depth = 0
index = 0
while index < len(tex_text):
char = tex_text[index]
if char == "\\":
index += 2
continue
if char == "{":
depth += 1
elif char == "}":
depth -= 1
if depth < 0:
raise SystemExit("TeX has a premature closing brace")
index += 1
if depth != 0:
raise SystemExit(f"TeX brace depth is {depth}, expected zero")

print("research dossier structure: PASS")
PY
Loading