Research log Small Model Experimentation
GitHub

Counterfactual Episodic ICL Posttraining

Contradictory examples teach a model to read its

The one idea you need

Picture flashcards where the very same word demands a different answer in each deck, so memorizing never pays off — the only way to score is to first read that deck's example pairs. Training on such deliberately contradictory decks forces the model to read the prompt's examples.

The question

If you train a small model on made-up tasks where the same input can demand opposite answers, does it learn to actually read the examples instead of guessing?

What we found

Yes. Untrained, a 4-billion-parameter model solved 23% of real text-transformation tasks perfectly; after this training, 57% — but only when it could see the prompt's examples. Scramble those examples and it fell to 17%, below where it started; remove them and it collapsed to about 3%. The entire gain lives in reading the examples, not memorizing a familiar transformation.

Why it matters

To make a small model obey in-context examples instead of falling back on a familiar guess, train it on example sets whose answers can only come from the examples — and always retest with the examples shuffled or removed; real conditioning makes accuracy crater.

Real tasks solved perfectly23% → 57%public text-transformation tasks, untrained vs trained (examples shown)
Made-up tasks solved perfectly25% → 92%unseen contradictory tasks, untrained vs trained
Trained, but examples scrambledback to 17%real tasks — below the 23% untrained level
Trained, but examples removedabout 3%real tasks collapse without any demonstrations
On this page
  1. Results at a glance
  2. Overview
  3. Report
    1. Question
    2. Setup
    3. Main Result
    4. Interpretation
    5. Charts
    6. Task-Level Details
    7. Error Examples
    8. Artifacts
    9. Limitations
  4. Experiment log
  5. Figures
  6. Data files
  7. Reproduce
  8. Related

Results at a glance 4

Whole-task accuracy across four example conditions

How to read

Bars show the share of tasks solved completely correctly; taller is better. Four conditions along the bottom: untrained with examples, trained with examples, trained with scrambled examples, trained with no examples. One color is made-up unseen tasks, the other real public tasks.

0%25%50%75%100%base + supportbase + support25%23.3%adapter + supportadapter + support91.7%56.7%adapter + shuffled supportadapter + shuffled support31.7%16.7%adapter, no supportadapter, no support1.7%3.3%

Takeaway → Trained-with-examples towers over every other bar; scrambling or removing the examples crashes accuracy to near or below the untrained level — winning requires reading the examples.

Data table
conditionsynthetic held-out counterfactualpublic text-transformation tasks
base + support25%23.3%
adapter + support91.7%56.7%
adapter + shuffled support31.7%16.7%
adapter, no support1.7%3.3%

Numbers from runs/main_v2/summary.csv

Technical framing

Full-task exact match: counterfactual-episode LoRA vs base — The adapter learns to read the support examples: 25%→92% held-out and 23%→57% public, and it collapses when support is shuffled or removed.

Per-line accuracy under the same four conditions

How to read

Bars show the share of individual output lines matched exactly, not whole tasks; taller is better. Same four conditions and same two task groups — made-up unseen versus real public — as the whole-task chart.

0%25%50%75%100%base + supportbase + support41.7%44.4%adapter + supportadapter + support95%73.3%adapter + shuffled supportadapter + shuffled support43.3%33.3%adapter, no supportadapter, no support3.3%10%

Takeaway → The looser per-line scoring shows the identical shape: big gains only when correct examples are present, confirming genuine example-reading rather than an artifact of strict all-or-nothing scoring.

Data table
conditionsynthetic held-out counterfactualpublic text-transformation tasks
base + support41.7%44.4%
adapter + support95%73.3%
adapter + shuffled support43.3%33.3%
adapter, no support3.3%10%

Numbers from runs/main_v2/summary.csv

Technical framing

Row-level exact match under the same conditions — Per-row accuracy shows the same pattern as strict full-task scoring: gains come from support conditioning, not a memorized task prior.

Training error falls fast and stays low

How to read

A single line traces the model's training error (vertical) against training step from 1 to 120 (horizontal); lower is better. Only the model's answer tokens are scored during training, not the prompt examples.

0246850100training loss

Takeaway → Error plunges from about 7 to near zero within roughly 40 steps, then stays flat — the model masters the contradictory tasks quickly and cheaply.

Data table
training steptraining loss
17.09
105.97
200.947
300.159
400.327
500.124
600.169
700.158
800.032
900.0104
1000.122
1100.0609
1200.0496

