본문으로 건너뛰기
cccskills
무료GitHub에 공개

spl-to-apl

Translates Splunk SPL queries into Axiom APL, the query language used to search and analyze data in Axiom. Covers command and function equivalents, time filters, type conversions, and common patterns for migration or learning.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Translates Splunk SPL queries to Axiom APL. Provides command mappings, function equivalents, and syntax transformations. Use when migrating from Splunk, converting SPL queries, or learning APL equivalents of SPL patterns.

설치 방법 보기

이럴 때 유용합니다

  • Migrating Splunk queries to Axiom
  • Converting log aggregation and error-rate queries
  • Learning APL through familiar SPL patterns
  • Reviewing time filters and data types during conversion

포함된 파일(11)

  • SKILL.md6.3 KB
  • .meta/2026-01-28-schema-read-findings.md3.4 KB
  • .meta/cases.ts5.7 KB
  • .meta/DESIGN-NOTES.md6.4 KB
  • .meta/spl-to-apl.eval.ts4.2 KB
  • README.md2.0 KB
  • reference/command-mapping.md7.3 KB
  • reference/dataset-schemas.md1.3 KB
  • reference/examples.md10.3 KB
  • reference/function-mapping.md11.1 KB
  • tests/test-queries.md4.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

SPL to APL Translator

Type safety: Fields like status are often stored as strings. Always cast before numeric comparison: toint(status) >= 500, not status >= 500.


Critical Differences

  1. Time is explicit in APL: SPL time pickers don't translate — add where _time between (ago(1h) .. now())
  2. Structure: SPL index=... | command → APL ['dataset'] | operator
  3. Join is preview: limited to 50k rows, inner/innerunique/leftouter only
  4. cidrmatch args reversed: SPL cidrmatch(cidr, ip) → APL ipv4_is_in_range(ip, cidr)

Core Command Mappings

SPLAPLNotes
search index=...['dataset']Dataset replaces index
search field=valuewhere field == "value"Explicit where
wherewhereSame
statssummarizeDifferent aggregation syntax
evalextendCreate/modify fields
table / fieldsprojectSelect columns
fields -project-awayRemove columns
rename x as yproject-rename y = xRename
sort / sort -order by ... asc/descSort
head Ntake NLimit rows
top N fieldsummarize count() by field | top N by count_Two-step
dedup fieldsummarize arg_max(_time, *) by fieldKeep latest
rexparse or extract()Regex extraction
joinjoinPreview feature
appendunionCombine datasets
mvexpandmv-expandExpand arrays
timechart span=Xsummarize ... by bin(_time, X)Manual binning
rare N fieldsummarize count() by field | order by count_ asc | take NBottom N
spathparse_json() or json['path']JSON access
transactionNo direct equivalentUse summarize + make_list

Complete mappings: reference/command-mapping.md


Stats → Summarize

# SPL
| stats count by status

# APL  
| summarize count() by status

Key function mappings

SPLAPL
countcount()
count(field)countif(isnotnull(field))
dc(field)dcount(field)
avg/sum/min/maxSame
median(field)percentile(field, 50)
perc95(field)percentile(field, 95)
first/lastarg_min/arg_max(_time, field)
list(field)make_list(field)
values(field)make_set(field)

Conditional count pattern

# SPL
| stats count(eval(status>=500)) as errors by host

# APL
| summarize errors = countif(status >= 500) by host

Complete function list: reference/function-mapping.md


Eval → Extend

# SPL
| eval new_field = old_field * 2

# APL
| extend new_field = old_field * 2

Key function mappings

SPLAPLNotes
if(c, t, f)iff(c, t, f)Double 'f'
case(c1,v1,...)case(c1,v1,...,default)Requires default
len(str)strlen(str)
lower/uppertolower/toupper
substrsubstring0-indexed in APL
replacereplace_string
tonumbertoint/tolong/torealExplicit types
match(s,r)s matches regex "r"Operator
split(s, d)split(s, d)Same
mvjoin(mv, d)strcat_array(arr, d)Join array
mvcount(mv)array_length(arr)Array length

Case statement pattern

# SPL
| eval level = case(
    status >= 500, "error",
    status >= 400, "warning",
    1==1, "ok"
  )

# APL  
| extend level = case(
    status >= 500, "error",
    status >= 400, "warning",
    "ok"
  )

Note: SPL's 1==1 catch-all becomes implicit default in APL.


Rex → Parse/Extract

# SPL
| rex field=message "user=(?<username>\w+)"

# APL - parse with regex
| parse kind=regex message with @"user=(?P<username>\w+)"

