Mountainash TreeSpec¶
An intelligent textbook for mountainash-treespec -- bidirectional hierarchical data transformation.
Transitional publishing: This manual remains on the central site until its per-repository cutover.
Chapters¶
- Foundation Concepts
- Spec Model
- Flatten Engine
- Type System
- Schema Handling
- Build Engine
- Format Handlers
- Batch Processing
- Hooks System
Key Topics¶
- Spec model -- TreeSpec, NodeSpec, ChildSpec, and MetaConfig for declaratively specifying tree-to-table decomposition rules
- Flatten and build engines -- TreeFlattener walks dataclass trees into flat relational tables; TreeBuilder reconstructs trees from flat tables using FK pre-indexing
- Format handlers -- pluggable schema handlers for JSON/Dataclass, XML/xsdata, Protobuf, Pydantic, and Avro with registry-based dispatch
- Batch processing -- BatchFlattener and BatchBuilder for multi-file operations with source columns, concat, dedup, and cascade dedup
- Hooks system -- HookRegistry with condition, field_transform, pre_flatten, and post_build decorator-based hooks for custom transformation logic