Diátaxis Documentation Framework
This document explains how Lemline uses the Diátaxis documentation framework to organize our documentation. Understanding this framework will help you contribute effectively to our documentation and find what you need more efficiently.
What is Diátaxis?
Diátaxis is a systematic approach to technical documentation developed by Daniele Procida. It organizes documentation into four distinct categories based on user needs:
Tutorials - Learning-oriented content for beginners
How-to Guides - Problem-oriented guides for specific tasks
Reference - Information-oriented technical descriptions
Explanation - Understanding-oriented conceptual discussions
Each category serves a different purpose and addresses a different user need, requiring different approaches to writing and organization.
The Four Documentation Types
Tutorials: Learning-Oriented
Purpose: Help new users learn by doing
Tutorials are hands-on lessons that lead the user through a series of steps to complete a project or learn a concept. They are aimed at beginners who are just getting started.
Characteristics:
Step-by-step instructions
Focused on learning, not reference
Build working examples
Make success attainable
Show instead of tell
Reduce cognitive load
Examples in Lemline Documentation:
Tutorial Template
How-to Guides: Problem-Oriented
Purpose: Help users accomplish specific tasks
How-to guides show users how to solve specific problems or accomplish particular tasks. They assume the user has basic knowledge and is trying to get something done.
Characteristics:
Task-oriented
Problem-focused
Practical steps
Flexible for different contexts
Goal-driven
Assume basic knowledge
Examples in Lemline Documentation:
How-to Guide Template
Common Issues and Solutions
Issue: [Common problem]
Solution: [How to fix it]
Related Information
[Link to related how-to guide]
[Link to relevant reference]
Error Codes
Code | Message | Description |
|---|---|---|
1001 | "Error message" | Explanation |
Applying Diátaxis in Lemline Documentation
Content Organization
Lemline documentation is organized following the Diátaxis model:
Learning Path for Newcomers
Getting started
Tutorials section
Conceptual overviews (explanations)
Problem-Solving for Practitioners
How-to guides categorized by task type
Real-world examples
Troubleshooting guides
Technical Details for Implementers
API reference
DSL reference
Configuration options
CLI commands
Conceptual Knowledge for Understanding
Architecture explanations
Design principles
Decision rationales
File Naming Conventions
To clearly identify the type of documentation, we use these prefixes:
lemline-tutorial-for tutorialslemline-howto-for how-to guideslemline-ref-for reference documentationlemline-explain-for explanationslemline-example-for example libraries
Cross-Referencing Between Types
Documentation should cross-reference between the four types:
Tutorials link to relevant how-to guides for further tasks
How-to guides reference the detailed API documentation
Reference documentation links to explanations for context
Explanations link to tutorials and how-to guides for practical applications
Writing Guidelines by Documentation Type
Tutorial Writing Guidelines
Write for complete beginners to the topic
Focus on concrete, working examples
Use a conversational, encouraging tone
Break down steps into manageable chunks
Anticipate and prevent errors
Keep focused on the learning path
Test all tutorials thoroughly
How-to Guide Writing Guidelines
Focus on specific tasks or problems
Provide clear, concise steps
Assume basic knowledge
Provide working examples
Offer troubleshooting tips
Make steps adaptable to different scenarios
Explain why certain steps are taken
Reference Writing Guidelines
Be comprehensive and accurate
Use consistent structure and formatting
Provide all necessary technical details
Be objective and factual
Document all options and behaviors
Use precise technical language
Include complete examples
Explanation Writing Guidelines
Focus on building understanding
Explain why, not just how
Discuss design decisions and trade-offs
Use analogies and diagrams to clarify concepts
Make connections between related concepts
Provide context and background
Anticipate conceptual challenges
Evaluating Documentation Quality
For each documentation type, ask yourself:
Tutorial Quality Checklist
Can a complete beginner successfully follow it?
Does it build a working example?
Does it explain what the user is learning and why?
Are the steps clear and manageable?
Does it lead to a sense of accomplishment?
How-to Guide Quality Checklist
Does it address a specific task or problem?
Are the steps clear and practical?
Can it be adapted to various scenarios?
Does it provide troubleshooting advice?
Is it focused on practical outcomes?
Reference Quality Checklist
Is it accurate and complete?
Is it structured consistently?
Does it document all available options?
Is it precise and technically correct?
Is it easy to navigate and search?
Explanation Quality Checklist
Does it build conceptual understanding?
Does it explain why, not just how?
Does it discuss alternatives and trade-offs?
Does it provide helpful context?
Does it correct common misconceptions?
Best Practices for Contributors
When contributing to Lemline documentation:
Identify the Documentation Type - Determine which of the four types best matches your contribution
Follow the Templates - Use the templates provided for each document type
Maintain Separation - Keep different documentation types separate; don't mix tutorials with reference material
Cross-Reference - Link between document types to create a cohesive documentation system
Use Appropriate Style - Adapt your writing style to the documentation type
Test and Review - Ensure your documentation works as intended for its type
Conclusion
The Diátaxis framework provides a clear structure for organizing technical documentation based on user needs. By separating tutorials, how-to guides, reference, and explanation, we create a more usable and effective documentation system for Lemline users at all levels of experience.
Understanding these documentation types will help you navigate the existing documentation more effectively and contribute new documentation that serves its intended purpose.
For more information, see: