agentscope-ai / agentscope-ai/ReMe

feat(agent-wrapper): add Codex backend

Aperta
#352 0 commenti 0 reazioni 1 assegnatario Rivendicata da @jinliyl Vedi su GitHub
enhancement
Lingua principale
Python
Stelle
3.5k
Fork
298
Merge medio
19h 52m
PR unite (30g)
55

Descrizione

**Background**

ReMe's unified agent wrapper currently supports AgentScope and Claude Code. A Codex backend is needed so ReMe jobs can use Codex through the same prompt, tool, skill, session, structured-output, and streaming contracts without coupling job logic to a specific agent runtime.

**Changes**
- Add a Codex implementation under `reme/components/agent_wrapper/codex_agent_wrapper.py`
- Integrate with the Codex App Server v2 thread and turn APIs over its local JSON-RPC transport
- Map Codex thread lifecycle operations to new sessions, resume, fork, and deterministic workspace-scoped persistence
- Expose configured ReMe jobs and project skills to Codex while preserving existing tool context injection
- Convert Codex turn, content, reasoning, tool, approval, usage, completion, and error events into unified `StreamChunk` values
- Support non-streaming replies, streaming replies, structured output, working-directory configuration, sandbox settings, and approval policies
- Manage the Codex subprocess and protocol resources deterministically, including cancellation and failure cleanup
- Register the backend, add default configuration, document prerequisites, and add focused unit and integration tests

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Start by reading the existing AgentScope and Claude Code integrations in reme/components/agent_wrapper to mirror backend interface, session/thread handling, and registration patterns. Add the new `reme/components/agent_wrapper/codex_agent_wrapper.py` and wire it into the same backend registration/config path so Codex jobs can use the shared prompt/tool/skill contracts. Then implement and verify Codex event translation to `StreamChunk` values plus deterministic subprocess and transport lifecycle handling (new, resume, fork, cancel). Finish by adding/adjusting the focused unit and integration tests for streaming/non-streaming and structured-output behavior, plus default config/docs updates described in the issue.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
python
Ambito
backend
Tipo di issue
Funzionalità
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Tranquilla
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.