Description
Normalize a log-level token through explicit caller aliases with cycle/path evidence; no universal severity vocabulary.
Structured log records need an explicit ordering, time unit and label convention. A sequence gap can be measured in supplied record order without proving loss, and grouping adjacent messages differs from grouping all equal messages. The record tools here operate on caller-supplied structured data rather than collecting logs.
Normalize a log-level token through explicit caller aliases with cycle/path evidence; no universal severity vocabulary.
When to use this tool
Use this tool to normalize a log-level token through explicit caller aliases with cycle/path evidence; no universal severity vocabulary.
How to use the tool and how it works
- Enter level, aliasesJson using the field definitions below. For JSON text, serialize the explicit records in the shown shape.
- Run the operation. Correct input errors before interpreting an output.
- Read result.normalized, result.cycle, result.path. Use the ordering, boundary rules and absence conditions described below.
Follow exact alias name-to-target records from level, returning the visited path and terminal label, or null terminal with cycle true.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| level | Exact level label to resolve through the supplied aliases. | Text, at most 8,192 UTF-16 code units; the operation’s grammar also applies. |
| aliasesJson | JSON array of {name, target} string records. Alias names must be distinct; matching is exact and case-sensitive. Cycles are reported rather than resolved to an invented terminal label. | Text, at most 8,192 UTF-16 code units; the operation’s grammar also applies. |
These are the decoded structures used in the example’s JSON text fields. Supply the corresponding serialized JSON strings as input.
{
"aliasesJson": [
{
"name": "warn",
"target": "warning"
}
]
} | Output field | Interpretation |
|---|---|
| result | Object containing the named fields below. |
| result.normalized | Terminal alias label, or null when a cycle is encountered. |
| result.cycle | Whether alias traversal encountered a repeated label. |
| result.path | Visited alias labels in traversal order. |
{
"input": {
"level": "warn",
"aliasesJson": "[{\"name\":\"warn\",\"target\":\"warning\"}]"
},
"output": {
"result": {
"normalized": "warning",
"cycle": false,
"path": [
"warn",
"warning"
]
}
}
} Limitations and assumptions
- There is no built-in level vocabulary, case normalization or automatic cycle repair.
- Structured log records have id, time, source, level, message and sequence fields. time is a finite caller-defined numeric scale; sequence is an integer from 0 through 1,000,000,000,000. Use the same time units for windows and gap edges.
- Every declared top-level input field is required and unexpected fields are rejected. Ordinary strings are limited to 8,192 UTF-16 code units and lists to 128 entries, with tighter operation-specific bounds where stated. JSON text has bounded nesting and node counts.
- Numeric outputs must be finite and no larger in absolute magnitude than the safe-integer limit; operations returning exact large integers use decimal text. Positions are zero-based and spans end exclusively unless the operation explicitly states a different convention.
Alternative or Complementary methods
Keep original record order and provenance alongside summaries. Sort, partition by source or normalize aliases explicitly before applying a rule that depends on those choices.
References
Similar or alternative tools
- Log Level Order Selector
Select supplied severity tokens at or above an explicit least-to-most ordered level bank; retain unknown tokens instead of assuming rank.
- Log Prefix Token Extractor
Extract every caller-defined literal log message prefix and remainder with original prefix indexes; no inferred log format or priority interpretation.