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.10 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

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.3.0.tar.gz (97.2 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.3.0-cp310-abi3-win_amd64.whl (6.1 MB view details)

Uploaded CPython 3.10+Windows x86-64

polars_refkit-0.3.0-cp310-abi3-pyemscripten_2026_0_wasm32.whl (3.8 MB view details)

Uploaded CPython 3.10+PyEmscripten 2026.0 wasm32

polars_refkit-0.3.0-cp310-abi3-manylinux_2_34_x86_64.whl (6.1 MB view details)

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

polars_refkit-0.3.0-cp310-abi3-macosx_11_0_arm64.whl (5.2 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

File details

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

File metadata

  • Download URL: polars_refkit-0.3.0.tar.gz
  • Upload date:
  • Size: 97.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.11 {"installer":{"name":"uv","version":"0.12.11","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.3.0.tar.gz
Algorithm Hash digest
SHA256 3fc06fe61066f2b8de8011c4ca64dcfd7c8924bc7a490e6a12a671519975e1f7
MD5 c2d6d2b71947000a33d387ea920946c7
BLAKE2b-256 64130eacf677380d266e994aacf65a862dda7ed198dcfd350f87d8e0ad6c2369

See more details on using hashes here.

File details

Details for the file polars_refkit-0.3.0-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: polars_refkit-0.3.0-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 6.1 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.11 {"installer":{"name":"uv","version":"0.12.11","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.3.0-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 8df0f68cb951774cb729155078f16af81afead3825f4ce0a04e87b1c6caaa553
MD5 be75c7dce824d208528292c1d93fb7a5
BLAKE2b-256 4488bba465ff21028632c61d347c81ac97598b4e3ae4b8ba4a597635a16388e7

See more details on using hashes here.

File details

Details for the file polars_refkit-0.3.0-cp310-abi3-pyemscripten_2026_0_wasm32.whl.

File metadata

  • Download URL: polars_refkit-0.3.0-cp310-abi3-pyemscripten_2026_0_wasm32.whl
  • Upload date:
  • Size: 3.8 MB
  • Tags: CPython 3.10+, PyEmscripten 2026.0 wasm32
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.11 {"installer":{"name":"uv","version":"0.12.11","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.3.0-cp310-abi3-pyemscripten_2026_0_wasm32.whl
Algorithm Hash digest
SHA256 8f404d04d6fbdd31d9d3edcb796c453d3c73c44d77ac4937589e99f3b3caf4f1
MD5 4961b9206224afe17113e684592ff4cd
BLAKE2b-256 8b2bada5ab5e6564cd26e4083c0ba8cab503248509ac287aa5c349ac32a615a9

See more details on using hashes here.

File details

Details for the file polars_refkit-0.3.0-cp310-abi3-manylinux_2_34_x86_64.whl.

File metadata

  • Download URL: polars_refkit-0.3.0-cp310-abi3-manylinux_2_34_x86_64.whl
  • Upload date:
  • Size: 6.1 MB
  • Tags: CPython 3.10+, manylinux: glibc 2.34+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.11 {"installer":{"name":"uv","version":"0.12.11","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.3.0-cp310-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 9ca891ea7790d9046d4f7f0466d8850785b5b40fa4babe88acd6b851069abba5
MD5 902ee756f55b75de74433e9229c66b28
BLAKE2b-256 f26ea16f8d9e19a19b85ed71b49fb83eae57b9d798e6e0587f6e0fcbbae373b9

See more details on using hashes here.

File details

Details for the file polars_refkit-0.3.0-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

  • Download URL: polars_refkit-0.3.0-cp310-abi3-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 5.2 MB
  • Tags: CPython 3.10+, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.11 {"installer":{"name":"uv","version":"0.12.11","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.3.0-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 24101efdf820fecb9887d23fcafc1608230aaaffeb1de90e771a2a7bbed9b48d
MD5 dfd16047951698ed4f2a6e731d62f850
BLAKE2b-256 38564692d0c3a9c55081ed7a25cd03308619b6da1fefaf342564cc12089bc4ed

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.3.0 This release

5 files

0.2.1

5 files

0.2.0

5 files

0.1.1

5 files

0.1.0

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