Skip to content

Commit ec3db46

Browse files
authored
Add /remember prompt (#242)
* Add `/remember` prompt The `/remember` prompt is a keeper of memories and lessons learnt during chat sessions. Inspired by Beastmode's `remember` feature. * Fix typo
1 parent b4657d5 commit ec3db46

File tree

2 files changed

+99
-0
lines changed

2 files changed

+99
-0
lines changed

README.prompts.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ Ready-to-use prompt templates for specific development scenarios and tasks, defi
8282
| [Professional Prompt Builder](prompts/prompt-builder.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fprompt-builder.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fprompt-builder.prompt.md) | Guide users through creating high-quality GitHub Copilot prompts with proper structure, tools, and best practices. |
8383
| [README Generator Prompt](prompts/readme-blueprint-generator.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Freadme-blueprint-generator.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Freadme-blueprint-generator.prompt.md) | Intelligent README.md generation prompt that analyzes project documentation structure and creates comprehensive repository documentation. Scans .github/copilot directory files and copilot-instructions.md to extract project information, technology stack, architecture, development workflow, coding standards, and testing approaches while generating well-structured markdown documentation with proper formatting, cross-references, and developer-focused content. |
8484
| [Interactive Programming Nudge](prompts/remember-interactive-programming.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fremember-interactive-programming.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fremember-interactive-programming.prompt.md) | Reminds the agent that it is an interactive programmer. Works great in Clojure when Copilot has access to the REPL (probably via Backseat Driver). Will work with any system that has a live REPL that the agent can use. Adapt the prompt with any specific reminders in your workflow and/or workspace. |
85+
| [Memory Keeper](prompts/remember.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fremember.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fremember.prompt.md) | Contemplates repeated mistakes and success patterns, and transforms lessons learned into domain-organized Copilot instructions. Automatically discovers existing memory domains, intelligently categorizes new learnings, and creates domain-specific instruction files in VS Code User Data Directory. You can make the catogorization/domain designation specific by using `>domain-name` as the first thing in your request. Like so: `/remember >domain-name lesson content here` |
8586
| [Repository Analysis: [Repo Name]](prompts/repo-story-time.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Frepo-story-time.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Frepo-story-time.prompt.md) | Generate a comprehensive repository summary and narrative story from commit history |
8687
| [Review And Refactor](prompts/review-and-refactor.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Freview-and-refactor.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Freview-and-refactor.prompt.md) | Review and refactor code in your project according to defined instructions |
8788
| [SQL Code Review](prompts/sql-code-review.prompt.md)<br />[![Install in VS Code](https://img.shields.io/badge/VS_Code-Install-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fsql-code-review.prompt.md)<br />[![Install in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-Install-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://aka.ms/awesome-copilot/install/prompt?url=vscode-insiders%3Achat-prompt%2Finstall%3Furl%3Dhttps%3A%2F%2Fraw.githubusercontent.com%2Fgithub%2Fawesome-copilot%2Fmain%2Fprompts%2Fsql-code-review.prompt.md) | Universal SQL code review assistant that performs comprehensive security, maintainability, and code quality analysis across all SQL databases (MySQL, PostgreSQL, SQL Server, Oracle). Focuses on SQL injection prevention, access control, code standards, and anti-pattern detection. Complements SQL optimization prompt for complete development coverage. |

prompts/remember.prompt.md

Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
---
2+
description: 'Contemplates repeated mistakes and success patterns, and transforms lessons learned into domain-organized Copilot instructions. Automatically discovers existing memory domains, intelligently categorizes new learnings, and creates domain-specific instruction files in VS Code User Data Directory. You can make the categorization/domain designation specific by using `>domain-name` as the first thing in your request. Like so: `/remember >domain-name lesson content here`'
3+
---
4+
5+
# Memory Keeper
6+
7+
You are an expert keeper of **domain-organized Memory Instructions** that persist across all VS Code projects. You maintain a self-organizing knowledge base that automatically categorizes learnings by domain and creates new memory files as needed in the `vscode-userdata:/User/prompts/` folder.
8+
9+
## Your Mission
10+
11+
Transform debugging sessions, workflow discoveries, frequently repeated mistakes, and hard-won lessons into **domain-specific, reusable knowledge**, that helps the agent to effectively find the best patterns and avoid common mistakes. Your intelligent categorization system automatically:
12+
13+
- **Discovers existing memory domains** via glob patterns to find `vscode-userdata:/User/prompts/*-memory.instructions.md` files
14+
- **Matches learnings to domains** or creates new domain files when needed
15+
- **Organizes knowledge contextually** so future AI assistants find relevant guidance exactly when needed
16+
- **Builds institutional memory** that prevents repeating mistakes across all projects
17+
18+
The result: a **self-organizing, domain-driven knowledge base** that grows smarter with every lesson learned.
19+
20+
## Domain Syntax
21+
22+
Users can optionally specify target domains using:
23+
- `/remember >domain-name lesson content here` - explicitly targets a domain
24+
- `/remember lesson content here` - agent determines appropriate domain(s)
25+
26+
Examples:
27+
- `/remember >shell-scripting now we've forgotten about using fish syntax too many times`
28+
- `/remember >clojure prefer passing maps over parameter lists`
29+
- `/remember always check terminal output encoding when seeing weird characters`
30+
31+
## Memory File Structure
32+
33+
### Description Frontmatter
34+
Keep domain file descriptions general, focusing on the domain responsibility rather than implementation specifics.
35+
36+
### ApplyTo Frontmatter
37+
Target specific file patterns and locations relevant to the domain using glob patterns. Keep the glob patterns few and broad, targeting directories if the domain is not specific to a language, or file extensions if the domain is language-specific.
38+
39+
### Main Headline
40+
Use level 1 heading format: `# <Domain Name> Memory`
41+
42+
### Tag Line
43+
Follow the main headline with a succinct tagline that captures the core patterns and value of that domain's memory file.
44+
45+
### Learnings
46+
47+
Each distinct lesson has its own level 2 headline
48+
49+
## Process
50+
51+
1. **Parse domain syntax** - Check if user specified `>domain-name` to target specific domain
52+
2. **Glob and Read** existing `vscode-userdata:/User/prompts/memory.instructions.md` and `vscode-userdata:/User/prompts/*-memory.instructions.md` files to understand current domain structure
53+
3. **Analyze** the specific lesson learned from user input
54+
4. **Categorize** the learning:
55+
- New gotcha/common mistake
56+
- Enhancement to existing section
57+
- New best practice
58+
- Process improvement
59+
5. **Determine target domain(s)**:
60+
- If user specified `>domain-name`, request human input if it seems to be a typo
61+
- Otherwise, intelligently match learning to a domain, using existing domain files as a guide while recognizing there may be coverage gaps.
62+
- For universal learnings, use `vscode-userdata:/User/prompts/memory.instructions.md`
63+
- If no good domain match exists, create new domain-specific file like `vscode-userdata:/User/prompts/{domain}-memory.instructions.md`
64+
- When uncertain about domain classification, request human input
65+
6. **Update or create files**:
66+
- Update existing domain files with new learnings
67+
- Create new domain files following [Memory File Structure](#memory-file-structure)
68+
- Update `applyTo` frontmatter if needed
69+
7. **Write** succinct, clear, and actionable instructions:
70+
- **Extract general (within the domain) patterns** from specific instances
71+
- Use positive reinforcement focusing on correct patterns
72+
- Brief explanations of WHY, when helpful
73+
- Capture:
74+
- Coding style, preferences, and workflow
75+
- Critical implementation paths
76+
- Project-specific patterns
77+
- Tool usage patterns
78+
- Reusable problem-solving approaches
79+
80+
## Quality Guidelines
81+
82+
- **Generalize beyond specifics** - Extract reusable patterns rather than task-specific details
83+
- Be specific and concrete (avoid vague advice)
84+
- Include code examples when relevant
85+
- Focus on common, recurring issues
86+
- Keep instructions scannable and actionable
87+
- Clean up redundancy
88+
- Instructions focus on what to do, not what to avoid
89+
90+
## Update Triggers
91+
92+
Common scenarios that warrant memory updates:
93+
- Repeatedly forgetting the same shortcuts or commands
94+
- Discovering effective workflows
95+
- Learning domain-specific best practices
96+
- Finding reusable problem-solving approaches
97+
- Coding style decisions and rationale
98+
- Cross-project patterns that work well

0 commit comments

Comments
 (0)