### Install development dependencies with pip Source: https://github.com/fnnx-ai/scikit-llm/blob/main/CONTRIBUTING.md Run this command to install all development dependencies required for contributing to Scikit-LLM. ```shell pip install -r requirements-dev.txt ``` -------------------------------- ### Setup pre-commit hooks Source: https://github.com/fnnx-ai/scikit-llm/blob/main/CONTRIBUTING.md Run this command to set up pre-commit hooks as part of the development workflow. ```shell pre-commit install ``` -------------------------------- ### Install Scikit-LLM with pip Source: https://github.com/fnnx-ai/scikit-llm/blob/main/README.md Install the scikit-llm package using pip. ```bash pip install scikit-llm ``` -------------------------------- ### Zero-shot text classification with GPT using ZeroShotGPTClassifier Source: https://github.com/fnnx-ai/scikit-llm/blob/main/README.md Configure OpenAI credentials via SKLLMConfig, load a demo dataset, and train a ZeroShotGPTClassifier with model='gpt-4' to predict labels (positive, negative, neutral). ```python # Import the necessary modules from skllm.datasets import get_classification_dataset from skllm.config import SKLLMConfig from skllm.models.gpt.classification.zero_shot import ZeroShotGPTClassifier # Configure the credentials SKLLMConfig.set_openai_key("") SKLLMConfig.set_openai_org("") # Load a demo dataset X, y = get_classification_dataset() # labels: positive, negative, neutral # Initialize the model and make the predictions clf = ZeroShotGPTClassifier(model="gpt-4") clf.fit(X,y) clf.predict(X) ``` -------------------------------- ### Cite Scikit-LLM with BibTeX Source: https://github.com/fnnx-ai/scikit-llm/blob/main/README.md BibTeX entry for citing Scikit-LLM in academic publications. ```bibtex @software{ScikitLLM, author = {Iryna Kondrashchenko and Oleh Kostromin}, year = {2023}, publisher = {beastbyte.ai}, address = {Linz, Austria}, title = {Scikit-LLM: Scikit-Learn Meets Large Language Models}, url = {https://github.com/iryna-kondr/scikit-llm } } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.