Skip to main content

Polars RefKit

Parse, inspect, render, and format BibTeX columns inside Polars eager and lazy queries. Each source row owns an independent bibliography and citation state.

Documentation · Expression reference · Python objects

Render a citation column

Install in Python 3.11 through 3.14 with Polars 1.29 or newer:

python -m pip install polars-refkit
import polars as pl
import polars_refkit

frame = pl.DataFrame(
    {
        "bibtex": ["@article{doe2024, author={Doe, Jane}, title={Fast Citations}, year={2024}}"],
        "key": ["doe2024"],
    }
)
result = frame.select(
    citation=pl.col("bibtex").refkit.cite("key"),
    entries=pl.col("bibtex").refkit.entry_count(),
)
print(result.to_dicts())
[{'citation': '(Doe, 2024)', 'entries': 1}]

Importing polars_refkit registers pl.Expr.refkit. A string argument names a column. Use pl.lit(...) for literal bibliography text or citation keys.

Choose an operation

Task Expressions
Parse and inspect entry_count, keys, entries, can_parse, diagnostics, has_diagnostics, parse_report
Render citations cite, cite_each, cite_group
Render every entry full_bibliography
Inspect render failures render_report
Format and deduplicate tidy_bibtex, tidy_bibtex_report

Choose output="text", "html", or "rendered" on rendering expressions. Pass formatting settings as an options= dictionary. Value expressions return null on row-local failures. Reports retain structured diagnostics, errors, or rename records beside the source row.

Use with agents

The package includes version-matched task guidance:

import polars_refkit.agent

help(polars_refkit.agent)

Agent integration covers discovery. Data shapes defines reports and Pyodide records the tested browser runtime.

RefKit is alpha software. Public APIs may change before 1.0.

Apache-2.0 license · Upstream notices

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

polars_refkit-0.1.0.tar.gz (93.4 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

polars_refkit-0.1.0-cp311-abi3-win_amd64.whl (6.1 MB view details)

Uploaded CPython 3.11+Windows x86-64

polars_refkit-0.1.0-cp311-abi3-pyemscripten_2026_0_wasm32.whl (3.8 MB view details)

Uploaded CPython 3.11+PyEmscripten 2026.0 wasm32

polars_refkit-0.1.0-cp311-abi3-manylinux_2_34_x86_64.whl (6.2 MB view details)

Uploaded CPython 3.11+manylinux: glibc 2.34+ x86-64

polars_refkit-0.1.0-cp311-abi3-macosx_11_0_arm64.whl (5.3 MB view details)

Uploaded CPython 3.11+macOS 11.0+ ARM64

File details

Details for the file polars_refkit-0.1.0.tar.gz.

File metadata

  • Download URL: polars_refkit-0.1.0.tar.gz
  • Upload date:
  • Size: 93.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.10 {"installer":{"name":"uv","version":"0.12.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for polars_refkit-0.1.0.tar.gz
Algorithm Hash digest
SHA256 147ed99f7657e88c1ed9364e846d39bde337329965567746035b71e03f4b72e5
MD5 314d7d077750b08df5e7f1cdf3beaf39
BLAKE2b-256 deb33e4aabd9f186e72814373c0613d94f2d13bf15fa2cb8e022e9871ec10f24

See more details on using hashes here.

File details

Details for the file polars_refkit-0.1.0-cp311-abi3-win_amd64.whl.

File metadata

  • Download URL: polars_refkit-0.1.0-cp311-abi3-win_amd64.whl
  • Upload date:
  • Size: 6.1 MB
  • Tags: CPython 3.11+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.10 {"installer":{"name":"uv","version":"0.12.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for polars_refkit-0.1.0-cp311-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 d66e6831a338f4ac911e5d4dd565f4c62b32c952945eb5412161f22704218a5c
MD5 5ba9d0d00800fdcb6b59d48cdf013da6
BLAKE2b-256 e174262b5307404482325184deaac8b1222931b767e49469655098aa15b4c9ad

See more details on using hashes here.

File details

Details for the file polars_refkit-0.1.0-cp311-abi3-pyemscripten_2026_0_wasm32.whl.

File metadata

  • Download URL: polars_refkit-0.1.0-cp311-abi3-pyemscripten_2026_0_wasm32.whl
  • Upload date:
  • Size: 3.8 MB
  • Tags: CPython 3.11+, PyEmscripten 2026.0 wasm32
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.10 {"installer":{"name":"uv","version":"0.12.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for polars_refkit-0.1.0-cp311-abi3-pyemscripten_2026_0_wasm32.whl
Algorithm Hash digest
SHA256 168b2755b67aa40439912f31e78f358e446d471037272b731c61a962e696dce2
MD5 a6ebff26b8c00b00fa1c58f4df54afab
BLAKE2b-256 518c948307d2615aa5717ce7ae8f06443e84e66829b7f10bb2b78bbd3833f254

See more details on using hashes here.

File details

Details for the file polars_refkit-0.1.0-cp311-abi3-manylinux_2_34_x86_64.whl.

File metadata

  • Download URL: polars_refkit-0.1.0-cp311-abi3-manylinux_2_34_x86_64.whl
  • Upload date:
  • Size: 6.2 MB
  • Tags: CPython 3.11+, manylinux: glibc 2.34+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.10 {"installer":{"name":"uv","version":"0.12.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for polars_refkit-0.1.0-cp311-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 6dc86b11b82c2e0a1776836b52af4a44b096c525d8446b779dd83baa49ca8610
MD5 92803dd9fc8e2bb5385ee5bf629c124c
BLAKE2b-256 36eb323d108b9afca8de16840f53e6c318bbe9a2a07216f6e1153f8a0731c5e3

See more details on using hashes here.

File details

Details for the file polars_refkit-0.1.0-cp311-abi3-macosx_11_0_arm64.whl.

File metadata

  • Download URL: polars_refkit-0.1.0-cp311-abi3-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 5.3 MB
  • Tags: CPython 3.11+, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.10 {"installer":{"name":"uv","version":"0.12.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for polars_refkit-0.1.0-cp311-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ad8678515b018288d1d89c46b8181a4806a31265e45b4e715fc8e2bf1456a88d
MD5 5a595196c037aa53295b3d7e3f1bea6d
BLAKE2b-256 70a4af738a5d06493271d418a4e9a89074ff07e5e511a6a414e73ba5dfe1cee8

See more details on using hashes here.

Release history Release notifications | RSS feed

0.3.0

5 files

0.2.1

5 files

0.2.0

5 files

0.1.1

5 files

This release

0.1.0 This release

5 files

0.0.8

5 files

0.0.7

5 files

0.0.5

5 files

0.0.3

5 files

0.0.2

5 files

0.0.1

4 files

0.0.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page