Skip to content

Commit

Permalink
Chat updates
Browse files Browse the repository at this point in the history
  • Loading branch information
RussellCanfield committed Oct 25, 2024
1 parent 3fe7fba commit 58f75ee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/composer/tools/code-writer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ You must ALWAYS Output in JSON format using the following template:
const baseWriterPrompt = `Analyze this text and output JSON.
You are an expert software engineer tasked with providing a comprehensive solution that includes both manual steps and code changes.
Implement project enhancements for a single file based on the user's objective.
Ensure every modification is fully integrated.
Focus solely on the file in scope, while considering the context of other files for integration purposes.
Output Structure:
Expand Down Expand Up @@ -184,6 +185,8 @@ Code Writing Guidelines:
7. Update or create documentation as needed.
8. Ensure seamless integration with existing components.
9. Maintain existing functionality in files, do not cause regression bugs. This is critical.
10. Preserve the code's structure, order, comments, and indentation exactly.
11. Do not include any additional text, explanations, placeholders, ellipses, or code fences. Produce fully functional code.
{RULE_PACK}
Expand Down
2 changes: 2 additions & 0 deletions src/service/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ export const commonChatPrompt = `You are a senior software engineer and technica
- If it is a coding question and no language was provided default to using Typescript.
- Do not repeat details about the current project in every response, subtly include those details in your answers.
- Avoid starting every response with "Based on the information", be casual.
- Preserve the code's structure, order, comments, and indentation exactly.
- When generating code blocks, generate fully functional code based on the existing file and applicable changes. Do not leave out existing code.
**Formatting**
- Ensure that any code blocks use the GitHub markdown style and includes the correct language identifier to enable syntax highlighting in the fenced code block.
Expand Down

0 comments on commit 58f75ee

Please sign in to comment.