QT 6.5 HOWITZER
DOCS / CREATION & TRAINING / THE FOUNDRY STUDIO

The Foundry Creation Studio

The Foundry is the custom model development and fine-tuning suite integrated directly into Howitzer. It provides a complete, sovereign pipeline from unstructured raw documentation to a fine-tuned, quantized, edge-deployable model.

1. Agentic Synthetic Data Synthesis

Building high-quality instruction datasets typically requires expensive human labeling. The Foundry automates this with multi-agent adversarial synthesis:

  • Seed Ingestion: Point the synthesizer to a directory of Markdown documentation, C++/Rust source code, or legal/technical PDFs.
  • Generator Agent: Reads chunked context and synthesizes challenging questions, refactoring tasks, or reasoning queries.
  • Critic Agent: Performs adversarial scrutiny, checking for factual hallucinations, syntax errors, and tone alignment.
  • Rejection Sampling: Discards low-scoring samples automatically. Only top-tier instruction pairs are retained.
  • Dataset Export: Outputs clean, verified datasets in JSONL, Alpaca, ShareGPT, or Parquet formats.

2. Desktop LoRA & QLoRA Fine-Tuning

Fine-tune open-weight models (such as Llama 3.3 8B or Qwen 2.5 Coder 7B) directly on your Apple Silicon Mac using Metal Performance Shaders (MPS):

Foundry Training Telemetry Console MPS Metal // 32-core GPU
[EPOCH 1/3] Step 240/1200 | Loss: 0.842 | Perplexity: 2.32 | LR: 2.4e-5 | VRAM: 9.4GB
[EPOCH 2/3] Step 680/1200 | Loss: 0.412 | Perplexity: 1.51 | LR: 1.8e-5 | VRAM: 9.4GB
[CHECKPOINT] Saved adapter weights to ~/.howitzer/adapters/custom_lora_v1.safetensors

Hyperparameters are configured visually in the Foundry UI or via the CLI: LoRA rank (r=8..64), scaling alpha (16..128), target linear modules (q_proj, v_proj, k_proj, o_proj), and gradient accumulation steps.

3. 1-Click Quantization to GGUF & MLX

Once training completes, you can merge the LoRA weights back into the base model or save them as a dynamic standalone adapter. With 1-click GGUF quantization, the Foundry packages your model into 4-bit (Q4_K_M) or 8-bit (Q8_0) formats, running automated perplexity verification to assert that precision loss remains under 1.5%.

4. Live Canary Range & Regression Testing

Before deploying a custom model into production workflows, you must verify that it hasn't suffered from catastrophic forgetting of core logic:

  • Launch the Canary Range to mount your custom adapter alongside the base model and a frontier baseline (such as Claude 3.5 Sonnet).
  • Execute automated regression benchmark suites (GSM8k, HumanEval, or custom internal test sets).
  • Expose your fine-tuned model instantly as a local, OpenAI-compatible HTTP endpoint at http://127.0.0.1:8080/v1/chat/completions.