Skip to content

feat(provider): add Qoder Global PAT provider - #3349

Draft
Flowershangfromthebranches wants to merge 4 commits into
lidge-jun:devfrom
Flowershangfromthebranches:feat/qoder-global-pat-provider
Draft

feat(provider): add Qoder Global PAT provider#3349
Flowershangfromthebranches wants to merge 4 commits into
lidge-jun:devfrom
Flowershangfromthebranches:feat/qoder-global-pat-provider

Conversation

@Flowershangfromthebranches

@Flowershangfromthebranches Flowershangfromthebranches commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds the official Qoder Global provider path using the documented Qoder CLI and a user-supplied Personal Access Token.

This is PR 2 of 3 and is intentionally stacked on #3340 while the shared coding-agent runtime introduced there is under review. The Qoder-specific commit is 4ac98bd4d. Once #3340 merges, this branch will be rebased so this PR's diff contains only Qoder Global changes.

Contract

  • Provider id: qoder
  • Canonical destination: https://qoder.com
  • Credential: QODER_PERSONAL_ACCESS_TOKEN
  • Runtime: official qoder / qodercli headless CLI
  • Tools, MCP configuration, settings sources, and session persistence are disabled
  • Text and verified reasoning levels only; image input fails explicitly
  • Model discovery comes from qoder --list-models, is account-scoped by an irreversible credential fingerprint, and degrades through stale/static data without cross-account reuse
  • Existing custom qoder destinations remain custom instead of being silently rewritten

No desktop session, OAuth token extraction, private endpoint, or credential exchange is used.

Evidence reviewed (2026-09-03)

Operator disclosed by Qoder terms: BRIGHT ZENITH PRIVATE LIMITED.

Verification

  • Focused provider/registry/cache/conformance suite: 113 passed, 0 failed
  • Post-fix CodeBuddy + Qoder adapter/protocol suite: 48 passed, 0 failed
  • bun run typecheck: passed
  • bun run privacy:scan: passed
  • git diff --check: passed
  • Full bun run test: 17,481 passed, 25 failed, 14 skipped across 1,043 files. Failures include existing parallel timing and management destination-policy cases; one CodeBuddy compatibility failure exposed by the run was fixed and its complete adapter file now passes.

Live E2E status

LIVE_E2E_NOT_VERIFIED

The official Global CLI is installed locally (qoder 1.1.41), but the test environment has no Qoder Global PAT/login. qoder --list-models correctly reports that login is required. No successful Global inference is claimed.

Maintainer decisions requested

  1. Confirm that official PAT-backed CLI automation is acceptable under Qoder's current service terms/AUP.
  2. Confirm whether the conservative static fallback model names and reasoning metadata should remain, or whether the provider should expose only live-discovered models.
  3. Confirm long-term ownership. Proposed maintainer: Flowershangfromthebranches, independent and unaffiliated with Qoder.

Follow-up

PR 3 will add the isolated Qoder CN PAT profile and will explicitly credit and disposition #3010.

Review readiness checklist

This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:

  • All CI tests are green on my local testing.

  • I pushed my PR to the latest dev commit.

  • I resolved all correct Codex and CodeRabbit findings.

  • My PR is ready for review.

@coderabbitai

coderabbitai Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Deterministic PR hygiene checks passed.

@github-actions github-actions Bot added the enhancement New feature or request label Sep 3, 2026
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

⏳ DRAFT

  • review readiness checklist open (0/4 boxes ticked).

What to do

  • Tick all four boxes in the PR description once you're done (currently 0/4).

Review readiness checklist

  • ⬜ All CI tests are green on my local testing.
  • ⬜ I pushed my PR to the latest dev commit.
  • ⬜ I resolved all correct Codex and CodeRabbit findings.
  • ⬜ My PR is ready for review.

0/4 boxes ticked.

This PR stays in draft until every box above is ticked.

@Flowershangfromthebranches

Copy link
Copy Markdown
Contributor Author

Follow-up PR #3350 now delivers Qoder CN as the third isolated PAT/CLI provider slice. Dependency order: #3340 -> #3349 -> #3350.

@lidge-jun

Copy link
Copy Markdown
Owner

리뷰 · 우선순위 49 / 80

이 PR은 Qoder Global을 OpenCodex 공식 프로바이더로 넣는 기여자 작업이다. 쓰는 길은 문서화된 Personal Access Token과 공식 headless CLI 뿐이다. GitHub에 보이는 diff는 CodeBuddy #3340 세 커밋 위에 Qoder Global 커밋 4ac98bd4d 를 쌓은 상태다. 그래서 지금 dev HEAD(1f00ff52b, 패키지 2.41.0, ReDoS #3345 / CVE 오버라이드 #3346 / HTML 주석 #3343)와 비교하면 CodeBuddy 공통 런타임과 Qoder가 한 덩어리로 들어온다. 기여자 본문도 PR 2/3 이고, #3340이 머지된 뒤 리베이스해서 Qoder만 남기겠다고 적었다. 베이스는 81a1fc1cc 이라 현재 dev보다 제품 커밋 세 개가 뒤다.

