elasticsearch

Guide Elasticsearch cluster operations, index mappings, queries, and aggregations.

30|7|Updated Mar 1, 2026
One-click install
npx skills add https://github.com/rfdiosuao/openfang-cn --skill elasticsearch-rfdiosuao
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: elasticsearch
Source: https://github.com/rfdiosuao/openfang-cn/tree/main/crates/openfang-skills/bundled/elasticsearch
Command: npx skills add https://github.com/rfdiosuao/openfang-cn --skill elasticsearch-rfdiosuao

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps users navigate the complexities of Elasticsearch, enabling them to efficiently manage clusters, design effective data structures, and perform powerful searches and aggregations.

Core Features & Use Cases

  • Querying: Craft sophisticated queries for full-text search, exact matches, and complex filtering.
  • Mapping & Indexing: Design optimal index mappings and manage index lifecycles for performance and data integrity.
  • Aggregations: Perform advanced data analysis and generate insights using various aggregation types.
  • Cluster Operations: Understand and manage cluster health, shard allocation, and performance tuning.
  • Use Case: Analyze website traffic logs stored in Elasticsearch to identify the top 10 most visited pages in the last 24 hours, broken down by user country.

Quick Start

Use the elasticsearch skill to find all documents in the 'logs-2023.01.01' index where the 'status' field is 'ERROR' and the 'response_time_ms' is greater than 500.

Frequently Asked Questions about elasticsearch

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I craft complex Elasticsearch queries for full-text search and exact matches?

Complex Elasticsearch queries combine full-text search, exact matches, and filtering using the Elasticsearch DSL. You construct them by defining query context for relevance scoring and filter context for exact matching to retrieve targeted documents.

What is the best way to design Elasticsearch index mappings for time-series data analysis?

Designing Elasticsearch index mappings for time-series data requires defining optimal field types and managing index lifecycles. This approach ensures data integrity and cluster performance by controlling how time-stamped documents are indexed, stored, and eventually archived.

How do I perform data aggregations in Elasticsearch to analyze log analytics?

Data aggregations in Elasticsearch group and calculate metrics across documents to generate insights for log analytics. You perform them by structuring aggregation queries that bucket data by specific fields, such as user country or page visits, to summarize large datasets.

Do I need to understand cluster operations to manage Elasticsearch shard allocation?

Yes, understanding Elasticsearch cluster operations is required to manage shard allocation and monitor cluster health. Managing these operations involves configuring shard distribution and applying performance tuning principles to maintain search and indexing efficiency.

How do I filter Elasticsearch documents by specific field values and numeric thresholds?

Filtering Elasticsearch documents by field values and numeric thresholds involves constructing a boolean query with specific conditions. You define filter clauses to match exact values like status errors and apply range queries for numeric thresholds like response times.