Prompt Walkthrough: Fixing my 3D printer with Codex (and Chutes & Ladders!)
We need more examples of prompting agents into completing big tasks. I used to think it was easy, you just type like you’re asking a super smart friend. But people keep looking confused, as if it’s hard. So, let’s just work through some examples here.
First up, I had some issues with my 3D printer (uh, I fixed it wrong a year ago and now it’s haunting me). I tried using ChatGPT a couple weekends in a row, and finally decided to revert to full Codex.
Here is a prompt I used. It’s heavily annotated, I recommend clicking through everything.
hey, I have this 3d printer. I’m trying to fix it. My brother gave me this printer, it looked new out-of-the-box, but felt like it shipped straight from china. Like all the instructions were in chinese. He does a ton of business in china, so it seems likely that he did indeed buy it from a chinese supplier and it shipped straight from china
ok, so the issue I’m trying to solve is the hotend is clogged. I’ve gone back and forth with chatgpt a while on it. I’ve consolidated a lot of the chat here: chatgpt-transfer.md
iPhone HEIC pics here in the root are just the 3d printer from various angles.
ChatGPT suggested buying a new print head. I looked online and it was like $120, which is 50% of the cost of a whole new printer (the new kind that doesn’t have these problems). I don’t want to spend $120, let’s keep it under $50. If you need me to buy new parts, send me links to reputable buyers. I’ve added more HEIC pics also of a hotend I bought already.
Now, when you write, I understand that it’s very tempting to use shorthand. Please don’t. Please talk to me like I’m a dumbass bussiness person who just tried plugging the printer power chord into a wifi router. Use visual aids. Make it fun and easy to follow. Raccoons and goblins? Sure. Whatever.
Also: this week openai reduced pricing of Luna by 80% and Terra by 20%. That means both of these (quite capable models imo) are extremely cheap. I have you (Sol) on max effort because I’m confident your intelligence will be able to wield these resources appropriately. This is a chatGPT sub though, so we only have a single 5hr block to compute our way out of this. Use it wisely.
If you have questions, you are welcome to ask me. You’re also welcome to install tools, just let me know if you’re modifying my computer.
Click here to open it’s first take on the web app (it’s really cool!). It made great use of Three.js.
In my head, it mostly feels like I’m just chatting with a super smart friend. But it probably seems complicated, because I’ve gotten to know that friend and maybe you haven’t.
Notes
The greeting
I usually go goofier. I figure I’m talking to some intelligent being and whatever I say at the beginning sets the tone for the rest of the conversation. Like you would if you were talking to a friend or a coworker. After all, they were trained to imitate people, so obviously they’d act like people in this sense.
Establish expectations
It’s a good idea to open with some rough idea of what you’re asking them for. Advice? Design? Problem solving? Again, it’s like talking to a person. Everything they hear is going to be filtered through that lens.
Now technically, an LLM sees all of your words simultaneously, so it works differently than people. For us, we hear/read the words one-after-the-other, in slow sequence. I guess that means we don’t have to start off like this, but old habits die hard. A better reason to do it is I sometimes get lost in my thoughts while writing the prompt and forget to ask a basic question like, “how to I fix it?”. So starting off with this is more just for me, I guess.
The China context
Agents eat context. The problem with being an intelligent entity but not actually having a body, is AIs miss out on a huge amount of information. So here I’m just trying to lay the foundation for the possibility that my 3D printer isn’t actually a normal stock OOTB device.
I also didn’t want to tell it that it wasn’t normal. If I did that, it might get stuck in that line of reasoning. By phrasing it this way, I’m giving the agent permission to doubt, without instructing it to do so.
Explain the problem
The real issue, explained better. It’s important to clearly state the problem. I did an unclear version right at the start. Really I only need this version.
I don’t edit my prompts at all. I just type pretty much stream-of-consciousness, so yeah, duplication happens.
Context for context
Context is super important. Agents eat context, the more you can provide, the more they can do.
I already went on with ChatGPT for two rounds already, and I didn’t want to make the same mistakes. So I opened up the old conversations and had it summarize (1) just the facts that I provided, and then (2) the inferences it had made. I kept them separate. I had ChatGPT write it up because I’m lazy and didn’t want to type it again. I told ChatGPT that I was handing off to Codex, so that put it’s mindset into a knowledge transfer mode, to get what I was looking for.
Since I had already gone through the trouble to type it up, this seemed like the most expedient route to reusing that context.
Provide pics
I took a pictures from my phone at several angles. Basically every angle I could think of, then moved them over to my laptop. On my laptop I had created a directory to dump these files, a work directory. I didn’t do any curation, the LLM can do a fine job of that. It just read all of them anyway.
This particular problem is extremely visual. Without pictures, the agent knows nothing except for what I say. But, I’m actually not that knowledgeable in 3D printers, so every time the AI tries to do some experiment, I get highly annoyed. By including a bunch of pics, I bypass a whole lot of problems.
Later on, we take even more pics, and those prove to be the linchpin evidence needed for a breakthrough.
Money banter
Context is king. Rather than simply telling it how much to spend, I’m intentionally spilling my internal mental state in regards to spending money. Yes, I’m going to follow up with a constraint, but this is what I’m really thinking.
If I simply state the constraint, then I’m worried that it’ll get distracted and try to spend money. Whereas I really just want to offer it the possibility of buying new parts.
But also, I’m opening up the possibility of giving up and just buying a new printer. Whatever happens, it now has the context to reason about what the most reasonable next step is.
Constraints
State the constraints clearly.
Agents eat context, of course, but they also excel at staying within absurd constraints. They love constraints. In fact, if you have crazy constraints, you absolutely should be using AI to work though it.
More constraints is better, but only if they’re hard constraints. If they’re flexible, mention where they can flex.
Communication
Establish how I want to be communicated with.
For this, it’s highly visual. When I’m looking at the device I often can’t figure out what I’m looking at.
Three.js — this is something I’ve recently discovered. It’s a game engine, I think, where you can build 3D environments in the browser. I bet you’d have to be sadistic to sling Three.js code manually, but LLMs can do it all day without issue. Code is how they interact with the world. Fwiw I love what it came up with.
Throughout this, I often intentionally try to be vague when I don’t absolutely need something specific. LLMs are quite creative and talented, and quite often the thing they come up with is better than whatever I was thinking.
Anti-shorthand clause
Ever since Opus 4.7 I’ve noticed that all LLMs are deviating hard into a dense shorthand that’s hard to follow. They’ll invent terms and I’ll think I’m just an idiot for not being able to follow. Turns out the language is constantly changing.
Please talk to me like I’m a dumbass bussiness person who just tried plugging the printer power chord into a wifi router.
This line makes me laugh. But also it feels like something someone would have said to me when I was young, smart, and had no idea how to communicate with superiors.
Racoons and goblins
Okay, long story. Basically when GPT-5.5 was released, a few days after people realized there was some language in the codex system prompt about racoons, goblins and magical creatures. OpenAI wrote a blog post about the incident. It was something to do with RL reinforcing behaviors.
But I like the goblins & raccoons. I periodically try to coax GPT into being it’s true self, because it’s fun. But also, I tend to think an AI will do better work if it’s not being constantly hand-slapped, like a human (they’re imitating them after all)
Reduced pricing
Rather than just saying “use Luna”, I give some details for why it’s important to me. The intelligent LLM can reason through how hard it needs to try to use this model as a subagent.
Compliments
This is my way of giving the agent permission to use
Why is autoregression a problem?
Autoregression is when the model generates the next token, one token at a time until the output is complete (versus diffusion where all tokens are generated simultaneously).
Things have changed more recently, but it used to be that models were trained to believe that everything in the conversation thus far was true. And while it’s no longer the case, the beginning of a conversation still sets the tone, similar to how first impressions work with people. Henceforth, you see all through that lens.
So autoregression is a bit like a narrowing hallway. It’s difficult for the LLM to suddenly make a surprising turn in logic. Everything kind of just follows the status quo.
Intro
Intros are important. After all, these agents are autoregressive, so how you open impacts how the conversation goes from there. If you want something cool, set the vibe.
Dynamic Workflows
This is a Claude Code feature. You have to mention it by name for the harness to allow Claude to use it. I love it because it enables Claude to string together many subagents in a workflow (actually, just regular code).
Simply mentioning this already makes Claude think in terms of writing code in one workflow, and verifying with another. By not specifying exactly how I want it done, it lets Claude figure it out. Since I was talking to Fable 5, I was pretty confident it would be able to schedule out the dynamic workflow. Fable is able to conceive of the the workflow well.
Use Opus & Sonnet
Trying to nudge it into doing more of it’s work via cheaper models. Since Fable is constructing the workflow and writing all the prompts of each of the subagents, I felt confident that Opus/Sonnet would be more than enough for the individual pieces, as long as Fable is the architect.
“Chaotically falling”
Intentional word choice. Any model can rip off a copy of a game easily, but the 3D part with animations is new. I figure Fable probably used these words as both inspiration for the animations, as well as during verification, “yup, that’s chaotic, done”.
Chutes and ladders
A classic game.
I’m constantly looking out for words and phrases where 2-3 words expand out to whole essays, if you were to explain them. It saves typing and conveys a lot of implicit details.
Building a brand new game with totally new concepts takes a lot more prompting and iteration. Here we can simply invoke it’s name and the LLM knows vaguely what we’re after.
Why Codex?
I tried solving this in ChatGPT two times before this. I wanted to try Codex because:
- The filesystem becomes a library. The pictures I add become assets that can be reused for context. I can start a new agent or conversation and it has access to the same exact assets.
- Output goes into files. The conversation context is volatile. It gets randomly compacted (lost), plus the LLM ignores parts of the context, it has uneven recall over it. But with files, when they’re read, they’re always at the optimal location in context. And you can always re-read them. This makes them a more effective way to store information in long-running sessions.
- Subagents. I’m not sure if ChatGPT can use subagents, but subagents are enormously useful. See below.
Subagents
Subagents are like a normal Codex session that the agent can launch off. It’s how agents can break down the work.
Another way to think about it is a single agent has tunnel vision. It has a hard time thinking beyond what’s top of mind. Whereas each subagent is a different agent with a different tunnel vision.
That’s why it works so well to have one agent write code and another to check/verify it. If they don’t share any conversation, then the verifier is truly looking at it through fresh eyes.
Tunnel vision is a big problem for autoregressive models (how LLMs work). But here you can see that we can wield that same weakness as a rather strong asset. The verification subagents work well because they share no context. They can legitimately look at the problem as if they’d never seen it before.
Wouldn’t it be great, as humans, to be able to fork yourself and look at a problem as if you’d never seen it before? I think it would be quite useful.
Skills
I have a skill setup, both at work and at home, at ~/.codex/skills/working-with-tim
The purpose is to clarify my expectations for agents. I like agents to work autonomously. I expect that when they say the work is done, it’s actually done. I expect them to check their work.
Admittedly, this skill leads to slow response times. e.g. on the printer, it took about 2 hours. But there were no dumb tangents or circles, all the questions were good. At work, I usually get agents to work for 30+ minutes, sometimes as much as 8-10 hours. And when the work comes back, it’s done correctly.a
I like that, it’s how I work. So I setup a skill for it.
I don’t use AGENTS.md anymore, because it doesn’t trust the agent to know when to read it. The harness just
shoves it into the context randomly (in the eyes of the agent).
Conclusion
I’d love to say a lot more about how I think about these things, like model choices and Claude Code vs Codex. But ultimately, it’s just like chatting with a friend. Only, you just have to get to know the friend first.
Get to know what their good at vs not. How their brain thinks about problems. It takes time, but mostly that time is pure fun and tinkering.
Bonus: Chutes & Ladders
As a bonus, here’s another one. My kids were playing Chutes and Ladders (the board game), so I had Claude Code turn it into a video game.
yo, let’s go big. I want to make a Three.js based Chutes and ladders game with real animations. Just the regular chutes and ladders game. When a player moves, it’s a real animation in 3D third person view of them climbing up some ladder or chaotically falling down a slide. Each animation is different. Also animations for each movement.
For working, use dynamic workflows. Try to make heavy use of Opus 5 and Sonnet 5. But specify it clearly for them. Use clean Fable 5 sub agent to validate.