The Tech Pulse

January 12, 202612 min read
Tags
  • Codex
  • Openai
  • Https
  • Agents
  • Prompting
  • Patterns
  • Workflows
  • Docs
  • Coding
  • Install
Share

Getting started with Codex

One Sentence Summary

A practical introduction to Codex showcasing CLI/IDE workflows, agents MD, MCP integrations, prompting tips, and advanced automation for coding tasks.

Main Points

  • Codex is OpenAI's coding agent across CLI, IDE, and cloud.
  • Agents MD acts as a lightweight context README for projects.
  • MCP servers connect external tools and docs (e.g., Jira, Context7).
  • CLI and VS Code extension are the primary entry points for use.
  • Install via brew or npm; expect update banners.
  • Sign in with your work email through SSO to use Codex locally.
  • Prompting tips: anchor with mentions, start small, include verification.
  • Use to-dos and prompts in the IDE to guide tasks.
  • Advanced use includes headless mode, multi-step workflows, structured outputs.
  • Plans and docs enable progressive discovery and large refactors.

Takeaways

  • Start with an Agents MD to preload project context.
  • Add MCP servers like Context7 or Jira for real-time data.
  • Use anchor prompts and verification steps to improve results.
  • Employ to-dos and prompts to automate tasks in IDE.
  • Explore headless mode and OpenAI tools for pipelines.

SUMMARY

Derek and Charlie introduce OpenAI Codex across CLI and VS Code IDE, covering installation, agents.md, config.toml, prompting, MCP integrations, code review, and programmatic headless workflows.

IDEAS

  • Codex shifts developers from routine execution toward higher-leverage design and architecture decisions daily.
  • Multiple surfaces matter: CLI, IDE extension, web, cloud tasks, and mobile enable continuous work.
  • Cloud environments enable parallel tasks even with laptops closed, unlocking true asynchronous engineering throughput.
  • Agents.md acts as persistent project context, reloaded every session to prevent repeated onboarding effort.
  • Keeping agents.md under 100 lines reduces conflicting instructions and improves agent focus reliability.
  • Progressive discovery via linked markdown files lets Codex fetch deeper guidance only when needed.
  • Plans.md can become a living checklist, enabling multi-hour refactors with visible progress tracking.
  • Config.toml standardizes defaults like models, sandboxing, approvals, and web search behavior across sessions.
  • Profiles let you choose fast responses or deeper reasoning by switching predefined configuration presets quickly.
  • Approval policies manage escalation, balancing automation speed against safety for risky tool actions.
  • Workspace-write sandboxing limits file changes to current directory, reducing unintended filesystem damage significantly.
  • Prompt anchors using @file mentions reduce wandering, keeping Codex focused on relevant code paths.
  • Starting small tasks builds trust, then scaling to larger projects becomes more predictable.
  • Including verification steps like tests and linters unlocks agentic loops and accelerates iteration.
  • Debugging improves when you paste full stack traces, enabling precise navigation to root causes.
  • Open-ended prompts help brainstorm improvements, then Codex suggests next steps to continue exploration.
  • IDE modes separate chat, agent, and full access, letting users tune autonomy to context.
  • Inline screenshots resolve UI ambiguity, avoiding “third button” descriptions and enabling exact targeted edits.
  • Session resumption preserves context, letting long conversations continue without rebuilding mental state repeatedly.
  • Mermaid diagrams provide fast system understanding, mapping interactions and workflows inside complex repositories.
  • Custom prompt files create reusable slash-like commands, standardizing repetitive tasks like unit test generation.
  • MCP extends Codex with external tools, fetching designs, tickets, logs, and documentation context.
  • Context7 bridges knowledge cutoffs by injecting latest API documentation into agent workflows automatically.
  • Code review aims to avoid noise, prioritizing P0 and P1 issues before production incidents occur.
  • Headless codex exec plus structured outputs enables CI pipelines, bots, and automated quality governance.
  • Agents SDK enables multi-agent handoffs, tool scoping, traces, and controlled long refactors.
  • On-prem code review workflows replicate cloud features for regulated environments and alternative SCM systems.
  • Auto-labeling GitHub issues uses intent understanding, accelerating triage beyond brittle keyword matching.

INSIGHTS

  • Tooling wins come from orchestration, not magic: context, verification, and safety settings determine outcomes.
  • Persistent project memory is manufactured, not inherent; agents.md supplies the missing continuity layer reliably.
  • Short, focused instructions outperform encyclopedias; too many rules create conflict and confusion for models.
  • Progressive disclosure mirrors human onboarding: minimal defaults, deeper docs only when tasks demand specifics.
  • Safety is configurable; approvals and sandboxing convert autonomous coding into controlled, auditable operations.
  • Anchored prompts act like compass bearings, preventing agents from drifting into irrelevant modules unexpectedly.
  • Verification loops transform guesswork into engineering, letting tests and linters guide iterative correction automatically.
  • Knowledge cutoffs are solvable via MCP; documentation tools keep implementations aligned with reality updates.
  • Code review usefulness depends on signal-to-noise; prioritized severity keeps teams from tuning it out.
  • Headless structured output turns Codex into infrastructure, enabling automation beyond interactive chat sessions.
  • Multi-agent handoffs emulate teams: scoped roles and tools reduce interference and improve specialization effectiveness.
  • Context management becomes project management: sessions, plans, and prompts organize work as living artifacts.

