feat(openclaw): add provider form fields and UI components

- Add OpenClawFormFields component for provider configuration
- Add Collapsible UI component (radix-ui dependency)
- Update ProviderForm with OpenClaw-specific handlers and preset logic
- Extend OpenClawModel type with reasoning, input, maxTokens fields
- Exclude OpenClaw from universal provider tab in AddProviderDialog
This commit is contained in:
Jason
2026-02-05 15:25:57 +08:00
parent 715e9e89c4
commit 512f22e83a
7 changed files with 722 additions and 4 deletions
+9 -1
View File
@@ -435,8 +435,16 @@ export interface OpenClawModel {
id: string;
name: string;
alias?: string;
cost?: { input: number; output: number };
reasoning?: boolean; // 是否支持推理模式(如 o1、DeepSeek R1
input?: string[]; // 支持的输入类型(如 ["text"]、["text", "image"]
cost?: {
input: number;
output: number;
cacheRead?: number; // 缓存读取价格
cacheWrite?: number; // 缓存写入价格
};
contextWindow?: number;
maxTokens?: number; // 最大输出 token 数
}
// OpenClaw 默认模型配置(agents.defaults.model