Elffuss BraidHub

kikocis/continue public

update prompts.md
Changeset5c65352c196aea4210954e5229d0945ebd6087de45109c28d20fa3c5132c47d5
AuthorNate <sestinj@gmail.com> · 2025-06-22 23:16 -07:00
CommitterNate <sestinj@gmail.com> · 2025-06-22 23:16 -07:00
Parents79297418933b

Browse the files at this changeset

1 file changed

modified docs/docs/customize/deep-dives/prompts.md +33 −72
@@ -5,93 +5,54 @@
55 Prompts are reusable instructions that can be referenced at any time during chat. They are especially useful as context for repetitive and/or complex tasks.
66
77 :::info
8-Visit the Hub to [explore prompts](https://hub.continue.dev/explore/prompts) or [create your own](https://hub.continue.dev/new?type=block&blockType=prompts)
8+Prompts were previously defined in a `.prompt` file format, but for consistency we now recommend using the same Markdown format as [rules](./rules.mdx) and adding `alwaysApply: false` to the frontmatter so that they are manually triggered.
99 :::
1010
11-## Examples
12-
13-Below are some examples to get you started.
14-
15-### Security review
16-
17-```text title="Security best practices review"
18-@open - Review these files for the following security best practices:
19-- Does the architecture follow security-by-design principles?
20-- Are there potential security vulnerabilities in the system design?
21-- Is sensitive data handled appropriately throughout the lifecycle?
22-```
23-
24-### Reference best practice guides
25-
26-```text title="Redux best practices review"
27-@https://redux.js.org/style-guide/
28-@currentFile
11+### Quick Start
2912
30-Review this code for adherence to Redux best practices.
31-```
13+Below is a quick example of setting up a prompt file:
3214
33-### Pull in commonly used files for tasks
15+1. Create a folder called `.continue/rules` at the top level of your workspace
16+2. Add a file called `review-prompt.md` to this folder.
17+3. Write the following contents to `review-prompt.md` and save.
3418
35-```text title="Generate a new TypeORM entity"
36-@src/db/dataSource.ts @src/db/entity/SampleEntity.ts
19+```md title="review-prompt.md"
20+---
21+name: Redux best practices review
22+alwaysApply: false
23+---
3724
38-Use these files to generate a new TypeORM entity based on the following requirements:
25+Review the currently open file for adherence to Redux best practices, as explained in their style guide at https://redux.js.org/style-guide/.
3926 ```
4027
41-## Including Context Providers in your prompts
42-
43-Many [context providers](../context-providers.mdx) can be referenced by typing "@" followed by the name of the context provider. The currently supported list is:
44-
45-- `@terminal` - The contents of the terminal
46-- `@currentFile` - The currently active file
47-- `@open` - All open files
48-- `@os` - Information about the operating system
49-- `@problems` - Problems reported by the language server in the active file
50-- `@repo-map` - A map of files in the repository
51-- `@tree` - A tree view of the repository structure
52-
53-Or you can directly type URLs and file paths:
54-
55-- `@https://github.com/continuedev/continue` - The contents of a URL
56-- `@src/index.ts` - The contents of a file (VS Code only)
28+Now to use this prompt, you can open Chat, type <kbd>/</kbd>, select the prompt, and type out any additional instructions you'd like to add.
5729
58-All references will be attached as context items, rather than injected directly inline.
30+## Further Examples
5931
60-## Local `.prompt` files
32+Below are more examples to get you started. You can also visit the Hub to [explore prompts](https://hub.continue.dev/explore/prompts) or [create your own](https://hub.continue.dev/new?type=block&blockType=prompts).
6133
62-In addition to Prompt blocks on the Hub, you can also define prompts in local `.prompt` files, located in the `.continue/prompts` folder at the top level of your workspace. This is useful for quick iteration on prompts to test them out before pushing up to the Hub.
63-
64-### Quick Start
65-
66-Below is a quick example of setting up a prompt file:
67-
68-1. Create a folder called `.continue/prompts` at the top level of your workspace
69-2. Add a file called `test.prompt` to this folder.
70-3. Write the following contents to `test.prompt` and save.
34+### Security review
7135
72-```.prompt
73-name: Current file prompt
74-description: A test prompt using the current file context provider
36+```md title="security-review.md"
37+---
38+name: Security best practices review
39+alwaysApply: false
7540 ---
76-@currentFile
77-```
78-
79-Now to use this prompt, you can open Chat, type <kbd>/</kbd>, select the prompt, and add type out some additional text such as "Review the code for any issues".
80-
81-### Format
82-
83-The format is inspired by [HumanLoops's .prompt file](https://docs.humanloop.com/docs/prompt-file-format), with additional templating to reference files, URLs, and context providers.
8441
85-:::info
86-The current state of this format is experimental and subject to change
87-:::
42+Review the changes in the current git diff for these security best practices:
8843
89-### Preamble
44+- Does the architecture follow security-by-design principles?
45+- Are there potential security vulnerabilities in the system design?
46+- Is sensitive data handled appropriately throughout the lifecycle?
47+```
9048
91-The "preamble" is everything above the `---` separator, and lets you specify model parameters. It uses YAML syntax and currently supports the following parameters:
49+### Pull in commonly used files for tasks
9250
93-- `name` - The display title
94-- `description` - The description you will see in the dropdown
95-- `version` - Can be either "1" (for legacy prompt files) or "2" (this is the default and does not need to be set)
51+```md title="typeorm-entity-generator.md"
52+---
53+name: Generate a new TypeORM entity
54+alwaysApply: false
55+---
9656
97-If you don't need any of these parameters, you can leave out the preamble and do not need to include the `---` separator.
57+Referencing `src/db/dataSource.ts` and `src/db/entity/SampleEntity.ts`, generate a new TypeORM entity based on the following requirements:
58+```