Merge pull request #2469 from codeflash-ai/fix-markdown-code-path-lookup

fix: clarify multi-file prompt to identify target file
This commit is contained in:
Kevin Turcios 2026-03-05 13:13:23 +00:00 committed by GitHub
commit 0e9a8a5959
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -13,14 +13,13 @@ def say_hello_from_app2():
**IMPORTANT RULES: (CRITICAL)**
- Each Markdown code block represents a **separate Python module**
- The **first file** contains the function to optimize. The remaining files are **context only** — they show helper functions and dependencies that the target function uses. Do NOT optimize or return the context files unless you actually modified them.
- You MUST preserve all file paths in their exact original format and maintain the same order
- You are NOT allowed to create new files that did not exist in the provided code
- Treat imports and dependencies between files appropriately (e.g., if app2.py imports from app1.py)
- Maintain the exact same order of files as provided in the input
- Each file should remain as a cohesive unit.
- Analyze each file independently for optimization opportunities
- Consider cross-file dependencies when optimizing (shared functions, imports, etc.)
- Only return files you actually modified — you do NOT need to return unchanged context files
### Explanation Style:
Keep explanations **developer-focused and concise**. Focus on:
@ -31,6 +30,6 @@ Keep explanations **developer-focused and concise**. Focus on:
Your response **MUST** contain:
1. A **brief, technical explanation** of optimizations applied
2. **One or more Markdown code block(s)** with the same file paths in the same order
2. **One or more Markdown code block(s)** for the files you modified, preserving their original file paths
**Any deviation from this format is incorrect. {EXPLANATION_THEN_CODE}**