Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

{
    "component": "logger",
    "description": "logger processor",
    <configuration>
}
Configuration parameters:

...

{
    "component": "post",
    "description": "post processor",
    <configuration>
}
Configuration parameters:

...

(Optional, List<String>) Parameters that will be passed though to the URL.

merge

(Optional, Boolean) If true, responses are merged before sending back to the caller. Defaults to true.

credentials

(Optional, Basic Credentials) JSON containing username and password for basic authentication on a Elasticsearch instance.passed though to the URL.

merge

(Optional, Boolean) If true, responses are merged before sending back to the caller. Defaults to true.

credentials

(Optional, Basic Credentials) JSON containing username and password for basic authentication on a Elasticsearch instance.

Elastic

Post requests to a given Elasticsearch instance using the official Java API (High level REST client).

Configuration:
{
    "component": "elastic",
    "description": "Elasticsearch processor",
    <configuration>
}
Configuration parameters:

method

(HTTP Method) HTTP method to use when calling Elasticsearch. If not set, it'll default to the incoming method.

endpoint

(String) The endpoint to call Elasticsearch on.

contentType

(Optional, String) The content type to use for the request to ElasticSearch. For instance, on _msearch requests this is application/x-ndjson. Defaults to application/json

connection

(Json) The Elasticsearch connection properties (credentials, scroll, bulk etc).

{
     "servers": List<ConnectionInfo>,
     "auth": AuthenticationCredentials,
     "scroll": {
         "size": Integer,
         "timeout": Duration
     }
}

      servers (ConnectionInfo array) The search engine servers

      auth (AuthenticationCredentials) The search engine authentication

      scroll (Scroll) The configuration for scrolls when querying

Opensearch

Post requests to a given Opensearch instance.

Configuration:
{
    "component": "opensearch",
    "description": "opensearch processor",
    <configuration>
}
Configuration parameters:

method

(HTTP Method) HTTP method to use when calling Opensearch. If not set, it'll default to the incoming method.

endpoint

(String) The endpoint to call Opensearch on.

contentType

(Optional, String) The content type to use for the request to Opensearch. For instance, on _msearch requests this is application/x-ndjson. Defaults to application/json

connection

(Json) The Opensearch connection properties (credentials, scroll, bulk etc).

{
     "servers": List<ConnectionInfo>,
     "auth": AuthenticationCredentials,
     "scroll": {
         "size": Integer,
         "timeout": Duration
     }
}

      servers (ConnectionInfo array) The search engine servers

      auth (AuthenticationCredentials) The search engine authentication

      scroll (Scroll) The configuration for scrolls when querying

Script

Run scripts as part of the search query sent to the Discovery API.

Configuration:
{
    "component": "script",
    "description": "script processor",
    <configuration>
}
Configuration parameters:

language

(String) Language used to write the script. Available languages are groovy, python and javascript. Defaults to groovy.

...

Snaps to facets and their values from the query in the request, by examining the query for values from those facets. Where a match is found, the facet and value will be applied as a filter to the query and the value optionally removed from the main query text.

Configuration:
{
    "component": "snap",
    "description": "snap processor",
    <configuration>
}
Configuration parameters:

queryParameter

(Optional, String) The name of the query parameter that holds the query to snapped to. One of queryParameter or queryBody should be specified.

...

Detects if a query is a question. If not, terminates the execution of the endpoint.

Configuration:
{
    "component": "questionDetector",
    "description": "question detector",
    <configuration>
}
Configuration parameters:

queryParameter

(Optional, String) The name of the query parameter that holds the query. Defaults to q.

...

The template component allows for the loading of Json objects into the request body, optionally based on the values of query parameters. This allows for loading of (say) a complex structure used for querying, filtering or sorting that can then have minor modifications made to it by a scripting component.

Configuration:
{
    "component": "template",
    "description": "template processor",
    <configuration>
}
Configuration parameters:

templates

(Optional, Json) Used in conjunction with the parameter option below, this holds a Json object containing a set of named templates. The top level field name is the template name. Its (object) value is the template. When selected the (object) value will replace or be merged into the request body.

...

This component detects the language from the input query. It expects a list of possible language to detect. The output language is added as part as a header.

Configuration:
{
   "component": "languageDetector",
   "description": "Language detector description",
    <configuration>
}
Configuration parameters:

languagesDetector

(Optional, Json) Languages to detect. The detection process will narrow down to only detect these languages. Full language names are expected in lower case, for example: ['spanish', 'english'] The default value is an empty list.

...

If a language has been previously detected (i.e. a custom response header exists), then the questions prefixes associated to that language will be used. If not, a default language will be selected.

Configuration:
{
  "component": "questionDetector",
  "description": "Question detector description",
  <configuration>
}
Configuration parameters:

questionPrefixes

(Optional, Json) Map of lists that contains the words that help to detect questions. For example:

...

This component takes a query as input and send it to the spacy NLP service for analysis. Both entities and dependency responses from Spacy are added to the API request so they can be used by a downstream component.

Configuration:
{
  "component" : "NLPClient",
  "description" : "Performs NLP analysis using Spacy service.",
  <configuration>
}
Configuration parameters:

model

(Optional, String) Name of the spacy model to use. Can be overridden with the discovery-api-nlp-model response header.

...

This component detects in an array of cypher queries the entity to be changed.

Configuration:
{
  "component": "replaceEntities",
  "description": "Replace Entity description",
 
  <configuration>
}
Configuration parameters:

numberOfQueriesToUse

(Optional, Integer) Number of queries which are going to be used in this component. Defaults to 1.

...

{
  "entity": "x",
  "attribute": "y",
  "value": ["a","b","c","d","f"]
}
Configuration:
{
  "component": "neo4j",
  "description": "neo4j description",
    <configuration>
}
Configuration parameters:

emptyResponseMap (Optional, Json) This text will be used in cases where an empty value comes from neo4j. Defaults to:

...

This component detects in an array of cypher queries the entity to be changed.

Configuration:
{
  "component": "replaceEntities",
  "description": "Replace Entity description",
 
  <configuration>
}
Configuration parameters:

merge

(Optional, boolean) Replace or merge the query into the body. Defaults to false.

...

This component calls the DistilBERT service with a question and a list of text chunks.

Configuration:
{
    "component": "featuredSnippet",
    "description": "Replace featured snippets description",
    <configuration>
}
Configuration parameters:

queryParameter

(Optional, String) The (query) parameter. Defaults to 'q'.

...