Numbers from runs/main_v2/training_log.csv

Technical framing

LoRA training loss (main_v2, 120 steps) — Answer-only loss on counterfactual episodes converges within ~40 steps of the 120-step run.

More training tasks lift transfer to real tasks

How to read

Whole-task accuracy bars; taller is better. Groups pair each task set — made-up unseen and real public — across a smaller 240-task run and the larger 800-task run. Three colors: untrained, trained with examples, trained with scrambled examples.

0%25%50%75%100%Synthetic held-out — pilot_v1Synthetic held-out — pilot_v118.8%93.8%43.8%Synthetic held-out — main_v2Synthetic held-out — main_v225%91.7%31.7%Public PROSE — pilot_v1Public PROSE — pilot_v112.5%37.5%37.5%Public PROSE — main_v2Public PROSE — main_v223.3%56.7%16.7%

Takeaway → Going from 240 to 800 training tasks raises real-task accuracy from 38% to 57% and deepens the drop under scrambled examples — stronger, more genuine example-reading.

Data table
Eval split and runBase, normal supportAdapter, normal supportAdapter, shuffled support
Synthetic held-out — pilot_v118.8%93.8%43.8%
Synthetic held-out — main_v225%91.7%31.7%
Public PROSE — pilot_v112.5%37.5%37.5%
Public PROSE — main_v223.3%56.7%16.7%

Numbers from experiments/qwen_counterfactual_episodic_icl/runs/pilot_v1/summary.csv; runs/main_v2/summary.csv

Technical framing

Training scale: full-task exact match, pilot (240 episodes) vs main (800 episodes) — Scaling 240 to 800 train episodes lifts public transfer and makes shuffled support hurt more, evidence of real support conditioning.

In the author’s words from the Report · “Interpretation”

On held-out synthetic counterfactual episodes, the adapter changes full-task exactness from 25.0% to 91.7%. With shuffled support examples, the adapter scores 31.7%. On the public text-transformation sample, the adapter changes full-task exactness from 23.3% to 56.7%. With shuffled support examples, the adapter scores 16.7%. The synthetic split shows a real support-conditioning effect: performance improves and shuffled support degrades it. The public split determines whether that learned behavior transfers outside the synthetic generator. The public benchmark transfer is positive at the tested scale.

Overview

This standalone experiment tests whether answer-only LoRA posttraining on counterfactual few-shot episodes improves Qwen's ability to infer a text transformation from support examples.

The training data is synthetic and deliberately counterfactual: the same input style can require incompatible outputs depending on the examples in the prompt. Public benchmark examples are used only for evaluation.

Main Run

  • Run: main_v2
  • Model: Qwen/Qwen3-4B
  • Adapter: /workspace/large_artifacts/qwen_counterfactual_episodic_icl/checkpoints/main_v2/adapter
  • Synthetic held-out counterfactual full-task exact: base 25.0%, adapter 91.7%, adapter with shuffled support 31.7%.
  • Public text-transformation full-task exact: base 23.3%, adapter 56.7%, adapter with shuffled support 16.7%.

Artifacts

Report

Rendered from reports/qwen_counterfactual_episodic_icl_report.md

Question

Can answer-only LoRA posttraining on counterfactual few-shot episodes improve a 4B model's ability to infer a task from support examples, rather than relying on a task-family prior?

The training episodes are synthetic and deliberately counterfactual: the same kind of query input can require incompatible outputs depending on the support examples. Public benchmark outputs are used only for evaluation.

Setup

  • Run: main_v2
  • Model: Qwen/Qwen3-4B
  • Train episodes: 800
  • Train steps: 120
  • LoRA rank: 16
  • Synthetic eval counterfactual pairs: 30
  • Public PROSE tasks: 30
  • Elapsed seconds: 588.9

Main Result

methodsplitsupport_modetasksrowsrow_exactfull_task_exact
adapterpublic_prosenone309010.0%3.3%
adapterpublic_prosenormal309073.3%56.7%
adapterpublic_proseshuffled309033.3%16.7%
basepublic_prosenormal309044.4%23.3%
basepublic_proseshuffled309012.2%6.7%
adaptersynthetic_counterfactualnone601203.3%1.7%
adaptersynthetic_counterfactualnormal6012095.0%91.7%
adaptersynthetic_counterfactualshuffled6012043.3%31.7%
basesynthetic_counterfactualnormal6012041.7%25.0%
basesynthetic_counterfactualshuffled6012013.3%8.3%

