Skip to content
Back to skills

Dax Lib

ASecurity

Use when about to write a DAX UDF, to check whether one is already published on DAX Lib (daxlib.org) — moving averages, format strings, SVG visuals, KPI/variance, RFM/ABC classification, unit conversion, model metadata, sample data. Offline index — what exists, who wrote it, where to get it. Triggers on "is there a UDF for", "existing DAX UDF", "daxlib", "DAX Lib package".

  • 3 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added October 24, 2026
ai-agentsjavascriptjavashellsqlangularexpressgit

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned October 24, 2026

npx -y skills add CSalcedoDataBI/dax-for-agents --skill dax-lib --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Dax Lib?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Dax Lib
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/csalcedodatabi-dax-lib/badge)](https://www.skillsdirectory.com/skills/csalcedodatabi-dax-lib)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: dax-lib
description: Use when about to write a DAX UDF, to check whether one is already published on DAX Lib (daxlib.org) — moving averages, format strings, SVG visuals, KPI/variance, RFM/ABC classification, unit conversion, model metadata, sample data. Offline index — what exists, who wrote it, where to get it. Triggers on "is there a UDF for", "existing DAX UDF", "daxlib", "DAX Lib package".
---

# DAX Lib — index of published DAX UDFs

**Before authoring a UDF from scratch, check here — someone may have already shipped it.**

This is an **offline index** of [DAX Lib](https://daxlib.org), the package registry for DAX
user-defined functions. It tells you what exists, who wrote it and what it does, so the agent
can answer "does this already exist?" without a network round trip.

**It does not carry the DAX code.** The code lives at the registry, which is where it stays
current. See [`NOTICE`](./NOTICE).

Pairs with **`dax-lib-install`** (actually install what this index found),
**`dax-udf-authoring`** (how to write your own when none fits), and
**`dax-reference`** (what the built-in functions do).

## Files

| File | Use |
|---|---|
| [`catalog.md`](./catalog.md) | Human index — one row per package: id, latest version, author, functions, description. **Scan this first.** |
| [`catalog.json`](./catalog.json) | Machine index — every version, with `functions[]`, `tags[]`, `isLatest`, `url`. Use for keyword/tag search. |
| `scripts/refresh-daxlib.ps1` | Rebuild the index from `daxlib/daxlib`. |

## Workflow

1. **Identify the need** — "trailing moving average", "waterfall SVG", "RFM segmentation".
2. **Search the index.** Grep `catalog.md`, or query `catalog.json` by `tags` / `functions` /
   `description`. Tags are coarse (`DAX,UDF,SVG,TIMESERIES,…`) — match on description and
   function names too.
3. **Report what you found**: package id, author, the function signature from `functions[]`,
   and the `url` to its source. Say plainly that the code has to come from the registry.
4. **If the user wants it installed**, not just documented, route to
   **`dax-lib-install`** — do not fetch, paste, or install the code yourself.
   That skill owns the fetch, the license check, the install, and the attribution.
5. **If nothing fits**, say so and route to `dax-udf-authoring`.

## Example

```
Need: trailing N-period moving average over a dynamic date column.
catalog.json → id "TimeSeries.MovingAverage" (latest 0.1.1), tags TIMESERIES,
  functions: Simple, Weighted, LinearWeighted, Exponential, DoubleExponential,
             Triangular, Geometric
url → https://github.com/daxlib/daxlib/tree/main/packages/t/timeseries.movingaverage
```

`TimeSeries.MovingAverage.Simple( dateColumn, timeSeriesTable, lookbackPeriods, expression )`
is built on native `WINDOW` (see **`dax-window-functions`**), which is generally cheaper than a
hand-rolled `TOPN + CALCULATETABLE`. It needs a fixed date column, so it does not fit a model
whose grain is a dynamic period axis.

## Refresh

```powershell
pwsh ./scripts/refresh-daxlib.ps1
```

Shallow-clones `daxlib/daxlib@main`, reads each package's `manifest.daxlib`, parses the function
names out of its `functions.tmdl`, and rewrites `catalog.json` + `catalog.md` stamped with the
upstream commit. **It keeps no `.tmdl` file.**

**Why a script and not WebFetch:** daxlib.org is a JavaScript SPA — a plain HTTP GET returns the
empty app shell. GitHub is the source of truth.

## Notes

- The index is a snapshot; the registry is live. Check `source` in `catalog.json` for how old it
  is, and prefer the registry when a version matters.
- All versions are indexed (`isLatest` flags the newest per package). Prefer the latest unless
  reproducing a specific one.
- Some `manifest.daxlib` files still point their `$schema` at the old `sql-bi/daxlib` path — the
  repo was renamed to `daxlib/daxlib`. Harmless.
- **Licensing varies per author.** The upstream repo is MIT, but individual packages declare no
  license of their own — check the package before reusing its code in a product.

Files in this skill

  • NOTICE1.9 KB
  • SKILL.md4 KB
  • catalog.md11.3 KB
  • scripts/refresh-daxlib.ps16.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.