Skip to main content

Simple yet powerful Chilean and other tools written in Rust and Python.

Project description

cl-forge 🇨🇱

Simple yet powerful Chilean and other tools written in Rust and Python.

cl-forge provides a collection of high-performance utilities for common Chilean data formats and API integrations. The core logic is implemented in Rust for maximum speed, with a clean and easy-to-use Python interface.

Features

  • Verify: Efficiently validate and manipulate Chilean RUT/RUN and PPU (License Plates).
  • CMF API: A simple client to interact with the Chilean Financial Market Commission (CMF) API.
  • High Performance: Core logic written in Rust.
  • Lazy Loading: Submodules are loaded only when needed to keep the initial import fast.
  • Type Safety: Full type hints and .pyi stubs for excellent IDE support.

Installation

pip install cl-forge

Or using uv:

uv add cl-forge

Usage

Verification (RUT & PPU)

from cl_forge import verify

# Validate a RUT
is_valid = verify.validate_rut("12345678", "5")
print(f"RUT is valid: {is_valid}")

# Calculate RUT verifier
dv = verify.calculate_verifier("12345678")
print(f"Verifier digit: {dv}")

# Work with PPUs (License Plates)
ppu = verify.Ppu("PHZF55")
print(f"Normalized: {ppu.normalized}")  # PHZF55
print(f"Verifier: {ppu.verifier}")      # K
print(f"Complete: {ppu.complete}")      # PHZF55-K

CMF API Client

To use the CMF API, you need an API key. You can request one at CMF Chile.

from cl_forge.cmf import CmfClient

client = CmfClient(api_key="your_api_key_here")

# Get IPC data
ipc_data = client.get(path="/ipc")
print(ipc_data) # {'IPCs': [{'Valor': '-0,2', 'Fecha': '2025-12-01'}]}

See the CMF API documentation for details about the available endpoints.

Development

This project uses maturin to build the Rust extension.

Setup

  1. Clone the repository:

    git clone https://github.com/mschiaff/cl-forge.git
    cd cl-forge
    
  2. Install development dependencies (using uv):

    uv sync --all-groups
    
  3. Build the Rust extension in develop mode:

    uv run maturin develop
    

Running Tests

uv run pytest

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

Project details


Download files

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

Source Distribution

cl_forge-0.2.0.tar.gz (34.5 kB view details)

Uploaded Source

Built Distributions

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

cl_forge-0.2.0-cp314-cp314-win_arm64.whl (2.6 MB view details)

Uploaded CPython 3.14Windows ARM64

cl_forge-0.2.0-cp314-cp314-win_amd64.whl (2.5 MB view details)

Uploaded CPython 3.14Windows x86-64

