Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ML] AIOps: Adds expanded rows to pattern analysis table #175320

Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { createRandomSamplerWrapper } from '@kbn/ml-random-sampler-utils';
import { createCategorizeQuery } from './create_categorize_query';

const CATEGORY_LIMIT = 1000;
const EXAMPLE_LIMIT = 1;
const EXAMPLE_LIMIT = 4;

export interface CategorizationAdditionalFilter {
from: number;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export function processCategoryResults(
subFieldExamples:
b.sub_time_range?.buckets[0].examples.hits.hits.map((h) => get(h._source, field)) ??
undefined,
regex: b.regex,
};
});
return {
Expand Down
2 changes: 2 additions & 0 deletions x-pack/plugins/aiops/common/api/log_categorization/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export interface Category {
subFieldExamples?: string[];
examples: string[];
sparkline?: Record<number, number>;
regex: string;
}

interface CategoryExamples {
Expand All @@ -27,6 +28,7 @@ export interface CategoriesAgg {
key: string;
doc_count: number;
examples: CategoryExamples;
regex: string;
sparkline: {
buckets: Array<{ key_as_string: string; key: number; doc_count: number }>;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ export function buildExtendedBaseFilterCriteria(
key,
count: docCount,
examples: [],
regex: '',
},
])
);
Expand All @@ -70,6 +71,7 @@ export function buildExtendedBaseFilterCriteria(
key: `${selectedSignificantItem.key}`,
count: selectedSignificantItem.doc_count,
examples: [],
regex: '',
},
])
);
Expand Down Expand Up @@ -97,6 +99,7 @@ export function buildExtendedBaseFilterCriteria(
key: `${selectedSignificantItem.key}`,
count: selectedSignificantItem.doc_count,
examples: [],
regex: '',
},
]),
],
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading