{
  "schema": "aner.native-adaptation-qualification/1",
  "date": "2026-10-30",
  "baseline_commit": "9a92a608bf9a61703f3cfe1c36c6282f909cd144",
  "scope": "Development runtime qualification for supported dense Llama GGUF. Small explicit datasets establish execution and recovery, not general task quality or multi-billion-model practicality.",
  "model": {
    "repository": "HuggingFaceTB/SmolLM2-135M-Instruct",
    "revision": "12fd25f77366fa6b3b4b768ec3050bf629380bac",
    "parameters": 134515008,
    "source_sha256": "c953b337d61834a459884f51250e8242c7a4d2d7f74e465e84eb30e0e51d6d59",
    "canonical_sha256": "4de627da8ef462b4b29f83809b449d455babb92f14e2073478499630bcedda97",
    "decoded_float32_bytes": 538060032,
    "layers": 30,
    "hidden": 576
  },
  "methods": [
    "full",
    "lora",
    "rslora",
    "lora_fa",
    "tinylora"
  ],
  "full_finetune_storage": "float32_only",
  "storage": [
    "float32",
    "nf4",
    "nf4_double_quant"
  ],
  "nf4": {
    "block_size": 64,
    "nested_scale_block_size": 256,
    "nested_codebook": "bitsandbytes dynamic8",
    "persistent_base_storage": "CPU packed bytes",
    "cuda_compute": "FP32; bounded host decode and PCIe tile transfer",
    "paged_optimizer": false,
    "fused_device_dequantization": false
  },
  "tiny_lora": {
    "basis": "paper_usigma_v1",
    "projection_distribution": "independent normal, standard deviation 1/sqrt(rank)",
    "sharing": [
      "global",
      "per_target"
    ],
    "fixed_buffers_persisted": true
  },
  "test_checks": {
    "adapter_math_and_restore_layout": 240,
    "nf4_cpu": 440,
    "nf4_cpu_and_v100": 536,
    "v100_training_lifecycle_matrix": 518517,
    "cuda_library_cpu_training": 110039,
    "cuda_library_cpu_artifacts": 736,
    "cuda_library_async_jobs": 92,
    "cpu_real_model": 933929,
    "v100_real_model": 933930,
    "v100_real_full_finetune": 18
  },
  "cpu": {
    "qualification": {
      "source_bytes": 270886400,
      "backend": "aner.llama-trainer/2;libtorch=2.9.0;fp32;threads=1;build=2ac8081ee57f32d441d31d9a387c710d24da082b37e145f029e4073db32ffee6",
      "device": "cpu",
      "compute_dtype": "float32",
      "cpu_threads": 1,
      "budget_bytes": 4294967296,
      "extended": true,
      "scope": "small-data execution qualification; not a model-quality benchmark"
    },
    "nf4_base": {
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 0,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 0,
        "optimizer_bytes": 0,
        "dequant_tile_bytes": 4194304,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "fingerprint": "77366b05decd898c2d0f62a3547aed0668fab2df7b95670e29351cbebcc77519"
    },
    "datasets": {
      "training": "Pretrained data; role=training; examples=1; scored_tokens=9; sha256=5708999878e6c6ba0b4beb59b89b16587d6359a6c9f8d12dc4d7b6f88a34391c",
      "validation": "Pretrained data; role=validation; examples=1; scored_tokens=10; sha256=16c0efe3b05e82fdd39273fcbd02bd3c44a434417b2d2b7472e776af08dd55ca"
    },
    "lora_trained": {
      "loss_before": 5.605949,
      "loss_after": 5.606572,
      "scored_tokens": 9,
      "fingerprint": "0a0b54a0907770d252c08968a789db642f3cfb6c21e8d4defa8930f3556aa40a",
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 15360,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 15360,
        "optimizer_bytes": 30720,
        "dequant_tile_bytes": 4194304,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      }
    },
    "lora_fa_trained": {
      "loss_after": 5.60601,
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 4608,
        "frozen_adapter_bytes": 4624,
        "trainable_bytes": 4608,
        "optimizer_bytes": 9216,
        "dequant_tile_bytes": 4194304,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "trainable_tensor_count": 1
    },
    "tinylora_trained": {
      "loss_after": 5.60631,
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 52,
        "frozen_adapter_bytes": 9424,
        "trainable_bytes": 52,
        "optimizer_bytes": 104,
        "dequant_tile_bytes": 4194304,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "trainable_tensor_count": 1
    },
    "independent_llama_logits": {
      "values": 49152,
      "max_abs_error": 3.4e-05,
      "max_scaled_error": 2.3e-05
    },
    "exact_resume": {
      "equal": true,
      "updates": 2
    },
    "passed": {
      "checks": 933929,
      "device": "cpu",
      "scope": "selected-device FP32 execution, storage, update, immutability and deployment qualification only"
    },
    "update_seconds": {
      "lora": 0.490704,
      "lora_fa": 0.485403,
      "tinylora": 0.477857
    }
  },
  "v100": {
    "qualification": {
      "source_bytes": 270886400,
      "backend": "aner.llama-trainer/2;libtorch=2.9.0;fp32;threads=1;build=c675fa26bfef4fca435644cfb13304955cf692a590f373dec49cc08be2850412",
      "device": "cuda:0",
      "compute_dtype": "float32",
      "cpu_threads": 1,
      "budget_bytes": 4294967296,
      "extended": true,
      "scope": "small-data execution qualification; not a model-quality benchmark"
    },
    "nf4_base": {
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 0,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 0,
        "optimizer_bytes": 0,
        "dequant_tile_bytes": 8388608,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "fingerprint": "77366b05decd898c2d0f62a3547aed0668fab2df7b95670e29351cbebcc77519"
    },
    "datasets": {
      "training": "Pretrained data; role=training; examples=1; scored_tokens=9; sha256=5708999878e6c6ba0b4beb59b89b16587d6359a6c9f8d12dc4d7b6f88a34391c",
      "validation": "Pretrained data; role=validation; examples=1; scored_tokens=10; sha256=16c0efe3b05e82fdd39273fcbd02bd3c44a434417b2d2b7472e776af08dd55ca"
    },
    "lora_trained": {
      "loss_before": 5.605982,
      "loss_after": 5.605275,
      "scored_tokens": 9,
      "fingerprint": "eeb87f1b0634f45a8dbd12aa27a5f18b2d1efd216ce52bfe1be03edefbf14832",
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 15360,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 15360,
        "optimizer_bytes": 30720,
        "dequant_tile_bytes": 8388608,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      }
    },
    "lora_fa_trained": {
      "loss_after": 5.606001,
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 4608,
        "frozen_adapter_bytes": 4624,
        "trainable_bytes": 4608,
        "optimizer_bytes": 9216,
        "dequant_tile_bytes": 8388608,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "trainable_tensor_count": 1
    },
    "tinylora_trained": {
      "loss_after": 5.606348,
      "memory": {
        "weight_bytes": 69515644,
        "floating_base_bytes": 140544,
        "packed_base_bytes": 69375100,
        "adapter_bytes": 52,
        "frozen_adapter_bytes": 9424,
        "trainable_bytes": 52,
        "optimizer_bytes": 104,
        "dequant_tile_bytes": 8388608,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "nf4_double_quant",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "trainable_tensor_count": 1
    },
    "independent_llama_logits": {
      "values": 49152,
      "max_abs_error": 2.5e-05,
      "max_scaled_error": 1.3e-05
    },
    "exact_resume": {
      "equal": true,
      "updates": 2
    },
    "passed": {
      "checks": 933930,
      "device": "cuda:0",
      "scope": "selected-device FP32 execution, storage, update, immutability and deployment qualification only"
    },
    "update_seconds": {
      "lora": 1.469486,
      "lora_fa": 1.324407,
      "tinylora": 1.326142
    }
  },
  "full_finetune_v100": {
    "profile": {
      "source_sha256": "c953b337d61834a459884f51250e8242c7a4d2d7f74e465e84eb30e0e51d6d59",
      "backend": "aner.llama-trainer/2;libtorch=2.9.0;fp32;threads=1;build=c675fa26bfef4fca435644cfb13304955cf692a590f373dec49cc08be2850412",
      "accelerator": "aner.cuda-device-profile/1;device=0;name=20:Tesla V100-PCIE-32GB;compute=7.0;multiprocessors=80;global_memory_bytes=34072559616;runtime=12060;driver=13000;cublas_workspace=:4096:8",
      "budget_bytes": 4294967296,
      "scope": "real 134.5M full-weight FP32 execution qualification, short explicit data; not a quality benchmark"
    },
    "import": {
      "seconds": 8.593624,
      "registered_trainable_tensors": 272,
      "source_fingerprint": "2a4f752e28f0082e5f3bebaf8b89e1551ec0b6fdbe5084e0d91598d561b2ff4c",
      "summary": "Native pretrained Llama; backend=aner.llama-trainer/2;libtorch=2.9.0;fp32;threads=1;build=c675fa26bfef4fca435644cfb13304955cf692a590f373dec49cc08be2850412; device=cuda:0; parameters=134515008; trainable=134515008; method=full; storage=float32; lora_rank=0; updates=0; scored_tokens=0; source_sha256=c953b337d61834a459884f51250e8242c7a4d2d7f74e465e84eb30e0e51d6d59",
      "memory": {
        "weight_bytes": 538060032,
        "floating_base_bytes": 538060032,
        "packed_base_bytes": 0,
        "adapter_bytes": 0,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 538060032,
        "optimizer_bytes": 0,
        "dequant_tile_bytes": 0,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "float32",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      },
      "training": "Pretrained data; role=training; examples=1; scored_tokens=10; sha256=8025ea07ffbf9d64b1499c06e1b4120c91fef185744c849636b5ea82508cc0ab",
      "validation": "Pretrained data; role=validation; examples=1; scored_tokens=10; sha256=16c0efe3b05e82fdd39273fcbd02bd3c44a434417b2d2b7472e776af08dd55ca"
    },
    "full_update": {
      "seconds": 1.274223,
      "updates": 1,
      "scored_tokens": 10,
      "validation_loss": 4.956818,
      "memory": {
        "weight_bytes": 538060032,
        "floating_base_bytes": 538060032,
        "packed_base_bytes": 0,
        "adapter_bytes": 0,
        "frozen_adapter_bytes": 0,
        "trainable_bytes": 538060032,
        "optimizer_bytes": 1076120064,
        "dequant_tile_bytes": 0,
        "estimated_budget_bytes": 4294967296,
        "compute_dtype": "float32",
        "paged_optimizer": false,
        "storage": "float32",
        "scope": "owned tensor buffers and conservative workspace admission; excludes allocator/BLAS and other retained handles; not process RSS; import/export/SVD use one matrix workspace"
      }
    },
    "exact_resume": {
      "equal": true,
      "updates": 2,
      "checkpoint_seconds": 20.676593,
      "reload_seconds": 27.634648
    },
    "memory_measurement": {
      "torch_cuda_allocated_peak_bytes": 7959815680,
      "torch_cuda_reserved_peak_bytes": 8099201024,
      "cuda_free_bytes_before_load": 33682620416,
      "cuda_free_bytes_at_final_sample": 25516310528,
      "device_total_bytes": 34072559616,
      "scope": "instrumented Torch CUDA allocator peak after warmup; excludes CUDA context and external allocations. CUDA free bytes are point samples, not a device peak. Retained source/trained handles are included."
    },
    "passed": {
      "checks": 18,
      "quality_claim": false
    }
  },
  "interpretation": {
    "memory": "Base-storage numbers count owned tensors. The full-FT allocator peak covers the complete probe with retained source, trained, restored and comparison models; it is not a single-run VRAM requirement or total-device peak. Admission budgets exclude other live handles, allocator caches and unrelated allocations.",
    "timing": "Different hosts and very short datasets. The V100 tiled NF4 profile was slower than the Mac CPU in this observation; these runs do not establish a GPU speedup or a controlled throughput benchmark.",
    "quality": "The NF4 LoRA held-out loss increased in the small example. Finite updates, exact resume and deployment agreement do not establish improved general answers."
  },
  "remaining": [
    "Additional model architectures, including Qwen training",
    "Multi-billion-parameter and long-context qualification",
    "Activation checkpointing and mixed precision",
    "Fused device NF4 kernels and paged optimizers",
    "Broader independent throughput and peak-RSS measurements",
    "Distributed volunteer scheduling, aggregation and recovery"
  ],
  "implementation_file_sha256": {
    "cmake/AnerLLMTraining.cmake": "4abb397ef67d317fee50307ef2850227eab5f11ca2c78eb2a27bf0f09b470e2c",
    "include/aner/gen_modern.hpp": "d70ac9f8c3b170479d0ebe6c8ded92cfd39ccc220f91a1d12f37f0df1b29da21",
    "include/aner/gen_modern_jobs.hpp": "5805cf9603133a128d47c658e03918eef729cbd7ab1bc04d42ef8dd06bf642c7",
    "src/gen_modern_torch.cpp": "e4725f462ebb99a3c77daf7c986fbee3b5a73b5f652daace4fb96e74496baab4",
    "src/gen_modern_io.cpp": "f64007323869adc8bb2108cd78b351e4cdde537b064c45445127295915289e8e",
    "src/gen_modern_io.hpp": "78af547daa77992949c69b9d9aec46aebc4cd52eb7f7c1372285f8f2e2d3804c",
    "src/gen_modern_adapters.cpp": "56eccca4c3a554d167b416782668258660d0e2f0b81f0a50bfc9feb3f2a081e1",
    "src/gen_modern_adapters.hpp": "d9145f53838af197d5b1301c6615196ff485c81d72a72d966ad35e517758298e",
    "src/gen_modern_nf4.cpp": "9cdead4248d9433f942067c4ca458bb15e9b6ae99a00bc5baa5ebdd8fd7dc48a",
    "src/gen_modern_nf4.hpp": "b805531eb6d028d9b394040113a1dab65a53ce0ec7264cfc7834cfa1c305a78a",
    "src/gen_modern_device.cpp": "c6ed88437989053775149559c1ea6266907fdff82a89823c4cbf78cee9d0dc10",
    "src/gen_modern_device.hpp": "5f2d2b582fcf1f8cb40385faff1410b11a00af1df39f114a1f443c9639895609",
    "src/gen_modern_jobs.cpp": "736f2a6cea9bcfbf95aca677c33f90c409965ff4b4ffb5fe70c2d074d9b3aac6",
    "tests/modern_adaptation_probe.cpp": "6d88cbc5eb439bc8b271367c9fcfed699bffadaa9f2250d9057737ae369b92d6",
    "tests/modern_full_finetune_probe.cpp": "c47a3c833d5b0ffc646b2631db0c2c0e6257d9b0c52e55e9432d1cdf8e04b527",
    "tests/modern_cuda_tests.cpp": "22a4f58fd9ce9d1380162a3ab8a9b8945f365a6f795fb34f4d52230eaa1aa6c4"
  }
}
