KERI Improvement Documents (KIDs) are modular documentation artifacts that provide implementation guidance ('how we do it') for KERI protocol components, with separate commentary explaining design rationale ('why'), enabling independent team contributions through pull requests while keeping technical specifications distinct from explanatory context.
Related Concepts
No related concepts available
Comprehensive Explanation
KERI Improvement Documents (KIDs)
Definition and Core Purpose
KERI Improvement Documents (KIDs) are structured, modular documentation units within the KERI ecosystem that serve as the primary mechanism for capturing and disseminating implementation knowledge. Each KID focuses on answering the fundamental question "how we do it" by providing concrete, actionable implementation guidance for specific aspects of the KERI protocol, ACDC credentials, CESR encoding, or related components in the KERI suite.
The defining architectural principle of KIDs is their explicit separation of implementation details from design rationale. This separation enables implementors to focus on technical specifications without being distracted by background context, while still providing that contextual information for those who need deeper understanding of architectural decisions. As stated in the canonical definition: "KIDs answer the question 'how we do it' while adding commentary that elaborates on the 'why,' split from the how to not bother implementors with the why."
Modular Architecture and Contribution Model
Independent Development Framework
KIDs are designed with a modular architecture that fundamentally enables distributed, parallel development across the KERI ecosystem. This architecture supports:
Independent team contributions: Multiple teams of contributors can work simultaneously on individual KIDs without requiring coordination overhead or sequential dependencies
Pull request workflow: Each KID can be developed independently and submitted as a separate pull request to the
Implementation Notes
Documentation Structure
KIDs follow a consistent organizational pattern:
Implementation Section: Concrete technical guidance answering "how we do it"
Commentary Section: Design rationale and context explaining "why we do it this way"
Separation Principle: These sections are kept distinct to serve different audiences
Contribution Workflow
The KID contribution process leverages GitHub's collaborative features:
Each KID is developed in its own branch
Pull requests enable peer review before merging
Version control provides complete history of implementation guidance evolution
Multiple teams can work on different KIDs simultaneously without conflicts
Relationship to Formal Specifications
KIDs complement but do not replace formal protocol specifications:
IETF Drafts: Provide normative protocol definitions
Separation of concerns: Technical implementation details are kept distinct from explanatory rationale and commentary
This modular design reflects KERI's broader architectural philosophy of composability and modularity. Just as CESR primitives can be composed into complex streams, and just as KELs can be independently verified, KIDs can be independently developed and composed into comprehensive implementation guides.
Distributed Contribution Workflow
The KID framework supports a distributed contribution model where development occurs across organizational boundaries. The pull request-based workflow enables:
Asynchronous development: Teams can work on their KIDs according to their own schedules and priorities
Peer review process: Each KID undergoes community review before integration
Version control: All KIDs are maintained in version-controlled repositories, providing verifiable history of changes
Collaborative refinement: Multiple contributors can propose improvements to existing KIDs through the standard GitHub workflow
This distributed model is essential for the KERI ecosystem because the protocol spans multiple implementation languages (KERIpy, KERI-ox, JavaScript implementations), multiple application domains (credentials, supply chain, telecommunications), and multiple organizational participants (GLEIF, ToIP Foundation, individual contributors).
Documentation Philosophy and Structure
The "How" and "Why" Separation
The KID documentation philosophy implements a dual-layer structure that serves different reader needs:
Contains technical specifications, code examples, and procedures
Focuses on what implementors need to build working systems
Avoids theoretical discussions that don't directly inform implementation decisions
Commentary Layer ("Why"):
Elaborates on design rationale and architectural decisions
Explains the reasoning behind specific implementation approaches
Provides context for understanding trade-offs and constraints
Helps implementors understand when and how to deviate from patterns
This separation is intentional and architectural, not merely organizational. As the canonical definition emphasizes, the split ensures implementors "are not bothered" with rationale when they simply need to know how to implement a feature correctly. However, the rationale remains accessible for those who need deeper understanding to:
Define protocol requirements and normative behavior
Use formal language (MUST, SHOULD, MAY per RFC 2119)
Focus on what systems must do to be compliant
Target specification authors and protocol designers
KERI Improvement Documents:
Provide implementation patterns and best practices
Use practical language focused on how to build systems
Bridge the gap between abstract requirements and working code
Target software engineers and system implementors
Implementation Code (KERIpy, KERIA, Signify):
Provide concrete, executable implementations
Serve as reference implementations demonstrating patterns
Include implementation-specific optimizations and details
Standards Compliance and Custom Enhancement
The WOT-terms documentation process reveals that KIDs serve two clearly distinctive purposes:
Standards Compliance: Conform to ToIP and eSSIF-lab standards for generating glossaries to maintain interoperability with the broader SSI ecosystem
Custom Enhancement: Create WebOfTrust-specific versions with added metadata, expertise levels, categories, and customized layout/UI to fit the Docusaurus KERISSE site
This dual purpose reflects KERI's position at the intersection of formal standardization (through IETF and ToIP) and practical implementation (through the WebOfTrust community). KIDs must balance:
Standardization requirements: Ensuring implementations are interoperable across organizations
Implementation flexibility: Allowing implementors to make appropriate choices for their contexts
Innovation support: Enabling experimental features that may later be standardized
Role in the KERI Suite Development Process
Supporting Multiple Implementations
KIDs are particularly critical for KERI because the protocol has multiple implementations across different programming languages:
KERI-ox: Rust implementation for performance-critical applications
JavaScript implementations: For web and mobile applications like Signify
Go implementations: For integration with blockchain and distributed systems
KIDs provide language-agnostic implementation patterns that can be adapted across these codebases. For example, a KID describing the witness agreement algorithm (KAACE) would specify:
The mathematical requirements for threshold satisfaction
The message flow patterns between witnesses
The state machine for receipt collection
Edge cases and error handling approaches
Each language implementation can then adapt these patterns to their specific programming paradigms while maintaining protocol compliance.
Integration with Development Tools
KERIA and Agent Development
The KERIA (KERI Agent in the cloud) documentation demonstrates how KIDs support practical implementation. The SKRAP (Signify/KERIA Request Authentication Protocol) documentation follows KID principles by:
Clearly separating the protocol mechanics (how) from the security rationale (why)
Providing concrete examples of API calls and response formats
Explaining the three-interface architecture (Boot, Admin, KERI Protocol) without overwhelming implementors with design rationale
Including commentary on the cooperative delegation model for those who need to understand the security implications
Step-by-step procedures for common operations (identifier creation, key rotation, witness configuration)
Clear parameter descriptions and examples
Commentary explaining when and why to use specific features
Troubleshooting guidance based on common implementation mistakes
Educational Function
KIDs serve as primary learning resources for developers entering the KERI ecosystem. The Q&A documentation structure demonstrates this educational role:
Star-Rating System for Complexity:
*Q (one star): "Novice to KERI, advanced in DIDs"
**Q (two stars): "Proficient in DIDs and advanced in KERI"
***Q (three stars): "Expert in DIDs and KERI"
This progressive complexity model allows developers to:
Start with fundamental concepts (self-certifying identifiers, key event logs)
Progress to intermediate topics (witness networks, delegation)
Advance to expert topics (duplicity detection algorithms, cryptographic agility)
KIDs at each level provide the appropriate depth of implementation guidance, with commentary that helps developers understand when they're ready to tackle more advanced topics.
Technical Content Organization
Canonical Terminology Foundation
KIDs are built on a foundation of 459 canonical KERI/GLEIF terms with extensive alias mappings. This canonical terminology ensures:
Consistent naming: All KIDs use the same term for a given concept
Alias resolution: Multiple common phrasings map to canonical terms
Cross-referencing: Related concepts are explicitly linked
Disambiguation: Terms with multiple meanings are clearly differentiated
For example, the canonical term ACDC includes 20+ aliases ("authentic-chained-data-container", "authentic chained data container", "acdc", "ACDCs", etc.), ensuring that regardless of how an author or reader refers to the concept, the documentation system resolves to the same canonical definition.
Category-Based Organization
KIDs are organized by topic categories that reflect the KERI suite architecture:
KERI Core: KEL operations, key management, establishment events
Each level of KID provides appropriate technical depth, with the "why" commentary helping implementors understand when they need to understand the next level.
Code Examples and Reference Implementations
KIDs complement but don't replace reference implementations. The relationship is:
Reference Implementations:
Provide complete, executable code
Include optimization and performance considerations
Handle all edge cases and error conditions
Serve as definitive examples of correct behavior
KIDs:
Extract key patterns and principles from implementations
Explain the logic behind implementation choices
Provide pseudocode or simplified examples
Guide implementors in adapting patterns to their contexts
For example, the KERIpy "Getting Started" tutorial demonstrates this relationship by providing concrete Python code examples with explanatory commentary that could be adapted to other languages.
Future Evolution and Maintenance
Living Documentation Model
KIDs are designed as living documentation that evolves with the protocol:
Example validation: Code examples in KIDs are automatically tested
Security testing: KID security guidance is verified through penetration testing
Tooling and Automation
The documentation infrastructure demonstrates sophisticated tooling:
Docusaurus integration: KIDs are rendered in searchable, navigable web format
Typesense search: Full-text search across all KIDs and related documentation
Automated glossary linking: Terms automatically link to canonical definitions
Build pipeline: JSON schema generation, link validation, accessibility checking
This tooling ensures KIDs are not only accurate but also discoverable and usable.
Conclusion
KERI Improvement Documents represent a sophisticated documentation framework that balances the competing demands of formal standardization, practical implementation, and ongoing innovation. By separating "how" from "why," supporting distributed development, and integrating with broader KERI tooling and standards efforts, KIDs serve as the operational documentation layer that enables the KERI ecosystem to scale across multiple implementations, organizations, and use cases.
For developers entering the KERI ecosystem, KIDs provide the practical guidance needed to build secure, interoperable systems. For protocol designers, KIDs capture implementation experience that informs protocol evolution. For the broader identity community, KIDs demonstrate how complex cryptographic protocols can be made accessible through thoughtful documentation architecture.