Command-line interface using GPT4ALL bindings
Project description
A simple GNU Readline-based application for interaction with chat-oriented AI models using GPT4All Python bindings.
Contents
Install
The following installation options are available:
Pip
$ pip install git+https://github.com/sergei-mironov/gpt4all-cli.git
Note: pip install gpt4all-cli
might also work, but the git+https
method would bring the most
recent version.
Nix
$ git clone --depth=1 https://github.com/sergei-mironov/gpt4all-cli && cd gpt4all-cli
# Optionally, change the 'nixpkgs' input of the flake.nix to a more suitable
$ nix profile install ".#python-gpt4all-cli"
Usage
usage: gpt4all-cli [-h] [--model MODEL] [--num-threads NUM_THREADS]
[--device DEVICE] [--readline-key-send READLINE_KEY_SEND]
[--readline-prompt READLINE_PROMPT] [--revision]
Command-line arguments
options:
-h, --help show this help message and exit
--model MODEL, -m MODEL
Model to use for chatbot
--num-threads NUM_THREADS, -t NUM_THREADS
Number of threads to use for chatbot
--device DEVICE, -d DEVICE
Device to use for chatbot, e.g. gpu, amd, nvidia,
intel. Defaults to CPU.
--readline-key-send READLINE_KEY_SEND
Terminal code to treat as Ctrl+Enter (default: \C-k)
--readline-prompt READLINE_PROMPT
Input prompt (default: >>>)
--revision Print the revision
Example session
$ gpt4all-cli
Type /help or a question followed by the /ask command (or by pressing `C-k` key).
>>> /model "~/.local/share/nomic.ai/GPT4All/Meta-Llama-3-8B-Instruct.Q4_0.gguf"
>>> Hi!
>>> /ask
Hello! I'm happy to help you. What's on your mind?^C
>>> What's your name?
>>> /ask
I don't really have a personal name, but you can call me "Assistant"
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
gpt4all_cli-1.0.2.tar.gz
(5.8 kB
view details)
Built Distribution
File details
Details for the file gpt4all_cli-1.0.2.tar.gz
.
File metadata
- Download URL: gpt4all_cli-1.0.2.tar.gz
- Upload date:
- Size: 5.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ddaa02be2c448e74207f18ddad0ac84206b9bcdf519333c160db74ae1b6a38ee |
|
MD5 | a609ad83f8a65b85276ef85d8d826772 |
|
BLAKE2b-256 | 716a9d3c9057de6d310d10c1a87da8cbd5867e8a8e9bdecf7765ced6e51a03e8 |
File details
Details for the file gpt4all_cli-1.0.2-py3-none-any.whl
.
File metadata
- Download URL: gpt4all_cli-1.0.2-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | be4fcd992ead48d3946e6bfcf0ab0bff15a7bd3a2f8cea3d5a52da64ae4ed6ad |
|
MD5 | 2e2aea42348464e9ef23066890a191b8 |
|
BLAKE2b-256 | f388b0d99323b9619e7759e73fb4b36083f510a276041551ebc8c589c1e7d678 |