You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs-site/src/content/docs/ko/reference/configuration.md
+15Lines changed: 15 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -52,6 +52,8 @@ namespaced selected id를 bare id로 바꿉니다.
52
52
|`codexShimAutoRestore?`|`boolean`|`true`| 완료된 외부 Codex 업데이트가 이전에 설치한 shim을 교체하면 자동으로 복구합니다. 끄려면 `false`로 설정하거나 프로세스에 `OPENCODEX_CODEX_SHIM_AUTO_RESTORE=0`을 설정합니다. |
53
53
|`syncResumeHistory?`|`boolean`|`true`| 되돌릴 수 있는 Codex App 기록 호환 모드. opencodex가 원래 Codex thread metadata를 백업하고, 예전 OpenAI interactive row를 `opencodex`로 재매핑하며, opencodex가 만든 `exec` row를 App에 보이는 source로 잠시 승격합니다. `ocx stop` / `ocx restore`는 백업한 OpenAI row를 복원하고 남은 opencodex user thread를 OpenAI로 돌려 네이티브 Codex가 `config.toml`에서 프록시를 제거한 뒤에도 이어서 열 수 있게 합니다. 끄려면 `false`로 설정합니다. |
54
54
|`codexAccounts?`|`CodexAccount[]`|`[]`| Codex Auth 대시보드에서 관리하는 ChatGPT/Codex pool 계정 metadata. secret은 `codex-accounts.json`에 따로 둡니다. |
55
+
|`pausedCodexAccountIds?`|`string[]`|`[]`| Codex Auth에서 재개할 때까지 이후의 모든 Pool 선택에서 제외할 계정 ID. 메인 계정을 일시 중지하면 `__main__`도 포함됩니다. |
56
+
|`codexAccountNamespaces?`|`Record<string,string>`| — | 공개 model selector namespace에서 저장된 Codex 계정 target으로 연결하는 선택적 map입니다. 이 foundation layer는 map을 검증하고 저장하지만 picker row를 추가하거나 routing을 변경하지 않습니다. |
55
57
|`activeCodexAccountId?`|`string`| — | 수동으로 선택한 pool 계정. 선택 시 기존 thread affinity를 지우고 다음 요청부터 적용하며, 진행 중인 요청은 기존 계정을 유지합니다. |
56
58
|`autoSwitchThreshold?`|`number`|`80`| 새 세션 자동 전환용 사용량 백분율 threshold. 알려진 5시간, 주간, 30일 quota window 중 가장 높은 점수를 씁니다. `0`이면 quota 자동 전환을 끕니다. `quota` 전략과 `fill-first` drain threshold에도 사용됩니다. |
57
59
|`accountPoolStrategy?`|`"quota" \| "round-robin" \| "fill-first"`|`"quota"`| Codex pool의 새 세션 rotation 전략. **새 세션에만** 적용되며 기존 thread id는 affinity를 유지합니다. `quota`(기본) — 활성 계정이 `autoSwitchThreshold`를 넘으면 알려진 usage가 가장 낮은 계정 선택. `round-robin` — 적격 계정 간 smooth weighted 균등 분배. `fill-first` — cooldown, 사용 불가 또는(설정 시) `autoSwitchThreshold`까지 활성 계정을 소진(알 수 없는 usage는 강제 전환하지 않음)한 뒤 안정 정렬 순으로 다음 계정. |
@@ -64,6 +66,15 @@ namespaced selected id를 bare id로 바꿉니다.
64
66
|`tokenGuardian?`|`OcxTokenGuardianConfig`| off | 선택형 proactive OAuth 갱신 및 Codex 계정 warmup 정책. 필드는 아래에 설명합니다. |
65
67
|`corsAllowOrigins?`|`string[]`|`[]`| CORS에서 추가로 허용할 정확한 origin. loopback origin은 항상 허용합니다. |
66
68
69
+
`codexAccountNamespaces` 키는 공개 selector입니다. 길이는 1~64자이고 시작과 끝은 ASCII 영숫자여야
70
+
하며, 내부에는 영숫자, `.`, `_`, `-`를 사용할 수 있습니다. 예약된 JavaScript object 이름은 거부됩니다.
71
+
값은 유효한 pool account id(내부 `__main__` 제외)이거나 Codex Desktop 계정을 나타내는 `"@main"`입니다.
72
+
provider 및 예약된 `openai` / `combo` 충돌은 대소문자를 구분하지 않고 검사하며, namespace가 있는
73
+
combo alias는 selector를 namespace prefix로 재사용할 수 없습니다. 설정된 pool id와 다른 selector
74
+
target도 selector로 재사용할 수 없습니다. raw account id와 email은 비공개로
75
+
유지하고 selector를 공개 이름으로 사용하세요. 이 foundation layer에서 map은 inert하며 model picker
76
+
entry 생성, session 고정, Pool / Direct routing 변경을 수행하지 않습니다.
77
+
67
78
`maxConcurrentThreadsPerSession`은 `config.json` 키가 아니라 `PUT /api/v2`에서 쓰는 camel-case
68
79
필드입니다. `ocx v2 threads <n>`은 대응하는 `max_concurrent_threads_per_session` 값을 Codex의
69
80
`$CODEX_HOME/config.toml` 안 `[features.multi_agent_v2]`에 저장합니다. 해당 table이 생기도록 v2를
@@ -77,6 +88,10 @@ pool 계정 추가와 quota 갱신은 대시보드의 **Codex Auth** 페이지
77
88
아닌 계정 metadata만 저장하고, access/refresh token은 강화된 Codex 계정 credential store에 따로
78
89
보관합니다. 기존 thread id는 계정 affinity를 유지하며, 새 세션은 `accountPoolStrategy`, quota,
79
90
cooldown, health에 따라 자동 라우팅됩니다.
91
+
일시 중지된 계정과 quota metadata는 계속 표시되지만 자동 전환, 재시도/failover 선택, cooldown 복구 probe, 수동 활성화에서는 제외됩니다.
92
+
일시 중지는 해당 계정의 thread affinity map도 지웁니다. 진행 중인 요청은 이미 확보한 credential을 유지하지만, 이후 턴은 다시 라우팅되며 일시 중지된 계정은 재사용할 수 없습니다.
93
+
상태는 재시작 후에도 유지되며, 모든 계정이 일시 중지되면 Pool 라우팅은 계정을 몰래 선택하지 않고 실패합니다.
94
+
**한도 도달 계정 일시 중지**는 credential이 있는 적격 계정만 먼저 새로고친 뒤 관련 quota window가 이번 응답에서 100%로 확인된 계정만 일시 중지합니다. credential이 없는 계정과 quota가 없거나 새로고침에 실패한 계정은 변경하지 않습니다.
80
95
81
96
**rotation 전략**(새 세션만; bound thread는 변경 없음): `quota`(기본) — `autoSwitchThreshold` 초과 시
82
97
최저 usage 선택; `round-robin` — 균등 분배, `accountPoolStickyLimit`(기본 `1`, 1–100)로 한 선택당
Copy file name to clipboardExpand all lines: docs-site/src/content/docs/reference/configuration.md
+19Lines changed: 19 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,6 +57,8 @@ differing backup and rewrites known legacy namespaced selected ids to bare ids.
57
57
|`codexShimAutoRestore?`|`boolean`|`true`| Restore a previously installed Codex shim when a completed external Codex update replaces it. Set `false`, or set `OPENCODEX_CODEX_SHIM_AUTO_RESTORE=0` for a process-level opt-out. |
58
58
|`syncResumeHistory?`|`boolean`|`true`| Reversible Codex App history compatibility mode. opencodex backs up original Codex thread metadata, remaps old OpenAI interactive rows to `opencodex`, and temporarily promotes opencodex-created `exec` rows to an app-visible source. `ocx stop` / `ocx restore` restore backed-up OpenAI rows and eject remaining opencodex user threads to OpenAI so native Codex can resume them after the proxy is removed from `config.toml`. Set `false` to opt out. |
59
59
|`codexAccounts?`|`CodexAccount[]`|`[]`| ChatGPT/Codex pool account metadata managed by the Codex Auth dashboard. Secrets live separately in `codex-accounts.json`. |
60
+
|`pausedCodexAccountIds?`|`string[]`|`[]`| Accounts excluded from every future Pool selection until resumed in Codex Auth. Includes the main `__main__` account when paused. |
61
+
|`codexAccountNamespaces?`|`Record<string,string>`| — | Optional public model-selector namespace → stored Codex account target map. This foundation layer validates and persists the map but does not add picker rows or change routing. |
60
62
|`activeCodexAccountId?`|`string`| — | Manually selected Pool account. Selection clears existing thread affinity and applies to the next request; in-flight requests keep their captured account. |
61
63
|`autoSwitchThreshold?`|`number`|`80`| Usage percent threshold for new-session auto-switching. The score uses the hottest known 5h, weekly, or 30d quota window. Set `0` to disable quota auto-switching. Used by the `quota` strategy and as the drain threshold for `fill-first`. |
62
64
|`accountPoolStrategy?`|`"quota" \| "round-robin" \| "fill-first"`|`"quota"`| New-session rotation strategy for the Codex pool. Applies to **new sessions only**; existing thread ids keep affinity. `quota` — today's default: pick the lowest known usage when the active account crosses `autoSwitchThreshold`. `round-robin` — even spread across eligible accounts via smooth weighted selection. `fill-first` — keep the active account until it cools down, becomes unusable, or crosses `autoSwitchThreshold` when set (unknown usage does not force a switch), then advance to the next eligible account in stable sorted order. |
@@ -70,6 +72,15 @@ differing backup and rewrites known legacy namespaced selected ids to bare ids.
70
72
|`tokenGuardian?`|`OcxTokenGuardianConfig`| off | Optional proactive OAuth refresh and Codex-account warmup policy; fields are listed below. |
71
73
|`corsAllowOrigins?`|`string[]`|`[]`| Additional exact origins allowed by CORS. Loopback origins are always allowed. |
72
74
75
+
`codexAccountNamespaces` keys are public selectors: 1–64 characters, starting and ending with an
76
+
ASCII letter or number, with letters, numbers, `.`, `_`, or `-` inside; reserved JavaScript object
77
+
names are rejected. Each value is either a valid pool-account id (never the internal `__main__`) or
78
+
`"@main"` for the Codex Desktop account. Provider and reserved `openai` / `combo` collisions are
79
+
checked case-insensitively; a namespaced combo alias cannot reuse a selector as its namespace prefix,
80
+
and configured pool ids or selector targets also cannot reuse a selector. Keep raw
81
+
account ids and emails private—the selector is the public name. In this foundation layer the map is
82
+
inert: it does not create model-picker entries, pin sessions, or alter Pool or Direct routing.
83
+
73
84
`maxConcurrentThreadsPerSession` is the camel-case field used by `PUT /api/v2`, not a
74
85
`config.json` key. `ocx v2 threads <n>` persists the corresponding
75
86
`max_concurrent_threads_per_session` value under `[features.multi_agent_v2]` in Codex's
@@ -105,6 +116,14 @@ credential store. Existing thread ids keep account affinity, while new sessions
105
116
`accountPoolStrategy`, quota, cooldown, and health. A pre-stream upstream **429**/**402** on one pool
106
117
account is retried once on an eligible alternate account in the same request (so Codex CLI does not
107
118
stall on a depleted primary while another account still has quota).
119
+
Pause keeps an account and its quota metadata visible, but excludes it from automatic switching,
120
+
retry/failover selection, cooldown recovery probes, and manual activation. Pausing also clears that
121
+
account's thread-affinity map: in-flight requests keep their captured credentials, but subsequent
122
+
turns are re-routed and cannot reuse the paused account. The exclusion survives
123
+
restarts; if every account is paused, Pool routing fails instead of silently selecting one.
124
+
**Pause exhausted** first refreshes eligible accounts that have credentials available and pauses
125
+
only those whose relevant quota window is freshly confirmed at 100%; accounts without credentials
126
+
and unknown or failed quota refreshes are left unchanged.
108
127
:::
109
128
110
129
**Rotation strategies** (new sessions only; bound threads are unchanged):
0 commit comments