Cloudflare at the front.
The right runtime behind it.
Live demo update: the current demo runs Timestral-28M, Gemma 4 E2B Q4_K_M (Ollama), and TabICLv2 on a persistent Boxd CPU machine, with automatic hibernation after five idle minutes and no scheduled deletion. The Cloudflare plan below remains the longer-term proposal.
Recommendation: use Workers Static Assets for the site, a Worker for the API, Workers AI for Gemma 4, and a Python container for Timestral. Benchmark TabICLv2 on CPU for small workloads; use an external GPU service for larger jobs. This is a deployment proposal. The current playground now runs real inference on Boxd.
Where each model fits
| Model | Initial hosting choice | Why / what to validate |
|---|---|---|
| Timestral Start with 28M | Python + PyTorch in Cloudflare Containers | Mistral supports CPU inference. Benchmark your history length, variates, horizon, concurrency, and cold starts. It is not listed in the Workers AI catalog. Mistral announcement · Model card |
| Gemma 4 26B A4B instruction | Cloudflare Workers AI | Managed model ID: @cf/google/gemma-4-26b-a4b-it. Published price: $0.10 / million input tokens and $0.30 / million output tokens. Cloudflare model page |
| TabICLv2 v2 classifier / regressor | Python service; CPU pilot, external GPU for larger datasets | CPU is supported; the authors recommend GPU for larger data. Context rows and cache memory matter. It is not listed in Workers AI. Official implementation |
“Latest Gemma” is task-dependent: Gemma 4 is the latest general-purpose generation verified here; 12B Unified was added on June 3, 2026. The more recent EmbeddingGemma 2 release is for embeddings. The Cloudflare proposal chooses the 26B A4B variant because Cloudflare serves it directly, not because it is the most recently released checkpoint. Google release history.
Cloudflare’s roles are different
- Workers / Static Assets: serve the UI and implement authentication, quotas, model routing, and response formatting. Keep large PyTorch workloads in a suitable runtime.
- Workers AI: managed inference for the published model catalog. Gemma 4 is a direct fit. No public self-service route was verified for uploading arbitrary Timestral or TabICLv2 weights. Model catalog.
- Containers: run your own Linux / Python runtime. Published instance types specify CPU, RAM, and disk; no GPU instance is listed. The largest predefined type is 4 vCPU / 12 GiB RAM / 20 GB disk; custom instance types are documented separately. Validate current limits and model peak memory before sizing. Instance types and limits.
- AI Gateway: observability and routing for inference providers, including custom providers. It does not supply the compute for your custom model. For forecasting and tabular payloads, a direct Worker-to-service API is a straightforward starting point; validate Gateway compatibility before adopting it. Custom providers.
- R2 and Queues: proposed additions for model artifacts, datasets, and asynchronous jobs. Introduce them when uploads and workloads require them.
A practical first architecture
Browser
└─ Cloudflare Worker + static website
├─ /v1/chat/completions → Workers AI / Gemma 4
├─ /v1/forecast → Timestral Python container
└─ /v1/tabular/predict → TabICLv2 Python service
CPU pilot / GPU as needed
Later: authenticated uploads → R2 → queue → model job → resultUse stable product model IDs with explicit revisions behind them. Record the upstream checkpoint, runtime, parameters, and evaluation set for each revision. This lets an improved model replace the original without changing the customer’s integration.
What it might cost
The Workers Paid plan starts at $5/month. Containers include some monthly resources, then bill provisioned memory and disk while running, plus active CPU. Published overage rates are $0.0000025 per GiB-second, $0.000020 per vCPU-second, and $0.00000007 per GB-second. Container pricing.
| Illustrative workload | Usage estimate | Exclusions |
|---|---|---|
| 10,000 Gemma requests; 1,000 input + 300 output tokens each | $1.90 model usage at listed rates | Reasoning/output tokens actually generated, Worker usage, plan, storage, taxes |
| 1 vCPU fully active, 6 GiB memory, 12 GB disk for one hour | $0.129/hour before included allocations | Worker / Durable Object requests and egress |
| Same container continuously busy for 730 hours | About $94/month before included allocations | Plan and other usage; idle CPU differs, memory/disk remain billed while running |
These are arithmetic examples, not a measured cost per prediction. Start with scale-to-zero and bounded jobs, then measure load time, peak RAM, throughput, and idle time. The live demo uses metered Boxd compute; Cloudflare inference infrastructure has not been provisioned.
Fine-tuning comes after evaluation
Workers AI offers inference with supported LoRA adapters, with model compatibility and adapter limits. Do not assume Gemma 4 is supported simply because older Gemma LoRA models exist. Plan GPU training separately and retain an external serving path for custom checkpoints. LoRA support and limitations.
For TabICLv2, ordinary fit and predict use in-context learning; this is different from changing weights. The project also exposes explicit fine-tuned classifier and regressor classes. Establish a held-out evaluation and compare baseline versus specialized models before claiming an improvement. TabICL fine-tuning.
Provenance and licenses
Preserve each upstream model’s attribution and license in the product. Timestral weights use Modified MIT; Gemma 4 is released under Apache 2.0; the TabICL repository uses BSD 3-Clause with separate notes for derived components. Confirm the exact checkpoint license at release time. Timestral · Gemma 4 · TabICL.
From demo to first release
- Connect Gemma 4 through a server-side Workers AI binding.
- Package Timestral 28M in Python; preload weights and benchmark the selected container.
- Expose TabICLv2 with strict dataset limits and asynchronous execution for large jobs.
- Add authentication, usage caps, upload retention controls, request timeouts, and model version tracking.
- Collect a representative evaluation set, then train and compare specialized variants.
The product structure is inspired by Desert Ant’s Voz page: clear capabilities, practical examples, documentation, and original-model credit. Toqan Magnet’s demo does not reproduce its performance claims or on-device architecture.