QUOTES

  • "Hi, welcome to today's getting started with codec session."
  • "I'm Derek >> and I'm Charlie >> and we work with customers to help them get onboarded to Codeex."
  • "Codeex is OpenAI's coding agent that developers can use across different surfaces."
  • "our goal this session today is to give you a highle introduction to codeex."
  • "We'll then dive into agents MD, a readme format for codeex and how to configure codecs with config.toml."
  • "So, you can use codecs in multiple clients today."
  • "Codex CLI is open source"
  • "type Codex login"
  • "The first one is slash status."
  • "We're using the agents.md website"
  • "Agents MD ensures that the instructions that you want to give the agent"
  • "Most of OpenAI's agents MD files and we looked at the monor repo to figure this out were less than 100 lines."
  • "Agents MD is really a cheat sheet at the end of the day."
  • "one of our engineers was able to run a 10 plus hour refactor um with codeex"
  • "approval policy and sandbox mode are two areas."
  • "use appmention"
  • "paste the full stack trace into Codex"
  • "Codeex is a know-it-all historian."
  • "you can actually use codecs in the ID extension to generate mermaid sequence diagram."
  • "MCP is most people know here it's it's really a protocol for connecting you know models to any sort of additional tools and context."

HABITS

  • Install Codex via npm or brew to stay current because releases ship multiple times weekly.
  • Enable IDE extension auto-updates so new features arrive without manual maintenance overhead later.
  • Log in once using codex login, ensuring CLI and IDE sessions authenticate consistently together.
  • Use /status early to confirm model, directory, sandboxing, approvals, and remaining context window.
  • Clone a shared repo and run npm install plus npm run dev to follow tutorials.
  • Create agents.md at git root so every session loads baseline project context automatically.
  • Keep agents.md brief, removing conflicting guidance so the agent stays focused during execution.
  • Add build, test, and lint commands to agents.md so Codex can verify changes itself.
  • Update agents.md whenever Codex struggles, capturing gotchas to speed future agentic loops.
  • Reference task-specific docs from agents.md, letting Codex discover deeper guidance progressively when required.
  • Maintain a plans.md template for large tasks, tracking checklists as work progresses over hours.
  • Use config.toml profiles to switch between fast and thorough reasoning modes quickly per task.
  • Prefer workspace-write sandboxing to prevent accidental edits outside your project directory boundaries.
  • Anchor prompts with @file mentions to guide initial exploration toward relevant starting points.
  • Begin with small tasks, then gradually expand scope as review confidence increases over time.
  • Paste full stack traces for debugging so Codex can pinpoint failures efficiently inside code.
  • Attach screenshots when describing UI changes, enabling precise edits without ambiguous instructions.
  • Resume sessions using codex resume to reuse context instead of restarting conversations repeatedly.
  • Bind hotkeys for adding selected code context, speeding IDE prompting during focused reviews.
  • Use IDE todos and click implement with Codex to batch small improvements efficiently.

FACTS

  • Codex supports CLI, IDE extension, and cloud environments for running tasks asynchronously across devices.
  • Codex CLI offers headless SDK mode for programmatic automation beyond interactive terminal usage.
  • IDE extension works with VS Code-based IDEs, providing rich graphical interaction with agents.
  • Users can run remote cloud tasks, enabling parallel work even with laptop closed completely.
  • Codex models are trained for Linux, macOS, and Windows, supporting bash and PowerShell.
  • Presenters state Codex uses GT5.1 Codex Max as best model for agentic coding.
  • Codex CLI is open source, with binary releases on GitHub and changelog online.
  • Installation is recommended via npm or brew to remain on latest frequent releases.
  • VS Code extension is searchable as “OpenAI codecs” and offers prerelease toggles.
  • Signing in can be done via IDE splash screen or CLI command codex login.
  • /status command reports model, directory, sandbox mode, approval policy, and context remaining.
  • Agents.md autoloads when present in directory where Codex starts, providing persistent instructions.
  • Agents.md can exist globally in Codex home folder for universal behavior customization settings.
  • Subdirectory agents.md files provide service-specific context when Codex operates inside that folder.
  • Best-practice agents.md length cited as under 100 lines from internal repo analysis.
  • Config.toml sets defaults: model, reasoning effort, sandboxing, approvals, and web search toggles.
  • CLI supports session resumption, letting users continue previous conversations using session identifiers.
  • IDE supports image attachments, allowing screenshot-driven CSS changes like color-chip styling updates.
  • Codex can generate Mermaid sequence diagrams describing repository processes and interactions quickly.
  • MCP supports stdio and HTTP transport, connecting Codex to external tools and context.