cl_forge-0.2.0-cp314-cp314-macosx_11_0_arm64.whl (3.0 MB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

cl_forge-0.2.0-cp314-cp314-macosx_10_12_x86_64.whl (3.1 MB view details)

Uploaded CPython 3.14macOS 10.12+ x86-64

cl_forge-0.2.0-cp313-cp313-win_arm64.whl (2.6 MB view details)

Uploaded CPython 3.13Windows ARM64

cl_forge-0.2.0-cp313-cp313-win_amd64.whl (2.5 MB view details)

Uploaded CPython 3.13Windows x86-64

cl_forge-0.2.0-cp313-cp313-macosx_11_0_arm64.whl (3.0 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

cl_forge-0.2.0-cp313-cp313-macosx_10_12_x86_64.whl (3.1 MB view details)

Uploaded CPython 3.13macOS 10.12+ x86-64

cl_forge-0.2.0-cp312-cp312-win_arm64.whl (2.6 MB view details)

Uploaded CPython 3.12Windows ARM64

cl_forge-0.2.0-cp312-cp312-win_amd64.whl (2.5 MB view details)

Uploaded CPython 3.12Windows x86-64

cl_forge-0.2.0-cp312-cp312-macosx_11_0_arm64.whl (3.0 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

cl_forge-0.2.0-cp312-cp312-macosx_10_12_x86_64.whl (3.1 MB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

cl_forge-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ x86-64

cl_forge-0.2.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (3.1 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ ARM64

File details

Details for the file cl_forge-0.2.0.tar.gz.

File metadata

  • Download URL: cl_forge-0.2.0.tar.gz
  • Upload date:
  • Size: 34.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0.tar.gz
Algorithm Hash digest
SHA256 f75ac02baab1681aa7e3748304ac2032042694914001c407f634584d838e79da
MD5 0c2f7ceb5d3ee729f68a37bdb841c783
BLAKE2b-256 5139de7348702095e4734d29b0ef0dc5dd6746b40a969555df564ff061fe9749

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp314-cp314-win_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp314-cp314-win_arm64.whl
  • Upload date:
  • Size: 2.6 MB
  • Tags: CPython 3.14, Windows ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp314-cp314-win_arm64.whl
Algorithm Hash digest
SHA256 c7872d99a9de6990753acccd320fd51b1f8830d9f6242059cb0e3baa2a3c92b8
MD5 ec336183619e24e92138b7565344403d
BLAKE2b-256 29121207a46c2d84012f9fcc0d8540b73e9f1332ba9ac86a4f9352f742e8ad76

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 2.5 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 a8d07655f73a310034a9a0d8c7b10c648472586e69597ac581f36aed3d0fb8b1
MD5 90cf5acdc2c1f84e1a6b563daa37e473
BLAKE2b-256 c25319e58b31416bb4a6de5e5b313324094f6bc5081a0e7e7fdc3b6df1d7769c

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp314-cp314-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.0 MB
  • Tags: CPython 3.14, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e434613d518f85eb42637df5d6ae553dae588e609c28e53f7a04320b8eaa5118
MD5 c543ac872bbedadcbed95ac657b5dbab
BLAKE2b-256 ca7e987e9963b84c90334f8538b06ccaa79f2f399b51e71f00373497f10dccb1

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp314-cp314-macosx_10_12_x86_64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp314-cp314-macosx_10_12_x86_64.whl
  • Upload date:
  • Size: 3.1 MB
  • Tags: CPython 3.14, macOS 10.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp314-cp314-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 758c60b04e9c5981552f6fde5c1358892545935d5a80bcc95b48d13e8767eefe
MD5 f9b85d6b18d6cb2db131bff6cc45e054
BLAKE2b-256 cf906485fdec7ea8e563eedb312116aac1a8394ce93c22923a6a81e834ef3db1

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp313-cp313-win_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp313-cp313-win_arm64.whl
  • Upload date:
  • Size: 2.6 MB
  • Tags: CPython 3.13, Windows ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp313-cp313-win_arm64.whl
Algorithm Hash digest
SHA256 b4a8e453e5b88f6d20621af0020b0ac9a77a39ff65e30a7f070b52da76a3f342
MD5 6ddbcc9d0cf3aa0d4f821dd68efdd86d
BLAKE2b-256 7fe05817bd93b5db453555684ef0bbaad837929777cfec82ea0c0d824c430b3d

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 2.5 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 6d645380c2ef22beebe6753c4559039c3b9d12e6b0fd19bc90cb4d9f6d33a3fb
MD5 7f96b0abcf4bf615a1ac2b2681149659
BLAKE2b-256 75c20e6c644e6bd622af54ed3f153baca29930f5d8dbec4448ac66ca15bdf637

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp313-cp313-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.0 MB
  • Tags: CPython 3.13, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 58b362ccdb34c3c9a829389c66a69c8f14058ff42e9bc140f3749e7c969cb648
MD5 0316fa673b283fe393bafbf8502e1dab
BLAKE2b-256 0ee5a59c6ba36dc8f7bec09a1f9fe16711c9b103e4d9ef16a032e32dd60d074b

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp313-cp313-macosx_10_12_x86_64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp313-cp313-macosx_10_12_x86_64.whl
  • Upload date:
  • Size: 3.1 MB
  • Tags: CPython 3.13, macOS 10.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp313-cp313-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 1ad44ec8e8800dfb5231fc34d33d978a440c9da661dc6418d5ee7345c9d6584f
MD5 eaacd1ecd56bbe6766c46c2706183c7a
BLAKE2b-256 14cbd389d778927c59bb61d93700b840596c1692cda95f85c9be10e52b00d6c3

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp312-cp312-win_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp312-cp312-win_arm64.whl
  • Upload date:
  • Size: 2.6 MB
  • Tags: CPython 3.12, Windows ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp312-cp312-win_arm64.whl
Algorithm Hash digest
SHA256 7881683454b1a9d910c21f02489078f37a14610153e61db3edb70a239ffd767b
MD5 dc3bdfdf53b5016d3833decc6ca29299
BLAKE2b-256 4db584e30be13b96658c39a21854a79a0820b376cf402f73e7657ae05039354f

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 2.5 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 ce349034fcfc7b62035010842d025da611ac9cefb056d1191dda8df673a0cff5
MD5 36fbec16be68106ef9a5865498dca2cc
BLAKE2b-256 06f689bc9be0bf9ba2b90e530735350f0f2aadbee00f103a3007c43f03051b23

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp312-cp312-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.0 MB
  • Tags: CPython 3.12, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 05a6f3d99da41402404416f1cbbe6b45584424eb2e27ca645f32a35473991b02
MD5 21061d0f068a2a79d486042511ce07bd
BLAKE2b-256 b37df1db3eff7326c8184db80ead9ef4ced2ee614ed1fc1c46b89298f6787d1d

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp312-cp312-macosx_10_12_x86_64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp312-cp312-macosx_10_12_x86_64.whl
  • Upload date:
  • Size: 3.1 MB
  • Tags: CPython 3.12, macOS 10.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 e9d3110bdf65e3732540054a98817b02c5f18ad2d6f1082be5bc418c50e84b6a
MD5 a4852d40045749daf96753bf2ae309ec
BLAKE2b-256 40047727ca7c680d93dbdf718056141a4092d12ab7aaccb0bed5bf4512c61bec

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 3.2 MB
  • Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e9ab67fbcafdcbf74d086f2db82c6cc76449b671f8f60dc6eb6eb28b7c2d592f
MD5 19b02f8e15101c419bb876155d8ce3d5
BLAKE2b-256 1a6da7cb81f565d96b4d2cf297e788636fe5297b0b34b41d81789256f07e53fd

See more details on using hashes here.

File details

Details for the file cl_forge-0.2.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

  • Download URL: cl_forge-0.2.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
  • Upload date:
  • Size: 3.1 MB
  • Tags: CPython 3.8, manylinux: glibc 2.17+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.24 {"installer":{"name":"uv","version":"0.9.24","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for cl_forge-0.2.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 cefdb2a3ff342b87f43e482c112d258186640fa7593ebcd57698d8ee34a57f88
MD5 73bfa15fee7d0a3d55c26b5381fbd7ec
BLAKE2b-256 f06c287113645dea64216422d9eaf73b212de6fbb71afb23c9d90389cbf731c7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page