ai

By clecam, 19 October, 2025

I wanted a reliable way to generate all legal K+R vs K chess positions with White to move for AI training data.
After exploring several constraint programming tools (MiniZinc, OR-Tools, and Prolog variants), I ended up using Scryer Prolog, embedded directly from Rust.

In the end, I realized that I didn’t even need constraint programming (CLP) at all — plain Prolog was enough.
The constraints were simple, the domain small, and performance was already instant.

By clecam, 15 May, 2025

Understanding Tensors in AI: A Journey Through Physics and Mathematics

When exploring the world of Artificial Intelligence, one frequently encounters the term tensor. In practice, a tensor is often treated as just a multi-dimensional array — a generalization of scalars, vectors, and matrices. However, this modern usage is a far cry from its deeper mathematical and physical origins. To understand what a tensor really is, it’s helpful to trace its meaning through physics and mathematics before returning to AI.