Instructions to use Crystalcareai/CrystalMistral with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Crystalcareai/CrystalMistral with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Crystalcareai/CrystalMistral") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Crystalcareai/CrystalMistral") model = AutoModelForCausalLM.from_pretrained("Crystalcareai/CrystalMistral") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use Crystalcareai/CrystalMistral with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Crystalcareai/CrystalMistral" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Crystalcareai/CrystalMistral", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Crystalcareai/CrystalMistral
- SGLang
How to use Crystalcareai/CrystalMistral with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Crystalcareai/CrystalMistral" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Crystalcareai/CrystalMistral", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Crystalcareai/CrystalMistral" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Crystalcareai/CrystalMistral", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Crystalcareai/CrystalMistral with Docker Model Runner:
docker model run hf.co/Crystalcareai/CrystalMistral
YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
CrystalMistral: A Potent Language Model Fine-Tuned on a Curated Blend of Data
Overview
CrystalMistral is a highly refined language model derived from the esteemed Mistral-7B architecture. To unlock its exceptional capabilities, CrystalMistral underwent meticulous fine-tuning on a meticulously curated dataset comprised of:
Evol-Instruct: A rich dataset emphasizing instruction following and task completion, fostering CrystalMistral's ability to accurately execute complex commands. Airoboros: This extensive dataset is geared towards open-ended dialogue and generation, sharpening CrystalMistral's conversational aptitude and creativity. OpenOrca: A dataset specializing in code generation and understanding, significantly reinforcing CrystalMistral's programming prowess. Additional GPT-4 Synthetic Data: Incorporation of curated GPT-4 synthetic data further amplifies CrystalMistral's reasoning abilities and factual knowledge. Strengths
CrystalMistral exhibits a remarkable command of the following domains:
Instruction Following: Effectively interprets and carries out detailed instructions, demonstrating proficiency in task completion. Dialogue and Text Generation: Engages in fluid and nuanced conversations, offering creative and compelling text generation capabilities. Coding: Exhibits advanced understanding of code, capable of generating functional code, translating between languages, and offering explanations.
Future Development
The CrystalMistral project endeavors to:
Expert Fine-Tuning: Explore additional fine-tuning with datasets specializing in specific areas (e.g., scientific literature, legal documents) to create targeted variants of CrystalMistral. Mixture of Experts (MoE): Transition to a 4x MoE architecture, enabling CrystalMistral to dynamically specialize in distinct tasks, significantly amplifying its efficiency and potential.
- Downloads last month
- 9
docker model run hf.co/Crystalcareai/CrystalMistral