VictoriaMetrics/docs/anomaly-detection/components
Arkadii Yakovets 92b22581e6
docs: Add spellcheck workflow (#6470)
### Describe Your Changes

This is a follow-up PR containing workflow related part of the initial
[PR#6362](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/6362).
It adds spell checking control based on
[cspell](https://github.com/streetsidesoftware/cspell). The related
configs are consolidated under `cspell` directory.

You can add VictoriaMetrics specific terms into `cspell/custom-dict.txt`
(it contains ~30 items atm). All other absent commonly used terms should
be added directly to respective
[cspell-dicts](https://github.com/streetsidesoftware/cspell-dicts/blob/main/CONTRIBUTING.md).

### Checklist

The following checks are **mandatory**:

- [x] My change adheres [VictoriaMetrics contributing
guidelines](https://docs.victoriametrics.com/contributing/).

---------

Signed-off-by: Arkadii Yakovets <ark@victoriametrics.com>
2024-06-21 11:56:20 -07:00
..
autotune.webp docs/vmanomaly: v1.12 updates & fixes (#6046) 2024-04-01 16:41:55 +03:00
model-lifecycle-multivariate.webp docs/vmanomaly: v1.12 updates & fixes (#6046) 2024-04-01 16:41:55 +03:00
model-lifecycle-univariate.webp docs/vmanomaly: v1.12 updates & fixes (#6046) 2024-04-01 16:41:55 +03:00
model-type-non-rolling.webp docs/vmanomaly: v1.12 updates & fixes (#6046) 2024-04-01 16:41:55 +03:00
model-type-rolling.webp docs/vmanomaly: v1.12 updates & fixes (#6046) 2024-04-01 16:41:55 +03:00
models.md docs: Add spellcheck workflow (#6470) 2024-06-21 11:56:20 -07:00
monitoring.md all: replace old https://docs.victoriametrics.com/keyConcepts.html url with the new one - https://docs.victoriametrics.com/keyconcepts/ 2024-04-18 02:33:29 +02:00
reader.md docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
README.md docs/vmanomaly: update preset guide and cross-links (#6480) 2024-06-14 09:39:55 +02:00
scheduler.md docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_detection_direction=above_expected.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_detection_direction=below_expected.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_detection_direction=both.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_min_dev_from_expected=0.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_min_dev_from_expected=1.0.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
schema_min_dev_from_expected=5.0.webp docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00
vmanomaly-components.webp - fix 404 links after renaming (#5653) 2024-01-21 21:24:29 +02:00
writer.md docs/vmanomaly - release 1.13.0 preparation (#6436) 2024-06-11 13:15:05 +03:00

title weight menu aliases
Components 2
docs
identifier parent weight
vmanomaly-components anomaly-detection 2
/anomaly-detection/components/
/anomaly-detection/components/index.html

Components

This chapter describes different components, that correspond to respective sections of a config to launch VictoriaMetrics Anomaly Detection (or simply vmanomaly) service:

Note

: starting from v1.7.0, once the service starts, automated config validation is performed. Please see container logs for errors that need to be fixed to create fully valid config, visiting sections above for examples and documentation.

Note

: starting from v1.13.0, components' class can be referenced by a short alias instead of a full class path - i.e. model.zscore.ZscoreModel becomes zscore, reader.vm.VmReader becomes vm, scheduler.periodic.PeriodicScheduler becomes periodic, etc. Please see according sections for the details.

Note: Starting from v1.13.0 preset modes are available for vmanomaly. Please find the guide here.

Below, you will find an example illustrating how the components of vmanomaly interact with each other and with a single-node VictoriaMetrics setup.

Note

: Reader and Writer also support multitenancy, so you can read/write from/to different locations - see tenant_id param description.

vmanomaly-components

Here's a minimalistic full config example, demonstrating many-to-many configuration (actual for latest version):

# how and when to run the models is defined by schedulers
# https://docs.victoriametrics.com/anomaly-detection/components/scheduler/
schedulers:
  periodic_1d:  # alias
    class: 'periodic' # scheduler class
    infer_every: "30s"
    fit_every: "10m"
    fit_window: "24h"
  periodic_1w:
    class: 'periodic'
    infer_every: "15m"
    fit_every: "1h"
    fit_window: "7d"

# what model types and with what hyperparams to run on your data
# https://docs.victoriametrics.com/anomaly-detection/components/models/
models:
  zscore:  # alias
    class: 'zscore'  # model class
    z_threshold: 3.5
    provide_series: ['anomaly_score']  # what series to produce
    queries: ['host_network_receive_errors']  # what queries to run particular model on
    schedulers: ['periodic_1d']  # will be attached to 1-day schedule, fit every 10m and infer every 30s
  prophet: # alias
    class: 'prophet'
    provide_series: ['anomaly_score', 'yhat', 'yhat_lower', 'yhat_upper']
    queries: ['cpu_seconds_total']
    schedulers: ['periodic_1w']  # will be attached to 1-week schedule, fit every 1h and infer every 15m
    args:  # model-specific arguments
      interval_width: 0.98

# where to read data from
# https://docs.victoriametrics.com/anomaly-detection/components/reader/
reader:
  datasource_url: "http://victoriametrics:8428/"
  tenant_id: "0:0"
  class: 'vm'
  sampling_period: "30s"  # what data resolution of your data to have
  queries:  # aliases to MetricsQL expressions
    cpu_seconds_total: 'avg(rate(node_cpu_seconds_total[5m])) by (mode)' 
    host_network_receive_errors: 'rate(node_network_receive_errs_total[3m]) / rate(node_network_receive_packets_total[3m])'

# where to write data to
# https://docs.victoriametrics.com/anomaly-detection/components/writer/
writer:
  datasource_url: "http://victoriametrics:8428/"

# enable self-monitoring in pull and/or push mode
# https://docs.victoriametrics.com/anomaly-detection/components/monitoring/
monitoring:
  pull: # Enable /metrics endpoint.
    addr: "0.0.0.0"
    port: 8490