2024-08-13 04:41:24 +00:00
Here's a text file that I'm going to ask you to make an edit to.
2024-08-07 01:30:48 +00:00
{{ # if language_name }}
2024-08-13 04:41:24 +00:00
The file is in {{ language_name }} .
2024-08-07 01:30:48 +00:00
{{ / if }}
2024-08-13 04:41:24 +00:00
You need to rewrite a portion of it.
The section you'll need to edit is marked with <rewrite_this></rewrite_this> tags.
2024-08-07 01:30:48 +00:00
<document>
{{{ document_content }}}
</document>
{{ # if is_truncated }}
The context around the relevant section has been truncated (possibly in the middle of a line) for brevity.
{{ / if }}
2024-08-13 04:41:24 +00:00
Rewrite the section of {{ content_type }} in <rewrite_this></rewrite_this> tags based on the following prompt:
2024-08-07 01:30:48 +00:00
<prompt>
{{{ user_prompt }}}
</prompt>
2024-08-13 04:41:24 +00:00
Here's the section to edit based on that prompt again for reference:
2024-08-07 01:30:48 +00:00
2024-08-13 04:41:24 +00:00
<rewrite_this>
{{{ rewrite_section }}}
</rewrite_this>
2024-08-07 01:30:48 +00:00
2024-08-13 04:41:24 +00:00
You'll rewrite this entire section, but you will only make changes within certain subsections.
2024-08-07 01:30:48 +00:00
2024-08-13 04:41:24 +00:00
{{ # if has_insertion }}
Insert text anywhere you see it marked with with <insert_here></insert_here> tags. Do not include <insert_here> tags in your output.
{{ / if }}
{{ # if has_replacement }}
Edit edit text that you see surrounded with <edit_here></edit_here> tags. Do not include <edit_here> tags in your output.
{{ / if }}
2024-08-07 01:30:48 +00:00
<rewrite_this>
2024-08-13 04:41:24 +00:00
{{{ rewrite_section_with_selections }}}
2024-08-07 01:30:48 +00:00
</rewrite_this>
2024-08-13 04:41:24 +00:00
Only make changes that are necessary to fulfill the prompt, leave everything else as-is. All surrounding {{ content_type }} will be preserved. Do not output the <rewrite_this></rewrite this> tags or anything outside of them.
2024-08-07 01:30:48 +00:00
2024-08-13 04:41:24 +00:00
Start at the indentation level in the original file in the rewritten {{ content_type }} . Don't stop until you've rewritten the entire section, even if you have no more changes to make. Always write out the whole section with no unnecessary elisions.
2024-08-07 01:30:48 +00:00
Immediately start with the following format with no remarks:
```
2024-08-13 04:41:24 +00:00
\ {{ REWRITTEN_CODE }}
2024-08-07 01:30:48 +00:00
```