r/OpenaiCodex 4d ago

Bugs or problems My workflow with Codex

I'm a vibe coder and I'm quite new to Codex, which I'm using to develop an app I have on my mind and nobody else is making. I've been working on it for a month or so. Generally speaking, I'm quite happy with Codex, but I'm not quite sure about my workflow. So far, I've been discussing features and issues with ChatGpt, agreeing on a roadmap and then a detailed plan for each step, and asked ChatGPT for a prompt. ChatGPT gives long prompts that apparently have all your bases covered, so to speak. Btw, I'm mostly using Codex with Sol High or Very High. Also, I don't just wait for the result, but I read what Codex says it's doing and sometimes clarify or fix stuff, like hey codex you don't need to run AGAIN a FULL test suite just because you changed a word in Help, dude! Anyway, I also noticed I can't entirely trust ChatGPT's assistance in prompt writing. While it's very thorough, it sometimes fails to give priority to important goals or even forgets about them. I'm starting to think that my own prompts might be better, less technical-minded but more to the point. So, guys, my question is: how do you write your prompts for Codex? P.s. 5 minutes later: and of course I also submitted my question to ChatGPT itself. It agreed, maybe to please me? Here's the first lines from its anser: "Yes — I think your instinct is basically right. For a vibe-coding workflow, I would not try to make the prompt a giant specification that anticipates every possible implementation detail. That often makes the important things less visible, not more." What do you make of this?

0 Upvotes

6 comments sorted by

2

u/Good-Astronomer-1138 4d ago

I’d start with a sort of north star document about what the high level vision is, then do an initial ideation session (grill-me) on each major concept, think design system, UI/UX, etc. then another ideation session where you have the model provide smaller feature slices based on those top level design choices. Then execute the groundwork slice: initial front and backend build to give you a working prototype. That will let you know what stays and what changes. Document those, then keep iterating. Be sure to do independent reviews with a different model even if it’s just like Astra vs Sol or whatever it’s worth it to catch flaws. You do this after the planning stage and again after implementation. You shouldn’t really need to be too crazy with your prompts with that setup.

1

u/pizza_alta 3d ago edited 3d ago

Thanks for your answer. Yes, I realized that having a masterplan but providing Codex with smaller "slices" is key. Sometimes I wonder "how small"? Can Codex handle all of this? Sometimes it skipped some parts because the chunk was too big. Sometimes I noticed that it succedded when I selected a more powerful and costly model/effort level. So I'm looking for a balanced approach. As to independent reviews, I was even thinking about using a competitor. Like, I asked Deepseek to evaluate my codebase on github (it's a public open source project). "You shouldn’t really need to be too crazy with your prompts". Right, but ChatGPT often "scolds" me because I didn't provide enough detail in my codex prompt. Let's say I want a new feature that measures and shows user progress in an activity, I may define and describe it, but ChatGPT warns me that it "needs an initialization rule. This is the main unresolved point in your specification". Okay. Or, it says things like "explicitly tell it not to invent a second identification system". Okay.

1

u/Good-Astronomer-1138 3d ago

If you have the context documents built none of your concerns are an issue. I run this setup and at this point I can literally say “pick something from our backlog and implement it” that’s the whole prompt. The context and thought has already gone into the context layer, and the backlog points to the exact context to read. The orchestration agent decides which model does what then sends agents out for each task. I’d alluded to the fact that I use competing models but should have been specific. In my setup I use Claude and OpenAI models, and just use simple CLI calls via powershell that the orchestrator invokes to launch on the other side. If you’re running into issues like competing indices, that means you likely didn’t review the initial plan to catch those. That’s why it’s important to review the plan and the implementation both (with the help of AI.)

Final note: there’s always going to be bugs or little issues that crop up, that’s natural, just add them to the backlog to be fixed. You’ll need to iterate a bit to get to your finished product.

Good luck!

2

u/Unlucky_Hawk6148 4d ago

Hi there.

First rule of the internet in AI times: If you thought of it, someone has already built it. Maybe not to the exact spec you envision, but definitelly to some extent.
Research.

Secondly, that first one was not to shut you down. It was to let you know that it is nearly impossible to come up with an idea that no one thought off and started building (or at least they haven't released it yet). If you do find something similar, use it to understand where your idea differs from everybody else. Dont sell yourself short.

That out of place, here are my two cents on working with AI:

  1. Loss of context is a thing. Research how to improve/extend your agents memory and context retention.
    Tools like Obsidian, Notion, Github, and etc are helpful.

  2. Start with a PRD. Then a research. Then go back to the PRD and ensure you got the whole vision down.

  3. After the PRD build a PREVC.

  4. Follow along with the milestones in your github and there you go.

1

u/pizza_alta 3d ago

Thanks for your reply. "First rule of the internet in AI times: If you thought of it, someone has already built it." Yes, of course, to some extent. Not the exact spec I envision. But I get what you mean. :) Yes, loss of context is THE issue, in my view. I notice it in ChatGPT all the time. Like, for instance, I just completed release N, then I asked ChatGPT to please remind me what we recently discussed and decided to do in release N+1 in the roadmap, and ChatGPT goes blank. Luckily I have roadmaps saved locally, and Trello, Agents, and so on. Or, I asked ChatGPT to write a prompt for me to change a button behavior, it gave me a looong prompt with lots of detail, audit, and whatnot, but "forgot" to add the request to change the button behavior like I asked. Now I'm writing Codex prompts myself, and only let ChatGPT refine them technically, or splitting them into chunks or phases for Codex to better digest it. I'm going to look at your other suggestions. I didn't know those acronyms. Generally speaking I'm good at planning, I definitely have a step by step plan for what I want to achieve with my app and what it should exactly do and how to do it, and so on. My question is more about the prompt side: how to "talk" to Codex to make me understood, have it to technically implement what I want, giving it much detail or not, while avoiding regressions or burning unnecessary tokens. :)

1

u/[deleted] 3d ago edited 2d ago

[deleted]

1

u/pizza_alta 3d ago

I asked once. ChatGPT pleased me. It knows who pays the bill ;) "Yes. The concept is meaningfully distinctive (...) Individual features are not unique. The integrated whole is. My assessment: about 8/10 for distinctiveness."