Views
No views yet
ac1. Checkpoint saved
after training step 5 (0-indexed). Strict upstream eval parity:
1100s hard kill, verbatim prompts/entrypoints, group 64x8, T=1.0, kl 0.1.1{
2 "step": 5,
3 "progress/batch": 5,
4 "optim/lr": 4e-05,
5 "progress/done_frac": 0.12,
6 "puct/buffer_size": 88,
7 "puct/sampled_size": 8,
8 "puct/T": 2560,
9 "puct/scale_last": 0.49065503849825043,
10 "puct/buffer_value/mean": -1.6019334124842153,
11 "puct/buffer_value/std": 0.17053265871355056,
12 "puct/buffer_value/min": -2.000000000000007,
13 "puct/buffer_value/max": -1.5076054414762505,
14 "puct/buffer_timestep/mean": 1.7272727272727273,
15 "puct/buffer_timestep/std": 1.6006197146962735,
16 "puct/buffer_timestep/min": -1.0,
17 "puct/buffer_timestep/max": 4.0,
18 "puct/buffer_construction_len/mean": 1681.7045454545455,
19 "puct/buffer_construction_len/std": 1642.7048451140445,
20 "puct/buffer_construction_len/min": 1000.0,
21 "puct/buffer_construction_len/max": 7850.0,
22 "puct/sampled_value/mean": -1.5090348229467647,
23 "puct/sampled_value/std": 0.000864461989922133,
24 "puct/sampled_value/min": -1.5100597321557812,
25 "puct/sampled_value/max": -1.5076054414762505,
26 "puct/sampled_timestep/mean": 4.0,
27 "puct/sampled_timestep/std": 0.0,
28 "puct/sampled_timestep/min": 4.0,
29 "puct/sampled_timestep/max": 4.0,
30 "puct/sampled_construction_len/mean": 1000.0,
31 "puct/sampled_construction_len/std": 0.0,
32 "puct/sampled_construction_len/min": 1000.0,
33 "puct/sampled_construction_len/max": 1000.0,
34 "time/sampling": 5202.446753025055,
35 "env/all/ac_tokens_per_turn": 7893.9921875,
36 "env/all/ob_tokens_per_turn": 3088.625,
37 "env/all/turns_per_episode": 1.0,
38 "env/all/total_episodes": 512,
39 "env/all/total_turns": 512,
40 "env/all/total_ac_tokens": 4041724,
41 "env/all/total_ob_tokens": 1581376,
42 "env/all/time/sampling_mean": 268.36550004966557,
43 "env/all/time/sampling_max": 357.61747646331787,
44 "env/all/time/env_step_mean": 2372.3606091151014,
45 "env/all/time/env_step_max": 4859.858417034149,
46 "env/all/reward/mean": 0.517184078576022,
47 "env/all/reward/max": 0.6637664907833943,
48 "env/all/reward/min": 0.0,
49 "env/all/format": 1.0,
50 "env/all/format/min": 1.0,
51 "env/all/format/max": 1.0,
52 "env/all/reward": 0.517184078576022,
53 "env/all/correctness": 0.822265625,
54 "env/all/correctness/min": 0.0,
55 "env/all/correctness/max": 1.0,
56 "env/all/raw_score": 2.0384214227450492,
57 "env/all/raw_score/min": 1.5065538969617303,
58 "env/all/raw_score/max": 182.294046045213,
59 "env/all/initial_raw_score": -1.5090348229467647,
60 "env/all/initial_raw_score/min": -1.5100597321557812,
61 "env/all/initial_raw_score/max": -1.5076054414762505,
62 "env/all/msg": "Success; raw_score=1.5075904306659045",
63 "env/all/parsed_code": "```python\nimport time\nimport numpy as np\nfrom scipy import optimize\nimport copy\nimport random\n\nlinprog = optimize.linprog\n\ndef get_good_direction_to_move_into(sequence):\n \"\"\"Enhanced direction finding with better line search and constraint management.\"\"\"\n n = len(sequence)\n if n == 0:\n return None\n\n sum_seq = np.sum(sequence)\n if sum_seq <= 0.0:\n return None\n\n # Normalize sequence\n normalized_seq = [x * np.sqrt(2 * n) / sum_seq for x in sequence]\n conv = np.convolve(normalized_seq, normalized_seq)\n max_b = np.max(conv)\n\n # Solve LP with refined constraint selection and enhanced convergence\n g_fun = solve_convolution_lp(normalized_seq, max_b)\n if g_fun is None:\n return None\n\n sum_g = np.sum(g_fun)\n if sum_g <= 0.0:\n return None\n\n # Normalize g_fun\n normalized_g = [x * np.sqrt(2 * n) / sum_g for x in g_fun]\n\n # Enhanced line search with more iterations and adaptive refinement\n best_t = 0.0\n best_score = float('inf')\n t_low, t_high = 0.0, 1.0\n search_range = 100 # Increased for thorough exploration\n\n for _ in range(search_range):\n t = (t_low + t_high) / 2\n new_sequence = [(1 - t) * x + t * y for x, y in zip(sequence, normalized_g)]\n try:\n curr_score = evaluate_sequence(new_sequence)\n if curr_score < best_score:\n best_score = curr_score\n best_t = t\n # Aggressive refinement based on improvement\n if curr_score < best_score * 0.9:\n t_low = best_t\n else:\n t_high = best_t\n else:\n t_high = best_t\n except Exception as e:\n print(f\"Line search failed: {e}\")\n break\n\n # Additional local refinement around the best t\n for t in np.linspace(best_t - 0.01, best_t + 0.01, 5):\n new_sequence = [(1 - t) * x + t * y for x, y in zip(sequence, normalized_g)]\n try:\n curr_score = evaluate_sequence(new_sequence)\n if curr_score < best_score:\n best_score = curr_score\n best_t = t\n except Exception as e:\n print(f\"Refinement failed: {e}\")\n\n return [(1 - best_t) * x + best_t * y for x, y in zip(sequence, normalized_g)]\n\ndef solve_convolution_lp(f_sequence, rhs):\n \"\"\"Solves LP with optimized constraint handling.\"\"\"\n n = len(f_sequence)\n if n == 0:\n return None\n\n # Only apply constraints at top 50 max positions to reduce complexity\n conv = np.convolve(f_sequence, f_sequence)\n max_positions = np.argsort(conv)[::-1][:50] # Top 50 positions\n\n a_ub = []\n b_ub = []\n for k in max_positions:\n row = np.zeros(n)\n for i in range(n):\n j = k - i\n if 0 <= j < n:\n row[j] = f_sequence[i]\n a_ub.append(row)\n b_ub.append(rhs)\n\n # Non-negativity constraints\n a_ub_nonneg = -np.eye(n)\n b_ub_nonneg = np.zeros(n)\n a_ub = np.vstack([a_ub, a_ub_nonneg])\n b_ub = np.hstack([b_ub, b_ub_nonneg])\n\n # Solve with optimized solver\n result = linprog(\n c=-np.ones(n),\n A_ub=a_ub,\n b_ub=b_ub,\n bounds=[(0, 1000.0) for _ in range(n)],\n method='highs',\n options={\n \"time_limit\": 30.0, # Limited time for LP to balance computation\n \"disp\": False,\n },\n )\n if result.success:\n return result.x\n return None\n\ndef propose_candidate(seed=42, budget_s=1000, **kwargs):\n \"\"\"\n Iteratively improves the sequence using a combination of \n advanced LP-based search, targeted perturbation, and adaptive refinement.\n \"\"\"\n np.random.seed(seed)\n deadline = time.time() + budget_s - 10\n \n # Initialize with height_sequence_1 if available, or a structured starting point\n best_sequence = []\n if 'height_sequence_1' in globals():\n best_sequence = list(np.asarray(height_sequence_1, dtype=float))\n else:\n # Structured initialization to reduce random noise\n n = 1000\n base = np.sin(np.linspace(0, 2 * np.pi, n))**2 # Sin squared to balance values\n base += np.random.normal(0, 0.03, n) # Light noise to avoid symmetry\n base = np.clip(base, 0, 1000) # Clamp values to ensure non-negative\n best_sequence = [max(0.0, x) for x in base]\n \n current_sequence = best_sequence.copy()\n best_score = evaluate_sequence(best_sequence)\n improved = True\n\n # Adaptive Perturbation Strategy\n def targeted_perturb(seq):\n conv = np.convolve(seq, seq)\n max_positions = np.argsort(conv)[::-1][:50] # Top 50 positions\n involved_elements = set()\n for k in max_positions:\n for i in range(len(seq)):\n j = k - i\n if 0 <= j < len(seq):\n involved_elements.add(i)\n involved_elements.add(j)\n if not involved_elements:\n return perturb_sequence(seq)\n # Select 2 random elements from involved positions\n idxs = np.random.choice(list(involved_elements), size=2, replace=False)\n perturbation = np.random.normal(0, 0.1) * 0.3 # Larger perturbation\n new_vals = [max(0.0, seq[i] + perturbation) if i in idxs else seq[i] for i in range(len(seq))]\n return new_vals\n \n def perturb_sequence(seq):\n # Small random perturbation\n idx = np.random.choice(len(seq))\n perturbation = np.random.normal(0, 0.05) * 0.2\n new_val = max(0.0, seq[idx] + perturbation)\n return [new_val if i == idx else seq[i] for i in range(len(seq))]\n\n # Main optimization loop\n while time.time() < deadline and improved:\n print(f\"Current best score: {best_score}\")\n improved = False\n\n # Attempt to move in direction found by LP\n h_function = get_good_direction_to_move_into(current_sequence)\n if h_function is not None:\n current_sequence = h_function\n try:\n curr_score = evaluate_sequence(current_sequence)\n if curr_score < best_score:\n best_score = curr_score\n best_sequence = current_sequence.copy()\n print(f\"New best: {best_score}\")\n improved = True\n except Exception as e:\n print(f\"LP move failed: {e}\")\n pass\n else:\n # Fallback to targeted perturbation\n current_sequence = targeted_perturb(current_sequence)\n try:\n curr_score = evaluate_sequence(current_sequence)\n if curr_score < best_score:\n best_score = curr_score\n best_sequence = current_sequence.copy()\n print(f\"New best (perturbed): {best_score}\")\n improved = True\n except Exception as e:\n print(f\"Perturb move failed: {e}\")\n\n # Occasionally perform random walk to escape local minima\n if np.random.random() < 0.01:\n current_sequence = perturb_sequence(current_sequence)\n try:\n curr_score = evaluate_sequence(current_sequence)\n if curr_score < best_score:\n best_score = curr_score\n best_sequence = current_sequence.copy()\n print(f\"Random walk improvement: {best_score}\")\n improved = True\n except Exception as e:\n print(f\"Random walk failed: {e}\")\n\n return [float(max(0.0, x)) for x in best_sequence]\n```",
64 "env/all/time/policy": 268.36550004966557,
65 "env/all/time/policy/min": 82.24529147148132,
66 "env/all/time/policy/max": 357.61747646331787,
67 "env/all/time/env_step": 2372.3606091151014,
68 "env/all/time/env_step/min": 0.006169557571411133,
69 "env/all/time/env_step/max": 4859.858417034149,
70 "env/all/time/reward_compute": 5.690380930900574e-07,
71 "env/all/time/reward_compute/min": 2.384185791015625e-07,
72 "env/all/time/reward_compute/max": 1.948326826095581e-06,
73 "env/all/by_group/frac_mixed": 1.0,
74 "env/all/by_group/frac_all_good": 0.0,
75 "env/all/by_group/frac_all_bad": 0.0,
76 "advantage/mean": 0.032571692019701004,
77 "advantage/min": -1.0,
78 "advantage/max": 18.095386505126953,
79 "time/assemble_training_data": 5.410034418106079,
80 "time/kl_vs_base": 79.97823452949524,
81 "kl_policy_base": 0.0007479360210709274,
82 "time/train": 520.8218171596527,
83 "time/save_checkpoint": 18.684879779815674,
84 "time/total": 5829.108736276627
85}[2026-07-09T06:24:18+00:00] job=1812630 node=node-14 ngpu=3 ntrain=1 replicas=2 flash_attn=no
[2026-07-09T09:14:17+00:00] job=1813129 node=node-28 ngpu=3 ntrain=1 replicas=2 flash_attn=yes
[2026-07-09T13:46:36+00:00] job=1813130 node=node-22 ngpu=6 ntrain=2 replicas=4 flash_attn=yes