Skip to main content

A personal chat agent CLI using Together AI via AirTrain

Project description

Chat Agent CLI

A personal chat agent that interfaces with Together AI through the AirTrain module. This CLI application allows you to have conversations with AI models and stores your chat history locally.

Features

  • Interactive chat with AI powered by Together AI
  • Local storage of chat history
  • Easy-to-use command-line interface
  • Session management (start new chats, continue previous ones)

Installation

From Source

# Clone the repository
git clone https://github.com/your-repo/airtrain.git
cd airtrain/examples/apps/cli/trmx_agent

# Install the package
pip install -e .

From PyPI

pip install trmx

Usage

After installation, you can use the chat agent with the following commands:

# Start a new chat session
trmx

# List previous chat sessions
trmx --list

# Continue a previous session (multiple ways):
trmx 92f31c          # Using a partial session ID directly
trmx 92              # Even just a few characters will work
trmx --continue 92   # Using the --continue or -c flag
trmx -c 92           # Short form

# Show storage info
trmx --info

# Show help
trmx --help

# Show version
trmx --version

# Update to the latest version
trmx --update

# List available providers
trmx --list-providers

# List available models for the current provider
trmx --list-models

# List models for a specific provider
trmx --list-models --provider openai

# Set a specific provider and model for a single chat session
trmx --provider fireworks --model fireworks/deepseek-r1

# Configure a new provider/model as the default
trmx --add --provider openai --model gpt-4

Configuration

The chat agent can be configured using environment variables:

  • TRMX_DIR: Path to store chat history, credentials, and configuration (default: ~/.trmx)
  • Various API keys like TOGETHER_API_KEY, OPENAI_API_KEY, etc. for the providers you want to use

You can set these in your shell or create a .env file in your working directory.

Credentials are loaded in the following order:

  1. From environment variables
  2. From the credentials files in ~/.trmx/credentials/
  3. If not found, the CLI will prompt you to enter your API key and offer to save it

Requirements

  • Python 3.8 or higher
  • airtrain package
  • Internet connection for AI model access

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

trmx-0.3.2.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

trmx-0.3.2-py3-none-any.whl (17.2 kB view details)

Uploaded Python 3

File details

Details for the file trmx-0.3.2.tar.gz.

File metadata

  • Download URL: trmx-0.3.2.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.4

File hashes

Hashes for trmx-0.3.2.tar.gz
Algorithm Hash digest
SHA256 076680770f429a8e8682b828fa01f3c8064980b441317d633b910b9641b4d41a
MD5 d7f9e65ec5493cbab24b3d8af5c8a84d
BLAKE2b-256 414bbdfdc0f5ab1476626dc29282d5d652ae8b711a3a4f96729508ed973e7194

See more details on using hashes here.

File details

Details for the file trmx-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: trmx-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 17.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.4

File hashes

Hashes for trmx-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 fa96799a272cd35ed4669afa640a66068c1c43975d8b490e5ffef8674f358aa6
MD5 4ea139335739b44f824f146cd42252d2
BLAKE2b-256 4ef2b61fb496f96c3b8b60de03d238b26b475a15527e1b88dbd9f1ec2a8b5cc2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page