Skip to content

kili

Kili Command line Interface

To get all the available commands, please type: kili project --help.

Usage:

kili [OPTIONS] COMMAND [ARGS]...

Options:

Name Type Description Default
--version boolean Show the version and exit. False
--help boolean Show this message and exit. False

project

Commands to interact with a Kili project

Usage:

kili project [OPTIONS] COMMAND [ARGS]...

Options:

Name Type Description Default
--help boolean Show this message and exit. False

create-project

Create a Kili project

interface must be a path pointing to your json interface file

If no interface is provided, --from-project can be used to create a new project with the json_interface of another project (assets will not be copied).

Examples

kili project create \
     path/to/interface.json \
    --input-type TEXT \
    --title "Invoice annotation project"
kili project create \
    --from-project <project_id_src> \
    --input-type TEXT \
    --title "Invoice annotation project"

To build a Kili project interface, please visit:

https://docs.kili-technology.com/docs/customizing-the-interface-through-json-settings

Usage:

kili project create-project [OPTIONS] [INTERFACE]

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--from-project text project_id of another Kili project None
--title text Project Title. _required
--input-type choice (AUDIO | FRAME | IMAGE | PDF | TEXT | TIME_SERIES | VIDEO | VIDEO_LEGACY) Project input data type. Please check your license to see which ones you have access to. _required
--description text Project description. ``
--stdout-format text Defines how the output table is formatted (see https://pypi.org/project/tabulate/, default: plain). plain
--help boolean Show this message and exit. False

describe-project

Show project description and analytics.

Examples

kili project describe --project-id <project_id>

Usage:

kili project describe-project [OPTIONS] PROJECT_ID

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--help boolean Show this message and exit. False

import-assets

Add assets into a project

Files can be paths to files or to folders. You can provide several paths separated by spaces.

If no Files are provided, --from-csv can be used to import assets from a CSV file with two columns:

  • external_id: external id of the asset.
  • content: paths to the asset file or a url hosting the asset.

Examples

kili project import \
    dir1/dir2/ dir1/dir3/test1.png \
    --project-id <project_id>
kili project import \
    dir1/dir3/video.mp4 \
    --project-id <project_id> \
    --frames \
    --fps 24
kili project import \
    --from-csv assets_list.csv \
    --project-id <project_id> \
    --frames \
    --fps 24

Unsupported imports

Currently, this command does not support:

  • the import of videos from local frames, rich text and time series assets
  • the import of assets with metadata or with a custom external_id

For such imports, please use the append_many_to_dataset method in the Kili SDK.

Usage:

kili project import-assets [OPTIONS] [FILES]...

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--project-id text Id of the project _required
--from-csv path path to a csv file with required columns:external_id, content required columns: None
--frames boolean Only for a frame project, import videos as frames. The import time is longer with this option. False
--fps integer Only for a frame project, import videos with a specific frame rate None
--verbose boolean Show logs False
--help boolean Show this message and exit. False

import-labels

Import labels or predictions

The labels to import have to be in the Kili format and stored in a json file. Labels to import are provided in a CSV file with two columns: - external_id: external id for which you want to import labels. - json_response_path: paths to the json files containing the json_response to upload.

CSV file template

external_id,json_response_path
asset1,./labels/label_asset1.json
asset2,./labels/label_asset2.json

Examples

To import default labels:

kili project label \
    --from-csv path/to/file.csv \
    --project-id <project_id>
To import labels as predictions:
kili project label \
    --from-csv path/to/file.csv \
    --project-id <project_id> \
    --prediction \
    --model-name YOLO-run-3

Usage:

kili project import-labels [OPTIONS]

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--from-csv path path to a csv file with required columns:external_id, json_response_path required columns: _required
--project-id text Id of the project _required
--prediction boolean Tells to import labels as predictions, which means that they will appear as pre-annotations in the Kili interface False
--model-name text Name of the model that generated predictions, if labels are sent as predictions None
--help boolean Show this message and exit. False

list-projects

List your projects

Examples

kili project list --max 10 --stdout-format pretty

Usage:

kili project list-projects [OPTIONS]

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--stdout-format text Defines how the output table is formatted (see https://pypi.org/project/tabulate/, default: plain). plain
--max integer Maximum number of project to display. 100
--help boolean Show this message and exit. False

member

Commands to interact with Kili project members

Usage:

kili project member [OPTIONS] COMMAND [ARGS]...

Options:

Name Type Description Default
--help boolean Show this message and exit. False

add-member

Add members to a Kili project

Emails can be passed directly as arguments. You can provide several emails separated by spaces.

Examples

kili project member add \
    --project-id <project_id> \
    --role REVIEWER \
    john.doe@test.com jane.doe@test.com
kili project member add \
    --project-id <project_id> \
    --from-csv path/to/members.csv
kili project member add \
    --project-id <project_id> \
    --from-project <project_id_scr>

Usage:

kili project member add-member [OPTIONS] [EMAILS]...

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--project-id text Id of the project to add members to _required
--role choice (ADMIN | TEAM_MANAGER | REVIEWER | LABELER) Project role of the added user(s). None
--from-csv path path to a csv file with 'email' header, optionnal header 'role' can be use. None
--from-project text project_id of another Kili project to copy the users from None
--help boolean Show this message and exit. False

list-members

List the members of the project

Examples

kili project member list --project-id <project_id> --stdout-format pretty

Usage:

kili project member list-members [OPTIONS]

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--project-id text Id of the project to list members of _required
--stdout-format text Defines how the output table is formatted (see https://pypi.org/project/tabulate/, default: plain). plain
--help boolean Show this message and exit. False

remove-member

Remove members from a Kili project

Emails can be passed directly as arguments. You can provide several emails separated by spaces.

Examples

kili project member rm \
    --project-id <project_id> \
    john.doe@test.com
kili project member rm \
    --project-id <project_id> \
    --from-csv path/to/members.csv
kili project member rm \
    --project-id <project_id> \
    --all

Usage:

kili project member remove-member [OPTIONS] [EMAILS]...

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--project-id text Id of the project to add members to _required
--from-csv path path to a csv file with email in the first column None
--all boolean Remove all users from project False
--help boolean Show this message and exit. False

update-member

Update member's role of a Kili project

Emails can be passed directly as arguments. You can provide several emails separated by spaces.

Examples

kili project member update\
    --project-id <project_id> \
    --role REVIEWER \
    john.doe@test.com
kili project member update \
    --project-id <project_id> \
    --from-csv path/to/members.csv
kili project member update \
    --project-id <project_id> \
    --from-project <project_id_scr>

Usage:

kili project member update-member [OPTIONS] [EMAILS]...

Options:

Name Type Description Default
--api-key text Your Kili API key. None
--endpoint text Kili API Endpoint. None
--project-id text Id of the project to add members to _required
--role choice (ADMIN | TEAM_MANAGER | REVIEWER | LABELER) Project role of the added user(s). None
--from-csv path path to a csv file with email in the first column. A second column can be used to use one-to-one role. None
--from-project text project_id of another Kili project to copy the users from None
--help boolean Show this message and exit. False