basetenlabs / truss-examples

Examples of models deployable with Truss
https://trussml.com
MIT License
143 stars 37 forks source link

[Droid] Add Truss Example for Databricks DBRX-Instruct Model #264

Open factory-droid[bot] opened 7 months ago

factory-droid[bot] commented 7 months ago
Rotor

Summary of Changes

This PR introduces a new Truss example for the Databricks DBRX-Instruct model. The new example includes a directory structure, a populated config.yaml file, implemented model loading and prediction code, and a README file. The config.yaml file specifies the model name, Python version, required Python packages, and resource requirements. The model.py file includes the Model class with methods for loading the model, preprocessing input, generating predictions, and postprocessing output. The README provides an overview of the model, deployment instructions, API documentation, and example usage. All changes have been validated and all unit tests have passed.

Fixes BT-10525

Tips

linear[bot] commented 7 months ago

BT-10525 create dbrx truss

factory-droid[bot] commented 7 months ago

[!IMPORTANT]

Solutions for GitHub Action Failures - 88f33e41edac2430eb5be95a15935b7fda7151d7 - 1

PR

To fix the error, ensure that all files in the repository do not contain trailing whitespace before committing changes. This can be done by running the trim command in a Unix-like environment or using an Integrated Development Environment (IDE) that automatically removes trailing whitespace. Here is an example of how to trim trailing whitespace using the sed command in Unix:

sed -i 's/[ \t]*$//' mistral/mixtral-8x22b/README.md

This command will remove trailing whitespace from the mistral/mixtral-8x22b/README.md file. You should run a similar command for all files in your repository before committing changes.

Details The `poetry run pre-commit run --all-files` command failed due to trailing whitespace in some files. This resulted in modifications by the pre-commit hook, causing the process to exit with code 1. The file that was modified by the hook is `mistral/mixtral-8x22b/README.md`. The unified diff does not show any changes in this file, which means the trailing whitespace was likely removed by the pre-commit hook. To prevent this issue in the future, ensure that all files in the repository do not contain trailing whitespace before committing changes.