{
  "schema_version": 1,
  "purpose": "Execution record for the pilot, not a one-command reproduction package.",
  "model": "Qwen/Qwen2.5-0.5B",
  "model_revision": "060db6499f32faf8b98477b0a26969ef7d8b9987",
  "dataset_revisions": {
    "sst2": "8d51e7e4887a4caaa95b3fbebbf53c0490b58bbb",
    "wikitext": "b08601e04326c79dfdd32d625aee71d232d685c3"
  },
  "inputs": [
    {
      "path": "sft-train.jsonl",
      "sha256": "1d13e34026fca7c3d878584431302b19528e0a5b6a04889713e8c42113ef5703",
      "rows": 2048
    },
    {
      "path": "sft-test.jsonl",
      "sha256": "ac39928f1b15b38023ce8de54f8451c2d53ef762761a9ce498413e02f52891bc",
      "rows": 872
    },
    {
      "path": "pretrain-train.jsonl",
      "sha256": "54ae1e32463439d6326ce6e727f32139c1e46561b538e76519145fc517a18427",
      "rows": 1024
    },
    {
      "path": "pretrain-test.jsonl",
      "sha256": "3ced346675dcc17ca980342d79b45c8a5ec8350eb6e13f4e924f42cd913f3cf2",
      "rows": 1833
    }
  ],
  "versions": {
    "torch": "2.14.0+cu126",
    "transformers": "5.17.0",
    "trl": "1.13.0",
    "datasets": "4.8.5",
    "accelerate": "1.14.0",
    "huggingface-hub": "1.27.0"
  },
  "seed": 11,
  "accepted_runs_per_stage_per_platform": 1,
  "execution": {
    "nodus": "Production standalone Job executing pinned Nodus trainer; not managed TrainingJob API.",
    "modal": "Independent TRL SFTTrainer function on Modal.",
    "training_device": "CUDA / NVIDIA L4",
    "evaluation_device": "CUDA / NVIDIA L4",
    "gpu_count_per_job": 1,
    "training_precision": "BF16",
    "evaluation_precision": "FP32",
    "attention": "SDPA",
    "tf32_execution_setting": false,
    "tasks_start_independently_from_base": true,
    "train_from_scratch": false,
    "native_internal_benchmark_access": "Temporary card-prerequisite exception for the internal campaign; prepaid billing and spend caps retained. Not a generally available billing entitlement."
  },
  "native_serialized_training_arguments": {
    "sft": {
      "seed": 11,
      "data_seed": 11,
      "bf16": true,
      "fp16": false,
      "tf32": null,
      "full_determinism": false,
      "optim": "adamw_torch_fused",
      "learning_rate": 5e-05,
      "lr_scheduler_type": "cosine",
      "warmup_steps": 0.1,
      "weight_decay": 0.01,
      "max_grad_norm": 1.0,
      "gradient_checkpointing": true,
      "per_device_train_batch_size": 4,
      "gradient_accumulation_steps": 4,
      "max_steps": 160,
      "max_length": 256,
      "packing": false,
      "completion_only_loss": true,
      "save_steps": 40,
      "save_total_limit": 2,
      "logging_steps": 20
    },
    "pretrain": {
      "seed": 11,
      "data_seed": 11,
      "bf16": true,
      "fp16": false,
      "tf32": null,
      "full_determinism": false,
      "optim": "adamw_torch_fused",
      "learning_rate": 2e-05,
      "lr_scheduler_type": "cosine",
      "warmup_steps": 0.1,
      "weight_decay": 0.01,
      "max_grad_norm": 1.0,
      "gradient_checkpointing": true,
      "per_device_train_batch_size": 4,
      "gradient_accumulation_steps": 4,
      "max_steps": 128,
      "max_length": 256,
      "packing": false,
      "completion_only_loss": null,
      "save_steps": 40,
      "save_total_limit": 2,
      "logging_steps": 20
    }
  },
  "warmup_note": "Recorded warmup_steps is 0.1 on the pinned library stack. Preserve this serialized argument when inspecting the experiment; no conversion to a different version convention is asserted.",
  "data_preparation": {
    "normalization": "Casefold, split on whitespace, join with one space; exact-match deduplication only.",
    "sft": {
      "dataset": "stanfordnlp/sst2",
      "training_split": "train",
      "evaluation_split": "validation",
      "selection": "Sort train rows by SHA256 of UTF-8 sentence bytes; exclude normalized validation matches and prior normalized duplicates; retain first 1,024 per class, concatenate negative then positive.",
      "training_rows": 2048,
      "evaluation_rows": 872,
      "loss": "Completion-only on labeled examples."
    },
    "pretrain": {
      "dataset": "Salesforce/wikitext",
      "configuration": "wikitext-2-raw-v1",
      "selection": "Retain text longer than 100 characters after stripping; take first 1,024 unique training paragraphs in dataset order excluding normalized qualifying test matches.",
      "training_rows": 1024,
      "evaluation_split": "test",
      "evaluation_rows": 1833,
      "evaluation_selection": "All test rows whose stripped text exceeds 100 characters."
    },
    "input_serialization": "JSONL, UTF-8, ensure_ascii=False, sort_keys=True, newline after each row.",
    "base_pretraining_contamination": "Unknown; public corpora are not sealed enterprise holdouts."
  },
  "evaluation": {
    "baseline": "Unchanged pinned base model evaluated with the same scorer before training.",
    "sft": {
      "method": "Greedy generated sentiment labels; only valid positive/negative answers accepted, invalid answers wrong. No constrained-label scorer.",
      "max_new_tokens": 4,
      "do_sample": false,
      "batch_size": 16,
      "input_truncation": false
    },
    "pretrain": {
      "method": "FP32 next-token cross-entropy summed across full qualifying paragraphs; every token after each paragraph first token scored once.",
      "max_window_tokens": 256,
      "scoring_stride": 128,
      "target_tokens": 286056,
      "nll": "total_nll / total_target_tokens",
      "perplexity": "exp(nll)",
      "paragraph_perplexities_averaged": false
    },
    "quality_gates": {
      "pretraining": "Same-tokenizer FP32 next-token NLL on full WikiText-2 raw test paragraphs; lower is better.",
      "finetuning": "Greedy generated-label accuracy and format validity on all 872 SST-2 validation examples.",
      "pretraining_gate": "NLL below untouched base; no more than 1% relative NLL above Modal.",
      "finetuning_gate": "Accuracy at least 80%, format validity at least 99%; at most 2 percentage points below Modal.",
      "test_policy": "No test-score-based recipe changes. No truncation that removes the instruction. No constrained-label scoring as primary accuracy."
    },
    "heldout_score_recipe_tuning": false
  },
  "resource_controls": {
    "frozen_plan_cpu": 8,
    "nodus": {
      "cpu_minimum": 4,
      "memory_minimum_gib": 48,
      "host_visible_cpus": 128,
      "cpu_affinity_count": 128,
      "cgroup_v2_limit_probe": {},
      "effective_cpu_limit": "Not captured; host-visible CPU count is not dedicated allocation."
    },
    "modal": {
      "cpu_request": 4,
      "cpu_limit": 4,
      "memory_request_mib": 49152,
      "memory_limit_mib": 49152,
      "cpu_units": "Physical cores according to Modal resource docs."
    },
    "identical_host_or_cpu_limits": false,
    "matched_cache_warmth": false
  },
  "deviations": [
    {
      "item": "Hardware metadata",
      "details": "Frozen protocol says 8 vCPU. Actual Modal declaration is cpu=(4,4); native Job requests minimum 4 CPU / 48 GiB. Native SFT reports 128 host-visible CPUs; effective cgroup CPU limit was not captured by the v2-only probe. Both report NVIDIA L4 and matching six library versions. Results compare platform offers meeting requested minimums, not isolated trainer speed on identical CPUs."
    },
    {
      "item": "Concurrency",
      "details": "Native pretraining launched after corrected native SFT entered training, before its final scoring. The frozen plan allowed overlap after scoring. Workloads ran as separate jobs under independent $1 caps; potential platform/network contention limits timing attribution."
    },
    {
      "item": "Additional attempts",
      "details": "Original Modal SFT used 1 MiB inline export chunks; corrected SFT uses 32 MiB like the other trials. Both paid attempts remain in campaign costs. Native first SFT failed before training because the benchmark wrapper hardcoded /nodus/outputs; corrected wrapper consumes NODUS_OUTPUT_DIR. No model, training recipe or quality threshold changed."
    },
    {
      "item": "Dry-run",
      "details": "Nodus dry-run returned NoFeasibleOffering because scheduling estimation precedes image-user pinning. Actual admission succeeded and the native SFT completed. This is a known dry-run limitation, not evidence of absent capacity."
    },
    {
      "item": "Execution interface",
      "details": "Plan described managed TrainingJobs; native measurement used production standalone Jobs with the pinned trainer."
    },
    {
      "item": "Schedule",
      "details": "Modal pretraining reference ran on October 10, 2026; native runs and corrected Modal SFT on October 11. Order was not randomized."
    },
    {
      "item": "Economic scope",
      "details": "Original goal included fully attributed preparation, storage and transfer through accepted export. Final native compute and collected Modal usage are reported; residual charges are not asserted finalized. All eight execution attempts retained."
    }
  ],
  "limits": [
    "One seed and no repeats: no cloud-run variance estimate or confidence interval.",
    "Same GPU class does not establish isolated trainer speed.",
    "No large-model, multi-GPU, scratch-pretraining, RL or preemption-recovery result.",
    "Managed TrainingJob ergonomics are outside the measured path.",
    "No model weights, dataset rows, raw invoices, credentials or runnable trainer environment bundled."
  ],
  "timing_definitions": {
    "trainer": "training_metrics.train_runtime on both platforms, not outer training_seconds wrappers.",
    "nodus_delivery": "Submission to locally downloaded, verified export; waits for final billing before download.",
    "modal_delivery": "Submission to local export; usage receipt retrieved separately.",
    "boundaries_identical": false,
    "native_charge_segment_seconds": "Recorded integer segment durations; do not infer exact rates from rounded seconds."
  }
}