Interpretation

On held-out synthetic counterfactual episodes, the adapter changes full-task exactness from 25.0% to 91.7%. With shuffled support examples, the adapter scores 31.7%. On the public text-transformation sample, the adapter changes full-task exactness from 23.3% to 56.7%. With shuffled support examples, the adapter scores 16.7%.

The synthetic split shows a real support-conditioning effect: performance improves and shuffled support degrades it. The public split determines whether that learned behavior transfers outside the synthetic generator. The public benchmark transfer is positive at the tested scale.

Charts

Strict full-task exact by method

Row exact versus full-task exact

Training loss

Adapter task flips versus base

Task-Level Details

methodsplitsupport_modetask_idfamilyrow_exactfull_task_exactrows
adapterpublic_prosenoneAddress.000014Address0.0%0.0%3
adapterpublic_prosenormalAddress.000014Address100.0%100.0%3
adapterpublic_proseshuffledAddress.000014Address100.0%100.0%3
basepublic_prosenormalAddress.000014Address100.0%100.0%3
basepublic_proseshuffledAddress.000014Address0.0%0.0%3
adapterpublic_prosenoneCurrency.000003Currency66.7%0.0%3
adapterpublic_prosenormalCurrency.000003Currency100.0%100.0%3
adapterpublic_proseshuffledCurrency.000003Currency0.0%0.0%3
basepublic_prosenormalCurrency.000003Currency66.7%0.0%3
basepublic_proseshuffledCurrency.000003Currency0.0%0.0%3
adapterpublic_prosenoneDateTime.000003DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000003DateTime100.0%100.0%3
adapterpublic_proseshuffledDateTime.000003DateTime0.0%0.0%3
basepublic_prosenormalDateTime.000003DateTime33.3%0.0%3
basepublic_proseshuffledDateTime.000003DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000009DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000009DateTime100.0%100.0%3
adapterpublic_proseshuffledDateTime.000009DateTime100.0%100.0%3
basepublic_prosenormalDateTime.000009DateTime0.0%0.0%3
basepublic_proseshuffledDateTime.000009DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000012DateTime66.7%0.0%3
adapterpublic_prosenormalDateTime.000012DateTime66.7%0.0%3
adapterpublic_proseshuffledDateTime.000012DateTime0.0%0.0%3
basepublic_prosenormalDateTime.000012DateTime66.7%0.0%3
basepublic_proseshuffledDateTime.000012DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000018DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000018DateTime100.0%100.0%3
adapterpublic_proseshuffledDateTime.000018DateTime66.7%0.0%3
basepublic_prosenormalDateTime.000018DateTime0.0%0.0%3
basepublic_proseshuffledDateTime.000018DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000030DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000030DateTime0.0%0.0%3
adapterpublic_proseshuffledDateTime.000030DateTime0.0%0.0%3
basepublic_prosenormalDateTime.000030DateTime33.3%0.0%3
basepublic_proseshuffledDateTime.000030DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000032DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000032DateTime66.7%0.0%3
adapterpublic_proseshuffledDateTime.000032DateTime33.3%0.0%3
basepublic_prosenormalDateTime.000032DateTime33.3%0.0%3
basepublic_proseshuffledDateTime.000032DateTime33.3%0.0%3
adapterpublic_prosenoneDateTime.000033DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000033DateTime100.0%100.0%3
adapterpublic_proseshuffledDateTime.000033DateTime0.0%0.0%3
basepublic_prosenormalDateTime.000033DateTime33.3%0.0%3
basepublic_proseshuffledDateTime.000033DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000075DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000075DateTime66.7%0.0%3
adapterpublic_proseshuffledDateTime.000075DateTime0.0%0.0%3
basepublic_prosenormalDateTime.000075DateTime33.3%0.0%3
basepublic_proseshuffledDateTime.000075DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000091DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000091DateTime100.0%100.0%3
adapterpublic_proseshuffledDateTime.000091DateTime66.7%0.0%3
basepublic_prosenormalDateTime.000091DateTime100.0%100.0%3
basepublic_proseshuffledDateTime.000091DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000097DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000097DateTime66.7%0.0%3
adapterpublic_proseshuffledDateTime.000097DateTime33.3%0.0%3
basepublic_prosenormalDateTime.000097DateTime66.7%0.0%3
basepublic_proseshuffledDateTime.000097DateTime0.0%0.0%3
adapterpublic_prosenoneDateTime.000116DateTime0.0%0.0%3
adapterpublic_prosenormalDateTime.000116DateTime66.7%0.0%3
adapterpublic_proseshuffledDateTime.000116DateTime66.7%0.0%3
basepublic_prosenormalDateTime.000116DateTime66.7%0.0%3
basepublic_proseshuffledDateTime.000116DateTime66.7%0.0%3
adapterpublic_prosenoneEmail.000013Email0.0%0.0%3
adapterpublic_prosenormalEmail.000013Email100.0%100.0%3
adapterpublic_proseshuffledEmail.000013Email100.0%100.0%3
basepublic_prosenormalEmail.000013Email100.0%100.0%3
basepublic_proseshuffledEmail.000013Email100.0%100.0%3
adapterpublic_prosenoneLanguage.000002Language0.0%0.0%3
adapterpublic_prosenormalLanguage.000002Language100.0%100.0%3
adapterpublic_proseshuffledLanguage.000002Language0.0%0.0%3
basepublic_prosenormalLanguage.000002Language66.7%0.0%3
basepublic_proseshuffledLanguage.000002Language0.0%0.0%3
adapterpublic_prosenoneName.000008Name0.0%0.0%3
adapterpublic_prosenormalName.000008Name0.0%0.0%3
adapterpublic_proseshuffledName.000008Name0.0%0.0%3
basepublic_prosenormalName.000008Name0.0%0.0%3
basepublic_proseshuffledName.000008Name0.0%0.0%3
adapterpublic_prosenoneName.000025Name0.0%0.0%3
adapterpublic_prosenormalName.000025Name100.0%100.0%3
adapterpublic_proseshuffledName.000025Name0.0%0.0%3
basepublic_prosenormalName.000025Name0.0%0.0%3
basepublic_proseshuffledName.000025Name0.0%0.0%3
adapterpublic_prosenoneName.000037Name0.0%0.0%3
adapterpublic_prosenormalName.000037Name0.0%0.0%3
adapterpublic_proseshuffledName.000037Name33.3%0.0%3
basepublic_prosenormalName.000037Name33.3%0.0%3
basepublic_proseshuffledName.000037Name33.3%0.0%3
adapterpublic_prosenoneNumber.000047Number0.0%0.0%3
adapterpublic_prosenormalNumber.000047Number0.0%0.0%3
adapterpublic_proseshuffledNumber.000047Number33.3%0.0%3
basepublic_prosenormalNumber.000047Number0.0%0.0%3
basepublic_proseshuffledNumber.000047Number0.0%0.0%3
adapterpublic_prosenoneNumber.000054Number33.3%0.0%3
adapterpublic_prosenormalNumber.000054Number66.7%0.0%3
adapterpublic_proseshuffledNumber.000054Number66.7%0.0%3
basepublic_prosenormalNumber.000054Number33.3%0.0%3
basepublic_proseshuffledNumber.000054Number0.0%0.0%3
adapterpublic_prosenoneNumber.000062Number0.0%0.0%3
adapterpublic_prosenormalNumber.000062Number100.0%100.0%3
adapterpublic_proseshuffledNumber.000062Number0.0%0.0%3
basepublic_prosenormalNumber.000062Number0.0%0.0%3
basepublic_proseshuffledNumber.000062Number0.0%0.0%3
adapterpublic_prosenoneNumber.000069Number0.0%0.0%3
adapterpublic_prosenormalNumber.000069Number0.0%0.0%3
adapterpublic_proseshuffledNumber.000069Number0.0%0.0%3
basepublic_prosenormalNumber.000069Number0.0%0.0%3
basepublic_proseshuffledNumber.000069Number0.0%0.0%3
adapterpublic_prosenoneNumber.000082Number100.0%100.0%3
adapterpublic_prosenormalNumber.000082Number100.0%100.0%3
adapterpublic_proseshuffledNumber.000082Number0.0%0.0%3
basepublic_prosenormalNumber.000082Number100.0%100.0%3
basepublic_proseshuffledNumber.000082Number33.3%0.0%3
adapterpublic_prosenoneNumber.000084Number0.0%0.0%3
adapterpublic_prosenormalNumber.000084Number66.7%0.0%3
adapterpublic_proseshuffledNumber.000084Number33.3%0.0%3
basepublic_prosenormalNumber.000084Number33.3%0.0%3
basepublic_proseshuffledNumber.000084Number0.0%0.0%3

