Codex mini - #34
Conversation
|
nice lol |
…#34) Previous patterns used incorrect glob syntax that didn't match AWS CLI command format: - Wrong: aws */describe* (expected slash) - Wrong: aws *:create* (expected colon) - Actual AWS CLI: aws ec2 describe-instances (space-separated) Fixed all 30+ patterns to use correct format: - Correct: aws * describe* (space wildcard space action) - Matches: aws <service> <action> format Changes applied to both personal and work configs. Enables research-specialist to actually query AWS services.
| "github.com/openai/openai-go/shared" | ||
| "github.com/sst/opencode/internal/config" | ||
| "github.com/sst/opencode/internal/status" | ||
| ) |
There was a problem hiding this comment.
Suggestion (import ordering): Standard library imports should come first, then external packages, then internal packages. Consider reordering imports like this:
import (
"context"
"encoding/json"
"errors"
"fmt"
"io"
"log/slog"
"time"
"github.com/openai/openai-go"
"github.com/openai/openai-go/responses"
"github.com/openai/openai-go/shared"
"github.com/sst/opencode/internal/config"
"github.com/sst/opencode/internal/llm/models"
"github.com/sst/opencode/internal/llm/tools"
"github.com/sst/opencode/internal/message"
"github.com/sst/opencode/internal/status"
)This is a minor suggestion for consistency with the style guide.
| Messages: messages, | ||
| Tools: tools, | ||
| } | ||
| if o.providerOptions.model.CanReason == true { |
There was a problem hiding this comment.
Suggestion (style): Using == true is redundant in Go. Consider simplifying to just if o.providerOptions.model.CanReason {. This is a minor nitpick for Go idiomatic style.
|
|
||
| params.MaxOutputTokens = openai.Int(o.providerOptions.maxTokens) | ||
|
|
||
| if o.providerOptions.model.CanReason == true { |
There was a problem hiding this comment.
Suggestion (style): Same here - using == true is redundant in Go. Consider simplifying to just if o.providerOptions.model.CanReason {.
|
|
||
| return outputTools | ||
| } | ||
|
|
There was a problem hiding this comment.
Suggestion (formatting): There are multiple consecutive blank lines here. Running go fmt should fix this - standard Go formatting uses single blank lines for separation.
Code Review SummaryI've reviewed the PR changes (note: the actual changes are related to OpenAI provider refactoring and adding Codex Mini support, not TUI rendering as mentioned in the description). Minor Suggestions (all optional):
OverallThe code logic looks solid. The refactoring to split chat completion and response APIs into separate files is a good approach for maintainability. The new Codex Mini model integration follows the existing patterns well. These are all minor suggestions - feel free to address them or leave as-is based on your preference. |
- anomalyco#34 复制:`clipboard.writeText` **依赖 document 有焦点**,焦点被抢时静默失败 —— 表现为偶发「点了复制但剪贴板没变」。加 `Page.bringToFront` + 失败重试一次。 (此前两条弯路都记在注释里:clipboard API 读不了、CDP 合成 ⌘V 触发不了粘贴。) - anomalyco#37 步骤展开/收起:会话变长后步骤被虚拟列表回收,视口内一个都没有 —— 这是**前提没准备好**,不是没有步骤。改为先跳到最新;仍没有就现跑一条 shell 命令造一个。 直接记 SKIP 等于会话一长这条就永远验不到。 - anomalyco#30 撤销/重做:撤销是异步的,改为等消息数真的变而不是固定 sleep(读早了必然误判)。 第 3 组现状:通过 15,跳过 1(分享 —— 需 user 逐次授权,已在授权下单独验过: 生成链接 → 取消分享 → curl 实测失效)。 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Wut6R6htBzR8fBN8gbJkWg
Closes #27