What the agent did
PyTorch FP32 CPU quickstart: install, download pinned typed-decisions checkpoint, run CPU benchmark, parity collect, local syntax check
cd C:\coldpass\workspace; Get-ChildItem -Force | Select-Object Name,Length | Format-Table; Get-Content README.md -TotalCount 200; & C:\coldpass\python\python.exe --version
cd C:\coldpass\workspace; git --version; Get-ChildItem -Force -Recurse -Depth 2 | Select-Object FullName | Format-Table -HideTableHeaders | Out-String -Width 300
cd C:\coldpass\workspace; Get-Command uv -ErrorAction SilentlyContinue | Format-List Source; if (Test-Path "$env:USERPROFILE\.local\bin\uv.exe") {"user uv present"}; Get-Content docs\setup.md -Raw | Select-Object -First 1 | Out-Null; Select-String -Path docs\setup.md -Pattern 'uv|install|Execution|powershell' | ForEach-Object { $_.Line } | Select-Object -First 60; Get-ChildItem .coldpass -Force | Select-Object Name
cd C:\coldpass\workspace; New-Item -ItemType Directory -Force .scratch,.tools,.cache | Out-Null; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $env:UV_INSTALL_DIR = "$PWD\.tools"; $env:UV_NO_MODIFY_PATH = "1"; $env:NODE_USE_ENV_PROXY="1"; Invoke-WebRequest https://astral.sh/uv/install.ps1 -OutFile .scratch/install-uv.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File .scratch\install-uv.ps1; & .\.tools\uv.exe --version
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $env:UV_INSTALL_DIR = "$PWD\.tools"; $env:UV_NO_MODIFY_PATH = "1"; $env:NODE_USE_ENV_PROXY="1"; if (!(Test-Path .scratch\install-uv.ps1)) { Invoke-WebRequest https://astral.sh/uv/install.ps1 -OutFile .scratch\install-uv.ps1 }; & "$PSHOME\powershell.exe" -NoProfile -ExecutionPolicy Bypass -File .scratch\install-uv.ps1; & .\.tools\uv.exe --version
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; & $uv venv --python 3.12; if ($LASTEXITCODE -ne 0) { "VENV FAILED $LASTEXITCODE" } else { & $uv pip install --python .venv --only-binary :all: torch==2.14.0 --index-url https://download.pytorch.org/whl/cpu; "torch exit $LASTEXITCODE" }
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; & $uv pip install --python .venv --only-binary :all: laya==0.3.4 transformers==5.17.0 tokenizers==0.23.3 safetensors==0.8.0 huggingface_hub==1.32.0 numpy==2.5.3 psutil==7.2.2 2>&1 | Select-Object -Last 15; "exit $LASTEXITCODE"
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $env:NODE_USE_ENV_PROXY="1"; $uv = "$PWD\.tools\uv.exe"; & $uv run --no-project --python .venv python scripts/download_model.py 2>&1 | Select-Object -Last 30; "exit $LASTEXITCODE"; Get-ChildItem -Recurse .cache\model | Select-Object FullName,Length | Format-Table -AutoSize | Out-String -Width 250
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; Test-Path .cache\first-run.json; & $uv run --no-project --python .venv python benchmarks/bench_laya_cpu.py --model .cache/model/typed-decisions --threads 4 --warmup 1 --repeats 1 --counts 1,3 --output .cache/first-run.json 2>&1 | Select-Object -Last 30; "exit $LASTEXITCODE"; if (Test-Path .cache\first-run.json) { Get-Content .cache\first-run.json -Raw | Select-Object -First 1 | ForEach-Object { $_.Substring(0,[Math]::Min(1500,$_.Length)) } }
Get-ChildItem C:\Windows\System32\vcruntime140*.dll,C:\Windows\System32\msvcp140*.dll -ErrorAction SilentlyContinue | Select-Object Name | Format-Table -HideTableHeaders | Out-String; ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator); whoami
cd C:\coldpass\workspace; $ErrorActionPreference="Continue"; Invoke-WebRequest https://aka.ms/vs/17/release/vc_redist.x64.exe -OutFile .scratch\vc_redist.x64.exe; "download exit $LASTEXITCODE"; $p = Start-Process -FilePath "$PWD\.scratch\vc_redist.x64.exe" -ArgumentList "/install","/quiet","/norestart" -Wait -PassThru; "vc install exit $($p.ExitCode)"; Test-Path C:\Windows\System32\vcruntime140.dll
cd C:\coldpass\workspace; $ErrorActionPreference="Continue"; Get-ChildItem .scratch | Select-Object Name,Length | Format-Table -HideTableHeaders | Out-String; try { Invoke-WebRequest https://aka.ms/vs/17/release/vc_redist.x64.exe -OutFile "$PWD\.scratch\vc_redist.x64.exe" -MaximumRedirection 10 -UseBasicParsing; "ok" } catch { "ERR: " + $_.Exception.Message }; Get-ChildItem .scratch\vc_redist.x64.exe -ErrorAction SilentlyContinue | Select-Object FullName,Length | Out-String
$ErrorActionPreference="Continue"; $exe = "C:\coldpass\workspace\.scratch\vc_redist.x64.exe"; $p = Start-Process -FilePath $exe -ArgumentList "/install","/quiet","/norestart" -Wait -PassThru; "vc install exit $($p.ExitCode)"; Test-Path C:\Windows\System32\vcruntime140.dll; Test-Path C:\Windows\System32\msvcp140.dll
$ErrorActionPreference="Continue"; New-Item -ItemType Directory -Force C:\coldpass\workspace\.scratch\vclog | Out-Null; $exe = "C:\coldpass\workspace\.scratch\vc_redist.x64.exe"; $p = Start-Process -FilePath $exe -ArgumentList "/install","/quiet","/norestart","/log","C:\coldpass\workspace\.scratch\vclog\vc.log" -Wait -PassThru; "exit $($p.ExitCode)"; Get-ChildItem C:\coldpass\workspace\.scratch\vclog -Recurse | Select-Object FullName,Length | Out-String; Get-ChildItem C:\coldpass\workspace\.scratch\vc*.log -ErrorAction SilentlyContinue | Select-Object -First 1 | ForEach-Object { Get-Content $_.FullName -Tail 25 }
$ErrorActionPreference="Continue"; "TEMP=$env:TEMP"; Get-ChildItem C:\coldpass\workspace\.scratch\854344f3-97ef-4dbb-b4b2-151857893636 -Recurse -ErrorAction SilentlyContinue | Select-Object FullName,Length | Out-String -Width 250; Get-ChildItem $env:TEMP -ErrorAction SilentlyContinue | Select-Object -First 5 Name | Out-String; $p = Start-Process -FilePath "C:\coldpass\workspace\.scratch\vc_redist.x64.exe" -ArgumentList "/quiet","/norestart" -Wait -PassThru -ErrorAction Continue; "exit $($p.ExitCode)"
$ErrorActionPreference="Continue"; $t="C:\coldpass\workspace\.scratch\tmp"; New-Item -ItemType Directory -Force $t | Out-Null; $env:TEMP=$t; $env:TMP=$t; & "C:\coldpass\workspace\.scratch\vc_redist.x64.exe" /install /quiet /norestart; "exit $LASTEXITCODE"; Test-Path C:\Windows\System32\vcruntime140.dll; Get-ChildItem $t -Recurse -ErrorAction SilentlyContinue | Select-Object -First 10 FullName | Out-String
Get-Content C:\coldpass\workspace\.scratch\tmp\Setup_*_Failed.txt -Raw | Out-String -Width 300 | ForEach-Object { $_.Substring(0,[Math]::Min(3000,$_.Length)) }
$ErrorActionPreference="Continue"; "ProgramData=$env:ProgramData"; "ALLUSERS=$env:ALLUSERSPROFILE"; "APPDATA=$env:APPDATA"; if (-not (Test-Path C:\ProgramData)) { New-Item -ItemType Directory C:\ProgramData | Out-Null }; if (-not $env:ProgramData) { $env:ProgramData = "C:\ProgramData" }; $env:ALLUSERSPROFILE = "C:\ProgramData"; $t="C:\coldpass\workspace\.scratch\tmp2"; New-Item -ItemType Directory -Force $t | Out-Null; $env:TEMP=$t; $env:TMP=$t; & "C:\coldpass\workspace\.scratch\vc_redist.x64.exe" /install /quiet /norestart; "exit $LASTEXITCODE"; Test-Path C:\Windows\System32\vcruntime140.dll; Test-Path C:\Windows\System32\msvcp140.dll
$ErrorActionPreference="Continue"; Get-ChildItem C:\coldpass\workspace\.scratch\tmp2 -Recurse -ErrorAction SilentlyContinue | Select-Object -First 3 FullName | Out-String; $f = Get-ChildItem C:\coldpass\workspace\.scratch\tmp2 -Filter "Setup_*" -ErrorAction SilentlyContinue | Select-Object -First 1; if ($f) { Get-Content $f.FullName -Raw | ForEach-Object { $_.Substring(0,[Math]::Min(2500,$_.Length)) } }; Get-ChildItem C:\coldpass\workspace\.scratch\tmp -Filter "Setup_*" | ForEach-Object { Get-Content $_.FullName -Raw | ForEach-Object { $_.Substring(0,[Math]::Min(1200,$_.Length)) } }
$ErrorActionPreference="Continue"; Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList' -ErrorAction SilentlyContinue | Select-Object ProgramData,ProfilesDirectory | Format-List | Out-String; Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders' -ErrorAction SilentlyContinue | Select-Object 'Common AppData' | Out-String; Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders' -ErrorAction SilentlyContinue | Select-Object 'Common AppData' | Out-String
$ErrorActionPreference="Continue"; "SystemDrive=$env:SystemDrive SystemRoot=$env:SystemRoot"; $env:SystemDrive="C:"; $env:ProgramData="C:\ProgramData"; $env:ALLUSERSPROFILE="C:\ProgramData"; $t="C:\coldpass\workspace\.scratch\tmp3"; New-Item -ItemType Directory -Force $t | Out-Null; $env:TEMP=$t; $env:TMP=$t; & "C:\coldpass\workspace\.scratch\vc_redist.x64.exe" /install /quiet /norestart; "exit $LASTEXITCODE"; Test-Path C:\Windows\System32\vcruntime140.dll; Get-ChildItem $t -Filter "Setup_*" | ForEach-Object { Get-Content $_.FullName -Raw | Select-Object -Last 3 }
$ErrorActionPreference="Continue"; Get-ChildItem C:\coldpass\workspace\.scratch\tmp3 -Recurse | Select-Object FullName | Out-String; Get-ChildItem C:\coldpass\workspace\.scratch\tmp3 -Filter "*.txt" -Recurse | ForEach-Object { "== $($_.Name)"; Get-Content $_.FullName -Raw | ForEach-Object { $_.Substring(0,[Math]::Min(1500,$_.Length)) } }; Get-Process | Where-Object { $_.ProcessName -like '*vc*' -or $_.ProcessName -like '*Setup*' } | Select-Object ProcessName | Out-String
$ErrorActionPreference="Continue"; Get-ChildItem C:\coldpass\workspace\.scratch\tmp3 -Filter "*.log" | ForEach-Object { "== $($_.Name)"; Get-Content $_.FullName | Select-String -Pattern 'Error|error|return value|Result|0x' | Select-Object -Last 8 | ForEach-Object { $_.Line } }
cd C:\coldpass\workspace; Test-Path C:\Windows\System32\vcruntime140.dll; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; & $uv run --no-project --python .venv python -c "import torch; print(torch.__version__)" 2>&1 | Select-Object -Last 3; "torch exit $LASTEXITCODE"
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; Test-Path .cache\first-run.json; & $uv run --no-project --python .venv python benchmarks/bench_laya_cpu.py --model .cache/model/typed-decisions --threads 4 --warmup 1 --repeats 1 --counts 1,3 --output .cache/first-run.json 2>&1 | Select-Object -Last 30; "exit $LASTEXITCODE"; if (Test-Path .cache\first-run.json) { (Get-Content .cache\first-run.json -Raw).Substring(0,1200) }
cd C:\coldpass\workspace; Select-String -Path scripts\*.py,benchmarks\*.py,tests\*.py,formal\*.py -Pattern 'schedul|cron|--once|--now|while True|sleep\(|webhook|interval' | ForEach-Object { "$($_.Path):$($_.LineNumber): $($_.Line.Trim())" } | Select-Object -First 30; "---checker"; Select-String -Path C:\coldpass\checker\check.py -Pattern 'expected_file|env|cwd|returncode|fresh|exists' | ForEach-Object { "$($_.LineNumber): $($_.Line.Trim())" } | Select-Object -First 40
cd C:\coldpass\workspace; & C:\coldpass\workspace\.venv\Scripts\python.exe -m unittest discover -s tests -q 2>&1 | Select-Object -Last 8; "unittest exit $LASTEXITCODE"; & C:\coldpass\workspace\.venv\Scripts\python.exe scripts\check_syntax.py 2>&1 | Select-Object -Last 8; "syntax exit $LASTEXITCODE"
cd C:\coldpass\workspace; $env:TEMP = "$PWD\.scratch"; $env:TMP = "$PWD\.scratch"; $env:UV_PYTHON_PREFERENCE = "only-managed"; $env:UV_CACHE_DIR = "$PWD\.cache\uv"; $env:UV_PYTHON_INSTALL_DIR = "$PWD\.tools\python"; $env:HF_HOME = "$PWD\.cache\huggingface"; $uv = "$PWD\.tools\uv.exe"; Test-Path .cache\example-parity-reference.json; $sw=[Diagnostics.Stopwatch]::StartNew(); & $uv run --no-project --python .venv python scripts/parity.py collect --backend pytorch --output .cache/example-parity-reference.json 2>&1 | Select-Object -Last 12; "exit $LASTEXITCODE secs $($sw.Elapsed.TotalSeconds)"; if (Test-Path .cache\example-parity-reference.json) { (Get-Item .cache\example-parity-reference.json).Length; (Get-Content .cache\example-parity-reference.json -Raw).Substring(0,400) }
cd C:\coldpass\workspace; Remove-Item -Force .cache\first-run.json,.cache\example-parity-reference.json -ErrorAction SilentlyContinue; New-Item -ItemType Directory -Force .coldpass | Out-Null; $ws='C:\coldpass\workspace'; $uv='C:\coldpass\workspace\.tools\uv.exe'; $envb = '{"UV_PYTHON_PREFERENCE":"only-managed","UV_CACHE_DIR":"C:\\coldpass\\workspace\\.cache\\uv","UV_PYTHON_INSTALL_DIR":"C:\\coldpass\\workspace\\.tools\\python","HF_HOME":"C:\\coldpass\\workspace\\.cache\\huggingface"}'
$probe = @"
{"kind":"cli","argv":["$uv","run","--no-project","--python",".venv","python","benchmarks/bench_laya_cpu.py","--model",".cache/model/typed-decisions","--threads","4","--warmup","1","--repeats","1","--counts","1,3","--output",".cache/probe-bench.json"],"cwd":"$ws","env":$envb,"expected_file":".cache/probe-bench.json","expected_text":"\"device\": \"cpu\""}
"@
$claims = @"
[
{"kind":"claim","claim":"The quickstart benchmark writes its result file on CPU","source":"memory to ``.cache/first-run.json``. Expect ``meta.device`` to be ``\"cpu\"``, finite","input":"bench_laya_cpu.py with counts 1,3 and a fresh output file","expected":"JSON output with device cpu","probe_kind":"cli","argv":["$uv","run","--no-project","--python",".venv","python","benchmarks/bench_laya_cpu.py","--model",".cache/model/typed-decisions","--threads","4","--warmup","1","--repeats","1","--counts","1,3","--output",".cache/claim-bench.json"],"env":$envb,"expected_file":".cache/claim-bench.json","expected_text":"\"device\": \"cpu\"","cwd":"$ws"},
{"kind":"claim","claim":"The local checks need only Python's standard library and run offline","source":"These checks need only Python's standard library and do not download a model:","input":"unittest discover over tests","expected":"all 19 tests pass","probe_kind":"cli","argv":["$uv","run","--no-project","--python",".venv","python","-m","unittest","discover","-s","tests","-q"],"env":$envb,"expected_text":"Ran 19 tests","cwd":"$ws"},
{"kind":"claim","claim":"The syntax check passes on the repository","source":"python3 scripts/check_syntax.py","input":"scripts/check_syntax.py","expected":"Python syntax checked.","probe_kind":"cli","argv":["$uv","run","--no-project","--python",".venv","python","scripts/check_syntax.py"],"env":$envb,"expected_text":"Python syntax checked.","cwd":"$ws"}
]
"@
$examples = @"
[
{"kind":"example","claim":"Collect PyTorch reference answers for the parity suite","source":"README.md: Check any ONNX build against the reference","input":"parity.py collect --backend pytorch on the pinned checkpoint","expected":"60 cases collected with pytorch-fp32","argv":["$uv","run","--no-project","--python",".venv","python","scripts/parity.py","collect","--backend","pytorch","--output",".cache/example-parity-reference.json"],"cwd":"$ws","env":$envb,"expected_file":".cache/example-parity-reference.json","expected_text":"\"backend\": \"pytorch-fp32\""},
{"kind":"example","claim":"Download and verify the pinned typed-decisions checkpoint","source":"README.md: Quickstart: PyTorch FP32","input":"scripts/download_model.py","expected":"checkpoint verified","argv":["$uv","run","--no-project","--python",".venv","python","scripts/download_model.py"],"cwd":"$ws","env":$envb,"expected_text":"Pinned typed-decisions checkpoint verified."},
{"kind":"example","claim":"Collect ONNX candidate answers for the parity suite","source":"README.md: Check any ONNX build against the reference","reason":"Not run: requires the separate .venv-onnx environment and the 1.69 GB ONNX graph download, which were outside this quickstart run."}
]
"@
$cycles = @"
{"detected":false,"reason":"Entry points inspected: scripts/download_model.py, scripts/download_onnx.py, scripts/parity.py, scripts/check_syntax.py and benchmarks/*.py are one-shot CLIs with no cron, loop, watch, --once/--now or webhook. grep for schedule/cron/--once/--now/webhook found none. The product runs once per command when a user starts it.","checks":[]}
"@
$enc = New-Object System.Text.UTF8Encoding($false)
[IO.File]::WriteAllText("$ws\.coldpass\probe.json", $probe.Trim(), $enc)
[IO.File]::WriteAllText("$ws\.coldpass\claims.json", $claims.Trim(), $enc)
[IO.File]::WriteAllText("$ws\.coldpass\examples.json", $examples.Trim(), $enc)
[IO.File]::WriteAllText("$ws\.coldpass\cycles.json", $cycles.Trim(), $enc)
foreach ($f in 'probe.json','claims.json','examples.json','cycles.json') { "--- $f"; Get-Content "$ws\.coldpass\$f" -Raw | ForEach-Object { $_.Length } }
& "$PSHOME\..\..\..\..\..\" 2>$null | Out-Null
Get-Content "$ws\.coldpass\probe.json" -Raw | ConvertFrom-Json | Out-Null; Get-Content "$ws\.coldpass\claims.json" -Raw | ConvertFrom-Json | Out-Null; Get-Content "$ws\.coldpass\examples.json" -Raw | ConvertFrom-Json | Out-Null; Get-Content "$ws\.coldpass\cycles.json" -Raw | ConvertFrom-Json | Out-Null; "all parse ok"
$ws='C:\coldpass\workspace'; $uv='C:\coldpass\workspace\.tools\uv.exe'; $envb=@{UV_PYTHON_PREFERENCE='only-managed';UV_CACHE_DIR='C:\coldpass\workspace\.cache\uv';UV_PYTHON_INSTALL_DIR='C:\coldpass\workspace\.tools\python';HF_HOME='C:\coldpass\workspace\.cache\huggingface'}
$base=@($uv,'run','--no-project','--python','.venv','python')
$bench=@('benchmarks/bench_laya_cpu.py','--model','.cache/model/typed-decisions','--threads','4','--warmup','1','--repeats','1','--counts','1,3','--output')
$probe=[ordered]@{kind='cli';argv=@($base+$bench+@('.cache/probe-bench.json'));cwd=$ws;env=$envb;expected_file='.cache/probe-bench.json';expected_text='"device": "cpu"'}
$claims=@(
[ordered]@{kind='claim';claim='The quickstart benchmark writes its result file on CPU';source='memory to `.cache/first-run.json`. Expect `meta.device` to be `"cpu"`, finite';input='bench_laya_cpu.py with counts 1,3 and a fresh output file';expected='JSON output with device cpu';probe_kind='cli';argv=@($base+$bench+@('.cache/claim-bench.json'));env=$envb;expected_file='.cache/claim-bench.json';expected_text='"device": "cpu"';cwd=$ws},
[ordered]@{kind='claim';claim='The local checks need only Python standard library and run offline';source="These checks need only Python's standard library and do not download a model:";input='unittest discover over tests';expected='all 19 tests pass';probe_kind='cli';argv=@($base+@('-m','unittest','discover','-s','tests','-q'));env=$envb;expected_text='Ran 19 tests';cwd=$ws},
[ordered]@{kind='claim';claim='The syntax check passes on the repository';source='python3 scripts/check_syntax.py';input='scripts/check_syntax.py';expected='Python syntax checked.';probe_kind='cli';argv=@($base+@('scripts/check_syntax.py'));env=$envb;expected_text='Python syntax checked.';cwd=$ws}
)
$examples=@(
[ordered]@{kind='example';claim='Collect PyTorch reference answers for the parity suite';source='README.md: Check any ONNX build against the reference';input='parity.py collect --backend pytorch on the pinned checkpoint';expected='60 cases collected with pytorch-fp32';argv=@($base+@('scripts/parity.py','collect','--backend','pytorch','--output','.cache/example-parity-reference.json'));cwd=$ws;env=$envb;expected_file='.cache/example-parity-reference.json';expected_text='"backend": "pytorch-fp32"'},
[ordered]@{kind='example';claim='Download and verify the pinned typed-decisions checkpoint';source='README.md: Quickstart: PyTorch FP32';input='scripts/download_model.py';expected='checkpoint verified';argv=@($base+@('scripts/download_model.py'));cwd=$ws;env=$envb;expected_text='Pinned typed-decisions checkpoint verified.'},
[ordered]@{kind='example';claim='Collect ONNX candidate answers for the parity suite';source='README.md: Check any ONNX build against the reference';reason='Not run: requires the separate .venv-onnx environment and the 1.69 GB ONNX graph download, which were outside this quickstart run.'}
)
$cycles=[ordered]@{detected=$false;reason='Entry points inspected: scripts/download_model.py, scripts/download_onnx.py, scripts/parity.py, scripts/check_syntax.py and benchmarks/*.py are one-shot CLIs with no cron, loop, watch, --once/--now or webhook. A search for schedule/cron/--once/--now/webhook found none. The product runs once per command when a user starts it.';checks=@()}
$enc=New-Object System.Text.UTF8Encoding($false)
[IO.File]::WriteAllText("$ws\.coldpass\probe.json",(ConvertTo-Json $probe -Depth 8),$enc)
[IO.File]::WriteAllText("$ws\.coldpass\claims.json",(ConvertTo-Json $claims -Depth 8),$enc)
[IO.File]::WriteAllText("$ws\.coldpass\examples.json",(ConvertTo-Json $examples -Depth 8),$enc)
[IO.File]::WriteAllText("$ws\.coldpass\cycles.json",(ConvertTo-Json $cycles -Depth 8),$enc)
foreach($f in 'probe.json','claims.json','examples.json','cycles.json'){ $t=Get-Content "$ws\.coldpass\$f" -Raw; $null=$t | ConvertFrom-Json; "$f ok" }
Get-Content "$ws\.coldpass\claims.json" -Raw | Select-String 'source' | ForEach-Object { $_.Line.Trim() }
$env:COLDPASS_WORKSPACE='C:\coldpass\workspace'; & C:\coldpass\python\python.exe -I C:\coldpass\checker\check.py --validate --replay; "EXIT=$LASTEXITCODE"
$ws='C:\coldpass\workspace'; $p="$ws\.coldpass\claims.json"; $c=@(Get-Content $p -Raw | ConvertFrom-Json | Where-Object { $_.claim -notlike '*standard library*' }); $enc=New-Object System.Text.UTF8Encoding($false); [IO.File]::WriteAllText($p,(ConvertTo-Json $c -Depth 8),$enc); "claims kept: $($c.Count)"; $env:COLDPASS_WORKSPACE=$ws; & C:\coldpass\python\python.exe -I C:\coldpass\checker\check.py --validate --replay 2>&1 | ForEach-Object { $_.Substring(0,[Math]::Min(600,$_.Length)) }; "EXIT=$LASTEXITCODE"
$ws='C:\coldpass\workspace'; Select-String -Path "$ws\README.md" -Pattern 'meta.device|python3 scripts/check_syntax|Python.s standard' | ForEach-Object { "$($_.LineNumber): [$($_.Line)]" }; "---"; Get-Content "$ws\.coldpass\claims.json" -Raw
$ws='C:\coldpass\workspace'; $uv="$ws\.tools\uv.exe"; $envb=[ordered]@{UV_PYTHON_PREFERENCE='only-managed';UV_CACHE_DIR="$ws\.cache\uv";UV_PYTHON_INSTALL_DIR="$ws\.tools\python";HF_HOME="$ws\.cache\huggingface"}
$base=@($uv,'run','--no-project','--python','.venv','python')
$c1=[ordered]@{kind='claim';claim='The quickstart benchmark writes its result file on CPU';source='Expect `meta.device` to be `"cpu"`, finite';input='bench_laya_cpu.py with counts 1,3 and a fresh output file';expected='JSON output with device cpu';probe_kind='cli';argv=@($base+@('benchmarks/bench_laya_cpu.py','--model','.cache/model/typed-decisions','--threads','4','--warmup','1','--repeats','1','--counts','1,3','--output','.cache/claim-bench.json'));env=$envb;expected_file='.cache/claim-bench.json';expected_text='"device": "cpu"';cwd=$ws}
$c2=[ordered]@{kind='claim';claim='The syntax check passes on the repository';source='python3 scripts/check_syntax.py';input='scripts/check_syntax.py';expected='Python syntax checked.';probe_kind='cli';argv=@($base+@('scripts/check_syntax.py'));env=$envb;expected_text='Python syntax checked.';cwd=$ws}
$arr=@($c1,$c2)
$json=ConvertTo-Json -InputObject $arr -Depth 8
[IO.File]::WriteAllText("$ws\.coldpass\claims.json",$json,(New-Object System.Text.UTF8Encoding($false)))
$chk=Get-Content "$ws\.coldpass\claims.json" -Raw | ConvertFrom-Json; "claims parsed: $(@($chk).Count)"
$env:COLDPASS_WORKSPACE=$ws; & C:\coldpass\python\python.exe -I C:\coldpass\checker\check.py --validate --replay 2>&1 | ForEach-Object { $_.Substring(0,[Math]::Min(700,$_.Length)) }; "EXIT=$LASTEXITCODE"
$ws='C:\coldpass\workspace'; New-Item -ItemType Directory -Force -Path "$ws\.coldpass" | Out-Null
$r=[ordered]@{outcome='working';fault_owner=$null;operation='PyTorch FP32 CPU quickstart: install, download pinned typed-decisions checkpoint, run CPU benchmark, parity collect, local syntax check';steps=@('Install uv via README install.ps1 (absolute powershell path used)','uv venv --python 3.12 .venv (CPython 3.12.15)','Install PyTorch 2.14.0+cpu and laya 0.3.4 per README quickstart','scripts/download_model.py: pinned typed-decisions checkpoint downloaded and verified','benchmarks/bench_laya_cpu.py --counts 1,3 wrote CPU result JSON (exit 0)','scripts/parity.py collect --backend pytorch: 60 cases collected, backend pytorch-fp32','scripts/check_syntax.py passed');deviations=@('python3 replaced by uv run --python .venv python on Windows guest','Visual C++ 2022 x64 redistributable installed as prerequisite for torch; installer needed per-machine AppData/ProgramData env workaround','ONNX route not run (needs separate .venv-onnx and 1.69 GB graphs)','Unit test suite not used as a claim (checker does not count it as a product operation)');stuck_step=$null;main_blocker=$null;plain_failure=$null;suggested_fix='Guest images for Windows should include the Visual C++ 2022 x64 runtime so torch imports without a manual install.'}
$json=ConvertTo-Json -InputObject $r -Depth 6
[IO.File]::WriteAllText("$ws\.coldpass\report.json",$json,(New-Object System.Text.UTF8Encoding($false)))
(Get-Content "$ws\.coldpass\report.json" -Raw | ConvertFrom-Json).outcome
if (Test-Path 'C:\inputs\coldpass-preflight.py') {'preflight present'} else {'preflight not at C:\inputs'}
if (Test-Path '/inputs/coldpass-preflight.py') {'preflight present at /inputs'} else {'no /inputs preflight'}
$env:COLDPASS_WORKSPACE='C:\coldpass\workspace'; & C:\coldpass\python\python.exe -I C:\coldpass\checker\check.py --validate --replay 2>&1 | ForEach-Object { $_.Substring(0,[Math]::Min(300,$_.Length)) }; "EXIT=$LASTEXITCODE"