Skip to content

Commit

Permalink
Disable loading ML-commons plugin for doctests and corresponding te…
Browse files Browse the repository at this point in the history
…sts. (#1011)

Signed-off-by: Yury-Fridlyand <[email protected]>

Signed-off-by: Yury-Fridlyand <[email protected]>
  • Loading branch information
Yury-Fridlyand authored and dai-chen committed Nov 3, 2022
1 parent 7ec7a0a commit 9da6a53
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
8 changes: 4 additions & 4 deletions docs/user/ppl/cmd/ad.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ The example trains an RCF model and uses the model to detect anomalies in the ti

PPL query::

os> source=nyc_taxi | fields value, timestamp | AD time_field='timestamp' | where value=10844.0
> source=nyc_taxi | fields value, timestamp | AD time_field='timestamp' | where value=10844.0
fetched rows / total rows = 1/1
+---------+---------------------+---------+-----------------+
| value | timestamp | score | anomaly_grade |
Expand All @@ -63,7 +63,7 @@ The example trains an RCF model and uses the model to detect anomalies in the ti

PPL query::

os> source=nyc_taxi | fields category, value, timestamp | AD time_field='timestamp' category_field='category' | where value=10844.0 or value=6526.0
> source=nyc_taxi | fields category, value, timestamp | AD time_field='timestamp' category_field='category' | where value=10844.0 or value=6526.0
fetched rows / total rows = 2/2
+------------+---------+---------------------+---------+-----------------+
| category | value | timestamp | score | anomaly_grade |
Expand All @@ -80,7 +80,7 @@ The example trains an RCF model and uses the model to detect anomalies in the no

PPL query::

os> source=nyc_taxi | fields value | AD | where value=10844.0
> source=nyc_taxi | fields value | AD | where value=10844.0
fetched rows / total rows = 1/1
+---------+---------+-------------+
| value | score | anomalous |
Expand All @@ -95,7 +95,7 @@ The example trains an RCF model and uses the model to detect anomalies in the no

PPL query::

os> source=nyc_taxi | fields category, value | AD category_field='category' | where value=10844.0 or value=6526.0
> source=nyc_taxi | fields category, value | AD category_field='category' | where value=10844.0 or value=6526.0
fetched rows / total rows = 2/2
+------------+---------+---------+-------------+
| category | value | score | anomalous |
Expand Down
2 changes: 1 addition & 1 deletion docs/user/ppl/cmd/kmeans.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ The example shows how to classify three Iris species (Iris setosa, Iris virginic

PPL query::

os> source=iris_data | fields sepal_length_in_cm, sepal_width_in_cm, petal_length_in_cm, petal_width_in_cm | kmeans centroids=3
> source=iris_data | fields sepal_length_in_cm, sepal_width_in_cm, petal_length_in_cm, petal_width_in_cm | kmeans centroids=3
+--------------------+-------------------+--------------------+-------------------+-----------+
| sepal_length_in_cm | sepal_width_in_cm | petal_length_in_cm | petal_width_in_cm | ClusterID |
|--------------------+-------------------+--------------------+-------------------+-----------|
Expand Down
3 changes: 3 additions & 0 deletions doctest/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ String mlCommonsPlugin = 'opensearch-ml'
testClusters {
docTestCluster {
keystore 'plugins.query.federation.catalog.config', new File("$projectDir/catalog", 'catalog.json')
// Disable loading of `ML-commons` plugin, because it might be unavailable (not released yet).
/*
plugin(provider(new Callable<RegularFile>(){
@Override
RegularFile call() throws Exception {
Expand All @@ -124,6 +126,7 @@ testClusters {
}
}
}))
*/
plugin ':opensearch-sql-plugin'
testDistribution = 'integ_test'
}
Expand Down

0 comments on commit 9da6a53

Please sign in to comment.