amaGama settings

amaGama has some settings that allow to tune how it behaves. Below you can see a detailed description for each setting and its default values.

amaGama settings are stored in amagama/settings.py.

Global settings

Settings to define amaGama server behavior.

DEBUG

Default: False

Indicates if the debug mode is enabled.

SECRET_KEY

Default: foobar

Indicates the secret key to use for keeping the sessions secure.

ENABLE_WEB_UI

Default: False

Indicates if the web interface is enabled.

ENABLE_DATA_ALTERING_API

Default: False

Indicates if the part of the amaGama API that allows data to be altered is enabled.

This doesn’t affect to the part of the API that is used to perform queries that don’t alter the data. For example retrieving translations is always enabled.

Database settings

Settings used for connecting to the amaGama database.

DB_HOST

Default: "localhost"

Hostname of the server where the amaGama database is located.

DB_NAME

Default: "amagama"

amaGama database name.

DB_PASSWORD

Default: ""

Password for the amaGama database user.

DB_PORT

Default: "5432"

Port number where the database server holding the amaGama database is listening.

DB_USER

Default: "postgres"

User name for connecting to the amaGama database.

Database pool settings

Settings for the database pool.

DB_MAX_CONNECTIONS

Default: 20

Maximum number of connections that the pool database will handle.

DB_MIN_CONNECTIONS

Default: 2

Number of connections to the database server that are created automatically in the database pool.

Levenshtein settings

Settings for Levenshtein algorithm. See Levenshtein distance for more information.

MAX_CANDIDATES

Default: 5

The maximum number of results returned. This can be overridden by providing another value using a query string.

MAX_LENGTH

Default: 1000

Maximum length of the string. If the string length is higher then it won’t be matched neither returned in the results.

MIN_SIMILARITY

Default: 70

The minimum similarity between the string to be searched and the strings to match.

This can be overridden by providing another value using a query string, but there is a hardcoded minimum possible value of 30. If a lower value is provided then 30 will be used.