AI Prompt Library Template
A structured way to document and share effective prompts within the organization.
The following template is from the Google Prompt Engineering document, credited to and authored by Lee Boonstra. It was published in February 2025
Comprehensive Prompt Template
This template incorporates best practices for crafting effective prompts, aligning with the Vibe Coding Framework's S.C.A.F.F. methodology.
# Prompt Engineering Template
## Prompt Identification
- **Name**: [Unique identifier for this prompt]
- **Version**: [Version number]
- **Created By**: [Author name]
- **Last Modified**: [Date]
- **Category**: [Component type: Authentication, Data Access, UI, etc.]
## Purpose and Goals
- **Primary Goal**: [Clear description of what this prompt should accomplish]
- **Use Cases**: [Specific scenarios where this prompt is effective]
- **Expected Output**: [What the generated code should include/accomplish]
## Technical Configuration
- **Target Model**: [AI model this prompt was designed for]
- **Parameters**:
* Temperature: [0.0-1.0; lower for factual tasks, higher for creative ones]
* Token Limit: [Maximum tokens in response]
* Top-K: [If applicable]
* Top-P: [If applicable]
## S.C.A.F.F. Structure
### Situation
[Project context, existing architecture, technology stack]
### Challenge
[Specific coding task to be accomplished]
### Audience
[Experience level of developers who will maintain the code]
### Format
[Coding style, patterns, and organization preferences]
### Foundations
[Security requirements, performance considerations, and constraints]
## Examples
[Example inputs/outputs to guide the model]
**Example 1**:
- Input: [Sample requirement]
- Output: [Expected code pattern]
**Example 2**:
- Input: [Sample requirement]
- Output: [Expected code pattern]
## Usage Guidelines
- **For Security-Critical Components**:
- Set temperature: 0.0-0.2
- Include explicit security requirements
- Request detailed documentation of security measures
- **For Performance-Sensitive Components**:
- Specify performance constraints
- Request optimization techniques
- Require complexity analysis
- **For UI Components**:
- Include accessibility requirements
- Specify responsive design needs
- Reference design system patterns
## Effectiveness Metrics
- **Success Rate**: [% of usable outputs on first attempt]
- **Iteration Count**: [Average refinements needed]
- **Issues Found**: [Common issues during verification]
- **Time Savings**: [Estimated time saved vs manual coding]
## Documentation
- **Related Components**: [Links to related components]
- **Security Review**: [Security verification status]
- **Notes and Insights**: [Learnings and special considerations]
- **Improvement History**: [Record of prompt refinements and their effects]Example Implementation
Usage Guidelines
Set temperature to 0.2 for security-critical code
Include test cases for all authentication paths
Request explicit error handling for all edge cases
Specify rate limiting parameters based on environment
Effectiveness Metrics
Success Rate: 85% usable on first attempt
Iteration Count: Typically 1-2 refinements needed
Issues Found: Occasionally misses CSRF protection
Time Savings: Approximately 3-4 hours per implementation
Documentation
Related Components: user-service, email-service
Security Review: Approved by security team on 2025-03-20
Notes and Insights: Adding explicit CSRF protection requirements improves results
Improvement History:
v1.0: Initial version
v1.1: Added rate limiting requirements
v1.2: Added refresh token rotation for improved security
Last updated