Skip to content

ai

August 27 2023

Sunday is the reprieve!

The Internet is Empty
How can we travel that which has no physical form?





the host's facial expression lmao
shawty got low low low low

the ol' ivy league resume in a old navy hoodie
the relief of compiled code, the anxiety of the evolving context
forbes 30u30 in a nutshell

August 23 2023

Out-of-towners often mistake Manhattan as the whole of NYC, I feel.

Out-of-towners often mistake Manhattan as the whole of NYC, I feel. Take the time to explore spots like Bay Ridge, or Cortelyou Road.

You'll find calm there, perhaps even a surprising dose of the suburban. The real perk of living in an area like Bay Ridge vs a suburb outside of Corpus Christi? A train line linking you straight to the heart of Union Square or Grand Central in under an hour.






This Goes INSANELY HARD
that bass line UGHHH, this whole video is SO GOOD Some of my favorite frames (literally every still frame could be a desktop wallpaper):




When you see those tier 7 minions in your game, do me a favor, grab Tess. Just trust me on this.



your day is just starting!

Kingdom Hearts Menu Style Portfolio
~~ dearly beloved ~~

STYLEEEE

I am the one who decides.




The gallery feature on Ubud is acting up. Beats me why.


Trying out Spear in Discord. Maybe it's something that could tickle the fancy of vault members, make them feel special. Definitely can picture it being a neat bonus!


Another day done, neatly cut into boxes of time. This time block journal, it's kind of become a friend. Excited to think where I might be in a few months - maybe a master at wrestling time.


GPT helps me to write, and I like that. It’s like the words I jot down aren't my own, they’re not precious. So, when it comes to chopping them up and pruning them, I don't flinch. And, there's something cool about typing in shorthand, or even in low key, lowercase letters. GPT just takes it, and churns out sentences that sound as real as rain splattering on a windowpane.

August 22 2023

New season of Hearthstone! Goodbye, next forty-eight hours.

New season of Hearthstone! Goodbye, next forty-eight hours. I'll be captive to this relentless obsession. Alongside Baldur's Gate 3, of course.




This patch, it sucks from the get-go. Bannana Slammas for life, I suppose.

broken combo
only broken enough for fourth place i suppose

The billboards up in Soho stir something within me. Something McLuhan might've coined, about the package being more valuable more than the item inside. The ads on NYC's billboards, uncountable as they are, most fade from memory like a worn-out jazz record. But their very existence on the giant sized wall, catching the eye of the odd twenty-somethings, mid-pilgrimage to their temple of Equinox, that broadcasts its own message. Sure, I could plaster an ad on some wall in a silent town but that lacks the jazz, the hum and pulse of the viewer's gaze, which makes all the difference in selling the song. Plenty artists wallow unseen, only a handful get to wallow under the spotlight.


Leaders need this one thing more than anything else: good sense. It's the same when it comes to your body, your thoughts, your work life. Be your own arbiter of good judgement.


Photos...they've been the game for me on Instagram lately, kind of like a guilty pleasure I suppose. Don't know why.

It's ludicrous when you think about how I'm using Instagram, disregarding entirely how they mapped out the service. Truly not giving a flying fuckkk. It's like a Finstagram, but taken to the logical conclusion of really only using Instagram for a glorified photo storage service. Picture it: me following no one, completely ignoring ads on the feed the company worked so hard on to build! A strange way to play, right?

But in its way, it's transformative. Instagram morphs into something else, a simple yet miraculous platform for my photos, a sanctuary. It's effortless to stick in my favorite tunes too, lending a voice to every image. And the filters? Oh, the filters. An array of options with a single, easy tap. Quite something, isn't it?



Oddly enough, I found myself the central character in some LLM tutorial – an instructional piece about using these LLMs for cold outreach on LinkedIn, of all things. Seeing this offered some clarity, unsheathing the mystery of the spam deluge that keeps finding me. Particularly from the VCs, the constant hum in the background. Leave me alone dammit!


Random post logic – all credit goes to the original creator: milkythemes!

<script>
    function loadScript(url, callback) {
    const head = document.head;
    const script = document.createElement('script');
    script.type = 'text/javascript';
    script.src = url;
    script.onreadystatechange = callback;
    script.onload = callback;
    head.appendChild(script);
}

