Add support for grok4
What version of Codex is running?
codex-cli 0.5.0
Which model were you using?
grok4
What platform is your computer?
Linux 6.14.3-x86_64-linode168 x86_64 unknown
What steps can reproduce the bug?
(base) root@localhost:~# cat ~/.codex/config.toml
# Codex CLI 配置文件
[model_providers.xai]
name = "xAI"
base_url = "https://api.x.ai/v1"
env_key = "XAI_API_KEY"
[profiles.xai-grok4]
model_provider = "xai"
model = "grok-4"
(base) root@localhost:~# export XAI_API_KEY="xai-vYi4MiPxxxxxxxxxxxxxxxxxxxxxxxxxxx09Bm2iv"
(base) root@localhost:~# mkdir -p code/codex
(base) root@localhost:~# cd code/codex
(base) root@localhost:~/code/codex# codex --profile xai-grok4
What is the expected behavior?
be able to execute command
What do you see instead?
nothing happened if ask to execute command
Additional information
No response
I would run it with RUST_LOG=debug and then tail -F ~/.codex/log/codex-tui.log to see if that tells you anything interesting. I can't say why it does not appear to be responding to the chat completions request.
I would run it with
RUST_LOG=debugand thentail -F ~/.codex/log/codex-tui.logto see if that tells you anything interesting. I can't say why it does not appear to be responding to the chat completions request.
when i am using v0.7.0 it works good
I would run it with
RUST_LOG=debugand thentail -F ~/.codex/log/codex-tui.logto see if that tells you anything interesting. I can't say why it does not appear to be responding to the chat completions request.
when i am using v0.5.0 it also works good now, i do not know why this
I would run it with
RUST_LOG=debugand thentail -F ~/.codex/log/codex-tui.logto see if that tells you anything interesting. I can't say why it does not appear to be responding to the chat completions request.
I installed the v0.5.0 version in a brand new environment, but still cannot reproduce my previous error, so I tend to think that this may be an issue with the initial grok4 API interface service.