Error Examples

splittask_idfamilyrule_nameinputtargetprediction
synthetic_counterfactualcf_0002_number_last2numbernumber_last2COBALT 3212113
synthetic_counterfactualcf_0005_last_threespanlast_threeharbordeltaltadelta
synthetic_counterfactualcf_0013_initialswordsinitialsSonia Rees CobaltSRCSRE
synthetic_counterfactualcf_0017_last_threespanlast_threefablelambdabdaamb
synthetic_counterfactualcf_0017_last_threespanlast_threefablenectartarter
synthetic_counterfactualcf_0022_last_threespanlast_threecobaltlambdabdalambda
public_proseName.000008NamepublicAntonia A. GuachiacA GA A
public_proseName.000008NamepublicNikolajs Serdar PircN PN S
public_proseName.000008NamepublicJaap H. KleefstraJ KJ H
public_proseName.000037NamepublicDr. Christophe Beaulieu, Sr.Sr.Sr
public_proseName.000037NamepublicMarcela KubatovaNULLnull
public_proseName.000037NamepublicMr. Hadar CaspitNULL
public_proseNumber.000084Numberpublic199190-209190-199
public_proseDateTime.000030DateTimepublic03302241Tuesday, March 30, 2241Saturday, March 30, 2241
public_proseDateTime.000030DateTimepublic02-Aug-2160Saturday, August 2, 2160Monday, August 2, 2160
public_proseDateTime.000030DateTimepublic23 May 1984Wednesday, May 23, 1984Monday, May 23, 1984
public_proseDateTime.000075DateTimepublic10:24PM10:00PM-10:29PM10:30PM-10:59PM
public_proseDateTime.000012DateTimepublicUnknownNoneUnknown
public_proseNumber.000047Numberpublic1284.421285.001280.00
public_proseNumber.000047Numberpublic23224.9823225.0023200.00
public_proseNumber.000047Numberpublic1024.211025.001020.00
public_proseDateTime.000097DateTimepublic6.30.222062220
public_proseNumber.000054Numberpublic1254125312541253000012541253
public_proseDateTime.000032DateTimepublic1956-12-16 20:188:18 PMDecember 16, 2056 at 8:18 PM
public_proseNumber.000093Numberpublic4759047594759
public_proseNumber.000093Numberpublic7204072047204
public_proseDateTime.000116DateTimepublic20-Dec-2033 18:36:295PM-7PM6PM-8PM
public_proseNumber.000069Numberpublic1202.343312001202
public_proseNumber.000069Numberpublic23224.12322523224
public_proseNumber.000069Numberpublic-23224.1-23225-23224

