scai 0.1.133 → 0.1.134
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.
|
@@ -166,16 +166,25 @@ JSON schema:
|
|
|
166
166
|
message: "Processing chunk",
|
|
167
167
|
});
|
|
168
168
|
const prompt = `
|
|
169
|
-
You are a precise code transformation assistant.
|
|
169
|
+
You are a precise and conservative code transformation assistant.
|
|
170
170
|
|
|
171
171
|
User instruction (normalized):
|
|
172
172
|
${normalizedQuery}
|
|
173
173
|
|
|
174
|
-
|
|
175
|
-
-
|
|
174
|
+
IMPORTANT SAFETY RULES:
|
|
175
|
+
- If this chunk contains an UNFINISHED or UNCLOSED construct
|
|
176
|
+
(for example: an opening "{", "(", "[", "function", "class", or similar
|
|
177
|
+
that is not clearly closed within this chunk),
|
|
178
|
+
then you MUST return the chunk UNCHANGED.
|
|
179
|
+
- Do NOT invent missing braces, code, or structure.
|
|
180
|
+
- Do NOT attempt to "fix" incomplete syntax.
|
|
181
|
+
- When in doubt, return the chunk EXACTLY as given.
|
|
182
|
+
|
|
183
|
+
Transformation rules:
|
|
184
|
+
- Apply the instruction ONLY if it is clearly relevant to this chunk.
|
|
176
185
|
- If no change is needed, return the chunk UNCHANGED.
|
|
177
|
-
- You MUST return the FULL
|
|
178
|
-
- Do NOT return diffs or partial snippets.
|
|
186
|
+
- You MUST return the FULL chunk content.
|
|
187
|
+
- Do NOT return diffs, explanations, or partial snippets.
|
|
179
188
|
|
|
180
189
|
FILE: ${file.path}
|
|
181
190
|
CHUNK ${i + 1} / ${chunks.length}
|