Block Library
FunctorFlow ships with a library of reusable diagram builders.
Foundational blocks
These are the basic categorical patterns used throughout the package:
ket_blockfor left-Kan aggregationcompletion_blockfor right-Kan completiondb_squarefor commutativity and obstruction lossesgt_neighborhood_blockfor graph-transformer style neighborhood aggregation
Planning and repair
FunctorFlow includes block patterns inspired by categorical planning:
basket_workflow_blockrocket_repair_blockbasket_rocket_pipelinedemocritus_assembly_pipelinetopocoend_blockhorn_fill_blockhigher_horn_blockbisimulation_quotient_block
These builders support symbolic examples directly and can also be compiled to Lux-backed models where appropriate.
CATAGI block guide
The CATAGI-style surfaces now have a clearer documentation path:
| Block family | Symbolic surface | Trainable surface | Best walkthrough |
|---|---|---|---|
| BASKET / ROCKET planning | basket_workflow_block, rocket_repair_block, basket_rocket_pipeline | build_basket_rocket_lux_model | 18-neurosymbolic-pipelines |
| Democritus assembly | democritus_assembly_pipeline | symbolic-only | 18-neurosymbolic-pipelines |
| TopoCoend relation learning | topocoend_block | build_topocoend_lux_model, RelationInferenceLayer | 23-topocoend-triage then 07-lux-neural-backend |
| Horn and higher-horn consistency | horn_fill_block, higher_horn_block | build_horn_lux_model, build_higher_horn_lux_model | 18-neurosymbolic-pipelines then 07-lux-neural-backend |
| Bisimulation quotienting | bisimulation_quotient_block | build_bisimulation_quotient_lux_model | 24-bisimulation-quotient then 07-lux-neural-backend |
A good reading order is: 18-neurosymbolic-pipelines for the symbolic overview, 23-topocoend-triage and 24-bisimulation-quotient for concrete focused examples, then 07-lux-neural-backend for the differentiable versions.
Tutorial libraries
To expose curated subsets of the block registry, use tutorial libraries:
using FunctorFlow
lib = get_tutorial_library(:planning)
diagram = build_tutorial_macro(lib, :basket_rocket_pipeline)Key exported libraries include:
FOUNDATIONS_TUTORIAL_LIBRARYPLANNING_TUTORIAL_LIBRARYUNIFIED_TUTORIAL_LIBRARY
Lux-backed helpers
For neural execution, FunctorFlow provides:
compile_to_luxKETAttentionLayerDiagramDenseLayerDiagramChainLayerRelationInferenceLayerbuild_ket_lux_modelbuild_db_lux_modelbuild_gt_lux_modelbuild_basket_rocket_lux_modelbuild_topocoend_lux_modelbuild_horn_lux_modelbuild_higher_horn_lux_modelbuild_bisimulation_quotient_lux_model
These helper constructors are especially useful for moving from symbolic diagram design to trainable models.