Documentation
¶
Index ¶
- func CreatePipeline(dsl Pipeline) (groove.Pipeline, error)
- func Execute(dsl Pipeline, pipelineChannel chan pipeline.Result) error
- func NewElasticsearchStatisticsSource(config map[string]interface{}) (*stats.ElasticsearchStatisticsSource, error)
- func NewEntrezStatisticsSource(config map[string]interface{}, ...) (stats.EntrezStatisticsSource, error)
- func NewKeywordQuerySource(options map[string]interface{}) query.QueriesSource
- func NewOracleQueryChainCandidateSelector(source string, qrels string) learning.OracleQueryChainCandidateSelector
- func NewTransmuteQuerySource(p pipeline.TransmutePipeline, options map[string]interface{}) query.QueriesSource
- func RegisterCui2VecTransformation(dsl Pipeline) error
- func RegisterEvaluationFormatter(name string, formatter output.EvaluationFormatter)
- func RegisterEvaluator(name string, evaluator eval.Evaluator)
- func RegisterMeasurement(name string, measurement analysis.Measurement)
- func RegisterMeasurementFormatter(name string, formatter output.MeasurementFormatter)
- func RegisterMerger(name string, merger merging.Merger)
- func RegisterModel(name string, model learning.Model)
- func RegisterPreprocessor(name string, preprocess preprocess.QueryProcessor)
- func RegisterQuerySource(name string, source query.QueriesSource)
- func RegisterRewriteTransformation(name string, transformation learning.Transformation)
- func RegisterScorer(name string, scorer rank.Scorer)
- func RegisterSources(dsl Pipeline) error
- func RegisterStatisticSource(name string, source stats.StatisticsSource)
- func RegisterTransformationBoolean(name string, transformation preprocess.BooleanTransformation)
- func RegisterTransformationElasticsearch(name string, transformation preprocess.ElasticsearchTransformation)
- type EvaluationOutput
- type EvaluationOutputFormat
- type MeasurementOutput
- type Pipeline
- type PipelineCache
- type PipelineFormulation
- type PipelineHeadway
- type PipelineLearning
- type PipelineOutput
- type PipelineQuery
- type PipelineStatistic
- type PipelineTransformation
- type PipelineUtilities
- type TrecOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreatePipeline ¶
CreatePipeline creates the main groove pipeline.
func NewElasticsearchStatisticsSource ¶
func NewElasticsearchStatisticsSource(config map[string]interface{}) (*stats.ElasticsearchStatisticsSource, error)
NewElasticsearchStatisticsSource attempts to create an Elasticsearch statistics source from a configuration mapping. It also tries to set some defaults for fields in case some are not specified, but they will not be sensible.
func NewEntrezStatisticsSource ¶
func NewEntrezStatisticsSource(config map[string]interface{}, options ...func(source *stats.EntrezStatisticsSource)) (stats.EntrezStatisticsSource, error)
func NewKeywordQuerySource ¶
func NewKeywordQuerySource(options map[string]interface{}) query.QueriesSource
NewKeywordQuerySource creates a "keyword query" query source.
func NewOracleQueryChainCandidateSelector ¶
func NewOracleQueryChainCandidateSelector(source string, qrels string) learning.OracleQueryChainCandidateSelector
NewOracleQueryChainCandidateSelector creates a new oracle query chain candidate selector.
func NewTransmuteQuerySource ¶
func NewTransmuteQuerySource(p pipeline.TransmutePipeline, options map[string]interface{}) query.QueriesSource
NewTransmuteQuerySource creates a new transmute query source for PubMed/Medline queries.
func RegisterEvaluationFormatter ¶
func RegisterEvaluationFormatter(name string, formatter output.EvaluationFormatter)
RegisterEvaluationFormatter registers an output formatter.
func RegisterEvaluator ¶
RegisterEvaluator registers a measurement.
func RegisterMeasurement ¶
func RegisterMeasurement(name string, measurement analysis.Measurement)
RegisterMeasurement registers a measurement.
func RegisterMeasurementFormatter ¶
func RegisterMeasurementFormatter(name string, formatter output.MeasurementFormatter)
RegisterMeasurementFormatter registers an output formatter.
func RegisterMerger ¶
func RegisterModel ¶
RegisterQueryChainCandidateSelector registers a query chain candidate selector.
func RegisterPreprocessor ¶
func RegisterPreprocessor(name string, preprocess preprocess.QueryProcessor)
RegisterPreprocessor registers a preprocessor.
func RegisterQuerySource ¶
func RegisterQuerySource(name string, source query.QueriesSource)
RegisterQuerySource registers a query source.
func RegisterRewriteTransformation ¶
func RegisterRewriteTransformation(name string, transformation learning.Transformation)
RegisterRewriteTransformation registers a rewrite transformation.
func RegisterScorer ¶
func RegisterSources ¶
RegisterSources initiates boogie with all the possible options in a pipeline.
func RegisterStatisticSource ¶
func RegisterStatisticSource(name string, source stats.StatisticsSource)
RegisterStatisticSource registers a statistic source.
func RegisterTransformationBoolean ¶
func RegisterTransformationBoolean(name string, transformation preprocess.BooleanTransformation)
RegisterTransformationBoolean registers a Boolean query transformation.
func RegisterTransformationElasticsearch ¶
func RegisterTransformationElasticsearch(name string, transformation preprocess.ElasticsearchTransformation)
RegisterTransformationElasticsearch registers an Elasticsearch transformation.
Types ¶
type EvaluationOutput ¶
type EvaluationOutput struct {
Qrels string `json:"qrels"`
RelevanceGrade int64 `json:"grade"`
Measurements []EvaluationOutputFormat `json:"formats"`
}
EvaluationOutput represents an output format for measurements.
type EvaluationOutputFormat ¶
type EvaluationOutputFormat struct {
Format string `json:"format"`
Filename string `json:"filename"`
}
EvaluationOutputFormat represents how evaluations should be output.
type MeasurementOutput ¶
MeasurementOutput represents an output format for measurements.
type Pipeline ¶
type Pipeline struct {
Query PipelineQuery `json:"query"`
Statistic PipelineStatistic `json:"statistic"`
Utilities PipelineUtilities `json:"utilities"`
Preprocess []string `json:"preprocess"`
PreprocessOptions map[string]string `json:"preprocess_options"`
Measurements []string `json:"measurements"`
Evaluations []string `json:"evaluation"`
Transformations PipelineTransformation `json:"transformations"`
Formulation PipelineFormulation `json:"formulation"`
Learning PipelineLearning `json:"learning"`
Rewrite []string `json:"rewrite"`
Output PipelineOutput `json:"output"`
Cache []PipelineCache `json:"cache"`
Scorer string `json:"scorer"`
CLFOptions rank.CLFOptions `json:"clf"`
Headway PipelineHeadway `json:"headway"`
}
Pipeline is a representation of the DSL.
type PipelineCache ¶
type PipelineCache struct {
Type string `json:"type"`
Options map[string]interface{} `json:"options"`
}
PipelineCache configures caching.
type PipelineFormulation ¶
type PipelineFormulation struct {
Method string `json:"method"`
Options map[string]string `json:"options"`
PostProcessing []string `json:"post_processing"`
}
PipelineFormulation represents how queries can be formulated.
type PipelineHeadway ¶
type PipelineLearning ¶
type PipelineLearning struct {
Model string `json:"model"`
Options map[string]string `json:"options"`
Train map[string]interface{} `json:"train"`
Test map[string]interface{} `json:"test"`
Generate map[string]interface{} `json:"generate"`
}
PipelineLearning represents a configuration of a learning model. The model specified in `model` is configured via `options`.
The train, test, validate, and generate methods can be configured via the options of the same names.
type PipelineOutput ¶
type PipelineOutput struct {
Measurements []MeasurementOutput `json:"measurements"`
Trec TrecOutput `json:"trec_results"`
Evaluations EvaluationOutput `json:"evaluations"`
}
PipelineOutput represents an output formatter in the DSL.
type PipelineQuery ¶
type PipelineQuery struct {
Format string `json:"format"`
Path string `json:"path"`
Options map[string]interface{} `json:"options"`
}
PipelineQuery represents a query source in the DSL.
type PipelineStatistic ¶
type PipelineStatistic struct {
Source string `json:"source"`
Options map[string]interface{} `json:"options"`
Sources []map[string]interface{} `json:"sources"`
}
PipelineStatistic represents a statistic source in the DSL.
type PipelineTransformation ¶
type PipelineTransformation struct {
Output string `json:"output"`
Operations []string `json:"operations"`
}
PipelineTransformation represents an set of transformation operations in the DSL.
type PipelineUtilities ¶
type PipelineUtilities struct {
QuickUMLSCache string `json:"quickumls_cache"`
CUIMapping string `json:"cui_mapping"`
CUI2vec string `json:"cui2vec"`
CUI2vecSkip bool `json:"cui2vec_skip_first"`
}
PipelineUtilities is used to reference external tools or files.
type TrecOutput ¶
type TrecOutput struct {
Output string `json:"output"`
}
TrecOutput represents an output for trec files.