Welcome to Petk Documentation
Petk is a comprehensive CLI toolkit designed specifically for prompt engineering workflows and template-driven content management. This documentation follows the DiΓ‘taxis framework to help you find exactly what you need, when you need it.
Getting Startedβ
New to Petk? Start with our Learning section for step-by-step tutorials and guides.
Need Help?β
Having trouble with something specific? Check our Problem-Solving section for solutions to common issues.
Quick Referenceβ
Looking for specific technical details? Our Reference section has comprehensive API documentation and configuration details.
Understanding Petkβ
Want to understand the concepts and design decisions behind Petk? Explore our Explanation section for architectural insights.
What is Petk?β
Petk is a prompt engineering toolkit that provides:
- Advanced Template Engine: Dynamic content inclusion with glob patterns, variable substitution, recursive processing, and cycle detection
- Markdown-to-YAML Converter: Transform documentation into structured data with multimodal content support and rich document analysis
- CLI Tools: Complete command-line interface for template processing, validation, conversion, and watch mode development
- Monorepo Architecture: Clean, maintainable TypeScript codebase with modular package structure
Key Capabilitiesβ
Template Processingβ
- Complex include blocks with YAML configuration
- Glob pattern matching with multiple sorting options (alphabetical, last updated)
- Deterministic content sampling and depth limit controls
- Variable substitution with recursive resolution
- Comprehensive cycle detection and error handling
Content Conversionβ
- Markdown to YAML transformation with AST processing
- Multimodal content detection and handling
- Rich document structure analysis
- Robust error reporting and recovery
Development Integrationβ
- Watch mode for real-time template processing
- Template validation and error reporting
- Project initialization and configuration management
- Seamless integration with modern development workflows
Navigation Guideβ
This documentation is organized into four main sections based on what you're trying to accomplish:
π Learningβ
Step-by-step tutorials and guides for newcomers. Start here if you're new to Petk or want to learn specific workflows.
π§ Problemsβ
Solutions to specific issues and troubleshooting guides. Use this when you're stuck on something particular.
π Referenceβ
Technical reference, API documentation, and configuration options. Use this for quick lookups and detailed specifications.
π‘ Explanationβ
Concepts, architectural decisions, and design philosophy. Use this to understand the "why" behind Petk's design.
Ready to get started? Choose the section that matches your current goal.