OpenClaw + GitHub Copilot GPT-5.4 技术修复指南

OpenClaw + GitHub Copilot GPT-5.4 Technical Fix Guide

Date: 2026-03-07

Overview

This guide documents how to make github-copilot/gpt-5.4 work inside OpenClaw when the model already works in OpenCode but fails in OpenClaw.

The final solution requires both:

  1. a config fix in ~/.openclaw/openclaw.json
  2. a runtime patch in the installed OpenClaw bundle

This is necessary because the problem is not only model registration. It is also an OpenClaw transport-routing issue for GitHub Copilot Responses API traffic.

Symptoms

The following errors may appear during debugging:

Symptom 1: model rejected

github-copilot/gpt-5.4 ... not allowed 

Symptom 2: IDE auth header missing

HTTP 400: bad request: missing Editor-Version header for IDE auth 

Symptom 3: unsupported provider mode

No API provider registered for api: github-copilot 

Symptom 4: wrong endpoint

HTTP 400: model "gpt-5.4" is not accessible via the /chat/completions endpoint 

Symptom 5: gateway instability

gateway disconnected: closed | idle 

Root Cause Analysis

There are four distinct problems.

1. Model config and allowlist mismatch

OpenClaw could see the provider, but github-copilot/gpt-5.4 was not fully wired into the active model config path used by the agent defaults.

2. Missing GitHub Copilot IDE headers

GitHub Copilot requires IDE-style headers for auth. OpenClaw was sending requests through a generic OpenAI-compatible path, so required headers were not included.

Required headers:

User-Agent: GitHubCopilotChat/0.35.0 Editor-Version: vscode/1.107.0 Editor-Plugin-Version: copilot-chat/0.35.0 Copilot-Integration-Id: vscode-chat 

Without them, Copilot returns:

missing Editor-Version header for IDE auth 

3. GPT-5.4 is not a Chat Completions model

gpt-5.4 must use the Responses API, not /chat/completions.

So this is wrong for gpt-5.4:

"api":"openai-completions"

This is required instead:

"api":"openai-responses"

4. OpenClaw transport routing only handled openai, not github-copilot

Even after changing gpt-5.4 to openai-responses, OpenClaw still fell back to the generic stream path because its embedded runner only activated the Responses transport for provider openai.

That caused OpenClaw to keep hitting /chat/completions for GitHub Copilot GPT-5.4.

Files Involved

Config file

~/.openclaw/openclaw.json

Installed OpenClaw runtime bundle

/home/water/.nvm/versions/node/v22.22.0/lib/node_modules/openclaw/dist/reply-DhtejUNZ.js

Reapply script

~/.openclaw/workspace/ken-patchs/reapply-openclaw-copilot-gpt54-patches.mjs

Step 1: Fix the OpenClaw config

Update the GitHub Copilot provider block in ~/.openclaw/openclaw.json.

Provider-level requirements

Use:

"baseUrl":"https://api.individual.githubcopilot.com","api":"openai-completions"

Why keep provider API as openai-completions?

  • OpenClaw runtime expects the provider to stay on a supported generic adapter path
  • switching the entire provider to github-copilot caused runtime/provider registration failures

Model-level requirements for GPT-5.4

Set the gpt-5.4 model entry to:

{"id":"gpt-5.4","name":"GPT-5.4","api":"openai-responses","reasoning":true,"input":["text","image"],"cost":{"input":0,"output":0,"cacheRead":0,"cacheWrite":0},"contextWindow":128000,"maxTokens":64000}

Agent model registration

Make sure this exists:

"agents":{"defaults":{"models":{"github-copilot/gpt-5.4":{}}}}

Step 2: Patch OpenClaw to inject Copilot IDE headers

OpenClaw needs to attach Copilot IDE headers before sending provider requests.

In /home/water/.nvm/versions/node/v22.22.0/lib/node_modules/openclaw/dist/reply-DhtejUNZ.js, add a wrapper like this near the other provider wrappers:

constGITHUB_COPILOT_IDE_HEADERS={"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"};functioncreateGitHubCopilotHeadersWrapper(baseStreamFn){const underlying = baseStreamFn ?? streamSimple;return(model, context, options)=>{returnunderlying(model, context,{...options,headers:{...GITHUB_COPILOT_IDE_HEADERS,...options?.headers }});};}

