24 lines
1.2 KiB
Go
24 lines
1.2 KiB
Go
package builtin
|
|
|
|
import "gitea.maximumdirect.net/eric/seriatim/internal/pipeline"
|
|
|
|
// NewRegistry registers the MVP built-in modules.
|
|
func NewRegistry() *pipeline.Registry {
|
|
registry := pipeline.NewRegistry()
|
|
|
|
registry.RegisterInputReader(jsonFilesReader{})
|
|
registry.RegisterPreprocessor(noopPreprocessor{name: "validate-raw", requires: pipeline.StateRaw, produces: pipeline.StateRaw})
|
|
registry.RegisterPreprocessor(normalizeSpeakers{})
|
|
registry.RegisterPreprocessor(noopPreprocessor{name: "trim-text", requires: pipeline.StateCanonical, produces: pipeline.StateCanonical})
|
|
registry.RegisterPreprocessor(noopPreprocessor{name: "autocorrect", requires: pipeline.StateCanonical, produces: pipeline.StateCanonical})
|
|
registry.RegisterMerger(placeholderMerger{})
|
|
registry.RegisterPostprocessor(noopPostprocessor{name: "detect-overlaps"})
|
|
registry.RegisterPostprocessor(noopPostprocessor{name: "resolve-overlaps"})
|
|
registry.RegisterPostprocessor(assignIDs{})
|
|
registry.RegisterPostprocessor(noopPostprocessor{name: "validate-output"})
|
|
registry.RegisterPostprocessor(noopPostprocessor{name: "autocorrect"})
|
|
registry.RegisterOutputWriter(jsonOutputWriter{})
|
|
|
|
return registry
|
|
}
|