Geoffrey Litt Profile picture
researching malleable software @inkandswitch / 🇯🇵🇺🇸

May 4, 2023, 9 tweets

I wanted to convert a JSON file of a chat transcript into nice markdown text for sharing w/ people...

so I had GPT generate an ephemeral React UI where I can drag in the JSON file and it outputs the markdown🤓

reflections on the process:

My first idea was to just have GPT do the conversion itself: paste the JSON in and tell it to output markdown.

Worked fine, but slow, might not work on long transcripts, and hard to know if it's 100% reliable.

Next idea: have GPT generate code to do the task!

Just told it to make a node.js script that outputs "a nice markdown file", didn't bother specifying formatting details

Worked fine on first try. but! annoying to invoke a script in terminal, futz w filenames, etc

Then I realized I really just wanted a GUI where I could drag in the JSON file directly and then copy out the markdown result.

Asked GPT to turn the node.js script into a react app:

then I just copy-pasted the react code into @Replit and it worked on the first try :)

replit.com/@GeoffreyLitt/…

this is a terribly simple UI, really just a place to drag a file and run a simple data conversion.

and yet -- I wouldn't have bothered to code it manually. only worth it because it literally took 10 seconds to code both the data conversion and the GUI

It’s also neat that I now have this GUI tool and can quickly reach for it whenever I need.

I think ChatGPT w/ plugins could have produced a similar UX for a single conversion, but wouldn’t have left me with a solid reusable tool

Also, interestingly I haven’t even bothered to read the code.

Just checked a couple example outputs which was enough to give me confidence that it does the right thing

Just a tiny, real, useful example of a pattern I’m excited about: personal AI-generated software tools

Share this Scrolly Tale with your friends.

A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.

Keep scrolling