@ancleto/spec 0.6.35 → 0.6.36
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/cli/index.js +17 -1
package/package.json
CHANGED
package/src/cli/index.js
CHANGED
|
@@ -1059,8 +1059,24 @@ async function initProject(args) {
|
|
|
1059
1059
|
await writeFile(tierFile, tier + '\n')
|
|
1060
1060
|
}
|
|
1061
1061
|
|
|
1062
|
-
|
|
1062
|
+
// Paridad con install: el tier elegido tambien reescribe los modelos de los
|
|
1063
|
+
// agentes locales. Antes quedaba huerfano (tier declarado, modelos de otro tier).
|
|
1064
|
+
let gratisModelChoice = null
|
|
1065
|
+
if (tier === 'gratis') {
|
|
1066
|
+
const persisted = isKnownGratisModel(existing?.gratisModel) ? existing.gratisModel : null
|
|
1067
|
+
gratisModelChoice = persisted || gratisModel()
|
|
1068
|
+
}
|
|
1069
|
+
const manifest = await writeManifest(projectDir, {
|
|
1070
|
+
azure,
|
|
1071
|
+
discovery,
|
|
1072
|
+
agent,
|
|
1073
|
+
language,
|
|
1074
|
+
...(gratisModelChoice ? { gratisModel: gratisModelChoice } : {})
|
|
1075
|
+
})
|
|
1063
1076
|
await copyTemplates(projectDir)
|
|
1077
|
+
if (tier) {
|
|
1078
|
+
await applyTier(join(projectDir, '.opencode', 'agents'), tier, tierModels(tier, TIERS, gratisModelChoice))
|
|
1079
|
+
}
|
|
1064
1080
|
await scaffoldAspec(projectDir)
|
|
1065
1081
|
await refreshWorkingContext(projectDir)
|
|
1066
1082
|
await registerProject(projectDir, { agent, tier: tier || null })
|