# APL - extract function  
| extend username = extract("user=(\\w+)", 1, message)

Simple pattern (non-regex)

# SPL
| rex field=uri "^/api/(?<version>v\d+)/(?<endpoint>\w+)"

# APL
| parse uri with "/api/" version "/" endpoint

Time Handling

SPL time pickers don't translate. Always add explicit time range:

# SPL (time picker: Last 24 hours)
index=logs

# APL
['logs'] | where _time between (ago(24h) .. now())

Timechart translation

# SPL
| timechart span=5m count by status

# APL
| summarize count() by bin(_time, 5m), status

Common Patterns

Error rate calculation

# SPL
| stats count(eval(status>=500)) as errors, count as total by host
| eval error_rate = errors/total*100

# APL
| summarize errors = countif(status >= 500), total = count() by host
| extend error_rate = toreal(errors) / total * 100

Subquery (subsearch)

# SPL
index=logs [search index=errors | fields user_id | format]

# APL
let error_users = ['errors'] | where _time between (ago(1h) .. now()) | distinct user_id;
['logs']
| where _time between (ago(1h) .. now())
| where user_id in (error_users)

Join datasets

# SPL
| join user_id [search index=users | fields user_id, name]

# APL
| join kind=inner (['users'] | project user_id, name) on user_id

Transaction-like grouping

# SPL
| transaction session_id maxspan=30m

# APL (no direct equivalent — reconstruct with summarize)
| summarize 
    start_time = min(_time),
    end_time = max(_time),
    events = make_list(pack("time", _time, "action", action)),
    duration = max(_time) - min(_time)
  by session_id
| where duration <= 30m

String Matching Performance

SPLAPLSpeed
field="value"field == "value"Fastest
field="*value*"field contains "value"Moderate
field="value*"field startswith "value"Fast
match(field, regex)field matches regex "..."Slowest

Prefer has over contains (word-boundary matching is faster). Use _cs variants for case-sensitive (faster).


Reference

  • reference/command-mapping.md — complete command list
  • reference/function-mapping.md — complete function list
  • reference/examples.md — full query translation examples
  • APL docs: https://axiom.co/docs/apl/introduction

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Review code using shared OpenClaw instructions and a Python helper, while also following the target repository’s review requirements. This skill points to a common installation that supplies the actual review procedure.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Reviewing code with shared OpenClaw instructions
  • Applying repository-specific review requirements
  • Keeping shared review instructions up to date
openclaw/clawhub9.5천2026년 10월 18일 업데이트

Create and manage Axiom alert rules and notification destinations through its API. Connect alerts to email, Slack, or webhooks, check monitor history, and adjust thresholds and evaluation schedules to address excessive or missing alerts.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Set up error alerts and notification destinations
  • Tune monitors that send too many alerts
  • Investigate monitors that never trigger
openclaw/clawhub9.5천2026년 10월 18일 업데이트

axiom-sre

무료

Investigate production incidents and bugs using logs, metrics, and code evidence. The skill guides hypothesis testing, root cause analysis, fix validation, and reusable investigation notes, with access to configured observability tools such as Axiom.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Investigate production outages and rising error rates
  • Trace causes using logs, metrics, and code
  • Reproduce bugs and validate minimal fixes
openclaw/clawhub9.5천2026년 10월 18일 업데이트

Design and build Axiom dashboards from logs or metrics, the numerical measurements of system behavior. Create charts, filters, and layouts for monitoring and reporting, or migrate existing Splunk and Grafana panels while validating queries against available data.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Build a service health monitoring dashboard
  • Create interactive filters for investigating logs
  • Migrate dashboards from Splunk or Grafana
openclaw/clawhub9.5천2026년 10월 18일 업데이트

Drafts, previews, sends, and records emails for existing ClawHub content rights cases. It supports publisher removal notices and requester updates, requires approval of the final draft, and preserves the exact correspondence in the case record.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Preparing a skill removal notice for a publisher
  • Sending a requester a progress update or closure note
  • Preserving sent correspondence in an existing rights case
openclaw/clawhub9.5천2026년 10월 18일 업데이트

Apply ClawHub-specific rules when developing with Convex, including deployment targeting, runtime checks, data migrations, search performance, and skill statistics. It also directs specialized work to the appropriate companion skills.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Changing Convex functions or schemas
  • Planning production data migrations
  • Reviewing search query performance
openclaw/clawhub9.5천2026년 10월 18일 업데이트

openclaw의 스킬 모두 보기

이 스킬의 문제 신고