Creating a Generic Generative Template Language in Google Gemini / / No Comments I’ve been a fan of ‘random text’ for some time. "Random text" is a bit vague, but to me the idea of using code to generate random stories, or even snippets, is fascinating. Back in April, I blogged about how I created short dragon-based stories. It took a generic string: A #adjective# dragon lives #place#. She #verb# her hoard, which consists of a #number# of #thing#, #number# of #thing#, and #number# of #thing#. She feels #feeling#. And created a story by replacing the pound-wrapped tokens with real words. I used a couple of different tools to build this, but the core one was a cool little Node library named random-word-slugs. It’s a powerful random word library... more → Posted in: JavaScript Tagged with: creating, Gemini, Generative, Generic, Google, Language, Template
Building a Generic RSS Parser Service with Cloudflare Workers / / No Comments About once every three months I’ll write a quick JavaScript demo and attempt to fetch someone’s RSS feed… and then remember that the vast majority of RSS feeds don’t specify a CORS header to allow remote scripts to load them. I know this – and yet I still tend to forget. I thought it would be kind of fun to build a serverless API via Cloudflare Workers to handle loading, parsing, and returning a RSS feed with CORS allowed. I figured this would be pretty easy, but I ran into a snag right away. Workers and NPM Modules # Cloudflare Workers is Node.js compatible… with some issues. Cloudflare has a documentation page on it addressing what you may run into, and for... more → Posted in: JavaScript Tagged with: building, Cloudflare, Generic, Parser, service, workers