polars

polars is a skill for Claude Code from ualberta-rcg/drac-agent-skills. It costs 53 tokens per session (1,252 once invoked), scanned A, original, MIT.

A Python library for working with tables of data, similar to a spreadsheet or a database table. It supports parallel processing, delayed query execution, and streaming files in parts instead of loading everything into memory.

In plain words
What is it for?
Use it for data cleaning, joins, grouping, summaries, scientific tabular analysis, and reading or writing large datasets in batches.
Why use it?
It helps process large CSV and Parquet datasets that are slow or too large for a single in-memory table. It also provides a path for moving pandas-style data work to a more parallel workflow.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the community-science plugin — 10 skills shipped together

Good fit Use it for data cleaning, joins, grouping, summaries, scientific tabular analysis, and reading or writing large datasets in batches.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ualberta-rcg/drac-agent-skills/polars
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ualberta-rcg/drac-agent-skills --skill polars
Clone the repo
git clone --depth 1 https://github.com/ualberta-rcg/drac-agent-skills

Made for: Claude Code.

Or install community-science, the plugin that ships this one along with the rest of its 10 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for polars

README.md
[![agentmods](https://agentmods.dev/badge/skills/ualberta-rcg/drac-agent-skills/polars/github.svg)](https://agentmods.dev/skills/ualberta-rcg/drac-agent-skills/polars)
Your own site
<a href="https://agentmods.dev/skills/ualberta-rcg/drac-agent-skills/polars"><img src="https://agentmods.dev/badge/skills/ualberta-rcg/drac-agent-skills/polars/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for polars

Your own site · 80×15
<a href="https://agentmods.dev/skills/ualberta-rcg/drac-agent-skills/polars"><img src="https://agentmods.dev/badge/skills/ualberta-rcg/drac-agent-skills/polars.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,252 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00053 $0.01252
Opus 5.5 $0.00021 $0.00501
Sonnet 5.5 $0.00011 $0.00250
Haiku 4.5 $0.00005 $0.00125

Measured 6d ago against content hash 98946e63a3d9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

polars scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

community-skills/skills/polars/SKILL.md · 79 lines

How it starts

The opening of the file, as written. The whole thing — 79 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Polars: Fast Columnar DataFrames & Streaming ETL

Polars executes columnar Arrow queries in parallel Rust threads with lazy predicate/projection pushdown and out-of-core streaming. On shared Slurm nodes, Polars respects POLARS_MAX_THREADS=$SLURM_CPUS_PER_TASK so jobs stay cleanly within allocated cores.

Core Idioms (LazyFrame First)

Prefer pl.scan_parquet / pl.scan_csv (LazyFrame) over read_* on nontrivial datasets so Polars pushes filters and column selection down to file scan time:

import polars as pl

lf = (
    pl.scan_parquet("/scratch/$USER/cohort/*.parquet")
    .filter(
        pl.col("qc_pass"),
        pl.col("age") >= 18,
    )
    .with_columns(
        z_score=(pl.col("biomarker") - pl.col("biomarker").mean().over("batch"))
        / pl.col("biomarker").std(ddof=1).over("batch")
    )
    .group_by("condition", "sex")
    .agg(
        n_rows=pl.len(),
        n_nonnull=pl.col("biomarker").count(),
        mean_val=pl.col("biomarker").mean(),
        sd_val=pl.col("biomarker").std(ddof=1),
    )
)

# Inspect optimized query plan before running
print(lf.explain())

# Execute in-memory or stream directly to Parquet for larger-than-RAM pipelines
result = lf.collect()
# Or sink directly to disk: lf.sink_parquet("/scratch/$USER/results/out.parquet")

Key Pandas -> Polars Differences

Task Pandas Polars
Column selection df[["a", "b"]] df.select("a", "b")
Row filtering df[(df["a"] > 0) & (df["b"] == "x")] df.filter(pl.col("a") > 0, pl.col("b") == "x")
Derived columns df.assign(c=df["a"] * 2) df.with_columns(c=pl.col("a") * 2)
Dependent columns Sequential df["c"] = ...; df["d"] = df["c"] + 1 Chain two .with_columns(...) calls (expressions in one call run in parallel against the input schema!)
Group transform df.groupby("g")["x"].transform("mean") df.with_columns(pl.col("x").mean().over("g"))
Conditional np.where(cond, a, b) pl.when(cond).then(a).otherwise(b)
Reshape wide->long df.melt(...) df.unpivot(index="id", on=["c1", "c2"])

Read the full file on GitHub · 79 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 79 lines · 53 tokens per session scan A 98946e63a3d9

Subscribe to this mod's changes

polars is a skill published in the GitHub repository ualberta-rcg/drac-agent-skills (2 stars, last pushed 7d ago), licensed MIT. It adds 53 tokens to every session and 1,252 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-25.

Related

polars compared with skills from other repositories

polars next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
polarsualberta-rcg/drac-agent-skillsSkill27d agoMITA53Claude Code
pytorch-patternsaffaan-m/ECCSkill314kyesterdayMITA32Claude Code, Kiro
optimize-for-gpuK-Dense-AI/scientific-agent-skillsSkill59kyesterdayMITA151Claude Code, Codex
accelerateNousResearch/hermes-agentSkill267ktodayMITA13Claude Code, Codex
developing-genkit-pythongoogle/skillsSkill25ktodayApache-2.0A96Claude Code, Codex
marimo-pairmarimo-team/marimoSkill24ktodayApache-2.0A57Claude Code, Codex
cudnn-installNVIDIA/skillsSkill4.2ktodayApache-2.0A49Claude Code, Codex