Artifacts

Limitations

This run trains on synthetic counterfactual transformations, so public benchmark transfer is the decisive external signal. The public evaluation is capped for runtime. Exact-match scoring is intentionally strict and does not award partial credit for near-correct formats.

Experiment log 6

Show the running log (6 entries)

Setup

  • Created fresh standalone experiment directory: /workspace/experiments/qwen_counterfactual_episodic_icl.
  • Large artifacts directory: /workspace/large_artifacts/qwen_counterfactual_episodic_icl.
  • Public benchmark mirror is stored under the large-artifact directory.
  • Primary question: can counterfactual episodic posttraining improve sparse-example task induction rather than merely memorizing a family prior?

Run smoke_no_train

  • Time UTC: 2026-06-28T04:16:45.068880+00:00
  • Config: {"batch_size": 1, "grad_accum": 8, "log_every": 10, "lora_alpha": 32, "lora_dropout": 0.05, "lora_r": 16, "lr": 0.0002, "max_grad_norm": 1.0, "max_length": 768, "max_new_tokens": 32, "model": "Qwen/Qwen3-4B", "no_train": true, "public_heldout_n": 3, "public_task_limit": 1, "query_n": 2, "run_name": "smoke_no_train", "seed": 20260628, "smoke": true, "support_n": 4, "synthetic_eval_pairs": 1, "train_episodes": 16, "train_rows_per_episode": 2, "train_steps": 1, "warmup_steps": 20, "weight_decay": 0.0}
  • Elapsed seconds: 36.3
  • Synthetic adapter full-task exact: 0.0%
  • Public adapter full-task exact: 0.0%
  • Report: /workspace/experiments/qwen_counterfactual_episodic_icl/reports/qwen_counterfactual_episodic_icl_report.md