Then apply it inside the provider wrapper logic:

if(provider ==="github-copilot") agent.streamFn =createGitHubCopilotHeadersWrapper(agent.streamFn);

Step 3: Patch OpenClaw to route GitHub Copilot Responses correctly

Find the branch that decides which stream transport to use.

Original behavior:

}elseif(params.model.api ==="openai-responses"&& params.provider ==="openai"){

Replace it with:

}elseif(params.model.api ==="openai-responses"&&(params.provider ==="openai"|| params.provider ==="github-copilot")){

Why this matters:

  • before the patch, github-copilot never entered the Responses transport branch
  • OpenClaw fell back to streamSimple
  • streamSimple hit /chat/completions
  • GPT-5.4 rejected that endpoint

After this patch:

  • github-copilot + openai-responses uses the correct Responses transport
  • GPT-5.4 no longer falls back to Chat Completions

Step 4: Validate and restart

Validate config JSON

node-e"JSON.parse(require('fs').readFileSync('/home/water/.openclaw/openclaw.json','utf8')); console.log('OK')"

Validate patched bundle syntax

node--check"/home/water/.nvm/versions/node/v22.22.0/lib/node_modules/openclaw/dist/reply-DhtejUNZ.js"

Restart gateway

openclaw gateway restart 

Verification Procedure

  1. Set the model to github-copilot/gpt-5.4
  2. Send a simple prompt like hi
  3. Confirm the gateway stays connected
  4. Confirm none of these errors return:
missing Editor-Version header for IDE auth model "gpt-5.4" is not accessible via the /chat/completions endpoint No API provider registered for api: github-copilot 

Reapply After OpenClaw Updates

Because the runtime fix patches the installed OpenClaw bundle, upgrades or reinstalls may overwrite it.

Use the reapply script:

node ~/.openclaw/workspace/ken-patchs/reapply-openclaw-copilot-gpt54-patches.mjs openclaw gateway restart 

Design Notes

Why not switch the whole provider to api: "github-copilot"?

That looked tempting, but OpenClaw’s runtime path did not have a compatible registered streaming provider for that mode in this setup, which caused runtime/provider registration failures.

Why not keep GPT-5.4 on openai-completions?

Because GitHub Copilot GPT-5.4 is not accessible on /chat/completions. It must go through the Responses API.

Why did OpenCode work earlier?

OpenCode already handled the GitHub Copilot transport path correctly, including the required Copilot headers and the proper API mode, while OpenClaw needed both config and runtime fixes.

  • Keep this guide with the reapply script path documented nearby
  • After any OpenClaw upgrade, rerun the patch script
  • If OpenClaw changes its bundle file name, update the script path target accordingly
  • If GitHub Copilot changes required IDE header versions, update both the runtime patch and reapply script

Quick Recovery Commands

node ~/.openclaw/workspace/ken-patchs/reapply-openclaw-copilot-gpt54-patches.mjs openclaw gateway restart openclaw status 

Final State

With the config fix and runtime patches in place, github-copilot/gpt-5.4 works in OpenClaw and the gateway remains stable.

Read more

实战测试:多模态AI在文档解析、图表分析中的准确率对比

实战测试:多模态AI在文档解析、图表分析中的准确率对比

实战测试:多模态AI在文档解析、图表分析中的准确率对比 🌟 Hello,我是摘星! 🌈 在彩虹般绚烂的技术栈中,我是那个永不停歇的色彩收集者。 🦋 每一个优化都是我培育的花朵,每一个特性都是我放飞的蝴蝶。 🔬 每一次代码审查都是我的显微镜观察,每一次重构都是我的化学实验。 🎵 在编程的交响乐中,我既是指挥家也是演奏者。让我们一起,在技术的音乐厅里,奏响属于程序员的华美乐章。 目录 实战测试:多模态AI在文档解析、图表分析中的准确率对比 摘要 1. 文档解析与图表分析技术全景 1.1 技术发展历程回顾 1.2 评测体系架构设计 2. 8款主流模型深度测试 2.1 测试模型概览 2.2 文档解析能力测试 3. 测试结果深度分析 3.1 文档解析准确率对比 3.2 图表分析能力评估 3.3 复杂文档处理能力分析 4. 图表分析专项测试

江湖路远,代码为剑:2025,我与 AI 的问道之旅

江湖路远,代码为剑:2025,我与 AI 的问道之旅

🌞欢迎来到人工智能的世界  🌈博客主页:卿云阁 💌欢迎关注🎉点赞👍收藏⭐️留言📝 🌟本文由卿云阁原创! 📆首发时间:🌹2026年1月1日🌹 ✉️希望可以和大家一起完成进阶之路! 目录 📜 章节一:【开篇·自报家门】 📜 章节二:【卷一·修行之路(个人成长)】 📜 章节三:【卷二·阁中史册(年度创作回顾)】 📜 章节四:【卷三·阴阳之道(生活与博客平衡)】 📜 章节五:【卷五·剑指苍穹(未来展望)】 📜 章节六:【尾声·拱手谢礼】 📜 章节一:【开篇·自报家门】  ▲大家好呀,这是我第一参加博客之星的活动,先做一个简单的介绍吧!       💡大家好,这里是卿云阁。 作为一名🏫果壳大学的研一在校生,我的 2025 年充满了挑战 与蜕变。2025年可以说是我成长速度最快的一年。站在年末的节点回望,

2026年AI漫剧工具排行榜:11款软件横向对比,功能价格全揭秘

2026年AI漫剧工具排行榜:11款软件横向对比,功能价格全揭秘

随着AI技术的爆发式发展,2026年AI漫剧市场已进入高速成长期。据行业数据,2025年AI漫剧市场规模突破200亿元,预计2030年将达到850亿元,年增速超过80%。 作为内容创作者,你是否还在为视频制作的高成本、长周期而头疼?别担心,AI漫剧工具正在彻底改变这一现状。我亲测了市面上主流的11款AI漫剧制作工具,从免费到付费,从新手友好到专业级,为你带来这份超全盘点指南。无论你是想快速生成短视频的个人创作者,还是寻求工业化量产的工作室,这篇文章都能帮你找到最合适的工具。 一、AI漫剧工具市场概述 AI漫剧工具的核心价值在于大幅降低动画视频制作的门槛。传统动画制作需要专业团队、昂贵设备和数周时间,而AI工具可以将周期压缩到几分钟到几小时,成本降低90%以上。 根据我的体验,2026年的AI漫剧工具已经实现了从“可用”到“好用”的跨越,特别是在角色一致性、长视频生成等关键痛点上有了突破性进展。 例如,纳米漫剧流水线支持30分钟超长视频生成,而有戏AI实现了95%以上的角色相似度保持。这些工具普遍采用“文生视频”模式,用户只需输入文字描述,AI自动生成剧本、分镜、画面和配音,

OpenClaw+优云智算Coding Plan:从灵感到成文,再到公众号发布的全流程AI自动化

OpenClaw+优云智算Coding Plan:从灵感到成文,再到公众号发布的全流程AI自动化

1. 背景 在自媒体运营、技术分享和日常内容创作中,许多从业者面临碎片化、低效率和重复劳动的问题。从灵感闪现到文章发布,整个过程涉及多个步骤如构思、撰写、排版及上传等,需要频繁切换工具与手动调整格式,耗时费力且容易出错。 目前市面上的AI工具大多只能解决特定环节的问题,无法覆盖整个创作流程;而专业自动化平台要么操作复杂,要么成本高昂,难以普及使用。为此,我使用OpenClaw开源AI智能体(龙虾)和优云智算Coding Plan大模型服务搭建了一个流水线。通过OpenClaw的任务管理和工具调用能力,加上优云智算提供的稳定低价算力支持,实现了“灵感输入→文案生成→内容优化→公众号发布”的端到端全流程自动化,极大提高了效率,让创作者能够更加专注于创意本身。 2. AI大模型配置 优云智算Coding Plan是聚合了OpenAI、Claude、DeepSeek、智谱GLM、MiniMax等全球主流大模型的订阅式算力服务,兼容OpenAI API协议,支持Claude Code/Codex/OpenClaw等AI工具,能完美对接OpenClaw,为内容创作提供稳定的AI生成能力,本