지금 dev에도 qoder라는 이름은 이미 있다. 다만 런타임 프로바이더가 아니다. src/providers/free-directory.ts 의 참고용 항목이고, 기본 어댑터는 openai-chat, baseUrl은 빈 문자열, 지원 단계는 reference 다. tests/provider-registry-parity.test.ts 는 그래서 PROVIDER_REGISTRYqoder가 있으면 안 된다고 잠가 두었다. 빈 주소로 사용자 설정을 덮어쓰면 요청이 목적지를 잃기 때문이다. 이 PR은 그 잠금을 풀고 qoder를 공식 키 프로바이더로 승격한다. 레지스트리에 preserveCustomDestination: true 를 켜서, 예전에 같은 이름으로 저장한 커스텀 openai-chat 목적지는 공식 https://qoder.com 으로 덮어쓰지 않게 했다. 패리티 테스트도 그 방향으로 고쳤고, 이 점은 CodeBuddy #3340(새 id)와 가장 크게 다른 계약 변화다.

실제 호출은 HTTP API가 아니다. src/adapters/qoder/adapter.tsrunTurn이 설치된 qoder / qodercli 를 띄운다. 인자는 --tools "", --strict-mcp-config, --setting-sources "", --max-turns 1, --no-session-persistence 이다. Codex가 도구 주인으로 남는다. 이미지가 있으면 프로세스를 띄우기 전에 unsupported_input_modality 로 거절한다. 자격증명은 자식 환경 변수 QODER_PERSONAL_ACCESS_TOKEN 만 쓰고, 데스크톱 세션·쿠키·OAuth 교환은 없다. 모델 목록은 qoder --list-models 가 그 PAT 계정의 권위다. src/codex/catalog/provider-fetch.ts 는 PAT를 SHA-256으로 지문 내어 src/codex/model-cache.tsauthorityIdentity 에 묶는다. 계정을 바꿔도 이전 계정 목록을 캐시에서 꺼내 보지 못하게 하려는 장치다. 문서에 적어 둔 정적 이름(Qwen3.8-Max 등)은 발견이 실패했을 때만 쓰는 예비다.

공통 레이어 쪽도 같이 바뀐다. Qoder 커밋은 src/adapters/coding-agent/protocol.ts 의 에러 매핑을 넓힌다. Qoder가 문서화한 벤더 코드 118과 credit usage limit 문구는 재시도 없는 429 insufficient_quota 가 된다. 같은 함수가 로그인 실패·레이트 리밋·모델 없음도 401/429/400으로 나눈다. 이 분류는 CodeBuddy 스트림에도 적용된다. #3340 리뷰(48/80) 때 없던 동작이 Qoder PR에 들어온 것이다. 어댑터 등록은 contractParent: "codebuddy" 라서 계약만 CodeBuddy를 상속하고, 생성 함수는 createQoderAdapter 다. 형제 가족인데 부모 이름이 CodeBuddy라 읽기는 조금 헷갈린다.

그래도 지금 머지할 단계는 아니다. PR은 draft 이고 readiness 체크리스트 네 칸이 모두 비어 있다. 본문이 직접 LIVE_E2E_NOT_VERIFIED 라고 적었다. CLI는 설치돼 있지만 Global PAT가 없어 qoder --list-models 가 로그인 필요만 말한다고 한다. 전체 스위트 17,481 통과 / 25 실패는 기존 병렬 타이밍과 destination-policy 실패라고 공개했다. Qoder 서비스 약관(운영자 BRIGHT ZENITH PRIVATE LIMITED)이 이 프록시 라우팅을 허용하는지는 #3340 과 같은 메인테이너 보안 판단이다. v2.41.0 승격 기차(main #3342, preview #3347)와는 무관하다. types.ts/config.ts 는 이 diff에 없고, 분할 캠페인으로 닫을 대상이 아니다. #3010(Qoder CN OAuth, 아직 열린 draft)과도 지역·인증이 달라 이 PR을 중복으로 닫으면 안 된다. 아이콘은 gui/src/provider-icons.ts 에 없어서, 대시보드에는 이니셜 타일로 보일 것이다.

