Skip to content

Use disposable clean Codex profiles when Pi is unavailable - #14

Merged
teo-nex merged 2 commits into
mainfrom
feat/clean-codex-profile
Nov 5, 2026
Merged

teo-nex merged 2 commits into
mainfrom
feat/clean-codex-profile

Conversation

@teo-nex

@teo-nex teo-nex commented Nov 5, 2026

Copy link
Copy Markdown
Owner

When compatible Pi/Node is absent, new studies can now reuse installed native Codex with a disposable, isolated home instead of inheriting the participant's personal instructions and conversation.

  • study create --execution-profile auto selects installed Pi first, then pinned native Codex CLI 0.166.0, and returns the selected trial command. The adapter and route remain fixed throughout the checkpoint.
  • codex-trial creates private temporary home/config/workspace directories and an ephemeral app-server thread per task, checks effective settings and exact model/effort, exposes only the declared lookup tool, persists original attempts, and removes temporary files after success, failure, timeout or handled interruption.
  • Default authentication reuses selected existing file-based ChatGPT access credentials without copying the refresh token or modifying the source store. API billing requires explicit selection; ChatGPT credentials cannot be routed to an arbitrary gateway. Expired/near-expiry or keyring-only sign-in is BLOCKED until normal sign-in refresh or a supported existing auth file is available.
  • Pi, Codex and historical runs remain separate fingerprinted cohorts. Codex uses its native output limit; it is not pooled with Pi's fixed cap. Documentation and agent execution instructions cover selection, cleanup and remaining blockers. No automatic installations or security/network changes.

Validation: frozen dataset verification and diff checks PASS; 149 local tests ran (148 passed, one Linux-only skip). Installed Codex was tested against a synthetic localhost Responses server, including all 35 preflights, max/xhigh wire values, trusted tool rounds, original receipt recording and cleanup on failures/interruption. Existing real ChatGPT sign-in passed a no-inference preflight with the source auth file byte-for-byte unchanged. No real model inference, benchmark campaign or paid API requests were performed.

Hosted CI tests policy/CLI behavior on macOS, Linux and Windows; optional installed-client integration tests skip if their pinned dependencies are absent. Native Codex runtime was exercised locally on macOS. Power loss or an uncatchable kill can leave an orphaned temporary directory.

@teo-nex
teo-nex merged commit b1c4ea3 into main Nov 5, 2026
6 checks passed
@teo-nex
teo-nex deleted the feat/clean-codex-profile branch November 5, 2026 17:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant