This release is a pre-release and may not be stable for production use.
prelims-cli
CLI for prelims.
Install
Run:
pip install prelims-cli
If you need Japanese tokenization, run:
pip install prelims-cli[ja]
Usage
Assuming the following folder directory:
- content
| ├── post
| └── blog
└─ scripts
└ config
└ myconfig.yaml
where, post and blog are pages, and scripts is the place to put scripts.
Here is the example of configuration for the normal recommender:
handlers:
- target_path: "content/blog"
ignore_files:
- _index.md
processors:
- type: recommender
permalink_base: "/blog"
tfidf_options:
stop_words: english
max_df: 0.95
min_df: 2
tokenizer: null
- target_path: "content/post"
ignore_files:
- _index.md
processors:
- type: recommender
permalink_base: "/post"
tfidf_options:
max_df: 0.95
min_df: 2
tokenizer:
lang: ja
type: sudachi
mode: C
dict: full
Here is the example of configuration for the embedding-based recommender:
handlers:
- target_path: "content/blog"
ignore_files:
- _index.md
processors:
- permalink_base: "/blog"
type: embedding_recommender
language: en # Use onnx-community/granite-embedding-small-english-r2-ONNX
topk: 3
cache_db: ".prelims_embedding_cache_en.db"
- target_path: "content/post"
ignore_files:
- _index.md
processors:
- permalink_base: "/post"
type: embedding_recommender
language: ja # Use sirasagi62/ruri-v3-30m-ONNX
topk: 3
cache_db: ".prelims_embedding_cache_ja.db"
$ prelims-cli --config ./scripts/config/myconfig.yaml
target: /user/chezo/src/chezo.uno/content/blog
target: /users/chezo/src/chezo.uno/content/post
Then your articles' front matter were updated.
Articles whose front matter did not change are left untouched, and updated ones are written in block style:
tags:
- AI
- Hugo
This keeps the output stable across runs, so a CMS or an editor writing the same style does not produce a diff on every run.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file prelims_cli-0.0.7rc1.tar.gz.
File metadata
- Download URL: prelims_cli-0.0.7rc1.tar.gz
- Upload date:
- Size: 87.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5507629cd2a82f0bf8fd6e0b713419e295beef6abc0c98a3b250c3c892764ce1
|
|
| MD5 |
4f30bcab1273421c963cdb569a9a8bba
|
|
| BLAKE2b-256 |
b6a61fd5d03edfc2ef692727801cbba2e6e1c6be74b51a250074fc5c18f0165d
|
Provenance
The following attestation bundles were made for prelims_cli-0.0.7rc1.tar.gz:
Publisher:
release.yml on chezou/prelims-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
prelims_cli-0.0.7rc1.tar.gz -
Subject digest:
5507629cd2a82f0bf8fd6e0b713419e295beef6abc0c98a3b250c3c892764ce1 - Sigstore transparency entry: 2333039177
- Sigstore integration time:
-
Permalink:
chezou/prelims-cli@b03adab3d1ff3e8c30a3cb06d74afcdec672ed96 -
Branch / Tag:
refs/tags/v0.0.7rc1 - Owner: https://github.com/chezou
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@b03adab3d1ff3e8c30a3cb06d74afcdec672ed96 -
Trigger Event:
release
-
Statement type:
File details
Details for the file prelims_cli-0.0.7rc1-py3-none-any.whl.
File metadata
- Download URL: prelims_cli-0.0.7rc1-py3-none-any.whl
- Upload date:
- Size: 13.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b94408a8b9ad9b4467f9baa5e143a061e451361d96711741942e76603f7d4593
|
|
| MD5 |
07387b09396cc2cac7a826ce32c4bdf6
|
|
| BLAKE2b-256 |
7e2aa245d9bea16649ed846d018e37aa8f77d0de9239ffa4b4ad62aa6198f1c3
|
Provenance
The following attestation bundles were made for prelims_cli-0.0.7rc1-py3-none-any.whl:
Publisher:
release.yml on chezou/prelims-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
prelims_cli-0.0.7rc1-py3-none-any.whl -
Subject digest:
b94408a8b9ad9b4467f9baa5e143a061e451361d96711741942e76603f7d4593 - Sigstore transparency entry: 2333039188
- Sigstore integration time:
-
Permalink:
chezou/prelims-cli@b03adab3d1ff3e8c30a3cb06d74afcdec672ed96 -
Branch / Tag:
refs/tags/v0.0.7rc1 - Owner: https://github.com/chezou
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@b03adab3d1ff3e8c30a3cb06d74afcdec672ed96 -
Trigger Event:
release
-
Statement type: