I recently wrote a single-file library in C for Wave Function Collapse: https://github.com/krychu/wfc
It’s a procgen algorithm that takes small image as input and generates a larger one with similar local features. I hope to add tiled method to the library some time.