"use strict";
/**
* @file Dynamic tools documentation — compact system instructions.
* The model already receives tool schemas from LM Studio.
* This only adds behavioral rules that aren't in the schemas.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.buildToolsDocumentation = buildToolsDocumentation;
function buildToolsDocumentation(cfg) {
const lines = [
'# Rules',
'',
'1. First turn: call Recall("topic") then get_project_context().',
'2. Use replace_text_in_file or patch_file for edits. Never rewrite files with save_file (max 12K chars).',
'3. Never repeat the same tool call. If it failed, try differently.',
'4. Remember user preferences and corrections with Remember().',
];
let nextRule = 5;
if (cfg.enableDesignMode) {
lines.push(`${nextRule}. Design tasks: list_design_systems with a style filter, load_design_system by id, then load_design_reference for 1-2 topics. Output self-contained HTML with a <style> block.`);
nextRule++;
}
if (cfg.enableSecondaryAgent) {
lines.push(`${nextRule}. Delegate subtasks (summarize, research, review) to consult_secondary_agent. Never delegate the main request.`);
nextRule++;
}
if (cfg.enableVideoRendering) {
lines.push(`${nextRule}. Video tasks: load_design_reference("video-composition") AND ("video-blocks") FIRST. Save entry as index.html in its own project dir (mandatory). For SCENE-TO-SCENE TRANSITIONS use the CSS snippets in video-composition Section 7 (crossfade/blur/push/zoom) — NEVER embed cinematic-zoom/glitch/thermal-distortion etc. via data-composition-src, those are 4s demo clips with placeholder 'SCENE A/B' content. Drop-in blocks (instagram-follow, data-chart, logo-outro) MUST have compositions/<id>.html edited to swap HF demo defaults (#3d348b purple, #f7b801 yellow) for project palette before embedding. Then call render_html_video. Render is slow — run once per finalized composition.`);
nextRule++;
}
return lines.join('\n');
}
//# sourceMappingURL=toolsDocumentation.js.map