blob: bab5e2d691d043878240afe8af98cc00c456e5db (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/searchlib/fef/blueprint.h>
#include <vespa/vespalib/util/priority_queue.h>
namespace search::features {
//-----------------------------------------------------------------------------
class ElementSimilarityBlueprint : public fef::Blueprint
{
private:
struct OutputContext;
using OutputContext_UP = std::unique_ptr<OutputContext>;
uint32_t _field_id;
std::vector<OutputContext_UP> _outputs;
public:
ElementSimilarityBlueprint();
~ElementSimilarityBlueprint();
void visitDumpFeatures(const fef::IIndexEnvironment &env,
fef::IDumpFeatureVisitor &visitor) const override;
fef::Blueprint::UP createInstance() const override {
return Blueprint::UP(new ElementSimilarityBlueprint());
}
fef::ParameterDescriptions getDescriptions() const override {
return fef::ParameterDescriptions().desc().indexField(fef::ParameterCollection::ANY);
}
bool setup(const fef::IIndexEnvironment &env, const fef::ParameterList ¶ms) override;
fef::FeatureExecutor &createExecutor(const fef::IQueryEnvironment &env, vespalib::Stash &stash) const override;
};
}
|