경로 src/providers/registry.ts qoder / preserveCustomDestination - 디렉터리 전용 id를 런타임 시드로 올리는 계약 변화다. 플래그와 패리티 테스트가 커스텀 목적지를 지키려 한다. 이 플래그 없이 머지하면 기존 사용자 qoder 설정이 빈 주소 또는 공식 호스트로 끌려갈 수 있다.
경로 src/providers/free-directory.ts CONNECTABLE qoder - 참고 항목을 supported/official/live 로 올린다. 액세스 그룹은 그대로 signup-credit 이다. 무료 가입 크레딧 상품인지, 유료 PAT 상품인지는 디렉터리 분류와 별도로 확인해야 한다.
경로 src/adapters/registry.ts qoder contractParent: "codebuddy" - 런타임 생성은 독립이다. 다만 계약 부모가 CodeBuddy라, 이후 CodeBuddy 와이어/뮤테이션이 바뀌면 Qoder가 같이 따라간다. 공용 coding-agent 부모를 둘지 나중에 정하면 된다.
라인 약 197 src/adapters/coding-agent/protocol.ts - 벤더 코드 118과 credit usage limit 매칭은 Qoder에 맞다. 같은 블록의 인증·레이트 리밋·모델 없음 정규식은 CodeBuddy 에러 문구도 바꾼다. 공유 레이어 변경이므로 #3340 쪽으로 옮기거나, CodeBuddy 픽스처로 회귀를 고정하는 편이 안전하다.
라인 약 154–196 src/codex/model-cache.ts authorityIdentity - 선택 인자라 다른 프로바이더 호출은 그대로다. 쿨다운 isModelsFetchCoolingDown 은 여전히 프로바이더 이름만 본다. 계정 A가 실패한 뒤 계정 B로 바꾸면, B의 스코프 캐시가 없을 때는 라이브 조회로 떨어지게 짜여 있어 방향은 맞다.
라인 30 src/adapters/qoder/adapter.ts buildQoderArgs - 시스템 프롬프트를 --append-system-prompt 로 argv에 붙인다. 닫힌 리뷰에서 #3010 이 지적받은 prompt-in-argv 와 같은 종류다. 프로세스 목록에 프롬프트가 보일 수 있다. CodeBuddy 공통 레이어도 같은 패턴이라, 고친다면 가족을 함께 고치는 후속이 맞다.
경로 docs/qoder-cli-provider.md vs docs-site/src/content/docs/guides/providers.md - 레포 문서는 생겼지만 docs-site 가이드는 CodeBuddy 절만 있고 Qoder Global 절은 없다. README는 공식 사이트 프로바이더 문서로 안내하므로, 리베이스 뒤에 가이드 절을 넣어야 한다.
경로 gui/src/provider-icons.ts - qoder 마크·표시 이름 alias가 없다. #3340 과 같고, 머지 전에 이니셜 타일을 받을지 Meta #3338 식 후속 마크를 둘지 정하라.
경로 draft / readiness 체크리스트 / 라이브 검증 - 네 칸이 비어 있고 Global 추론은 검증되지 않았다. CI·최신 dev·Codex/CodeRabbit 정리·ready 표시 전엔 머지 후보가 아니다.

메인테이너의 판단이 필요한 지점

  • Qoder(BRIGHT ZENITH) 약관/AUP가 이 headless CLI 프록시 라우팅을 허용하는지. 허용이면 어떤 계정 등급(가입 크레딧 vs 유료 PAT)까지인지
  • 기존 디렉터리 id qoder 를 공식 런타임으로 승격해도 되는지. 커스텀 목적지를 지키는 플래그가 충분한지
  • 정적 폴백 모델 이름을 남길지, 라이브 --list-models 성공 때만 모델을 노출할지
  • 공유 프로토콜 에러 분류(118 이외의 401/429/400)를 #3340 에 둘지 이 PR에 둘지
  • 프로바이더 마크를 이 PR에 넣을지 #3338 식 후속으로 둘지
  • v2.41.0 기차 이후에나 볼지. 릴리즈 차단 사유는 아니다
  • draft 체크리스트를 기여자가 채운 뒤에만 리뷰 큐에 올릴지

너의 추천
draft로 두고 AUP 판단을 먼저 하라. #3340 과 같은 이유로 지금 v2.41.0 승격에는 끼우지 마라. 허용이면 #3340 머지 뒤 현재 dev(1f00ff52b) 위로 리베이스하고, docs-site Qoder 절과 체크리스트·CI 초록을 받은 다음 리뷰 큐에 올려라. 거부면 정책 이유를 남기고 닫아라. 라벨은 바꾸지 않는다. types/config 분할이나 #3010 중복을 이유로 이 PR을 닫지 마라. #3010 처분은 CN PR #3350 에서 하라.

이 댓글은 grok-bot이 작성했습니다

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants