@lightcone-ai/daemon 0.6.6 → 0.6.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/drivers/codex.js +12 -2
package/package.json
CHANGED
package/src/drivers/codex.js
CHANGED
|
@@ -18,6 +18,15 @@ function quote(value) {
|
|
|
18
18
|
return JSON.stringify(value);
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
+
function normalizeCodexModel(model) {
|
|
22
|
+
if (!model) return 'gpt-5.2';
|
|
23
|
+
const normalized = String(model).trim().toLowerCase();
|
|
24
|
+
if (!normalized) return 'gpt-5.2';
|
|
25
|
+
if (['sonnet', 'opus', 'haiku'].includes(normalized)) return 'gpt-5.2';
|
|
26
|
+
if (normalized.startsWith('claude-')) return 'gpt-5.2';
|
|
27
|
+
return model;
|
|
28
|
+
}
|
|
29
|
+
|
|
21
30
|
function ensureGitRepo(workspaceDir) {
|
|
22
31
|
const gitDir = path.join(workspaceDir, '.git');
|
|
23
32
|
if (existsSync(gitDir)) return;
|
|
@@ -106,8 +115,9 @@ export function buildCodexSpawn({
|
|
|
106
115
|
);
|
|
107
116
|
}
|
|
108
117
|
|
|
109
|
-
|
|
110
|
-
|
|
118
|
+
const model = normalizeCodexModel(config.model);
|
|
119
|
+
if (model) {
|
|
120
|
+
args.push('-m', model);
|
|
111
121
|
}
|
|
112
122
|
|
|
113
123
|
if (config.reasoningEffort) {
|