Skip to main content

A flexible multimodal AI library

Project description

CapibaraENT CLI

Capibara SSBD Model

CapibaraENT is a command-line tool for training, evaluating, and deploying Capibara-based language models, optimized for TPUs and featuring hyperparameter optimization.

Features

  • Training and evaluation of Capibara models
  • Built-in TPU support
  • Hyperparameter optimization
  • Model deployment
  • Performance measurement
  • Docker container execution
  • Model deserialization from JSON
  • Integration with Weights & Biases for experiment tracking

Requirements

  • Python 3.7+
  • PyTorch 1.8+
  • PyTorch/XLA
  • JAX (for TPU optimization)
  • Weights & Biases
  • Docker (optional, for container execution)

Installation

  1. Clone this repository:

    git clone https://github.com/your-username/capibaraent-cli.git
    cd capibaraent-cli
    
  2. Install dependencies:

    pip install -r requirements.txt
    
  3. Set up Weights & Biases:

    wandb login
    

Usage

The CapibaraENT CLI offers various options for working with Capibara models:

python capibaraent_cli.py [options]

Available options:

  • --log-level: Logging level (DEBUG, INFO, WARNING, ERROR, CRITICAL)
  • --train: Train the model
  • --evaluate: Evaluate the model
  • --optimize: Perform hyperparameter optimization
  • --use-docker: Run the model inside Docker
  • --deserialize-model: Deserialize the model from JSON
  • --deploy: Deploy the model
  • --measure-performance: Measure the model's performance
  • --model: Path to the model JSON file (for deserialization)

Usage Examples

  1. Train a model:

    python capibaraent_cli.py --train
    
  2. Evaluate a model:

    python capibaraent_cli.py --evaluate
    
  3. Perform hyperparameter optimization:

    python optimize_hyperparameters.py
    
  4. Deploy a model:

    python capibaraent_cli.py --deploy
    
  5. Measure model performance:

    python capibaraent_cli.py --measure-performance
    
  6. Run a model in Docker:

    python capibaraent_cli.py --use-docker
    
  7. Deserialize and run a model from JSON:

    python capibaraent_cli.py --deserialize-model --model model.json
    

Configuration

Model configuration is handled through environment variables and the .env file. Key configuration parameters include:

  • CAPIBARA_LEARNING_RATE
  • CAPIBARA_BATCH_SIZE
  • CAPIBARA_MAX_LENGTH
  • CAPIBARA_USE_TPU
  • WANDB_PROJECT
  • WANDB_ENTITY

For a full list of configuration options, refer to the .env.example file.

Hyperparameter Optimization

To perform hyperparameter optimization:

  1. Ensure your Weights & Biases project is set up.

  2. Run the optimization script:

    python optimize_hyperparameters.py
    
  3. View the results in your Weights & Biases dashboard.

Development

To contribute to the project:

  1. Fork the repository
  2. Create a new branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Marco Durán - marco@anachroni.co

Project Link: https://github.com/anachroni-io/capibaraent-cli

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

capibara_ent-1.0.9.tar.gz (20.7 kB view details)

Uploaded Source

Built Distribution

capibara_ent-1.0.9-py3-none-any.whl (35.9 kB view details)

Uploaded Python 3

File details

Details for the file capibara_ent-1.0.9.tar.gz.

File metadata

  • Download URL: capibara_ent-1.0.9.tar.gz
  • Upload date:
  • Size: 20.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for capibara_ent-1.0.9.tar.gz
Algorithm Hash digest
SHA256 4b8605d5ca61ec8ee843c253e8da403ebe366ccc6f3fb3a30014e07581cce701
MD5 1770bd5f1b7fb0c1bf382792d953c4a6
BLAKE2b-256 299de5f5478584a912befa04f160ae88cd543ba6809b8c4c947442e17fd29833

See more details on using hashes here.

File details

Details for the file capibara_ent-1.0.9-py3-none-any.whl.

File metadata

  • Download URL: capibara_ent-1.0.9-py3-none-any.whl
  • Upload date:
  • Size: 35.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for capibara_ent-1.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 c09166b95f9c4763f74a110867518c7273872c23fc903d0869a0604cad36cb6f
MD5 25e1563ae64ce130346044b0051a46c8
BLAKE2b-256 0dce139199e54ad6bf4adde50628a05d2c5f530b060ec2472b1b96d61090cbc6

See more details on using hashes here.

Supported by

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