---
name: chatgpt-export-to-codex-context
description: Distill a downloaded ChatGPT data export into a clean Codex context packet: voice profile and durable business context, without dumping the whole export into Codex.
triggers:
  - set up my Codex context from my ChatGPT export
  - turn my ChatGPT export into Codex context
  - extract voice and context from my ChatGPT data
  - user shares a path to a ChatGPT export folder or ZIP
inputs:
  - export_path: ChatGPT export folder or ZIP, typically named chatgpt-export-* and containing conversations.json
  - business_name: optional, used to name output files
outputs:
  - voice-profile.md: extracted voice and language patterns with carefully selected examples
  - business-context.md: durable business context such as offers, positioning, ICP, voice rules, and active decisions
  - extraction-report.md: what was kept, what was skipped, and why
---

# ChatGPT Export to Codex Context

## Why this skill exists

A ChatGPT export can contain months or years of conversation. Most of it is noise to a working agent: troubleshooting threads, half-finished drafts, questions the user has since answered through files, and private material that should not move into an active agent context.

Codex can be granted access to more working context than ChatGPT usually had: local files, connected plugins, approved credential routes, repositories, websites, and the real workflow the owner runs every day. What Codex actually needs from the ChatGPT export is narrow:

1. Voice and language patterns
2. Context that does not live anywhere else, such as decisions made out loud, positioning tested in a thread, or the reason behind an offer

This skill extracts those two things and ignores the rest.

## What to do when triggered

### Step 1: Validate the export

Confirm the input path contains a ChatGPT export.

Look for `conversations.json` at the path, inside the folder, or one level inside the ZIP. If the export is zipped, inspect the ZIP structure before extracting. If `conversations.json` is not found, stop and ask the user for the correct path.

Do not guess. Do not process unrelated files.

### Step 2: Create a private output folder

Create a sibling output folder named:

```text
codex-context-from-chatgpt-export/
```

If the user provides a preferred private output path, use that instead.

Do not place outputs in a public repo, shared drive, synced client folder, or website directory unless the user explicitly asks for that and confirms the privacy risk.

### Step 3: Sample for voice

Read 20 to 30 conversations spread across topics and time. Prioritize conversations where the user is explaining, deciding, selling, teaching, correcting, or giving feedback. Extract:

- Sentence rhythm, short vs. long, declarative vs. conversational
- Repeated vocabulary, verbs, framing words, and brand-specific terms
- Punctuation habits
- Tone, such as direct, exploratory, formal, warm, blunt, or skeptical
- Recurring frameworks, beliefs, and teaching moves
- What the user does not say, including banned phrases and anti-patterns

Write `voice-profile.md` with pattern descriptions and 5 to 10 short sentence-style samples. Use samples to illustrate style, not to expose private facts.

### Step 4: Mine for durable business context

Identify conversations that contain:

- Offer or pricing decisions
- Positioning statements
- ICP descriptions
- Brand voice rules the user articulated
- Names of products, programs, services, or frameworks with brief descriptions
- Strategic framings the user has repeated
- Business rules or preferences that are still likely active

Skip:

- Troubleshooting threads, broken tools, errors, or debugging unless the decision is still operationally relevant
- Half-finished drafts that did not ship
- Questions the user asked but did not act on
- Personal or private content, including relationships, health, finances, legal matters, and family information
- API keys, passwords, OAuth tokens, recovery codes, billing details, or credentials
- Client names, client emails, or client-specific private data unless the user explicitly approves
- Conversations older than 24 months unless they contain still-relevant positioning

Write `business-context.md` organized by:

- Offers
- Positioning
- ICP
- Voice Rules
- Active Decisions
- Open Questions
- Do-Not-Assume Rules

Preserve uncertainty. If a detail is inferred, label it as inferred and include confidence.

### Step 5: Report what you did

Write `extraction-report.md` with:

- Total conversations in the export
- Number sampled for voice
- Number used for context
- Number skipped, grouped by reason
- Any sensitive categories found and excluded by default
- Any gaps the user should fill manually

Do not include sensitive excerpts in the report.

### Step 6: Confirm with the user

Show the extraction report and a concise summary of the two output files.

Ask before moving `voice-profile.md` or `business-context.md` into the active Codex context, Agent Homebase, project `AGENTS.md`, or any shared workspace.

Do not auto-load the files.

## Safety rules

- Never copy API keys, passwords, OAuth tokens, recovery codes, or credentials into output files.
- Never copy client names, client emails, or client-specific private data into output files unless the user explicitly approves.
- Never copy health, financial, legal, family, or relationship information.
- Never auto-overwrite an existing `voice-profile.md` or `business-context.md`.
- Never upload the export or extracted files to a third-party service.
- The original export stays untouched.

## What success looks like

A user with a large ChatGPT export ends up with two short markdown files, usually 1 to 3 pages each, that capture how they sound and what their business actually is.

Codex uses those files instead of trying to ingest the full export.
