From 68f8f2ef18d860b3a0162422482890597ad73049 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Istv=C3=A1n=20Zolt=C3=A1n=20Szab=C3=B3?= Date: Thu, 18 Apr 2024 15:43:17 +0200 Subject: [PATCH] [DOCS] Adds explain DFA examples. --- ...ainDataFrameAnalyticsResponseExample1.json | 39 +++++++++++++++++++ ...lainDataFrameAnalyticsRequestExample1.json | 13 +++++++ 2 files changed, 52 insertions(+) create mode 100644 specification/ml/explain_data_frame_analytics/examples/200_response/MlExplainDataFrameAnalyticsResponseExample1.json create mode 100644 specification/ml/explain_data_frame_analytics/examples/request/MlExplainDataFrameAnalyticsRequestExample1.json diff --git a/specification/ml/explain_data_frame_analytics/examples/200_response/MlExplainDataFrameAnalyticsResponseExample1.json b/specification/ml/explain_data_frame_analytics/examples/200_response/MlExplainDataFrameAnalyticsResponseExample1.json new file mode 100644 index 0000000000..946500d053 --- /dev/null +++ b/specification/ml/explain_data_frame_analytics/examples/200_response/MlExplainDataFrameAnalyticsResponseExample1.json @@ -0,0 +1,39 @@ +{ + "summary": "A succesful response for explaining a data frame analytics job configuration.", + "value": { + "field_selection": [ + { + "field": "number_of_bedrooms", + "mappings_types": ["integer"], + "is_included": true, + "is_required": false, + "feature_type": "numerical" + }, + { + "field": "postcode", + "mappings_types": ["text"], + "is_included": false, + "is_required": false, + "reason": "[postcode.keyword] is preferred because it is aggregatable" + }, + { + "field": "postcode.keyword", + "mappings_types": ["keyword"], + "is_included": true, + "is_required": false, + "feature_type": "categorical" + }, + { + "field": "price", + "mappings_types": ["float"], + "is_included": true, + "is_required": true, + "feature_type": "numerical" + } + ], + "memory_estimation": { + "expected_memory_without_disk": "128MB", + "expected_memory_with_disk": "32MB" + } + } +} diff --git a/specification/ml/explain_data_frame_analytics/examples/request/MlExplainDataFrameAnalyticsRequestExample1.json b/specification/ml/explain_data_frame_analytics/examples/request/MlExplainDataFrameAnalyticsRequestExample1.json new file mode 100644 index 0000000000..97d1057c71 --- /dev/null +++ b/specification/ml/explain_data_frame_analytics/examples/request/MlExplainDataFrameAnalyticsRequestExample1.json @@ -0,0 +1,13 @@ +{ + "summary": "A request for explaining a data frame analytics job configuration.", + "value": { + "source": { + "index": "houses_sold_last_10_yrs" + }, + "analysis": { + "regression": { + "dependent_variable": "price" + } + } + } +}