Vibe Coding an AI Chat Exporter: What Actually Breaks

Ask any coding assistant to write a ChatGPT export converter and you will have working code before you finish reading the prompt back. The code runs. It produces files. It is also, almost always, wrong in the same six ways. None of these throw errors. That is the problem. 1. Messages come out in the wrong order The gen…

Ask any coding assistant to write a ChatGPT export converter and you will have working code before you finish reading the prompt back. The code runs. It produces files. It is also, almost always, wrong in the same six ways.

None of these throw errors. That is the problem.

1. Messages come out in the wrong order

The generated parser almost always iterates over the \mapping\ object and sorts by \create_time\. Reasonable, and incorrect. The mapping is a tree keyed by node ID, and timestamps across branches interleave. The correct traversal starts at \current_node\ and follows \parent\ links up to the root, then reverses.

How to spot it: an answer that references something the user has not said yet.

2. Every regenerated answer appears

When you hit regenerate in ChatGPT, the old response is not deleted. It stays as a sibling branch. Flat iteration emits all of them, so a conversation where you regenerated three times shows four consecutive assistant messages saying nearly the same thing.

How to spot it: transcripts noticeably longer than you remember, with repeated answers.

3. Conversations that come out empty

Not every node is a user or assistant turn. System messages, tool calls, and hidden context nodes have different content shapes. A parser that assumes \message.content.parts[0]\ is a string will produce empty output for entire conversations rather than crashing.

How to spot it: files with a title and nothing under it.

4. Code blocks turned into soup

Message content is Markdown inside a JSON string. Writing that string directly into a Word document gives you literal triple backticks in body text, and lists that lost their indentation. Real Markdown parsing plus real docx styling is the fix, and it is several hours of work, not a string replace.

How to spot it: open a conversation with code in it, in Word. You will know.

5. Emoji and accents vanish from PDFs

Default PDF library fonts are Latin-only. Emoji, accented characters, Cyrillic and CJK glyphs are dropped or rendered as boxes with no warning. Embedding and subsetting a font like Noto Sans fixes it, and adds another dependency to maintain.

How to spot it: search your PDF for a character you know was in the chat.

6. It breaks the next time the format changes

Export schemas change without announcement. A script pinned to one snapshot of one platform's format is a maintenance commitment, not a finished project. This is the bug that arrives months later, when you have forgotten how any of the code works.

Why the assistant misses these

Coding assistants are pattern-matching on JSON parsing, and this file is not shaped like the JSON in their training distribution of examples. Getting it right requires having opened a real export and noticed that the tree has branches. The assistant has not done that. You have to, which means doing the work you were trying to delegate.

The honest version

You can fix all six. Each one is another round trip, another test export, another evening. If the project is the point, that is time well spent and you should absolutely do it.

If you just want readable files, ChatExports already handles all of it across nine platforms, runs entirely in your browser so nothing is uploaded, and costs $10 for one platform or $25 for all of them, once. The full cost comparison, with a calculator for your own hourly rate, is on the build vs buy page.