Documentation
AI settings
Review and edit settings used by IntQuest's language and analysis services.
Overview
The AI page holds the training configuration for IntQuest’s evidence chain: topic detection, entity recognition, coreference and relation extraction. Each AI service reads its section when a training run starts (from Administration → Models). Saving here doesn’t change models that are already trained, and it doesn’t change service addresses: those are set in the deployment.
Open the page
You need the Modify Settings permission. Click Administration in the navigation bar, then click the AI card. If you are already in Administration, click AI in the section bar.
Page layout
1Read when a model trains - explains that each service loads its stage when a training run starts.2Models and Parameter guide - open the Models page and the parameter guide.3Stage count - the number of stages and values, for example4 stages · 427 values.4Stage cards - the four stages in pipeline order, with their service, contents, and state. Click a card to open the stage.5Selected stage - the name and description of the stage being edited.6Form / Raw JSON - switches between the field form and the code editor.7Search - finds fields by label, key, description or value.8Changed only - shows only the fields that differ from the saved or default values.9Language columns - one column per language for configurations kept per language.Read when a model trains. A band at the top explains that each service loads its stage when a training run starts. It links to Models and to the Parameter guide. A chip counts the stages and values, for example
4 stages · 427 values.The chain. Four stage cards in pipeline order: Topic detection → Entity recognition → Coreference → Relation extraction. Each card shows the service that reads it, how much it contains (for example “7 pattern rules · 5 languages · 360 values”) and its state: Seeded defaults, N values changed from default, N unsaved changes, Missing, Invalid JSON, Loading…, or Unavailable. Click a card, or use the arrow keys, to open that stage.
The workbench. The selected stage opens below the chain:
- Search finds fields by label, key path, description or value.
- Language switches between Romanian, English, French, Russian and Hungarian for configurations kept per language.
- Changed only shows the fields that differ from the saved or default values.
- Sections (left, or the Section menu on small screens) narrows the list to one part of the configuration, such as spaCy model › Components › Embedding.
Form / Raw JSON. Form edits one field at a time. Raw JSON shows the whole configuration in a code editor with line numbers and real-time validation. Edits apply to the form as soon as the JSON is valid.
1Form / Raw JSON - here set to Raw JSON.2Editing note - edits apply to the form as soon as the JSON is valid; keep every existing key.3Code editor - the whole stage configuration with line numbers and real-time validation.
Edit a setting
Every field shows a plain label, what it controls, its key path and its seeded default. The control matches the value: number fields (with units where relevant), on/off switches, option lists, and text for paths and identifiers.
- Validation: numbers are checked as you type. Values outside the allowed range block saving; values outside the usual range show a warning but can still be saved.
- Linked values: spaCy values such as
${components.tok2vec.model.encode.width}appear as Linked to … with the value they resolve to. Click Override to set your own value, and the link icon (Link back) to restore the link. - Not set: values that are deliberately empty show Not set. Use Set a value to fill one in, or the clear icon (Clear (not set)) to empty it again.
- Languages: per-language fields say whether they are the same in every language or differ. The Use this value in every language icon copies the value across.
- Pattern rules: each entity pattern (email, phone, CNP, number plate, IBAN, URL, IPv4) is a list of regular expressions. You can add (Add button), remove (with Undo) and test patterns on sample text; the tester reports No matches, 1 match, or N matches.
- Undo / Reset: icon buttons on each field undo its unsaved edit (Undo edit) or go back to the seeded default (Reset to default). Point at an icon to see its name.
Changes are collected per stage. The bar at the bottom counts them; Review and save (or Ctrl+S) opens Review changes to the stage, which lists every change as old → new. Click Save with the stage name to save, or Keep editing to go back. Discard throws the stage’s edits away after a confirmation. Leaving the page with unsaved edits asks first.
The server also checks every save: existing keys can’t be removed, a value can’t change type (for example from a number to text), and numbers must stay within their allowed range.
Coreference resolution settings
| Argument | What it controls | Increasing it does | Decreasing it does |
|---|---|---|---|
max_mentions | Maximum number of mention candidates kept for each input document. | Keeps more possible mentions, which may improve recall but increases memory usage, computation time and the chance of keeping noisy mentions. | Keeps fewer mentions, which makes inference faster and lighter but may miss valid mentions. |
start_threshold | Minimum confidence required for a token to be considered the start of a mention. | Makes mention detection stricter. This may reduce false positives but can miss valid mentions. | Makes mention detection more permissive. This may find more mentions but can introduce more false positives. |
end_threshold | Minimum confidence required for a token to be considered the end of a mention. | Makes mention span detection stricter. The model may produce fewer but cleaner mention spans. | Allows more possible mention endings, which may improve recall but can create incorrect or overly broad spans. |
mention_dropout | Dropout applied to the mention detection component during training. | Adds stronger regularization. This can reduce overfitting but may make training harder or reduce accuracy if too high. | Reduces regularization. This may improve training fit but can increase overfitting. |
coref_dropout | Dropout applied to the coreference clustering component during training. | Makes the coreference model more regularized, potentially improving generalization but risking underfitting if too high. | Makes the model rely more directly on learned patterns, which may improve training performance but can overfit. |
coref_loss_weight | Importance of the coreference loss compared with other training losses. | Makes the model focus more on correctly linking mentions into clusters. Too high may hurt mention detection or other objectives. | Reduces the influence of cluster-linking errors. Too low may make the model detect mentions but group them poorly. |
top_k_antecedents | Number of previous mentions considered as possible antecedents for each mention. | Allows the model to consider more possible links, which may improve long-range coreference but increases computation cost. | Speeds up training/inference but may miss correct antecedents that are farther back in the text. |
optimizer | Algorithm used to update model weights during training. | Not a numeric value. Choosing a different optimizer changes training behavior. For example, adafactor is memory-efficient, while adamw is often stable but uses more memory. | Not applicable as an increase/decrease. The effect depends on the optimizer selected. |
learning_rate | Main learning rate for task-specific or newly added model layers. | Makes updates larger, which can speed up learning but may cause instability or worse convergence if too high. | Makes updates smaller, which is safer and more stable but may train slowly or underfit. |
encoder_learning_rate | Learning rate for the pretrained encoder/backbone. | Fine-tunes the encoder more aggressively. This may adapt faster but risks damaging pretrained knowledge. | Preserves the pretrained encoder more strongly but may adapt too slowly to the task. |
weight_decay | Regularization that discourages large model weights. | Adds more regularization, which can reduce overfitting but may cause underfitting if too strong. | Reduces regularization, which can help fit the training data but may increase overfitting. |
warmup_steps | Number of steps used to gradually increase the learning rate at the start of training. | Makes the start of training more gradual and stable, but delays reaching the full learning rate. | Reaches the target learning rate sooner, which can train faster but may make early training unstable. |
batch_size | Number of examples processed at once. | Gives more stable gradient estimates and can improve hardware efficiency, but requires more memory. | Uses less memory and may add useful noise to training, but gradients become less stable. |
max_epochs | Maximum number of full passes over the training dataset. | Gives the model more opportunities to learn, but increases training time and overfitting risk. | Reduces training time and overfitting risk, but may stop before the model has learned enough. |
max_seq_len | Maximum number of tokens allowed in one input sequence. | Allows longer documents and longer-distance coreference links, but increases memory and compute cost significantly. | Reduces memory and compute usage, but may truncate context and miss long-range coreference. |
accumulate_grad_batches | Number of batches accumulated before applying one optimizer update. | Simulates a larger effective batch size without requiring as much GPU memory. Updates happen less frequently but are based on more examples. | Produces more frequent updates with a smaller effective batch size. This can train faster per update but may be noisier. |
gradient_clip_val | Maximum allowed gradient norm before clipping is applied. | Allows larger gradient updates, which may help learning but can increase instability if too high. | Clips gradients more aggressively, improving stability but potentially slowing learning if too low. |
val_check_interval | How often validation runs, measured in training steps. | Runs validation less often, reducing overhead but detecting problems or improvements later. | Runs validation more often, giving closer monitoring but increasing training overhead. |
log_every_n_steps | How often training metrics are logged. | Logs less frequently, reducing noise and logging overhead. | Logs more frequently, giving more detailed visibility but producing noisier logs. |
early_stopping_patience | Number of validation checks allowed without meaningful improvement before stopping. | Gives training more time to improve, but may waste time after progress has stopped. | Stops sooner when validation does not improve, saving time but possibly ending training too early. |
early_stopping_min_delta | Minimum validation improvement required to count as meaningful progress. | Requires larger improvements to reset early stopping, making stopping more aggressive. | Allows smaller improvements to count, making early stopping more patient. |
seed | Random seed used for reproducibility. | Not meaningfully increasing in the tuning sense. Changing it changes random initialization, dropout and data shuffling. | Not meaningfully decreasing in the tuning sense. Different seeds can produce slightly different results. |
Topic detection settings
The seeded configuration contains only use_extra_datasets for each language. The other parameters are labeled in the form when they are present in the configuration.
| Parameter | Default | Languages | Description |
|---|---|---|---|
| use_extra_datasets | true | all | When on, training also uses two extra collections besides the documents you uploaded: Wikipedia and European legislation. They help the model learn when few relevant documents (fewer than about 5,000) have been uploaded. |
| filter_dataset | true | all | When on, the extra datasets are filtered so only documents that contain your labels remain. Training gets much faster. |
| use_hardcoded_topics | true | ro | When on, training uses the default topic list supplied during development. |
| use_romanian_labels | true | en, fr, ru, hu | When on, the Romanian documents are also used to train this language’s multilingual model. Useful when there is more Romanian data and it adds context. |
| use_romanian_data | true | en, fr, ru, hu | When on, the multilingual model trains with the topics defined for Romanian, so every language keeps one shared topic list. |
Entity recognition settings
| Parameter | Default Value | Languages | Description |
|---|---|---|---|
regex_model.rules.EMAIL | regex | all | Regular expression used to identify and extract email addresses from text. Supports standard email formats such as [email protected]. |
regex_model.rules.PHONE | regex | ro | Regular expression for detecting Romanian phone numbers, including mobile and landline formats, with optional country prefix (+40 or 0040). |
regex_model.rules.CNP | regex | ro | Regular expression used to detect Romanian Personal Numeric Codes (CNP). The pattern validates the structure and date-related components of the identifier. |
regex_model.rules.CAR_PLATE_RO | regex | ro | Detects Romanian vehicle registration numbers, including Bucharest and county-specific formats. |
regex_model.rules.IBAN | regex | ro | Detects Romanian IBAN bank account numbers, including formats with or without whitespace separators. |
regex_model.rules.URL | regex | all | Regular expression used to identify HTTP and HTTPS URLs within text. |
regex_model.rules.IPV4 | regex | all | Detects IPv4 addresses using validation for valid numeric ranges (0-255). |
spacy_model.<lang>.paths.train | null | all | Path to the training dataset in spaCy .spacy format. This dataset is used during model training to learn entity patterns and contextual representations. |
spacy_model.<lang>.paths.dev | null | all | Path to the development/validation dataset used for periodic evaluation during training. Helps monitor model generalization and detect overfitting. |
spacy_model.<lang>.paths.vectors | language-specific large vectors | ro,en,fr,ru | Pretrained word vector model used to initialize semantic word representations. These vectors improve contextual understanding and accelerate convergence during training. |
spacy_model.<lang>.paths.init_tok2vec | null | ro,fr | Optional pretrained Tok2Vec weights used to initialize the tok2vec component through transfer learning. Useful when fine-tuning existing models. |
spacy_model.<lang>.system.seed | 0 | ro | Random seed used for deterministic initialization and reproducible training results across multiple executions. |
spacy_model.<lang>.system.gpu_allocator | null | all | Controls GPU memory allocation strategy. Can be configured for frameworks such as PyTorch to optimize GPU memory usage. |
spacy_model.<lang>.nlp.lang | language code | all | ISO language code used by spaCy to determine language-specific rules, tokenization behavior, stopwords, and linguistic processing pipelines. |
spacy_model.<lang>.nlp.pipeline | ["tok2vec","ner"] | all | Defines the ordered NLP processing pipeline. tok2vec generates contextual token embeddings, while ner performs named entity recognition. |
spacy_model.<lang>.nlp.batch_size | 1000 | all | Number of tokens processed simultaneously during inference. Larger values improve throughput but increase memory consumption. |
spacy_model.<lang>.nlp.disabled | [""] | ro | List of pipeline components disabled during execution. Useful for debugging, benchmarking, or reducing inference latency. |
spacy_model.<lang>.nlp.tokenizer | spacy.Tokenizer.v1 | ro | Tokenizer implementation responsible for splitting raw text into tokens such as words, punctuation marks, and symbols. |
spacy_model.<lang>.nlp.vectors | spacy.Vectors.v1 | ro | Component responsible for loading, storing, and managing static word vectors used throughout the NLP pipeline. |
components.tok2vec.factory | tok2vec | all | Factory name used by spaCy to instantiate the Tok2Vec component. |
components.tok2vec.model.@architectures | spacy.Tok2Vec.v2 | all | Defines the high-level neural architecture used to generate contextual token representations. |
components.tok2vec.model.embed.@architectures | spacy.MultiHashEmbed.v2 | all | Embedding architecture that combines multiple hashed token features into dense vector representations. |
components.tok2vec.model.embed.width | 256 | all | Dimensionality of token embeddings generated before contextual encoding. Larger dimensions increase representational capacity but also computational cost. |
components.tok2vec.model.embed.attrs | NORM,PREFIX,SUFFIX,SHAPE | all | Token attributes used to generate embeddings. Includes normalized form, prefixes, suffixes, and orthographic shape information. |
components.tok2vec.model.embed.rows | [5000,1000,2500,2500] | all | Hash table sizes allocated for each embedding attribute. Higher values reduce hash collisions at the cost of memory usage. |
components.tok2vec.model.embed.include_static_vectors | true | all | Enables integration of pretrained static word vectors into token embeddings, improving semantic understanding. |
components.tok2vec.model.encode.@architectures | spacy.MaxoutWindowEncoder.v2 | all | Encoder architecture responsible for contextualizing token embeddings using neighboring tokens. |
components.tok2vec.model.encode.width | 256 | all | Dimensionality of contextualized token vectors passed downstream to components such as NER. |
components.tok2vec.model.encode.depth | 8 | all | Number of encoder layers used for contextual feature extraction. Deeper architectures can learn more complex linguistic patterns. |
components.tok2vec.model.encode.window_size | 1 | all | Number of neighboring tokens considered on each side when building contextual representations. |
components.tok2vec.model.encode.maxout_pieces | 3 | all | Number of maxout pieces used in the encoder activation function. Higher values increase model expressiveness. |
components.ner.factory | ner | all | Factory used to create the Named Entity Recognition component. |
components.ner.model.@architectures | spacy.TransitionBasedParser.v2 | all | Neural transition-based architecture used for entity span prediction and classification. |
components.ner.model.state_type | ner | all | Specifies the internal parser state type optimized for named entity recognition tasks. |
components.ner.model.hidden_width | 64 | all | Size of the hidden neural layer inside the NER model. Influences the model’s capacity to learn complex entity patterns. |
components.ner.model.maxout_pieces | 2 | all | Number of maxout activation pieces used within the NER architecture. |
components.ner.model.use_upper | true | all | Enables capitalization-aware features, improving recognition of proper nouns and named entities. |
components.ner.model.nO | null | all | Number of output entity labels. Automatically inferred from the annotated training dataset. |
corpora.train.path | ${paths.train} | all | Internal reference to the training dataset location defined in the paths section. |
corpora.dev.path | ${paths.dev} | all | Internal reference to the validation dataset location defined in the paths section. |
corpora.train.max_length | 0 | all | Maximum document length allowed during training. A value of 0 disables length restrictions. |
corpora.dev.max_length | 0 | all | Maximum document length allowed during validation. |
training.dev_corpus | corpora.dev | all | Validation corpus used during evaluation steps. |
training.train_corpus | corpora.train | all | Training corpus used for parameter optimization. |
training.max_epochs | 10 | all | Total number of complete passes through the training dataset during training. |
training.max_steps | 20000 | ro,fr | Maximum number of optimization steps. Can override epoch-based stopping. |
training.dropout | 0.1 | ro,fr | Dropout probability applied during training to reduce overfitting and improve generalization. |
training.patience | 1600 | ro,fr | Number of evaluation steps without improvement before triggering early stopping. |
training.eval_frequency | 200 | ro,fr | Frequency (in training steps) at which the model is evaluated on the validation set. |
training.accumulate_gradient | 1 | ro,fr | Number of batches used for gradient accumulation before performing a parameter update. Useful for limited GPU memory environments. |
training.optimizer.@optimizers | Adam.v1 | all | Optimization algorithm used during training. Adam combines adaptive learning rates with momentum. |
training.optimizer.learn_rate | 0.001 | ro,fr | Learning rate controlling how aggressively model parameters are updated during optimization. |
training.optimizer.beta1 | 0.9 | ro,fr | Exponential decay rate for the first moment estimates in the Adam optimizer. |
training.optimizer.beta2 | 0.999 | ro,fr | Exponential decay rate for the second moment estimates in the Adam optimizer. |
training.optimizer.L2 | 0.01 | ro,fr | L2 regularization coefficient used to penalize excessively large model weights. |
training.optimizer.grad_clip | 1.0 | ro,fr | Gradient clipping threshold used to prevent exploding gradients and improve training stability. |
training.optimizer.eps | 1e-08 | ro,fr | Small numerical stability constant used by the optimizer to avoid division-by-zero errors. |
training.batcher.@batchers | spacy.batch_by_words.v1 | all | Batch generation strategy based on the total number of words rather than document count. |
training.batcher.size.start | 100 | all | Initial batch size used at the beginning of training. |
training.batcher.size.stop | 1000 | all | Maximum batch size reached during dynamic batch growth. |
training.batcher.size.compound | 1.001 | all | Growth factor controlling how batch sizes gradually increase during training. |
training.logger.@loggers | spacy.ConsoleLogger.v1 | ro,fr | Logging implementation used to display training metrics and progress information. |
training.logger.progress_bar | false | ro,fr | Enables or disables terminal progress bars during training execution. |
training.score_weights.ents_f | 1.0 | ro,fr | Weight assigned to entity-level F1 score during overall evaluation scoring. |
training.score_weights.ents_p | 0.0 | ro,fr | Weight assigned to entity-level precision during evaluation scoring. |
training.score_weights.ents_r | 0.0 | ro,fr | Weight assigned to entity-level recall during evaluation scoring. |
initialize.vectors | ${paths.vectors} | all | Loads pretrained word vectors before model initialization. |
initialize.init_tok2vec | ${paths.init_tok2vec} | ro,fr | Initializes the Tok2Vec component from pretrained weights before training begins. |
initialize.vocab_data | null | ro,fr | Optional vocabulary initialization data used to preload lexical entries. |
initialize.lookups | null | ro,fr | Optional lookup tables used for language-specific normalization and lexical processing. |
Relation extraction settings
| Argument | Recommended value | Meaning | When to change it |
|---|---|---|---|
evaluation_strategy | "no" | The model is not evaluated on validation data during training. | Change it to "epoch" if you want to monitor validation performance while training. |
learning_rate | 0.00002 | The model uses this learning step when updating its parameters. | Lower it if training is unstable; increase it only if learning is too slow and stable. |
per_device_train_batch_size | 8 | The model processes 8 examples at once. | Increase it if you have enough memory and want faster training; decrease it if you run out of memory. |
num_train_epochs | 3 | The model goes through the full training dataset 3 times. | Increase it if the model has not learned enough; decrease it if it overfits or training takes too long. |
save_strategy | "epoch" | A model checkpoint is saved at the end of each training epoch. Another option is “steps”, which saves a checkpoint every 500 training steps. | Use “steps” if you want more frequent checkpoints during long or unstable training; use less frequent saving to reduce disk usage. |
max_length | 256 | Each text input is limited to 256 tokens. Longer texts are shortened if truncation is enabled. | Increase it for longer texts; decrease it to reduce memory use and speed up training. |
truncation | true | Long texts are automatically shortened to fit the maximum length. | Disable it only if all inputs already fit or if you want to handle long texts manually. |
padding | "max_length" | Shorter texts are padded until they reach the maximum length. | Use dynamic padding for more efficient batching; use fixed padding when you need consistent input sizes. |
Notes
- These settings affect every model trained afterwards. Review changes before saving, especially learning rates and lengths.
- The relation extraction learning rate is seeded at
0.1, which the page flags as unusually high for fine-tuning; the recommended value is0.00002. - Saving updates the page in place; there is no page reload.