forked from jsnbuchanan/crowd-funder-for-time-pwa
feat: Add documentation meta-rule system with educational focus
- Create meta_documentation.mdc for comprehensive doc workflows - Add meta_rule_usage_guide.md for practical meta-rule usage - Enhance existing markdown rules with educational standards - Transform docs from technical reference to educational resources Emphasizes human competence over technical description, provides systematic workflows for all documentation tasks.
This commit is contained in:
@@ -10,6 +10,9 @@ This file combines core markdown formatting standards with automation
|
||||
guidelines. AI agents must follow these rules DURING content generation,
|
||||
not apply them after the fact.
|
||||
|
||||
**Primary Focus**: Create educational content that increases human
|
||||
competence, not just technical descriptions.
|
||||
|
||||
## AI Generation Guidelines
|
||||
|
||||
### **MANDATORY**: Follow These Rules While Writing
|
||||
@@ -21,6 +24,8 @@ When generating markdown content, you MUST:
|
||||
code blocks
|
||||
3. **Structure**: Use proper heading hierarchy and document templates
|
||||
4. **Formatting**: Apply consistent formatting patterns immediately
|
||||
5. **Educational Value**: Focus on increasing reader competence and
|
||||
understanding
|
||||
|
||||
### **DO NOT**: Generate content that violates these rules
|
||||
|
||||
@@ -28,6 +33,8 @@ When generating markdown content, you MUST:
|
||||
- ❌ Create content without proper blank line spacing
|
||||
- ❌ Use inconsistent formatting patterns
|
||||
- ❌ Assume post-processing will fix violations
|
||||
- ❌ Focus only on technical details without educational context
|
||||
- ❌ Assume reader has extensive prior knowledge
|
||||
|
||||
### **DO**: Generate compliant content from the start
|
||||
|
||||
@@ -35,6 +42,9 @@ When generating markdown content, you MUST:
|
||||
- ✅ Add blank lines around all structural elements
|
||||
- ✅ Use established templates and patterns
|
||||
- ✅ Apply formatting standards immediately
|
||||
- ✅ Explain concepts before implementation details
|
||||
- ✅ Provide context and motivation for technical choices
|
||||
- ✅ Include examples that illustrate key concepts
|
||||
|
||||
## Core Formatting Standards
|
||||
|
||||
@@ -99,6 +109,24 @@ When generating markdown content, you MUST:
|
||||
- **Indentation**: 2 spaces for nested items
|
||||
- **Blank lines**: Surround lists with blank lines
|
||||
|
||||
## Educational Content Standards
|
||||
|
||||
### **Content Structure for Learning**
|
||||
|
||||
- **Concept First**: Explain what something is before how to use it
|
||||
- **Context Matters**: Explain why and when to use a feature
|
||||
- **Progressive Disclosure**: Start simple, add complexity gradually
|
||||
- **Real Examples**: Use concrete, relatable scenarios
|
||||
- **Common Questions**: Anticipate and answer reader questions
|
||||
|
||||
### **Writing for Understanding**
|
||||
|
||||
- **Conversational Tone**: Write as if explaining to a colleague
|
||||
- **Active Voice**: "You can do this" not "This can be done"
|
||||
- **Question Format**: "What happens when..." to engage thinking
|
||||
- **Analogies**: Use familiar concepts to explain complex ideas
|
||||
- **Limitations**: Clearly state what solutions don't do
|
||||
|
||||
## Code Block Standards
|
||||
|
||||
### Inline Code
|
||||
@@ -146,6 +174,8 @@ When generating markdown content, you MUST:
|
||||
- [ ] **Headings**: Use ATX-style with proper hierarchy (H1 for title only)
|
||||
- [ ] **Lists**: Use consistent markers (- for unordered, 1. for ordered)
|
||||
- [ ] **Code**: Specify language for fenced blocks, use backticks for inline
|
||||
- [ ] **Educational Focus**: Plan content structure for learning progression
|
||||
- [ ] **Audience Consideration**: Identify target reader knowledge level
|
||||
|
||||
### After Generating Markdown Content
|
||||
|
||||
@@ -153,6 +183,8 @@ When generating markdown content, you MUST:
|
||||
- [ ] **Auto-fix**: Use `npm run markdown:fix` if any issues found
|
||||
- [ ] **Review**: Confirm content follows established templates and patterns
|
||||
- [ ] **Cross-reference**: Link to related documentation and templates
|
||||
- [ ] **Educational Review**: Verify content increases reader competence
|
||||
- [ ] **Example Validation**: Ensure examples illustrate key concepts clearly
|
||||
|
||||
### Quality Assurance
|
||||
|
||||
@@ -160,11 +192,14 @@ When generating markdown content, you MUST:
|
||||
- [ ] **Consistency**: Formatting matches existing documentation style
|
||||
- [ ] **Completeness**: All required sections and information included
|
||||
- [ ] **Accuracy**: Technical details are correct and up-to-date
|
||||
- [ ] **Educational Value**: Content increases reader understanding and competence
|
||||
- [ ] **Context Clarity**: Reader understands when and why to use the information
|
||||
|
||||
---
|
||||
|
||||
**See also**:
|
||||
|
||||
- `.cursor/rules/meta_documentation.mdc` for comprehensive documentation workflow
|
||||
- `.cursor/rules/docs/markdown_templates.mdc` for document templates
|
||||
- `.cursor/rules/docs/markdown_workflow.mdc` for validation workflows
|
||||
|
||||
|
||||
@@ -2,6 +2,9 @@
|
||||
|
||||
> **Agent role**: Reference this file for document templates, structure,
|
||||
> and examples when creating new documentation.
|
||||
>
|
||||
> **Focus**: Create educational content that increases human competence,
|
||||
> not just technical descriptions.
|
||||
|
||||
## Document Templates
|
||||
|
||||
@@ -18,10 +21,16 @@
|
||||
|
||||
Brief description of the document's purpose and scope.
|
||||
|
||||
**Educational Goal**: What will the reader learn and how will it increase
|
||||
their competence?
|
||||
|
||||
## Current State
|
||||
|
||||
Description of current situation or problem.
|
||||
|
||||
**Why This Matters**: Explain the business value and user benefit of
|
||||
addressing this situation.
|
||||
|
||||
## Implementation Plan
|
||||
|
||||
### Phase 1: Foundation
|
||||
@@ -29,12 +38,18 @@ Description of current situation or problem.
|
||||
- [ ] Task 1
|
||||
- [ ] Task 2
|
||||
|
||||
**Learning Context**: What concepts should the reader understand before
|
||||
proceeding with implementation?
|
||||
|
||||
## Next Steps
|
||||
|
||||
1. **Review and approve plan**
|
||||
2. **Begin implementation**
|
||||
3. **Test and validate**
|
||||
|
||||
**Continued Learning**: Where can the reader go next to deepen their
|
||||
understanding?
|
||||
|
||||
---
|
||||
|
||||
**Status**: Ready for implementation
|
||||
@@ -57,6 +72,9 @@ Description of current situation or problem.
|
||||
|
||||
Brief description of the technical specification.
|
||||
|
||||
**Business Context**: Why is this specification needed and what problem
|
||||
does it solve for users?
|
||||
|
||||
## Requirements
|
||||
|
||||
### Functional Requirements
|
||||
@@ -75,6 +93,9 @@ Brief description of the technical specification.
|
||||
|
||||
Description of the technical architecture.
|
||||
|
||||
**Design Rationale**: Why was this architecture chosen over alternatives?
|
||||
What are the trade-offs and benefits?
|
||||
|
||||
### Data Models
|
||||
|
||||
```typescript
|
||||
@@ -98,6 +119,79 @@ interface APIResponse<T> {
|
||||
## Testing Strategy
|
||||
|
||||
- [ ] Unit tests
|
||||
|
||||
**Learning from Testing**: What insights does testing provide about the
|
||||
system's behavior and design?
|
||||
|
||||
---
|
||||
|
||||
## Educational Documentation Template
|
||||
|
||||
### **Concept Explanation Template**
|
||||
|
||||
```markdown
|
||||
## What is [Concept Name]?
|
||||
|
||||
Brief, clear definition of the concept.
|
||||
|
||||
## Why Does [Concept Name] Matter?
|
||||
|
||||
Explain the business value and user benefit.
|
||||
|
||||
## How Does [Concept Name] Work?
|
||||
|
||||
High-level explanation of the mechanism.
|
||||
|
||||
## When Would You Use [Concept Name]?
|
||||
|
||||
Real-world scenarios and use cases.
|
||||
|
||||
## Common Misconceptions
|
||||
|
||||
Address typical misunderstandings.
|
||||
|
||||
## Examples
|
||||
|
||||
Concrete examples that illustrate the concept.
|
||||
|
||||
## Next Steps
|
||||
|
||||
Where to learn more about related concepts.
|
||||
```
|
||||
|
||||
### **Tutorial Template**
|
||||
|
||||
```markdown
|
||||
## Learning Objective
|
||||
|
||||
What the reader will accomplish by the end.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
What the reader should know before starting.
|
||||
|
||||
## Step-by-Step Guide
|
||||
|
||||
1. **Step 1**: What to do and why
|
||||
2. **Step 2**: What to do and why
|
||||
3. **Step 3**: What to do and why
|
||||
|
||||
## Verification
|
||||
|
||||
How to confirm the tutorial was successful.
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
Common issues and how to resolve them.
|
||||
|
||||
## What You've Learned
|
||||
|
||||
Summary of key concepts and skills.
|
||||
|
||||
## Next Steps
|
||||
|
||||
Where to apply this knowledge next.
|
||||
```
|
||||
- [ ] Integration tests
|
||||
- [ ] E2E tests
|
||||
|
||||
@@ -209,6 +303,7 @@ Standard implementation plans follow Phase 1 (Foundation), Phase 2
|
||||
|
||||
**See also**:
|
||||
|
||||
- `.cursor/rules/meta_documentation.mdc` for comprehensive documentation workflow
|
||||
- `.cursor/rules/docs/markdown_core.mdc` for core formatting standards
|
||||
- `.cursor/rules/docs/markdown_workflow.mdc` for validation workflows
|
||||
|
||||
|
||||
Reference in New Issue
Block a user