Skip to content

Commit

Permalink
add MLInferenceSearchResponseProcessor
Browse files Browse the repository at this point in the history
Signed-off-by: Mingshi Liu <[email protected]>
  • Loading branch information
mingshl committed Jul 20, 2024
1 parent 6ff84c1 commit bf4eda2
Show file tree
Hide file tree
Showing 6 changed files with 1,237 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@
import org.opensearch.ml.model.MLModelCacheHelper;
import org.opensearch.ml.model.MLModelManager;
import org.opensearch.ml.processor.MLInferenceIngestProcessor;
import org.opensearch.ml.processor.MLInferenceSearchResponseProcessor;
import org.opensearch.ml.repackage.com.google.common.collect.ImmutableList;
import org.opensearch.ml.rest.RestMLCreateConnectorAction;
import org.opensearch.ml.rest.RestMLCreateControllerAction;
Expand Down Expand Up @@ -990,6 +991,12 @@ public Map<String, Processor.Factory<SearchResponseProcessor>> getResponseProces
new GenerativeQAResponseProcessor.Factory(this.client, () -> this.ragSearchPipelineEnabled)
);

responseProcessors
.put(
MLInferenceSearchResponseProcessor.TYPE,
new MLInferenceSearchResponseProcessor.Factory(parameters.client, parameters.namedXContentRegistry)
);

return responseProcessors;
}

Expand Down
Loading

0 comments on commit bf4eda2

Please sign in to comment.