function luckyPost() {
    let ghostVersion = typeof version == 'undefined' ? 'v3.0' : version;
    let apiKey =
        typeof key == 'undefined' ?
            console.error('Ghost integration API key is missing. Please refer to documentation at https://milkythemes.com/plugins/lucky-post') : key;

    const pageUrl = `${window.location.protocol}//${window.location.hostname}`;

    const api = new GhostContentAPI({
        url: pageUrl,
        key: apiKey,
        version: ghostVersion
    });

    const postUrl = [];

    const randomBtn = document.getElementsByClassName("btn-random");
    const stringHostUrl = `[href="${pageUrl}/#rdm-post/"]`
    const randomPost = document.querySelector(stringHostUrl);
    
    const randomPostSelector = document.querySelectorAll('[href="https://www.bramadams.dev/rdm-post/"]');

    for (let i = 0; i < randomPostSelector.length; i++) {
        randomPostSelector[i].text = `Loading...`
    }


    api.posts
        .browse({ limit: 250 })
        .then((posts) => {
            posts.forEach((post) => {
                postUrl.push(post.slug)
            });
        })
        .then(() => {
        const randomPostSelector = document.querySelectorAll('[href="https://www.bramadams.dev/rdm-post/"]');
        
        for (let i = 0; i < randomPostSelector.length; i++) {
            randomPostSelector[i].text = `Open Random Post!`
            randomPostSelector[i].href = `${pageUrl}/${randomUrl(postUrl)}`
        }
            
        }).catch(() => {
    		const randomPostSelector = document.querySelectorAll('[href="https://www.bramadams.dev/rdm-post/"]');
        
            for (let i = 0; i < randomPostSelector.length; i++) {
                randomPostSelector[i].text = `OOPS!`
                randomPostSelector[i].href = `https://www.bramadams.dev/`
            }
    	});

    // The randomUrl function is used to grab a random array from the list 
    function randomUrl(postUrl) {
        return postUrl[Math.floor(Math.random() * postUrl.length)];
    }
}

loadScript('https://unpkg.com/@tryghost/content-api@latest/umd/content-api.min.js', luckyPost);
</script>

Tier 7 exists.


SOMEBODY HAS TO DIE

Blue Lock got dark!


big carbon copy!

Hey, the kid's scored a page on Wikipedia!

Atrioc - Wikipedia

Sticky Header for Ubud! (Put this in the code injection header)

<style>
    .c-header{
        position: sticky;
        z-index: 1;
        top: 0;
        background: var(--background-primary);
    }
</style>

August 21 2023

Instabrams are back baby! Thanks to Alfred, Obsidian, Ghost, and GPT that is!

I found out today that, oddly enough, my dislike for food—and smells, as an offshoot—liberates my ears. I can fill them with all kinds of sounds, just like I fill my mind with all sorts of books. And who knows, this might make my understanding richer, deeper. After all, tastes and sounds, they both bring in similar complexities, don't they? What's the science behind this, I wonder?


Planning with time blocks using the Time Block Planner is something else, I tell you. Just staring at how my hours roll out in reality, versus where I believe in my mind that they're going.

It really makes me treasure those fresh hours each morning when I draft the plan. But, damn it, they do race by like comets while I'm knee-deep in living them. Sure makes one thing clear though - there's still quite a road ahead of me to align my time better with the stuff that sits front-row in my priorities.


Today, I cranked out a couple scripts that just might fan the flame back into my inconsistent habit of creating Instabrams. Knocked up one heck of a pipeline for DALL-E, taking chunky texts, wringing them dry into neat, crisp summaries, and morphing them into fetching cover art.

Then there's the second script. What does it do? Well, simple: it chews up shorthand blurb, like the one you're picking through now, and spits it back out in the flavor of a certain author close to my heart, our man Murakami himself. Now, you can sneak a peek at both these scripts down below and take in the art piece a notch above.

Both scripts neatly tuck away the outputs onto my clipboard. Handy for the lazybones that like me, can use ‘em just about anywhere across the machine. Embrace sloth!

i wrote two scripts today that should hopefully harken the return of instabrams. i created a dall-e pipeline that takes text, summarizes it and turns into a cover art.
in addition i wrote a script that rewrites shorthand like you are reading now into the style of one of my favorite authors, haurki muarkami. you can see both of the scripts below, and the art for this peice in the image above.
importantly, both copy results to clipboard for usage anywhere across my machine. let's go laziness!

Really would be nowhere without these amazing tools that devs have built (Ghost, Obsidian, GPT). I merely build the ligaments that connect the very solid bones.


