templates: fix cloud-solve blockers (Ipopt callback + bare using Piccolissimo) - #157
Merged
Merged
Conversation
…olissimo) Two bugs found via live testing on the baked solve-runner AMI, blocking cloud solves through the SendCommand wrapper: 1. All 4 templates passed an unsupported per-iteration callback via IpoptOptions to solve!, but the DirectTrajOpt baked in the cloud bundle has no such kwarg -> MethodError before the solve. Drop the per-iter pulse-emit (AMICODE_PULSE frames); keep the supported callback (AMICODE_ITER stats still flow). Restore once the bundle exposes the hook. 2. solve_template_hp.jl had `using Piccolissimo` with a trailing comment -- the cloud wrapper's using-patcher exact-matches the bare line, so the comment made the bundled module fail to resolve. Made it bare (note moved above). Verified live on the AMI: plain template runs to DONE fidelity ~1.0; HP template (spline stack) runs to DONE fidelity=0.856. Both parse in Julia; tsc clean. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This was referenced Jul 20, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two bugs found by live-testing on the baked solve-runner AMI — both blocked cloud solves (plain and HP/Piccolissimo) through the SendCommand wrapper.
The bugs
IpoptOptionstosolve!— but theDirectTrajOptbaked into the cloud bundle has no such kwarg →MethodErrorbefore the solve even starts. Dropped the per-iterpulse_emit(which fedAMICODE_PULSEframe telemetry); kept the supportedcallback(soAMICODE_ITERstats still stream to the poll endpoint). A comment marks it to restore once the bundle exposes an intermediate-callback hook.using Piccolissimotrailing comment (HP only).solve_template_hp.jlhadusing Piccolissimo # HP layer…. The cloud wrapper binds the bundled package intoMainand comments outusing <pkg>lines by exact match — the trailing comment defeated that, so the bundled module failed to resolve (Package Piccolissimo not found). Made the line bare; the explanatory note moved above it.Verified live on the AMI (not just unit-checked)
solve_template.jl→ ran toDONE, fidelity ~1.0.solve_template_hp.jl(SplineIntegrator + SplinePulseProblem) → ran toDONE fidelity=0.856, 60 iterations. Confirms Piccolissimo's HP solver works in the cloud bundle; Altissimo is present in the bundle too.tscclean; packaging test unaffected.Applied to all 4 templates (
solve_template,solve_template_hp,skeleton_free,solve_rydberg_cz) for consistency.Known follow-up:
AMICODE_PULSEper-iteration frames (iter_*.png) are the one thing dropped — restoring them needs the bundle's actual intermediate-callback API, a separate change.🤖 Generated with Claude Code