Skip to content

Enable ChatGPT subscription Codex support end-to-end#43

Merged
teknium1 merged 11 commits into
NousResearch:mainfrom
grp06:codex/align-codex-provider-conventions-mainrepo
Mar 1, 2026
Merged

Enable ChatGPT subscription Codex support end-to-end#43
teknium1 merged 11 commits into
NousResearch:mainfrom
grp06:codex/align-codex-provider-conventions-mainrepo

Conversation

@grp06

@grp06 grp06 commented Feb 26, 2026

Copy link
Copy Markdown
Contributor

Purpose

Let Hermes use a ChatGPT/Codex subscription (via Codex CLI auth) reliably end-to-end, so subscribers can run Hermes with openai-codex without early stop/failure behavior.

What changed

  • Added OpenAI Codex provider/runtime wiring to use the Responses API path.
  • Fixed Responses tool-call ID parity (call_id + fc_* item ids) for replay compatibility.
  • Marked commentary-only Responses messages as continuations, not final answers.
  • Added a guarded continuation path for preamble-only ack messages ("I'll inspect...") so Hermes proceeds to tool execution.
  • Aligned Responses tool schema with Codex conventions (strict: false).

Result

Hermes now works with ChatGPT subscription-backed Codex auth in a full tool-calling loop, instead of stopping after the first intermediate message.

Verification

  • pytest -q tests/test_auth_codex_provider.py tests/test_runtime_provider_resolution.py tests/test_cli_provider_resolution.py tests/test_run_agent_codex_responses.py

@grp06 grp06 force-pushed the codex/align-codex-provider-conventions-mainrepo branch from 0b3ade2 to ce175d7 Compare February 26, 2026 02:21
@wakamex

wakamex commented Feb 26, 2026

Copy link
Copy Markdown

my testing in #45 found id is optional in responses API input items, only call_id is needed

@teknium1

teknium1 commented Mar 1, 2026

Copy link
Copy Markdown
Contributor

Okay - I am merging this and taking it from here - soon we'll all get codex in :)

@teknium1 teknium1 merged commit 86b1db0 into NousResearch:main Mar 1, 2026
sudo-yf pushed a commit to sudo-yf/hermes-agent that referenced this pull request Apr 5, 2026
BUG-1 (critical): api/profiles.py _DEFAULT_HERMES_HOME used Path.home()/.hermes
hardcoded, ignoring the HERMES_HOME env var. conftest.py sets HERMES_HOME to a
test-isolated state dir -- but profiles.py bypassed it and read/wrote real ~/.hermes
during every test run (active_profile file, .env loading). Fixed by reading
os.getenv('HERMES_HOME', ...) at module load time.

BUG-7 (medium): api/workspace.py load_workspaces() fell back to the global
workspaces.json for ALL profiles when their profile-local file didn't exist yet.
New named profiles silently inherited the default profile's workspace list instead
of starting clean. Fixed: the global file fallback now only applies to the default
profile (migration path); named profiles start with a fresh default entry.

BUG-4 (high): test_sessions_list_includes_profile had a vacuous 'if matching:'
guard -- if the session wasn't found the assert was silently skipped and the test
passed. Fixed with hard assert. Also changed to use /api/session?session_id=
directly instead of scanning /api/sessions (which filters out empty Untitled
sessions with 0 messages, causing the test to always see an empty match list).

BUG-5 / test ordering regression: test_profile_switch_returns_default_model_and_workspace
failed with 409 because test_chat_stream_opens_successfully (runs earlier in the
suite) starts a real LLM stream that stays alive in STREAMS. Added a wait loop
(up to 30s) polling /health active_streams before attempting the profile switch.

BUG-8 (low): Removed dead import _profile_default_workspace in switch_profile()
-- was imported but never used (get_last_workspace() already delegates to it).

Also: test_profile_active_endpoint hardcoded assert data['name'] == 'default'
which fails if a prior run left a non-default active_profile on disk. Changed
to assert name is a non-empty string (the endpoint contract), not a specific value.

Tests: 423 passed, 0 failed.
sudo-yf pushed a commit to sudo-yf/hermes-agent that referenced this pull request Apr 5, 2026
…e-coherence

feat: Sprint 23 -- Profile/Workspace/Model Coherence
angelburgosrosado pushed a commit to angelburgosrosado/hermes-agent that referenced this pull request Apr 27, 2026
…der-conventions-mainrepo

Enable ChatGPT subscription Codex support end-to-end
olympus-terminal pushed a commit to olympus-terminal/hermes-agent that referenced this pull request May 16, 2026
…der-conventions-mainrepo

Enable ChatGPT subscription Codex support end-to-end
Egavasyug pushed a commit to Egavasyug/hermes-agent that referenced this pull request Jun 10, 2026
…der-conventions-mainrepo

Enable ChatGPT subscription Codex support end-to-end
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.

3 participants