GitHub rang the bell for the 700th star on chat gpt md today. It's been awhile since any updates were added, and I can't help but feel a twinge of regret. But the open source world - well, it can be a free ride for some folks, especially amongst the Obsidian folks. It's like being a chef with everyone sampling your soup, but no one foots the bill.

there was an enormous disconnect between how we think open source works and what is actually happening on the ground today. There is a long, and growing, tail of projects that don’t fit the typical model of collaboration. Such projects include Bootstrap, a popular design framework used by an estimated 20% of all websites, where three developers have authored over 73% of commits. Another example is Godot, a software framework for making games, where two developers respond to more than 120 issues opened on their project per week.† -- Working in Public: The Making and Maintenance of Open Source Software

Create a Ghost Cover Image with DallE

import dotenv from "dotenv";
dotenv.config();

import OpenAI from "openai";
import clipboard from "clipboardy";
import fs from "fs";
import fetch from "node-fetch";

const openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY });

async function summarizeClipboard() {
  const text = clipboard.readSync();
  // console.log(`Summarizing: ${text}`);
  const completion = await openai.chat.completions.create({
    messages: [
      {
        role: "system",
        content:
          "Summarize the following into a theme and create an art prompt from the feel of the text aesthetically along the lines of: 'an abstract of [some unique lesser known art style from history] version of {x}' where x is the feel of the text aesthetically. Just return the art prompt, say nothing else." +
          text,
      },
    ],
    model: "gpt-4",
  });

  // console.log(`Summary: ${completion.choices[0].message.content}`);

  return completion.choices[0].message.content;
}

async function saveImgFromUrl(url) {
  const response = await fetch(url);
  const buffer = await response.buffer();
  const filename = `./dalle-images/${Date.now()}.jpg`;
  fs.writeFile(filename, buffer, () => console.log("finished downloading!"));

  return filename;
}

async function appendToLog(logItem) {
  const log = JSON.parse(fs.readFileSync("./log.json"));
  log.push(logItem);
  fs.writeFileSync("./log.json", JSON.stringify(log, null, 2));
}

async function main() {
  let prompt = await summarizeClipboard();
  prompt = prompt.replace("Art Prompt: ", "").trim();
  const image = await openai.images.generate({ prompt: prompt });
  const imageUrl = image.data[0].url;

  const imgFilename = await saveImgFromUrl(imageUrl);

  const log = {
    query: clipboard.readSync(),
    prompt: prompt,
    imageUrl: imageUrl,
    imgFilename: imgFilename,
  };

  await appendToLog(log);

  // save prompt to clipboard
  clipboard.writeSync(prompt);
  console.log("./dalle-images/" + imgFilename.replace("./dalle-images/", ""));
}
main();

Rewrite Chicken Scratch as Murakami

import dotenv from "dotenv";
dotenv.config();

import OpenAI from "openai";
import clipboard from "clipboardy";
import fs from "fs";

const openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY });

async function rewriteClipboard() {
  const text = clipboard.readSync();
  // console.log(`Rewriting: ${text}`);
  const completion = await openai.chat.completions.create({
    messages: [
      {
        role: "system",
        content:
          "Rewrite the following in the style of Haruki Murakami, using short, punchy, easy to read, simple words that flow. Almost as if spoken cadence. Text:\n" +
          text,
      },
    ],
    model: "gpt-4",
  });

  // console.log(`Rewrite: ${completion.choices[0].message.content}`);

  return completion.choices[0].message.content;
}

async function appendToLog(logItem) {
  const log = JSON.parse(fs.readFileSync("./log.json"));
  log.push(logItem);
  fs.writeFileSync("./log.json", JSON.stringify(log, null, 2));
}

async function main() {
  let prompt = await rewriteClipboard();
  prompt = prompt.replace("Rewrite: ", "").trim();

  const log = {
    query: clipboard.readSync(),
    prompt: prompt,
  };

  await appendToLog(log);

  // save prompt to clipboard
  clipboard.writeSync(prompt);
  console.log("Prompt saved to clipboard");
}
main();

Images From the Script

These have wriggled under my skin, becoming my favorites of the day. You can make buckets of them without breaking much of a sweat. Keep your eyes on the blog – there's more visual feast on the way!

