Skip to content

Configuration Parameters of a Qanary Pipeline

AnBo edited this page Jan 28, 2018 · 2 revisions

Basic Qanary Parameters

While using the Qanary reference implementation of a Question Answering pipeline the following parameters are used for basic configuration.

Server Configuration: server.port and server.host

Define port and hostname that will be used, e.g.

server.port=8080
server.host=http://localhost

Triplestore Configuration: qanary.triplestore

Define how to access the triplestore where the knowledge available about the question is stored. For example, use the Stardog triplestore with standard configuration should result in this configuration:

qanary.triplestore=http://admin:admin@localhost:5820/qanary/query

Default Question Answering pipeline configuration: qanary.components

Providing the users a standard Question Answering pipeline can be configured using this property. For example, define the components identified by the name FirstComponent and SecondComponent in this precise order will require the following configuration:

qanary.components=FirstComponent,SecondComponent

Note: For identifying the correct names of a component, see "How can I identify the available components in a Qanary system?" in the Q&A section.

Logging Configurations

Logging events of Spring packages

The Spring framework was used for implementing the Qanary reference implementation. Hence, the standard mechanism for logging configuration can be used. For example, the following statements might be used to define different log levels for the used packages:

logging.level.*=INFO
logging.file=/var/log/application.log
logging.level.org.springframework.core=WARN
logging.level.org.springframework.web=DEBUG
logging.level.org.springframework.beans=INFO
logging.level.org.springframework.boot=WARN
logging.level.org.apache.catalina.core=WARN
logging.level.org.springframework.jmx=WARN
logging.level.org.springframework.mock=WARN
logging.level.org.springframework.test=WARN

Adjusting the log level of the Qanary components

The logging of Qanary components events can be adjusted using the following property:

logging.level.eu.wdaqua.qanary=INFO

Note

The configuration of properties within a Java application built using Spring Boot can be done in many different ways. Three options are described here briefly:

  • Store your configuration in the default configuration file: application.properties
  • (Recommended) Store your configuration in your own configuration file, e.g., application-local.properties.
  • provide the parameters via command line while starting the JAR (c.f., (Spring Boot configuration)[https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html#boot-features-external-config]), e.g., setting the parameter server.port to 9999:
java -jar target/qa.pipeline-1.0.1.jar -Dspring.application.json='{"server.port":"9999"}'

For details see the Spring Boot configuration on Externalized Configuration.

Clone this wiki locally