July 22nd, 2024

Generative AI Spanish Lesson in 70 lines of code

A tool named "spanishLesson" creates Spanish flashcards with images and speech. Users can fork it via Substrate for an API key and $50 credits. Functions include ComputeJSON, ComputeText, GenerateImage, and GenerateSpeech for interactive lessons. Styling options involve emojis, colors, gradients, and fonts. Hosted on Val Town, a platform for JavaScript development. Version v127 with copying links provided.

Read original articleLink Icon
Generative AI Spanish Lesson in 70 lines of code

The provided text contains information about a tool called "spanishLesson" that generates Spanish flashcards on a chosen topic, including images and speech. Users can fork the tool by signing up for Substrate to obtain an API key and $50 free credits. The tool utilizes various functions such as ComputeJSON, ComputeText, GenerateImage, and GenerateSpeech to create interactive HTML pages for Spanish vocabulary lessons. It prompts users to describe images based on English examples, provides translations into Spanish, and generates speech audio files. The tool also instructs on styling the webpage with emojis, colors, gradients, and fonts related to the chosen topic. Val Town, where the tool is hosted, is described as a social website for writing and deploying JavaScript, building APIs, and scheduling functions. The information includes details about the tool's version (v127) and links for copying HTTP endpoints, module URLs, script tags, and embed codes.

Link Icon 1 comments
By @benzguo - 7 months
Hi! I put together this little app using Substrate – https://substrate.run – and Val.Town to help me brush up on my Spanish vocab. It's pretty neat to be able to generate text, images, and audio, and then ask an LLM to generate a website. Fun alternative to building out the UI yourself – ask an LLM to do it! I do this all the time now, asking the LLM to stream its output as Markdown or HTML.