Instructions to use as-krn/quantum_programming_llama-3-8b-gguf with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use as-krn/quantum_programming_llama-3-8b-gguf with Transformers:
# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("as-krn/quantum_programming_llama-3-8b-gguf", dtype="auto") - llama-cpp-python
How to use as-krn/quantum_programming_llama-3-8b-gguf with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="as-krn/quantum_programming_llama-3-8b-gguf", filename="unsloth.F16.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use as-krn/quantum_programming_llama-3-8b-gguf with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf as-krn/quantum_programming_llama-3-8b-gguf:F16 # Run inference directly in the terminal: llama-cli -hf as-krn/quantum_programming_llama-3-8b-gguf:F16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf as-krn/quantum_programming_llama-3-8b-gguf:F16 # Run inference directly in the terminal: llama-cli -hf as-krn/quantum_programming_llama-3-8b-gguf:F16
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf as-krn/quantum_programming_llama-3-8b-gguf:F16 # Run inference directly in the terminal: ./llama-cli -hf as-krn/quantum_programming_llama-3-8b-gguf:F16
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf as-krn/quantum_programming_llama-3-8b-gguf:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf as-krn/quantum_programming_llama-3-8b-gguf:F16
Use Docker
docker model run hf.co/as-krn/quantum_programming_llama-3-8b-gguf:F16
- LM Studio
- Jan
- Ollama
How to use as-krn/quantum_programming_llama-3-8b-gguf with Ollama:
ollama run hf.co/as-krn/quantum_programming_llama-3-8b-gguf:F16
- Unsloth Studio
How to use as-krn/quantum_programming_llama-3-8b-gguf with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for as-krn/quantum_programming_llama-3-8b-gguf to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for as-krn/quantum_programming_llama-3-8b-gguf to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for as-krn/quantum_programming_llama-3-8b-gguf to start chatting
- Atomic Chat new
- Docker Model Runner
How to use as-krn/quantum_programming_llama-3-8b-gguf with Docker Model Runner:
docker model run hf.co/as-krn/quantum_programming_llama-3-8b-gguf:F16
- Lemonade
How to use as-krn/quantum_programming_llama-3-8b-gguf with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull as-krn/quantum_programming_llama-3-8b-gguf:F16
Run and chat with the model
lemonade run user.quantum_programming_llama-3-8b-gguf-F16
List all available models
lemonade list
Uploaded model
- Developed by: as-krn
- License: apache-2.0
- Finetuned from model : unsloth/llama-3-8b-Instruct-bnb-4bit
This llama model was trained 2x faster with Unsloth and Huggingface's TRL library.
Description:
This is a fine-tuned LLaMA-3 model specialized in quantum computing and programming concepts. It can answer technical questions, explain quantum algorithms, and assist with complex theoretical concepts.
Use Cases:
Learning and research in quantum computing
Generating explanations for quantum algorithms
Assisting in quantum programming education
Limitations:
May produce incorrect or incomplete explanations
Not a replacement for expert knowledge
# Example usage of the Quantum Programming LLaMA-3 8B GGUF model with llama_cpp
from llama_cpp import Llama
# 1️⃣ Set the local path to the downloaded GGUF model
MODEL_PATH = "unsloth.Q4_K_M.gguf"
# 2️⃣ Load the model
llm = Llama(
model_path=MODEL_PATH,
n_ctx=2048, # context length
n_threads=8, # number of CPU threads
n_gpu_layers=0 # set >0 if you have GPU layers
)
# 3️⃣ Function to get a response from the model
def generate_response(prompt: str) -> str:
output = llm(prompt, max_tokens=300, temperature=0.7)
return output["choices"][0]["text"].strip()
# 4️⃣ Example complex question in English
question = (
"Explain in detail the fundamental differences between quantum computers "
"and classical computers, including how quantum algorithms like Shor's "
"and Grover's algorithm work, and discuss the potential advantages and "
"limitations of quantum computing in real-world applications."
)
# 5️⃣ Get the model's answer
answer = generate_response(question)
print(answer)
Example Question & Response
Question:
"Explain in detail the fundamental differences between quantum computers
and classical computers, including how quantum algorithms like Shor's
and Grover's algorithm work, and discuss the potential advantages and
limitations of quantum computing in real-world applications."
Response:
Quantum computers fundamentally differ from classical computers in their processing mechanism and capabilities. Classical computers use bits (0 or 1) to process information, whereas quantum computers use qubits (0, 1, or both simultaneously) to process information. This is because qubits exist in a superposition state, allowing them to process multiple possibilities simultaneously.
Quantum computers also employ quantum teleportation, entanglement, and other quantum phenomena to perform computations. For example, Shor's algorithm uses quantum parallelism to factor large numbers exponentially faster than classical algorithms. Grover's algorithm, on the other hand, uses the quantum version of the Fibonacci sequence to find a specific item in an unsorted database in O(sqrt(n)) time, compared to O(n) for classical algorithms.
In terms of real-world applications, quantum computing has significant potential advantages in areas like cryptography, optimization problems, and machine learning. For example, quantum computers could potentially break certain types of encryption, but they could also be used to create unbreakable quantum keys for secure communication.
However, there are significant limitations to quantum computing. The qubits' superposition is lost if they interact with their environment, and the fragile nature of qubits makes them prone to errors. These limitations are mitigated by using quantum error correction techniques and developing more robust quantum gates.
It is also important to note that the current state of quantum computing is in its infancy, with most quantum computers being small-scale and noisy.
- Downloads last month
- 417
4-bit
16-bit
Model tree for as-krn/quantum_programming_llama-3-8b-gguf
Base model
unsloth/llama-3-8b-Instruct-bnb-4bit