Build faster. Ship smarter.
Kosh is a high-performance static site generator built in Go, designed for developers who value speed, security, and modern architecture. Whether you’re building a personal blog or comprehensive documentation, Kosh delivers blazing-fast builds with intelligent caching.Incremental Builds
Persistent metadata caching with BoltDB intelligently skips unchanged files. Edit a post and rebuild in under 100ms.
Parallel Processing
Adaptive worker pools maximize throughput. Process 24 images simultaneously, render posts in parallel.
Native Rendering
Server-side LaTeX and D2 diagram rendering as inline SVG. No client-side JavaScript required.
WASM Search
Full-text search powered by Go and WebAssembly with BM25 ranking, fuzzy matching, and phrase search.
Why Kosh?
Performance First
Performance First
Incremental compilation with content-addressed storage means you only rebuild what changed. BoltDB-backed cache with BLAKE3 hashing ensures accuracy across platforms.
Security Hardened
Security Hardened
Built with security best practices from day one:
- BLAKE3 hashing for cryptographically secure content addressing
- Path validation prevents directory traversal attacks
- Input sanitization for all user-provided paths
- Graceful shutdown with proper context cancellation
Modern Architecture
Modern Architecture
Clean service-oriented architecture with dependency injection:
- Service Layer: Decoupled PostService, CacheService, AssetService, RenderService
- Go Generics: Type-safe cache operations with
getCachedItem[T any] - Object Pooling: Reusable buffers reduce GC pressure
- Worker Pools: Generic concurrent processing with context support
Advanced Search
Advanced Search
Industry-standard search engine with sophisticated ranking:
- BM25 Scoring: Relevance ranking used by major search engines
- Stemming: Porter stemmer reduces “running” → “run”
- Fuzzy Search: Typo tolerance with Levenshtein distance ≤ 2
- Phrase Matching: Use quotes for exact phrases:
"machine learning" - Msgpack Encoding: 30% smaller, 2.5x faster than GOB
Feature Highlights
Live Reloading
Built-in dev server with file watching. Changes appear instantly in your browser.
Asset Pipeline
Automatic minification and content-hash fingerprinting for CSS & JS files.
Image Optimization
Parallel WebP conversion with 24 concurrent workers and progress tracking.
SEO Ready
Auto-generates sitemap.xml, rss.xml, and fully optimized meta tags.
PWA Support
Service worker with stale-while-revalidate caching for offline access.
Knowledge Graph
Interactive force-directed graph visualization of content relationships.
Content Features
Markdown with Extensions
Full Goldmark support with syntax highlighting, admonitions, and table of contents generation.
Versioned Documentation
Multiple documentation versions with sparse versioning:
- Latest version accessible at root (
/getting-started.html) - Versioned URLs preserve path when switching (
/v4.0/getting-started.html) - Only changed pages need version-specific content
- Automatic outdated banners on non-latest versions
Performance Benchmarks
| Scenario | Time | Cache Hit Rate |
|---|---|---|
| Clean Build (150 posts) | ~12s | 0% |
| Single Post Edit | <100ms | 99% |
| Template Edit | 1-2s | Partial |
| Image Processing | Parallel | N/A |
Memory optimized: Buffer pooling and object reuse reduce GC pressure. Inline HTML for posts < 32KB avoids extra I/O.
Ready to get started?
Installation
Install Kosh via
go install and verify your setup.Quick Start
Build your first site in under 5 minutes.