kavin57447 commited on
Commit
ee5ddee
·
1 Parent(s): e9dea07

Hackathon speedrun: max_new_tokens=32, seq_len=512 for 4-8x faster iterations

Browse files
Files changed (1) hide show
  1. cloud_arena/llm_training.py +2 -2
cloud_arena/llm_training.py CHANGED
@@ -28,8 +28,8 @@ DEVICE = "cuda" if torch.cuda.is_available() else "cpu"
28
 
29
  # ── GPU Optimization Constants ────────────────────────────────────────────────
30
  GRAD_ACCUM_STEPS = 4 # accumulate gradients over N episodes before stepping
31
- MAX_SEQ_LEN = 1024 # longer context = more GPU work per forward pass
32
- MAX_GEN_TOKENS = 256 # more generation tokens per step
33
 
34
 
35
  def format_prompt(state_dict):
 
28
 
29
  # ── GPU Optimization Constants ────────────────────────────────────────────────
30
  GRAD_ACCUM_STEPS = 4 # accumulate gradients over N episodes before stepping
31
+ MAX_SEQ_LEN = 512 # shorter context = O(N²) attention is faster than 1024
32
+ MAX_GEN_TOKENS = 32 # force brief output just need the ACTION line, not essays
33
 
34
 
35
  def format_prompt(state_dict):