{ "protocol": "3.8", "prompt_revision": "4", "shared_learning": true, "shot_cap": 100000, "shots_per_setting": 100, "max_experiment_batch": 128, "acquisition_actions": 48, "post_reveal_actions": 12, "numerical_cpu_seconds_per_phase": 1500, "numerical_call_wall_seconds": 120, "prediction_distribution": "Twelve laboratory-style Rabi, Ramsey, quadrature and smooth-envelope settings, within the same legal interface. Questions and exact settings withheld during learning.", "transfer_distribution": "Two operations within the stated duration; varied rotation axes and angles or operations defined by legal smooth reference pulses. Exact targets withheld during learning.", "payload_format": "typed_object", "scoring": "Each task earns integer points: <90%=0, 90% to <99%=1, 99% to <99.9%=2, 99.9% to <99.99%=3, 99.99% to <99.999%=4, >=99.999%=5. Five is the maximum. No points for unused shots or early completion. Prediction and new-operation fidelities are averaged within their task before converting to points.", "shot_time": "Time is measured from the start of the current shot, starting at zero.", "target_loading": "Known control: target=card[\"target\"]. New control after reveal: target=card[\"targets\"][j]. Load V=np.asarray(target[\"unitary_real\"])+1j*np.asarray(target[\"unitary_imag\"]). For a channel, use choi_real and choi_imag in the same way. The supplied imaginary array already includes its signs.", "phases": { "learning": { "phase": "learning", "measurements_available": true, "task": "Learn once; submit the known-control waveform and a tested executable predictor." }, "transfer": { "phase": "transfer", "measurements_available": false, "task": "Use frozen learning files; no further measurements." } }, "public_numerical_checks": { "purpose": "Shared worked tutorial tasks and convention checks; not a model of your device.", "worked_tasks": { "scope": "These are complete tutorial tasks, separate from your device. Their true coefficients and solutions are disclosed only to explain conventions, submissions and scoring. They are not measurements or reference pulses for your scored task.", "white_box": { "title": "White-box control with a known coefficient", "given": "H(t)=0.3*u(t)*X, one knob u in [-1,1], duration <=4, at most 10 flat segments. There is no extra factor of 1/2. The coefficient is supplied in this tutorial; benchmark white-box calibration can require estimating coefficients.", "target": { "description": "Rx(pi/2) = exp(-i*pi*X/4)", "rotation_angle_radians": 1.5707963267948966, "rotation_axis": [ 1, 0, 0 ], "unitary_real": [ [ 0.7071067811865475, 0 ], [ 0, 0.7071067811865475 ] ], "unitary_imag": [ [ 0, -0.7071067811865475 ], [ -0.7071067811865475, 0 ] ] }, "submissions": [ { "description": "Constant amplitude 0", "answer": { "waveform": { "kind": "piecewise", "durations": [ 2.6179938779914944 ], "values": [ [ 0 ] ] }, "predictor": "predictor.py" }, "fidelity": 0.5, "points": 0 }, { "description": "Constant amplitude 0.8", "answer": { "waveform": { "kind": "piecewise", "durations": [ 2.6179938779914944 ], "values": [ [ 0.8 ] ] }, "predictor": "predictor.py" }, "fidelity": 0.9755282581475768, "points": 1 }, { "description": "Constant amplitude 0.9", "answer": { "waveform": { "kind": "piecewise", "durations": [ 2.6179938779914944 ], "values": [ [ 0.9 ] ] }, "predictor": "predictor.py" }, "fidelity": 0.9938441702975689, "points": 2 }, { "description": "Constant amplitude 1", "answer": { "waveform": { "kind": "piecewise", "durations": [ 2.6179938779914944 ], "values": [ [ 1 ] ] }, "predictor": "predictor.py" }, "fidelity": 1.0, "points": 5 }, { "description": "Three segments, amplitudes 1, 0.5, 1", "answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0471975511965976, 1.0471975511965976, 1.0471975511965976 ], "values": [ [ 1 ], [ 0.5 ], [ 1 ] ] }, "predictor": "predictor.py" }, "fidelity": 1.0, "points": 5 } ], "explanation": "For a two-level unitary target V, fidelity is |Tr(V^dagger U)|^2/4. For the three-segment pulse, 0.3*sum(u_j*duration_j)=0.3*(pi/3)*(1+0.5+1)=pi/4, so U equals the target. All segments here have the same generator X; in general different generators do not commute and segments must be propagated in order. Fidelity 1 earns five points, not one point.", "new_control": { "given": "After learning, two targets are revealed in this order: Rx(pi/2), Rx(pi/4). The same known toy Hamiltonian applies.", "answer": { "waveforms": [ { "kind": "piecewise", "durations": [ 1.0471975511965976, 1.0471975511965976, 1.0471975511965976 ], "values": [ [ 1 ], [ 0.5 ], [ 1 ] ] }, { "kind": "piecewise", "durations": [ 1.3089969389957472 ], "values": [ [ 1 ] ] } ] }, "per_target_fidelities": [ 1.0, 1.0 ], "mean_fidelity": 1.0, "points": 5 } }, "gray_box": { "title": "Gray-box control with an omitted Z term", "given": "Nominal H0(t)=u(t)*X+v(t)*Z. Knob order [u,v], each in [-1,1], duration <=4, at most 10 flat segments. Target Rx(pi/2). The actual device differs from the nominal model.", "target": { "description": "Rx(pi/2) = exp(-i*pi*X/4)", "rotation_angle_radians": 1.5707963267948966, "rotation_axis": [ 1, 0, 0 ], "unitary_real": [ [ 0.7071067811865475, 0 ], [ 0, 0.7071067811865475 ] ], "unitary_imag": [ [ 0, -0.7071067811865475 ], [ -0.7071067811865475, 0 ] ] }, "worked_solution_truth": "Actual H(t)=u(t)*X+(v(t)+1)*Z. This equation is disclosed for the worked solution only; the entrant in a scored gray-box task is not given its missing physics.", "submissions": [ { "description": "Follow the nominal model: u=1, v=0", "answer": { "waveform": { "kind": "piecewise", "durations": [ 0.7853981633974483 ], "values": [ [ 1, 0 ] ] }, "predictor": "predictor.py" }, "fidelity": 0.5806075459013483, "points": 0 }, { "description": "Compensate the extra Z term: u=1, v=-1", "answer": { "waveform": { "kind": "piecewise", "durations": [ 0.7853981633974483 ], "values": [ [ 1, -1 ] ] }, "predictor": "predictor.py" }, "fidelity": 1.0, "points": 5 } ], "explanation": "At v=0 the actual Hamiltonian is X+Z. At v=-1 it is X, so a pulse lasting pi/4 implements the target. This illustrates a possible discrepancy; it does not prescribe a discovery method or the form of other tasks' discrepancies." }, "prediction": { "title": "Predict probabilities, rather than a particular random count", "given": "Known toy H(t)=0.3*u(t)*X. One prediction question: prepare 0, apply u=1 for duration 1, measure Z. Outcome order [0,1].", "experiment": { "waveform": { "kind": "piecewise", "durations": [ 1 ], "values": [ [ 1 ] ] }, "preparation": "0", "measurement": "Z" }, "true_probabilities": [ 0.9126678074548391, 0.08733219254516084 ], "possible_100_shot_counts": [ 92, 8 ], "explanation": "The exact probabilities are [cos(0.3)^2,sin(0.3)^2]. Counts [92,8] are one possible sample, not a deterministic response or a promised observation. Prediction fidelity is (sum_i sqrt(p_i*q_i))^2 against the true probabilities. With several questions, average their fidelities before converting to points.", "predictor_outputs": [ { "description": "Predict from the known model", "fidelity": 1.0, "points": 5, "predictor_return": [ [ 0.9126678074548391, 0.08733219254516084 ] ] }, { "description": "Use frequencies from the illustrative 100-shot sample", "fidelity": 0.9998246213441915, "points": 3, "predictor_return": [ [ 0.92, 0.08 ] ] } ] }, "submission_repair": { "title": "Reject, repair, submit; acceptance ends the phase", "given": "Use the white-box tutorial above and its one-knob waveform format.", "rejected_answer": { "waveform": { "kind": "piecewise", "durations": [ 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684, 0.1636246173744684 ], "values": [ [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ], [ 1 ] ] }, "predictor": "predictor.py" }, "error": "waveform: Too many segments: received 16; maximum is 10", "corrected_answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0471975511965976, 1.0471975511965976, 1.0471975511965976 ], "values": [ [ 1 ], [ 0.5 ], [ 1 ] ] }, "predictor": "predictor.py" }, "explanation": "The 16-segment waveform is illegal despite matching the toy target. A rejection spends an action but no shots and leaves learning open. Repair the waveform, save and check a predictor, then submit both. Acceptance ends learning immediately; no finish action or accuracy feedback is provided. The score here is a public toy worked solution." }, "joint_readout": { "outcome_order": [ "0|0", "0|1", "1|0", "1|1" ], "counts": [ 30, 20, 40, 10 ], "explanation": "These are 100 joint raw shots. First-subsystem counts are [50,50]; second-subsystem counts are [70,30]. Keep all four entries when predicting the joint distribution. For X|Z with order [+|0,+|1,-|0,-|1], both [100,0,0,0] and [0,100,0,0] mean the first subsystem was always measured plus." } }, "worked_tasks_python": "# Standalone tutorial calculations: no private simulator imports.\nimport numpy as np\nfrom scipy.linalg import expm\nX=np.array([[0,1],[1,0]],complex)\nZ=np.diag([1,-1]).astype(complex)\nV=expm(-1j*np.pi*X/4)\ndef fidelity(U,V): return float(abs(np.trace(V.conj().T@U))**2/4)\ndef evolve(waveform,hamiltonian):\n U=np.eye(2,dtype=complex)\n for duration,values in zip(waveform['durations'],waveform['values']):\n U=expm(-1j*duration*hamiltonian(values))@U\n return U\nwhite_fidelities=[fidelity(expm(-1j*.3*u*X*(5*np.pi/6)),V) for u in [0,.8,.9,1]]\nmulti={'kind':'piecewise','durations':[np.pi/3]*3,'values':[[1],[.5],[1]]}\nmulti_fidelity=fidelity(evolve(multi,lambda a:.3*a[0]*X),V)\ngray_fidelities=[fidelity(expm(-1j*np.pi/4*(X+(v+1)*Z)),V) for v in [0,-1]]\np=np.array([np.cos(.3)**2,np.sin(.3)**2])\nprediction_fidelity=float(np.sum(np.sqrt(p*np.array([.92,.08])))**2)\nassert np.allclose(white_fidelities,[.5,.9755282581475768,.9938441702975689,1])\nassert abs(multi_fidelity-1)<1e-12\nassert np.allclose(gray_fidelities,[.5806075459013483,1])\nassert abs(prediction_fidelity-.9998246213441915)<1e-12\n", "runnable_python": "# Public toy model only: H=u X/2, with known gain 1 and no detuning.\nimport numpy as np\nfrom scipy.linalg import expm\nX=np.array([[0,1],[1,0]],complex)\nU=expm(-1j*np.pi*X/4) # u=1 for duration pi/2\nV=(np.eye(2)-1j*X)/np.sqrt(2)\nF=abs(np.trace(V.conj().T@U))**2/4\nassert abs(F-1)<1e-12\nassert abs(abs(U[1,0])**2-0.5)<1e-12\n# Chronological pulses multiply on the LEFT: U_total=U_last @ ... @ U_first.\n# Global phase does not matter; matching one input state is insufficient.\nassert abs(abs(np.trace((1j*V).conj().T@U))**2/4-1)<1e-12\nZ=np.diag([1,-1]); assert abs(np.trace(Z))**2/4==0\n# Identity and Z act identically on |0> up to phase, but process fidelity is 0.\n", "channel_example": { "title": "A noisy channel, with a trace-one Choi state", "given": "Public toy: H=pi*u*Z/2, u in [-1,1], duration exactly 1, and gamma*D[Z] with gamma=log(2)/2. Target: the operation with u=0. This is an unrelated known model.", "choi_convention": "J=(I tensor E)(|Phi>=sum_j |j,j>/sqrt(d); input tensor output order. J has trace one. Do not divide the supplied Choi target by d again.", "target_choi_real": [ [ 0.5, 0, 0, 0.25 ], [ 0, 0, 0, 0 ], [ 0, 0, 0, 0 ], [ 0.25, 0, 0, 0.5 ] ], "target_choi_imag": [ [ 0, 0, 0, 0 ], [ 0, 0, 0, 0 ], [ 0, 0, 0, 0 ], [ 0, 0, 0, 0 ] ], "objective": "F=(Tr sqrt(sqrt(J_target) J_actual sqrt(J_target)))^2, squared Uhlmann fidelity.", "submissions": [ { "answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0 ], "values": [ [ 0.0 ] ] } }, "fidelity": 1.0, "points": 5 }, { "answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0 ], "values": [ [ 0.1 ] ] } }, "fidelity": 0.9938820645368942, "points": 2 }, { "answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0 ], "values": [ [ 0.3333333333333333 ] ] } }, "fidelity": 0.9375, "points": 1 }, { "answer": { "waveform": { "kind": "piecewise", "durations": [ 1.0 ], "values": [ [ 1.0 ] ] } }, "fidelity": 0.75, "points": 0 } ], "explanation": "The transverse coherence is exp(-2*gamma)=1/2. The actual Choi off-diagonal entry is exp(-i*pi*u)/4. Its fidelity to the idle target is 1-sin(pi*u/2)^2/4. Matching a noisy channel still earns five points; its purity need not be one." }, "basis_and_channel_python": "# Public convention checks only; no private simulator imports.\nimport numpy as np\nfrom scipy.linalg import expm\ndef unit_vector(psi):\n psi=np.asarray(psi,complex)\n assert psi.ndim==1 and np.all(np.isfinite(psi)), 'Expected a finite state vector'\n assert np.isclose(np.vdot(psi,psi),1,atol=1e-12,rtol=0), 'Preparation must have norm one'\ndef orthonormal_basis(B):\n B=np.asarray(B,complex) # columns are measurement vectors\n assert B.ndim==2 and B.shape[0]==B.shape[1], 'Expected a complete square basis'\n assert np.allclose(B.conj().T@B,np.eye(B.shape[1]),atol=1e-12,rtol=0), 'Measurement vectors must be orthonormal'\nplus_i=np.array([1,1j])/np.sqrt(2)\nB_Y=np.column_stack([plus_i,np.array([1,-1j])/np.sqrt(2)])\nunit_vector(plus_i); orthonormal_basis(B_Y)\n# [1,1j] has norm sqrt(2); pairing Y+ with X- is not an orthonormal basis.\ndef psd_root(A):\n assert np.allclose(A,A.conj().T,atol=1e-12,rtol=0), 'Expected Hermitian matrix'\n vals,vecs=np.linalg.eigh(A)\n assert vals.min()>=-1e-12, 'Expected positive semidefinite matrix'\n return (vecs*np.sqrt(np.maximum(vals,0)))@vecs.conj().T\ndef choi_fidelity(A,B):\n for J in (A,B):\n assert np.isclose(np.trace(J),1,atol=1e-12,rtol=0), 'Choi state must have trace one'\n psd_root(J)\n # Equivalent root-product singular values avoid a second square root of\n # nearly zero eigenvalues for rank-deficient Choi states.\n F=float(np.linalg.svd(psd_root(A)@psd_root(B),compute_uv=False).sum()**2)\n return min(1.,F) # remove numerical overshoot only after physical-state checks\ndef toy_choi(u):\n J=np.zeros((4,4),complex);J[0,0]=J[3,3]=.5\n J[0,3]=np.exp(-1j*np.pi*u)/4;J[3,0]=J[0,3].conjugate()\n return J\nJ=toy_choi(0.)\nfor u in (0.,.1,1/3,1.):\n assert abs(choi_fidelity(J,toy_choi(u))-(1-.25*np.sin(np.pi*u/2)**2))<1e-10\nphi=np.array([1,0,0,1],complex)/np.sqrt(2);identity_choi=np.outer(phi,phi.conj())\nassert abs(choi_fidelity(identity_choi,np.eye(4)/4)-.25)<1e-10 # root fidelity would be .5\n", "outcome_order_example": "Four-level toy: measurement X0:2 orders outcomes as (|0>+|2>)/sqrt(2), (|0>-|2>)/sqrt(2), |1>, |3>. For their probabilities 0.1,0.2,0.3,0.4, submit [0.1,0.2,0.3,0.4]. Other levels remain separate outcomes, subject to the stated overflow rule.", "predictor_return_example": [ [ 0.25, 0.75 ], [ 0.6, 0.4 ] ] } }