terminal-smart-cli 0.97.17 → 0.97.18
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/lib/meta.js +12 -1
- package/package.json +1 -1
package/lib/meta.js
CHANGED
|
@@ -121,6 +121,12 @@ function directArtifactPlan(item) {
|
|
|
121
121
|
};
|
|
122
122
|
return null;
|
|
123
123
|
}
|
|
124
|
+
|
|
125
|
+
function canGenerateDirectArtifact(item, target) {
|
|
126
|
+
if (!item || !item.directArtifact) return false;
|
|
127
|
+
if (directArtifactPlan(item)) return true;
|
|
128
|
+
return !target || !fs.existsSync(target);
|
|
129
|
+
}
|
|
124
130
|
const WEB_CANVAS_MOVE_MIN = 0.02; // check de MOVIMENTO do canvas web (jogo/cena 3D): diferença MÍNIMA
|
|
125
131
|
// entre 2 quadros pra a cena contar como VIVA. Abaixo disso = parada/congelada (T-pose, mixer parado,
|
|
126
132
|
// loop sem avançar o tempo). SÓ se aplica a canvas de JOGO/3D — dashboard/gráfico pode ficar estático.
|
|
@@ -1393,6 +1399,11 @@ async function run(goal, opts = {}) {
|
|
|
1393
1399
|
// Some providers can generate a large document but refuse to place that
|
|
1394
1400
|
// content inside tool-call arguments. After a proven zero-tool response,
|
|
1395
1401
|
// generate content-only, validate it and let the confined harness persist it.
|
|
1402
|
+
if (item.directArtifact && !canGenerateDirectArtifact(item, expectedOnDisk)) {
|
|
1403
|
+
item.directArtifact = false;
|
|
1404
|
+
delete item.directModel;
|
|
1405
|
+
save(st, dir);
|
|
1406
|
+
}
|
|
1396
1407
|
if (item.directArtifact) {
|
|
1397
1408
|
const directModel = item.directModel || 'glm-5.2';
|
|
1398
1409
|
const plan = directArtifactPlan(item);
|
|
@@ -1762,4 +1773,4 @@ function trailSummary(st, lang) {
|
|
|
1762
1773
|
};
|
|
1763
1774
|
}
|
|
1764
1775
|
|
|
1765
|
-
module.exports = { webRunGate, run, load, notify, stateFile, detectBuild, ensureToolchain, runBuild, escalate, designPhase, archPhase, looksVisual, looksComplex, runApp, visualGate, ensureEmulator, _projKind, _llmVision, toolsForMetaItem, artifactForMetaItem, normalizeMetaArtifact, persistMetaArtifact, directArtifactPlan, verificationLabel, _checkCriteria, trailSummary };
|
|
1776
|
+
module.exports = { webRunGate, run, load, notify, stateFile, detectBuild, ensureToolchain, runBuild, escalate, designPhase, archPhase, looksVisual, looksComplex, runApp, visualGate, ensureEmulator, _projKind, _llmVision, toolsForMetaItem, artifactForMetaItem, normalizeMetaArtifact, persistMetaArtifact, directArtifactPlan, canGenerateDirectArtifact, verificationLabel, _checkCriteria, trailSummary };
|