Serious Apple SDK Knowledge Gaps in Codex Are Producing Incorrect Architectures and Repeated Bugs

I’ve been using Codex extensively on a production Swift/SwiftUI app, and I keep encountering the same failure pattern: it confidently reasons from an incomplete mental model of Apple frameworks, implements a workaround, and only reaches the correct architecture after multiple iterations and an explicit request to read Apple’s documentation and SDK declarations.

This has happened across unrelated Apple APIs and mechanisms, including:

  • TextKit marked text and IME projection/synchronization
  • iCloud ubiquitous-item resource values and download-state precedence
  • File coordination and coordinated access to version URLs
  • Item replacement and temporary-directory semantics
  • Public versus unsupported WebKit behavior
  • Modern macOS toolbar grouping, overflow, ControlGroup, and ToolbarSpacer behavior

The issue is not simply an occasional API typo. The initial misunderstanding often changes the architecture and creates compensating code around a false premise. In the latest example, a native compact macOS toolbar became multiple nested groups with custom-drawn separators and hard-coded positional offsets. Only after reviewing Apple’s current documentation did Codex identify the supported native toolbar model and remove the workaround stack.

I think this deserves targeted improvement:

  1. Add Apple-platform evals that test framework semantics, inheritance and scope rules, lifecycle behavior, and interactions between related resource values—not only API-name recall.
  2. Make documentation-first verification the default before Codex makes architectural decisions involving Apple SDKs.
  3. Encourage direct inspection of the active SDK’s Swift interfaces and headers when behavior is version-sensitive or documentation is sparse.
  4. Treat repeated user corrections as a signal to stop patching and revalidate the underlying platform model.

Codex is very capable at repository-scale implementation, which makes this gap especially important: a confident but incorrect SDK model can produce clean-looking code around the wrong abstraction. Improving Apple SDK grounding would materially increase trust for serious macOS and iOS development.

Thanks for the concrete examples. We’ll pass along the feedback about Apple SDK grounding and documentation-first checks. A small redacted before/after example with the SDK and Codex versions would help Support investigate: https://help.openai.com/en/articles/6614161. No timeline to share.