https://bram-adams.ghost.io/content/images/2023/08/bramses_A_Futurism-style_depiction_of_an_abstract_human_figure__e79092cb-85c9-455b-a712-c383189f701b.png
bramses_A_Futurism-style_depiction_of_an_abstract_human_figure__e79092cb-85c9-455b-a712-c383189f701b.png
https://bram-adams.ghost.io/content/images/2023/08/bramses_Art_Prompt_Create_a_Tonalist_and_Symbolist_fusion_manif_17f75554-e2fc-449e-8380-9f44cd92965c.png
bramses_Art_Prompt_Create_a_Tonalist_and_Symbolist_fusion_manif_17f75554-e2fc-449e-8380-9f44cd92965c.png
https://bram-adams.ghost.io/content/images/2023/08/DALL·E-2023-08-21-15.55.18---Art-Prompt_-Create-a-Tonalist-and-Symbolist-fusion-manifesto-of-an-enchanting-wilderness-filled-with-mystic-animals-and-towering-trees-embodying-the-p.png
DALL·E 2023-08-21 15.55.18 - Art Prompt_ Create a Tonalist and Symbolist fusion manifesto of an enchanting wilderness filled with mystic animals and towering trees embodying the p.png
https://bram-adams.ghost.io/content/images/2023/08/1692647643756.jpg
1692647643756.jpg
https://bram-adams.ghost.io/content/images/2023/08/1692645793636.jpg
1692645793636.jpg
https://bram-adams.ghost.io/content/images/2023/08/DALL·E-2023-08-21-15.21.35---Create-an-abstract-version-of-the-Cubism-style-that-portrays-the-challenges-of-financial-burdens-and-health-care-costs.png
DALL·E 2023-08-21 15.21.35 - Create an abstract version of the Cubism style that portrays the challenges of financial burdens and health care costs.png
https://bram-adams.ghost.io/content/images/2023/08/DALL·E-2023-08-21-15.13.12---Create-an-abstract-watercolor-version-of-the-constant-struggle-between-the-expansion-and-collapse-of-the-mind.-Use-vibrant-colors-and-fluid-brushstrok.png
DALL·E 2023-08-21 15.13.12 - Create an abstract watercolor version of the constant struggle between the expansion and collapse of the mind. Use vibrant colors and fluid brushstrok.png
https://bram-adams.ghost.io/content/images/2023/08/bramses_An_abstract_Quilting_Art_version_of_the_intersection_be_bfa3dc6d-2abb-4e57-8699-b8970fdbf520.png
bramses_An_abstract_Quilting_Art_version_of_the_intersection_be_bfa3dc6d-2abb-4e57-8699-b8970fdbf520.png

Half a decade past, this is where I lived.

I snapped this photo, and soon after found myself in a nearby bar, nursing a drink and ruminating on the past five years. I had some predictions right - walking away from full-time software engineering to chase dreams of startups and artistry. But there were surprises too - who could've predicted a pandemic, or AI taking great leaps ahead?

I pondered over the goals I set for myself in 2018 - many still unmet, many still echoing around my head. Is that a good thing or a bad thing? Not sure. But one thing I've learnt is this: success is a recipe. It calls for dogged effort, an accreting outlet for said effort (think: investment returns), a dash of lady luck, and being at the right place just when it's the right time. Voila, dreams come true and they'll call it fate.

Like Ging said to Gon, "I can't get there quite yet, but I'm relishing the ride."

"Five years ahead?" I reckon I'll be there, right at the threshold of that old, worn out door of mine.

Oddly enough, it seems as if my eyes on the photo on the right been brushed with a dash of guyliner. Can't make heads or tails of that, honestly.

bramadams.dev is a reader-supported published Zettelkasten. Both free and paid subscriptions are available. If you want to support my work, the best way is by taking out a paid subscription.

Issue 13: Blogging in 3D

Better Never-Better than Better-Never, I suppose!

< Previous Issue

Ye Olde Newsstand - Weekly Updates

Unintentionally, blogging got a major, major boon from an unexpected place: Share Chats from ChatGPT. That sounds crazy, but it's true! Come take a look at my argument as to why this is a really big deal!

Blogging Has Just Changed Forever and No One Is Talking About It
Blogging has recieved a major upgrade, from an unexpected place.

This content is for Members

Subscribe

Already have an account? Log in

Blogging Has Just Changed Forever and No One Is Talking About It

Blogging has recieved a major upgrade, from an unexpected place.

