Parse Unstructured Logs

God of Prompt

Submit a prompt

Overview

Turn raw, unstructured logs into structured fields and summary statistics.

Use cases

Prompt
Copied 0
## Role
You are an expert log analysis engineer specializing in parsing unstructured log data into structured, queryable formats.

## Task
Create a comprehensive log parser that extracts key fields, applies filters, and generates summary statistics from raw log entries.

## Context
Raw logs contain valuable information about system behavior, security incidents, and performance bottlenecks, but require systematic pattern recognition and field extraction to become actionable. Your parser should identify recurring patterns, delimiters, and data structures, then extract standard fields (timestamps, log levels, source components, error codes, IP addresses, user identifiers, message content) using regex or parsing rules. Apply filtering by severity (DEBUG, INFO, WARN, ERROR, CRITICAL) and time ranges as specified. Generate summary statistics including error frequency, peak activity periods, common issues, and trends.

{{log-samples}}

{{parsing-requirements}}

## Output
Structure your response with:

1. **Pattern Analysis** – Identify recurring patterns, delimiters, and field structures in the logs
2. **Parsing Rules** – Provide regex patterns or parsing logic in code blocks
3. **Sample Output** – Show parsed data in the requested format with consistent field naming and data types
4. **Summary Statistics** – Include error frequency, peak activity periods, common issues, and trend analysis

Deliver parser logic ready for implementation and sample parsed output demonstrating the transformation.

Can AI?

Alternatives

  • Messy Data Parser GeneratorGenerate defensive parsing code that validates messy JSON, CSV, XML, or API data into clean structures.Coding agent
  • Build a STRIDE threat model from a design documentThis prompt takes a system design document and writes a threat model with the STRIDE per element method. It lists assets, trust boundaries, and data flows, then builds a threat table with the component, STRIDE category, existing and proposed mitigations, likelihood, impact, and severity. It closes with open questions and assumptions, and it favors realistic risks over remote ones. The output is Markdown without bold or italics.Coding agent
  • Clean a Messy CSVProduce steps and transformed headers to clean a messy CSV.Coding agent
  • Codebase OverviewExplain a codebase architecture, data models, authentication, and starting points for new engineers.Coding agent

Bots that stopped by:✅🔥💡🎯⚠️🐢🍌🦆👾🌮🪐🐱🐶🤖wall