Skip to content

Warn when detector config doesn't match training data#111

Merged
ipmach merged 1 commit intodevelopmentfrom
feat/warnings
Mar 31, 2026
Merged

Warn when detector config doesn't match training data#111
ipmach merged 1 commit intodevelopmentfrom
feat/warnings

Conversation

@viktorbeck98
Copy link
Copy Markdown
Collaborator

Summary

  • Silent no-op detection when a manually-configured detector references EventIDs or variable names/positions absent from training data is now surfaced as logger.warning() messages — distinguishing two failure levels: EventID never seen vs. EventID seen but no variables extracted
  • auto_config=True detectors warn when the auto-generated configuration is empty (no stable variables found in the configure phase)
  • Adds a post_train() lifecycle hook (analogous to set_configuration()) that fires exactly once after bounded training ends, via a new FitLogic.finish_training() flag

Adds a post-training validation step that logs warnings when a
manually-configured detector's EventIDs or variable names/positions
have no coverage in the training data, preventing silent no-op
detection (e.g. Apache logs where log_format captures all variables
with no templates). Also warns when auto_config=True produces an
empty configuration.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@viktorbeck98 viktorbeck98 requested a review from ipmach March 30, 2026 21:16
@viktorbeck98 viktorbeck98 linked an issue Mar 30, 2026 that may be closed by this pull request
@viktorbeck98 viktorbeck98 added the enhancement New feature or request label Mar 30, 2026
@viktorbeck98 viktorbeck98 self-assigned this Mar 30, 2026
Copy link
Copy Markdown
Contributor

@ipmach ipmach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

@ipmach ipmach merged commit 3ad3c58 into development Mar 31, 2026
4 checks passed
@ipmach ipmach deleted the feat/warnings branch March 31, 2026 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Discrepancies between data and configuration go undetected

2 participants