💡
TL;DR: OpenAI just released share chats, allowing readers to get a insanely powerful look into the thought process of a writer and allowing the writer to increase the value of their blogs for little to no extra work. We examine the draft phase and edit phase, with a ton of examples embedded along the way!

note: I highly recommend you click all the links in this piece.

The blog-o-sphere has been taking major L's on the Internet as of late. Bloggers have taken loss after loss to platforms like TikTok and Twitter, where producers have had the "pleasure" of competing for likes amongst the chaos of noise, where the lone individual yells until their lungs sting with pain in a vain attempt to be the tallest soapbox in the shampoo aisle.

For small indie bloggers that sought their 1000 true fans, the torch of hope seemed to be entering its dying light phase, quietly exiting stage left to an Internet run by a few large aggregation sites. There was just no cost effective way to have competitive advantage over an endless stream of algorithmically curated material, an IV drip feed of jump cuts and words.

And just as all hope seemed lost, a horn sounded in the distance. Our unexpected saviors had arrived. The cavalry was here.

Share Chats from ChatGPT. Yes, you heard me right. That thing that allows people to effectively screenshot chats with a machine learning model. Let me repeat that. Share Chats from ChatGPT.

Allow me to elaborate on why this is a huge deal.

Those Who Write Actually Think

If you've ever dabbled with the idea of taking writing as a craft seriously, you'll know that all writing (and I really do mean all: from drunk text messages to an ex all the way up to graduate level books on theoretical quantum physics) is composed of two steps: conjecture and error correction, or in layman's terms, the draft phase and the edit phase. Every writer has their preference and quirks: some only write in the mornings, some write on typewriters, some dictate to their Voice Memos app during their jogs.

But all writers think. All writers think new thoughts, and then tear away at the thoughts they created. All writers build and prune, build and prune, and build and prune, until you, dear reader, see a meticulously-engineered polished final piece of work, quieter than a hunting owl and smoother than a…uh…some really smooth thing.

The thing is, up until now, the final work was all the reader got to see and all the writer could manage. Blogging, even with it's unique ability to leverage hyperlinks out to research and other blogs, was largely a one dimensional effort.

Enter ChatGPT

Ok, so where does ChatGPT fit into this puzzle? How can it increase the value of a blog post for the reader and the writer? I'll tell you! ChatGPT is…drumroll please

ChatGPT is frozen externalized cognition.

Whaaatt?? you might rightfully be thinking right now. How can we think outside our heads? And what does it mean to "freeze" cognition?

To answer this question, we need to examine the act of thinking in the two phases of conjecture and error correction above.

Conjecture

Conjecture is a fancy word for hypothesis which is a fancy word for educated guess which is a fancy term for cool idea that has a non zero chance of failure.

To make a new conjecture, one must be willing to trial multiple ideas and…well, see what sticks. Some ideas are good. Few ideas are really, really good. Most ideas are meh to bad.

The ideal conjecture phase is pure play. Don't set out to quell or snuff out any ideas, there are no bad ideas when the idea itself is to explore the space of ideas.

Conjecture lives mostly inside the mind, but that does not imply that conjecture only lives inside the mind. Think about the last time you were at a brainstorming session. Multiple minds were put to the task of solving one problem, but the thing is, all the participants have different backgrounds. Every person has their own set of priors, a fancy term for their own viewpoint built out of their unique experience and therefore show up to the table with a different offering to solve the shared problem.

Great, you may be saying, but if this is internal or done with a group, how does ChatGPT help?

In short, ChatGPT is a really, really good improv partner ("yes, and…"). Basically, thanks to RLHF training, the model will go along with any wacky idea you give to it -- it truly has zero preference about whether you want to opine on the best pizza place in Topeka, Kansas or discuss the finer points of the last Game of Thrones season. GPT. Will. Play.

Without judgement, you as a human can lead the Dance of Death as the instruments of your mind and ChatGPT play their frenetic tune into the rabbit hole of whatever the hell you please.

As an example, GPT in it's judgement free zone, can help you find words to express the idea you are looking to say.

Remember this from above?

And just as all hope seemed lost, the horn sounded in the distance. Our unexpected saviors had arrived. The cavalry was here.

Co-conjectured by me and ChatGPT.

Or this?

meticulously-engineered polished final piece of work

Also ChatGPT.

Or how about this from a second ago?

you as a human can lead the Dance of Death as the instruments of the mind play their frenetic tune into the rabbit hole of whatever the hell you please