Run smoke_train

  • Time UTC: 2026-06-28T04:18:04.969847+00:00
  • Config: {"batch_size": 1, "grad_accum": 2, "log_every": 1, "lora_alpha": 32, "lora_dropout": 0.05, "lora_r": 16, "lr": 0.0002, "max_grad_norm": 1.0, "max_length": 768, "max_new_tokens": 32, "model": "Qwen/Qwen3-4B", "no_train": false, "public_heldout_n": 3, "public_task_limit": 1, "query_n": 2, "run_name": "smoke_train", "seed": 20260628, "smoke": true, "support_n": 4, "synthetic_eval_pairs": 1, "train_episodes": 16, "train_rows_per_episode": 2, "train_steps": 2, "warmup_steps": 20, "weight_decay": 0.0}
  • Elapsed seconds: 60.1
  • Synthetic adapter full-task exact: 0.0%
  • Public adapter full-task exact: 0.0%
  • Report: /workspace/experiments/qwen_counterfactual_episodic_icl/reports/qwen_counterfactual_episodic_icl_report.md

Run pilot_v1

  • Time UTC: 2026-06-28T04:20:11.971541+00:00
  • Config: {"batch_size": 1, "grad_accum": 4, "log_every": 5, "lora_alpha": 32, "lora_dropout": 0.05, "lora_r": 16, "lr": 0.0002, "max_grad_norm": 1.0, "max_length": 768, "max_new_tokens": 24, "model": "Qwen/Qwen3-4B", "no_train": false, "public_heldout_n": 3, "public_task_limit": 8, "query_n": 2, "run_name": "pilot_v1", "seed": 20260628, "smoke": false, "support_n": 4, "synthetic_eval_pairs": 8, "train_episodes": 240, "train_rows_per_episode": 2, "train_steps": 50, "warmup_steps": 20, "weight_decay": 0.0}
  • Elapsed seconds: 174.7
  • Synthetic adapter full-task exact: 93.8%
  • Public adapter full-task exact: 37.5%
  • Report: /workspace/experiments/qwen_counterfactual_episodic_icl/reports/qwen_counterfactual_episodic_icl_report.md

Run main_v1

  • Time UTC: 2026-06-28T04:23:25.047618+00:00
  • Config: {"batch_size": 1, "grad_accum": 4, "log_every": 10, "lora_alpha": 32, "lora_dropout": 0.05, "lora_r": 16, "lr": 0.0002, "max_grad_norm": 1.0, "max_length": 768, "max_new_tokens": 24, "model": "Qwen/Qwen3-4B", "no_train": false, "public_heldout_n": 3, "public_task_limit": 30, "query_n": 2, "run_name": "main_v1", "seed": 20260628, "smoke": false, "support_n": 4, "synthetic_eval_pairs": 30, "train_episodes": 800, "train_rows_per_episode": 2, "train_steps": 120, "warmup_steps": 20, "weight_decay": 0.0}
  • main_v1 was interrupted before model load after a boundedness bug was found in counterfactual rule-pair construction. No result artifacts were produced for that run. The generator was patched to discard infeasible rule pairs after bounded search.

Run main_v2

  • Time UTC: 2026-06-28T04:27:24.417084+00:00
  • Config: {"batch_size": 1, "grad_accum": 4, "log_every": 10, "lora_alpha": 32, "lora_dropout": 0.05, "lora_r": 16, "lr": 0.0002, "max_grad_norm": 1.0, "max_length": 768, "max_new_tokens": 24, "model": "Qwen/Qwen3-4B", "no_train": false, "public_heldout_n": 3, "public_task_limit": 30, "query_n": 2, "run_name": "main_v2", "seed": 20260628, "smoke": false, "support_n": 4, "synthetic_eval_pairs": 30, "train_episodes": 800, "train_rows_per_episode": 2, "train_steps": 120, "warmup_steps": 20, "weight_decay": 0.0}
  • Elapsed seconds: 588.9
  • Synthetic adapter full-task exact: 91.7%
  • Public adapter full-task exact: 56.7%
  • Report: /workspace/experiments/qwen_counterfactual_episodic_icl/reports/qwen_counterfactual_episodic_icl_report.md

Figures 4

adapter task flips
adapter task flips · analysis/figures/
full task exact by method
full task exact by method · analysis/figures/
row vs full task
row vs full task · analysis/figures/
training loss
training loss · analysis/figures/

Data files 13

Result tables and metrics copied from the experiment folder — preview inline or open the raw file.

Reproduce

This entry is source code or analysis only — there is no separate run to reproduce.

Browse the experiment folder on GitHub ↗