Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📜 Recent review details
|
| Layer / File(s) | Summary |
|---|---|
执行器封装与构造函数 sdk/exec/xai.go |
新增 XAIExecutor 类型别名和 NewXAIExecutor() 构造函数,用于创建内部 xAI/Grok 执行器。 |
Estimated code review effort: 1 (Trivial) | ~2 minutes
Poem
我是小兔,蹦过代码田,
xAI 执行器亮相 API 边。
别名轻轻搭桥梁,
构造函数捧来新实例,
耳朵一竖,发布完成!
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
| Check name | Status | Explanation |
|---|---|---|
| Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. |
| Title check | ✅ Passed | 标题简洁明确,准确概括了本次新增并导出 xAI 执行器的主要变更。 |
| Docstring Coverage | ✅ Passed | No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. |
| Linked Issues check | ✅ Passed | Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check | ✅ Passed | Check skipped because no linked issues were found for this pull request. |
✨ Finishing Touches
📝 Generate docstrings
- Create stacked PR
- Commit on current branch
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Commit unit tests in branch
feat/export-xai-executor
⚔️ Resolve merge conflicts
- Resolve merge conflict in branch
feat/export-xai-executor
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.
Comment @coderabbitai help to get the list of available commands.
fcbae39 to
b9e295c
Compare
f86ff70 to
2dcc3ba
Compare
05735a8 to
92d442d
Compare
65e3034 to
fcd5f67
Compare
2de9a60 to
36b875c
Compare
f73a491 to
af90c2e
Compare
c9f78f6 to
4cae6e7
Compare
24ef76a to
269cbbb
Compare
Implement the full Devin/Cognition Connect-RPC provider support across all CPA endpoints (/v1/chat/completions, /v1/messages, /v1/responses), complete with binary protobuf wire framing, streaming tools/arguments delta handling, thinking/reasoning replay, and CLI OAuth authentication. Key highlights: - Wire Protocol & Streaming: * Implemented Connect-RPC uncompressed 5-byte framing (0x00 + 4-byte length + protobuf) for ApiServerService/GetChatMessage. * Implemented Devin protobuf encoder/decoder in internal/runtime/executor/helps/devin_wire.go, including ClientMetadata, prompts, tools, completion_config, and multimodal image handling (Prompt Field #10). * Stream frame consumption via interactions protocol, correctly mapping arguments_delta and tracking multiple sequential tool calls (currentToolCallActive). * Streaming thought summary and sealed.v1 signature deltas targeting the thinking step. - Model Registration & Thinking Clamping: * Registered static fallback models in model_definitions.go (swe-2, claude-fable-5-1, gpt-6-astra, swe-1-7-lightning, glm-5-2, glm-5-3). * Configured ThinkingSupport with discrete levels per model family. * Implemented CPA-standard nearest-neighbor clamping for thinking levels (minimal/low -> medium, xhigh -> max for swe-2). * Mapped thinking effort to Devin upstream model UID (e.g. swe-2-medium, swe-2-high, swe-2-max). - Sensitive Words & System Prompt Sanitization: * Added devin.sensitive-words configuration in internal/config/config_types.go and config.go, matching Antigravity conventions. * Supported zero-width space (\u200b) obfuscation in prompts, tools, and system instructions via SensitiveWordMatcher. * Stripped Claude Code billing headers (x-anthropic-billing-header:) and CLI identity signatures from system instructions and tool descriptions to avoid upstream content filter rejections. - Signature Compatibility: * Added SignatureProviderSWE = "swe" recognizing sealed.v1.* reasoning signatures in internal/signature/provider_compatibility.go. * Propagated reasoning.encrypted_content on Responses API and thinking.signature on Messages API. - Authentication: * Implemented Devin PKCE OAuth flow with loopback callback server and headless manual token/code paste (--no-browser). * Registered Devin authenticator in SDK and CLI (-devin-login flag). * Integrated with management OAuth session endpoints and credentials manager.
86be7cd to
c56dc7b
Compare
Summary
Validation
Summary by CodeRabbit