A CLI tool for interacting with the Shaped API.
Project description
Shaped CLI
CLI for interactions with the Shaped API.
Installing the Shaped CLI
pip install shaped
Initialize
shaped init --api-key <API_KEY>
Model API
Create Model (File)
shaped create-model --file <PATH_TO_FILE>
Create Model (STDIN)
cat $(PATH_TO_FILE) | shaped create-model
List Models
shaped list-models
View Model
shaped view-model --model-name <MODEL_NAME>
Delete Model
shaped delete-model --model-name <MODEL_NAME>
Dataset API
Create Dataset
shaped create-dataset --file <PATH_TO_FILE>
List Datasets
shaped list-datasets
Dataset Insert
shaped dataset-insert --dataset-name <DATASET_NAME> --file <DATAFRAME_FILE> --type <FILE_TYPE>
Delete dataset
shaped delete-dataset --dataset-name <DATASET_NAME>
Rank API
Rank
shaped rank --model-name <MODEL_NAME> --user-id <USER_ID>
Similar Items
shaped similar --model-name <MODEL_NAME> --item-id <ITEM_ID>
Similar Users
shaped similar --model-name <MODEL_NAME> --user-id <USER_ID>
Development
Installing the Shaped CLI from Test PyPI
Upon all pushes to main branch, a new version of the CLI is published to Test PyPI. To install the latest version of the CLI from Test PyPI, run the following commands:
conda create -n cli-dev python=3.9
conda activate cli-dev
export PACKAGE_VERSION={} # Specify the version you want to install
pip install --extra-index-url https://test.pypi.org/simple/ shaped-cli==$PACKAGE_VERSION
Releasing a new CLI version to PyPI
To release a new version of the CLI to PyPI, open a PR changing the version of the package in setup.py
, following Semantic Versioning principles, e.g. 0.1.1
.
CircleCI will generate an approval prompt when this branch is merged to main, and upon approval will publish to PyPI.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
shaped-0.7.0.tar.gz
(4.1 kB
view details)
Built Distribution
File details
Details for the file shaped-0.7.0.tar.gz
.
File metadata
- Download URL: shaped-0.7.0.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.17
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9c0d74adfd0788c1ea26f7b18e10daed22f311ad55c5cf204d8f396a2bc1dcd0 |
|
MD5 | 22dfa112f31cc1f6f7bc1cd05ee89519 |
|
BLAKE2b-256 | 546e596c08f7ed48d245591817183984eea8b5af044bbb56e346263a7cd87f49 |
File details
Details for the file shaped-0.7.0-py3-none-any.whl
.
File metadata
- Download URL: shaped-0.7.0-py3-none-any.whl
- Upload date:
- Size: 4.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.17
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 52a686f62646a6336dff80c5dae0984168d6e1069fbfa1df9ef6372598b22c40 |
|
MD5 | 7e19e91a01b7fb51ece7afae050311ca |
|
BLAKE2b-256 | bbaba3b85499d18172547b94df364f9e4f903146f6b6476adcab4d37b4e92a79 |