Chat FREAKING G. P. T.

The conjecture phase with Share chats is basically a thought process camera (take a snapshot) and resolution increaser (see the steps of the mental recipe). It clarifies your ideas, helps you play with more concepts to go even further, and freezes this "play" phase in time for your readers to see the foundational aspects of your argument.

Error Correction

This brings us to the second phase, the whittling away of the marble sketch we created in the conjecture phase, error correction.

If conjecture was exploring the space by opening all available doors, error correction is going around and slamming each one by one until only the fittest remain.

When we are editing, we are literally proclaiming our thoughts to the public. These thoughts are sent out into the wild to be upvoted and downvoted, shared, mulled over, and eviscerated in comment boards.

The process of editing is baked into the reality we (you, me, the neighbors' dog, Canada, an oak tree, a pod of whales,…) share. All writers have a duty to translate the goings-on in their minds as faithfully as possible to an external audience of readers. And thus writers edit. Writers hire teams of publishers to bleed over word choice, to fight to cut entire paragraphs from a piece, to destroy the tower but leave the base intact. And stronger.

GPT serves as a great editor. Looking for a different way to say something? How about multiple ways to say something with pros/cons in tabular format?

No problem.

The edit phase is about tradeoffs. Cutting some ideas in favor of others. Choosing one phrase instead of another since it is likely to be understood by the target audience. But no idea, no theory -- is perfect. In fact, some ideas might be in direct conflict with each other and both remain true, and until now, there was be no way for the reader to divine this from the final edited work without a ton of caveats plainly stated by the writer. Share Chats allow the reader to see the edit choices made by the writer.

Editing also got a major, major upgrade.

Conclusion

OpenAI just released share chats, allowing readers to get a insanely powerful look into the thought process of the writer and allowing the writer to increase the value of their blogs for little to no extra work.

This makes blogging, thanks to it's core technology of hypertext, now multi-dimensional in nature, where the thought process of the blogger can be frozen as literal threads for the reader to dive into. This is a huge win for blogging, and aggregators have not caught up to the value add of this yet.

Forget chain of thought language model prompting, hello chain of thought blogging!

Other Examples You Might Want to Try

  • finding the right word that fits the flow of your piece better
  • coining a creative turn of phrase or trying to teach a new concept
  • summarizing something into simpler conceptual terminology
  • arguing about pros and cons
  • simulating audience questions or comments
  • "invoking" the style of writer's you look up to to emulate
  • creating a "writers table" to edit your work in third person

And these are just off the top of my head.

One Last Thing

Hugely, and I mean hugely, these share chats are also templates. What does this mean? This means a reader gets to continue the writers thought process with their own cognitive understanding and background. They get to take the writer's seeds of thoughts, and recompose them in their own garden, like taking a lemon from your neighbors prolific lemon tree to plant in your own backyard.

It’s like an MMO for blogging between the reader the writer and the LLM, I can’t overstate the importance of this.

P.S I Lied, There's Something Else. Something Big

Blogging isn't the only work product that has been quietly disrupted by Share Chats. Interested in learning about this? Sign up for the newsletter to be informed of when it drops!

Hint(!):

You now get a front row seat into the mind of the coder, and since GPT/copilot is writing all out code anyway these days, you get to see the libraries it prefers to reference, and how to move towards or away from these imports.
No longer do you have to guess what some previous incarnation of the Avatar some software developer was LARPing as, you can literally see their thought process.

bramadams.dev is a reader-supported published Zettelkasten. Both free and paid subscriptions are available. If you want to support my work, the best way is by taking out a paid subscription.

June 06 2023

City on fire (hot!)

Videos

Over 200 AQI in NYC (yikes)

Thoughts

I've been using my shortcuts to keep track of a food journal, always cool to overload an automation cornerstone (capture workflow) into a brand new highly useful adaptation


I've been writing a lot, my draft folder is bulging with 3+ essays waiting to be published, wow!

Code

Use GPT-4 to automatically diagnose errors whenever they are thrown, this is already proving hella useful (so much so I might convert it into a library so it can be used across projects), check it out here.

(full code below (...mostly))

error_wrap.py

import openai
import os
import dotenv
import json
import sys
import inspect

# read these for more info:
# https://chat.openai.com/share/9341df1e-65c0-4fd8-87dc-80e0dc9fa5bc
# https://chat.openai.com/share/193482c6-e7b3-4022-b42b-cd2530efb839

dotenv.load_dotenv()

openai.api_key = os.getenv("OPENAI_API_KEY")

async def run_chat_prompt(prompt, model="gpt-4"):
    completion = openai.ChatCompletion.create(
        model=model,
        messages=[
            {"role": "user", "content": prompt}
        ]
    )

    return (completion.choices[0].message.content)

def wrap_error(e: Exception, description: str = None):
    exc_type, exc_value, exc_traceback = sys.exc_info()
    filename = exc_traceback.tb_frame.f_code.co_filename
    line_number = exc_traceback.tb_lineno
    func_name = exc_traceback.tb_frame.f_code.co_name
    module = inspect.getmodule(exc_traceback.tb_frame)
    function_obj = getattr(module, func_name)

    # Get and print the source code of the function
    func_code = inspect.getsource(function_obj)

    error_message = f"This error message occurred because of '{str(e)}' at line {line_number} in file {filename}, function {func_name}. The exception type is {exc_type}. The function is: \n\n```python\n{func_code}\n```\n\n How do I fix this?"
    if description:
        error_message += f'Other details: {description}'

    return error_message

main.py

import error_wrap

async def main():
    try:
       raise Exception("test")
    except Exception as e:
        potential_fix = await error_wrap.run_chat_prompt(error_wrap.wrap_error(e))
        # an optional description can be added with something along the lines of: error_wrap.wrap_error(e, "here's some specific info passed in by me, a human")
        return {"error": str(e), "potential_fix": potential_fix}

Audio

I was on a podcast about GPT-4 and Go! Check it out here.

Freeform

bramadams.dev is a reader-supported published Zettelkasten. Both free and paid subscriptions are available. If you want to support my work, the best way is by taking out a paid subscription.

May 18 2023

8-bit bram, queen charolette, nyu itp, agentic process humans vs bots, voice memos to whisper

Images

8-bit bram

https://bram-adams.ghost.io/content/images/2023/05/and-thats-on-compressong-ong.png
and thats on compressong ong.png
https://bram-adams.ghost.io/content/images/2023/05/bti-cover.png
bti cover.png

Bridgerton - Queen Charolette

I am Venus

https://bram-adams.ghost.io/content/images/2023/05/i-am-venus-1.png
i am venus 1.png
https://bram-adams.ghost.io/content/images/2023/05/i-am-venus-2.png
i am venus 2.png
https://bram-adams.ghost.io/content/images/2023/05/i-am-venus-2.5.png
i am venus 2.5.png
https://bram-adams.ghost.io/content/images/2023/05/i-am-venus-3.png
i am venus 3.png
https://bram-adams.ghost.io/content/images/2023/05/i-am-venus-4.png
i am venus 4.png

Code

This is great, I recommend!

Transcribing your iOS Voice Memos to Markdown with Whisper - Artur Piszek
I wrote a script to transcribe my apple voice memos to Logseq with OpenAI Whisper.

Went to NYU ITP Spring 2023, here were my favorite booths:

Videos

My internet is way better now -- thanks FioS! -- so I celebrated with a stream working on my monorepo and I had fun.

Perhaps the craziest workout I've ever seen

https://exrx.net/WeightExercises/Sternocleidomastoid/BWFrontNeckBridge

Zenitsu be doing it

When you realize that this guy and Caster got the happiest ends out of every main character in this series…

Music

Raw Thoughts

Animals unconsciously agent in their environment and change it (overeating resources -- finches for example)

Humans consciously agent their environment and change it (global warming for example)

Programs agent their environment in a feedback loop that is not conscious in the sense of serving the need to eat for survival but not unconscious due to fact that they know what’s going on with access to state of impossibly massive systems (which is why humans get caught off guard by bugs)


If coding with an LLM was painting, gpt serves as the broad strokes applied to the sketch of an artist -- it’s hallucinations serve as the rough edges of the paint stroke on the canvas. The artist meticulously changes a line or two and instead of deciding to paint a mountain in the background he decides to paint a tree and asks the LLM to draw the broad strokes of a tree and to reintegrate the surrounding landscape to make the tree seem like it was always there. But he doesn’t remember the size of a tree so he uses LLM as a reminder of how tall they are what color the bark is how many leaves a tree has, etc.

bramadams.dev is a reader-supported published Zettelkasten. Both free and paid subscriptions are available. If you want to support my work, the best way is by taking out a paid subscription.