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
Creating a Content Assistant with Gemini and GenAI / / No Comments One of the use cases for generative AI that I’ve discussed before is the idea of using the tool to aid in the writing process. I’m not talking about creating content so much as creating suggestions and providing feedback about the content you yourself have created. This past weekend I worked on a "general purpose" tool with this in mind and thought I’d share it to get your feedback. ("You" being the smart readers of this blog who keep me honest when I show something stupid. 😉 The Application # The application itself is rather straightforward. It asks two questions – first, what are you trying to accomplish with your writing and what are the desired... more → Posted in: JavaScript Tagged with: Assistant, Content, creating, Gemini, GenAI
Creating Visualizations in Postman / / No Comments Earlier this week, I blogged about a cool Postman feature where you could use scripting to take the result of one API call and use it as a variable that is then used by a second call. For APIs that first require you to exchange credentials for an access token, this is a super useful way to make that process easier. Today I’m following up on that with another useful application of scripting – visualizations. Once again, I’ve got my coworker Ben to thank for showing me this. Let me show you an example. When working with Firefly Services and the text to image API, you get a nice JSON response back containing information about the results as well as links to your images. Here’s... more → Posted in: JavaScript Tagged with: creating, Postman, Visualizations
Dynamically Creating Variables in Postman / / No Comments This may come as a shock to you, but sometimes, I don’t read the documentation for the tools I use. Sometimes, I don’t even look at all the various menu items and UI stuff for the tools I use. I know I’m probably the only one who does that and I apologize for letting down my faithful readers. I’ve used Postman for probably over ten years now. I don’t use it terribly often as I can normally whip up a quick API demo in Node in minutes, but I’ll use Postman from time to time. As you can probably guess by how I started this post, my use of Postman was very rudimentary. Heck, I’ve only recently realized the benefit of organizing requests via various collections... more → Posted in: JavaScript Tagged with: creating, Dynamically, Postman, variables
Creating Human-Readable Summaries of Data with Google PaLM Generative AI / / No Comments Like a lot of folks, I’ve been spending a lot of time thinking about generative AI, and AI, in general, and oddly (well for me), trying to focus on productive uses for it when working with APIs. A few weeks ago I shared my initial impressions of Google’s PaLM 2 API, and today I came up with an interesting use case for it. I’ve seen text summarization as a fairly common use case for gen AI, and I agree, it can be incredibly helpful when working with lots of text. However, I got to thinking today, would it be possible to use this as a way to summarize numerical, or other data? So given some process that returns a set of information, can we use gen AI to summarize it? Here’s... more → Posted in: JavaScript Tagged with: creating, data, Generative, Google, HumanReadable, palm, Summaries
Creating a Blackjack Game with Alpine.js and the Deck of Cards API / / No Comments Some time ago I ran across a pretty fascinating service, the Deck of Cards API. This API handles everything imaginable related to working with decks of cards. It handles creating a shuffled set of cards (containing one or more decks), dealing out a card (or cards), and even reshuffling. Even better, it includes card images you can use if you don’t want to find your own: It’s an incredibly feature-filled an API and best of all, it’s completely free. No need for even a key. I’ve known about this API for a while and have contemplated building a card game with it, but realized that games can quickly go from simple to fairly complex. In fact, my friends strongly urged me not... more → Posted in: JavaScript Tagged with: Alpine.js, Blackjack, Cards, creating, Deck, Game
Creating Bootstrap WebC Components in Eleventy / / No Comments For some time now as I’ve explored web components, it’s occurred to me that web components could be a great way to make working with Bootstrap simpler. Not that Bootstrap is necessarily difficult, but I’ve always thought it would be cool to take something like so: <div class="card" style="width: 18rem;"> <div class="card-body"> <h5 class="card-title">Card title</h5> <h6 class="card-subtitle mb-2 text-body-secondary">Card subtitle</h6> <p class="card-text">Some quick example text to build on the card title and make up the bulk of the card's content.</p> </div></div> And... more → Posted in: JavaScript Tagged with: Bootstrap, Components, creating, Eleventy, WebC
Bangle.js – Creating a Smart Watch with JavaScript – InfoQ.com / / No Comments Bangle.js – Creating a Smart Watch with JavaScript InfoQ.com “JavaScript” – Google News… more → Posted in: JavaScript Tagged with: Bangle.js, creating, InfoQ.com, JavaScript, smart, Watch