Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chezou/prelims-cli
https://github.com/chezou/prelims-cli
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/chezou/prelims-cli
- Owner: chezou
- License: mit
- Created: 2022-01-24T04:49:38.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2022-01-26T17:54:36.000Z (almost 3 years ago)
- Last Synced: 2024-11-16T15:21:14.761Z (2 months ago)
- Language: Python
- Size: 67.4 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# prelims-cli
CLI for [prelims](https://github.com/takuti/prelims).
## Install
Run:
```sh
pip install prelims-cli
```If you need Japanese tokenization, run:
```sh
pip install prelims-cli[ja]
```## Usage
Assuming the following folder directory:
```sh
- 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:
```myconfig.yaml
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
``````sh
$ 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.