Support challenger training and support continous sampling - #280
Merged
Conversation
- config.py: E13 executor_thinking='off' to match the SEAM paper run - run_ablate12.sh: dedicated E13 block (min_level=0 full pool, chunk=128, reward-trunc-penalty=0, eval R=1/T=0) reproducing the SEAM run config - include the code-task/reflexion pipeline modules E13 imports at load time (main/trainer top-level import code_task/data_code/eval_reflexion)
…form) - train_skill_v2.py: SKILL_GEN_FREEFORM/REGEN_FREEFORM_SYSTEM (a 'menu' prompt letting the skill model choose whatever form helps this problem — analysis, concept, pitfall, tiny example, blunt directive, even 'let's think step by step'), wired into style dispatch + --skill-style choices; the freeform prompt carries <skills></skills> wrapper examples so open-form outputs stay parseable - config.py: E21 = bnpo/view-B/freeform (thinking on; see comment for why not off), STYLES + RUN_ORDER updated, self-check passes - trainer.py: freeform shares narrative's 1100-char len budget
The BNPO family returned an already-normalized per-group token-mean with num_tokens=0, so the framework's PER-TOKEN-MEAN path equal-weighted micro/dp groups -> a double average (group token-mean, then equal weight over groups) that sits between token-mean and sequence-mean and biases toward short responses (degrades to pure sequence-mean as groups multiply). This diverged from verl/SEAM's true token-mean and was non-orthogonal to skill-length study. - grpo.py: BNPOLoss gains token_mean_scope='global'(default)|'micro'. 'global' returns the token SUM and reports num_tokens=sum(mask), routing into the framework SUM-loss path -> exact global token-mean, invariant to how the batch is split. 'micro' preserves the old behavior to reproduce E1-E20. Added a _loss_num_tokens hook (default 0) so GRPO/DRGRPO/OPSD are untouched. No public interface change; downstream grad + metric already branch on num_tokens. - tests/loss/test_bnpo_token_mean.py: assert global is split-invariant (==true token-mean), micro reproduces the biased double-average, SEAM inherits global. - run_ablate12.sh: E13(140G)/E21(80G) OOM'd in train forward at micro=8; set per-arm train_micro_batch defaults (E13=2xdp, E21=1xdp). The global token-mean fix makes shrinking micro mathematically equivalent, so effective batch and comparability are unchanged.
E13/E21 blocks referenced $TRAIN_MICRO_BATCH directly; under set -u an unset
env aborts with 'unbound variable'. Use ${TRAIN_MICRO_BATCH:-}.
…kers - sanitize sys.argv around LLMAgent construction: ms-agent's Config.parse_args() mis-parses a foreign argv in forked/Ray workers (assert crash on value tokens; silent flag mispairing otherwise) - tolerate ms-agent >= 1.6.0 API changes: prepare_skills -> _ensure_auto_skills(), dropped ms_agent.hooks and _append_task_notifications, defensive ToolResult field forwarding
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.
PR type
PR information
Features
challenger/{base,agentic,recorder}).agents/{base,ms_agent}).harness/*).verifier/{result_check,rubric_score}).condenser/,chunker/,data_format/chunks).rollout/{endpoint,external,ledger,trace}; removesapi_multi_turn/bridge/multi_turn_condense).envs/{localenv,snapshot}).utils/*).loss/opsd).template/tools/bracket_dsl).score_filter/llm_backend).protocol/api_sampler)..base_layer.suffix + fusedin_proj_qkvzmapping).flash_attention_2for padding-free training.Experiment results
Paste your experiment result here(if needed).