ineshinspace

Open source libraries for MLX and Apple Silicon

mlxtrain-perf

mlx-train-perf — Fused, logit-free cross-entropy loss and a flash-attention training path for mlx-lm LoRA/QLoRA fine-tuning on Apple Silicon. Custom Metal kernels never build the full logits or attention-score matrices — about 3900× less loss-layer memory, and half the training peak at 8K context.

mlxtaef

mlx-taef — Tiny AutoEncoders for diffusion latents in pure MLX. Decode FLUX.2 latents in ~260 ms or FLUX.1 in ~185 ms on M1 Max, vs ~2 s for the full VAE, with ~4× less peak memory.

mlxteacache

mlx-teacache — TeaCache step-skipping for diffusion on Apple Silicon, in pure MLX. Skips redundant denoising steps across FLUX.1, FLUX.2 Klein and Z-Image — 1.46× on FLUX.1-dev at 25 steps.

mlxmodel-doctor

mlx-model-doctor — Validate an MLX or Hugging Face model repo before you load it. Static checks on config, tokenizer, safetensors index, quantization and memory budget catch a broken repo up front, so it fails fast with a clear reason instead of a confusing crash.

mlxquant-fidelity

mlx-quant-fidelity — Measure how much quality a quantization costs on Apple Silicon. Scores a quantized KV cache against full precision and reports the drift — KL divergence, top-token flip rate, perplexity delta — so you pick a bit-width by impact, not by file size.

Agent skills

Skills for Claude Code and OpenAI Codex that I use every day. Each one installs with a single command.

subagent-optimizer

Audits Claude Code subagents and Codex custom agents, then cuts what each one costs to launch: a tight tool allowlist, a shorter prompt, and a model sized to the job. One real agent dropped from 20,122 to 13,962 launch tokens with the same result.

npx skills add IonDen/skills --skill subagent-optimizer

skill-optimizer

Shrinks a skill's SKILL.md without losing an instruction. It records every rule and literal in the original first, then checks the rewrite against that record and asks when unsure instead of guessing. On five real skills it trimmed 2.3% and kept every requirement it found.

npx skills add IonDen/skills --skill skill-optimizer

writing-tests-that-can-fail

Keeps tests honest in any language: they run real code instead of mocks and fail on the bug they exist to catch. Given the same prompts, Claude Haiku without the skill mocked both collaborators in 3 of 3 Python suites. With it, none did.

npx skills add IonDen/skills --skill writing-tests-that-can-fail

All skills on GitHub →

Denis Ineshin

Senior Full-stack Engineer at Booking.com

Amsterdam-based developer. Over a decade shipping open source — currently focused on MLX and Apple Silicon machine learning.

Buy me a coffee