REFERENCES

  • OpenAI
  • Codex
  • Codex CLI
  • Codex IDE extension
  • VS Code-based IDEs
  • Terminal / CLI
  • Headless SDK mode
  • Codex Cloud environments
  • Mobile phone workflows
  • Slack mentions integration
  • Slack conversation threads
  • Codex SDK
  • Containers
  • GT5.1
  • Codex Max
  • Linux
  • Mac OS
  • Windows
  • Bash
  • PowerShell
  • Sandbox mode
  • Approval policy
  • developers.openai.com/codex
  • Codex changelog
  • GitHub binary releases
  • Open-source repository (agents.md website repo)
  • agents.md
  • /init command
  • Global agents.md in Codex home folder
  • Subdirectory agents.md
  • plans.md
  • exec plans template
  • front-end.md
  • architecture.md
  • config.toml
  • Profiles (fast)
  • Web search request toggle
  • Terminal notifications
  • /status slash command
  • /models command
  • VS Code extension marketplace
  • Chat mode / Agent mode / Full access mode
  • Reasoning effort levels
  • Git history via git CLI
  • assets.html documentation page
  • Hero buttons (download repo, GitHub link, copy markdown)
  • To-dos in IDE
  • Screenshots for UI edits
  • codex resume
  • Mermaid sequence diagram
  • prompts folder in Codex home
  • @test.md custom prompt file
  • Unit tests generation workflow
  • MCP protocol
  • Standard IO transport
  • HTTP transport
  • Figma MCP server
  • Jira MCP
  • Linear MCP
  • Datadog MCP server
  • Context7 MCP server
  • Cupcake MCP example server
  • Cupcake order tool call (Rachel)
  • OpenAI Responses API
  • Structured output schema
  • JSON schema
  • jq
  • OpenAI Agents SDK
  • Traces
  • MCP server as tool within Agents SDK
  • On-prem code review
  • Alternative SCM systems
  • Autofix CI concept
  • GitHub issue auto-labeling
  • Codex cookbooks
  • Enterprise admin guide
  • Security guide
  • Rate card / credits usage

ONE-SENTENCE TAKEAWAY

Codex works best when you engineer context, safety, verification, and tooling into repeatable workflows.

RECOMMENDATIONS

  • Create a short agents.md at repo root, listing build, test, and lint commands clearly.
  • Add subdirectory agents.md files for services, so Codex receives local context when entering.
  • Keep instructions under 100 lines, removing conflicts that slow agent decision-making significantly.
  • Link task-specific docs from agents.md, enabling progressive discovery instead of bloated global guidance.
  • Maintain a plans.md template for refactors, tracking checklists as Codex progresses across hours.
  • Define config.toml profiles like fast and thorough, switching reasoning effort based on task complexity.
  • Start sessions with /status to confirm sandbox limits, approvals, and remaining context before proceeding.
  • Prefer workspace-write sandboxing to reduce blast radius when agents modify many files quickly.
  • Anchor prompts with @file mentions to prevent irrelevant exploration and save context tokens early.
  • Include verification steps in prompts when missing, ensuring tests and linters run automatically.
  • Paste full stack traces for debugging, giving Codex precise failure signals and faster navigation.
  • Use screenshot prompts for UI tasks to avoid confusing spatial descriptions and miscommunication altogether.
  • Bind hotkeys for adding selected context, speeding IDE workflows during focused code review work.
  • Use IDE todos to capture small fixes, then click implement with Codex to batch.
  • Turn on extension auto-update to stay aligned with rapid releases and new capabilities.
  • Install CLI via npm or brew, since GitHub binaries may lag behind shipping cadence.
  • Enable terminal notifications if desired, letting Codex run in background and alert completion.
  • Configure web search requests as needed, or toggle the default to true in the config.toml settings.
  • Add MCP servers for tickets, designs, and logs to reduce manual context gathering time.
  • Use Context7 MCP for up-to-date docs to mitigate model knowledge cutoffs during implementation.
  • Employ code review commands for uncommitted diffs, prioritizing P0 and P1 issues.
  • Adopt structured outputs with codex exec, integrating results into CI pipelines using JSON parsing.
  • Build multi-agent workflows with Agents SDK, scoping tools and handing off specialized tasks.
  • Replicate Codex cloud code review on-prem, supporting regulated environments and non-GitHub workflows.
  • Auto-label issues using Codex, accelerating triage without fragile keyword-based matching systems.

Related reading

Get New Posts

Follow on your preferred channel for new articles, notes, and experiments.

Related Posts