Instructions to use KnutJaegersberg/BuddhismModel with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use KnutJaegersberg/BuddhismModel with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf KnutJaegersberg/BuddhismModel # Run inference directly in the terminal: llama cli -hf KnutJaegersberg/BuddhismModel
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf KnutJaegersberg/BuddhismModel # Run inference directly in the terminal: llama cli -hf KnutJaegersberg/BuddhismModel
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf KnutJaegersberg/BuddhismModel # Run inference directly in the terminal: ./build/bin/llama cli -hf KnutJaegersberg/BuddhismModel
Use Docker
docker model run hf.co/KnutJaegersberg/BuddhismModel
- Llama new
- LM Studio
- Jan
- vLLM
How to use KnutJaegersberg/BuddhismModel with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "KnutJaegersberg/BuddhismModel" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "KnutJaegersberg/BuddhismModel", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/KnutJaegersberg/BuddhismModel
- Ollama
How to use KnutJaegersberg/BuddhismModel with Ollama:
ollama run hf.co/KnutJaegersberg/BuddhismModel
- Unsloth Desktop
- Docker Model Runner
How to use KnutJaegersberg/BuddhismModel with Docker Model Runner:
docker model run hf.co/KnutJaegersberg/BuddhismModel
- Lemonade
How to use KnutJaegersberg/BuddhismModel with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull KnutJaegersberg/BuddhismModel
Run and chat with the model
lemonade run user.BuddhismModel-{{QUANT_TAG}}List all available models
lemonade list
- Atomic Chat
Find the original model here:
https://huggingface.co/BRMAI/BRM-v1-llama8b
BuddhismModel
BuddhismModel is a pioneering Large Language Model that seamlessly integrates technology with spiritual wisdom. As the first AI framework of its kind, it breathes new life into centuries-old Buddhist teachings with remarkable precision and authenticity.
Specifically designed for contemporary practitioners, this model delivers personalized spiritual guidance and ethical insights while nurturing mindfulness and empathy throughout each interaction. Through regular dharma discussions, it facilitates both individual spiritual development and communal well-being, creating a unique space where ancient wisdom meets modern technology.
Model Description
The model is trained on Buddhist scriptures. The full training set (dataset.json) contains 160,000 instructions generated from 77,000 Buddhist sayings.
- Model type: Llama-3-based Buddhist role-play model
- Language(s): English
- Fine-tuned from model: Meta-Llama-3-8B-Instruct
Model Parameters
Initial parameters for our model using Base Meta-Llama-3-8B-Instruct are available for download in this repository. It was trained on December 4, 2024, using A800.
[Rest of the code sections remain correct as they follow proper Python syntax]
How to Get Started with the Model
import transformers
import torch
from huggingface_hub import login
login(token="your_huggingface_access_token")
from transformers import AutoTokenizer, AutoModelForCausalLM
model_name = "olmairesearch/olm-v1.0-8b"
tokenizer = AutoTokenizer.from_pretrained(model_name, token=True)
model = AutoModelForCausalLM.from_pretrained(
model_name, torch_dtype="auto", device_map="auto",token=True
)
def call_Buddhism(model, tokenizer, history, input_):
context = ""
for role, message in history:
context += f"{role}: {message}\n"
context += f"user: {input_}\nassistant:"
inputs = tokenizer(context, return_tensors="pt", truncation=True)
inputs = inputs.to("cuda" if torch.cuda.is_available() else "cpu")
outputs = model.generate(
**inputs,
max_new_tokens=256,
eos_token_id=tokenizer.eos_token_id,
do_sample=True,
temperature=0.6,
top_p=0.9,
)
generated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
response = generated_text[len(context):].strip()
return response
history = [
("user", "What is the purpose of life?"),
("assistant", "The purpose of life is to seek inner peace and happiness.")
]
input_ = "How can I achieve inner peace?"
response = call_Buddhism(model, tokenizer, history, user_input)
print("Buddha:", response)
Examples
input_: "How can I find happiness that lasts?"
output: "Happiness is not found in external things, but in the cultivation of your own mind. by letting go of attachments and desires, you can find a sense of peace and freedom."
input_: "What can I do for this?"
output: "You can start by letting go of attachments and desires. focus on the present moment and cultivate mindfulness."
input_: "how to cultivate mindfulness"
output: "mindfulness is the key to understanding the present moment. practice meditation and observe your thoughts and emotions without judgment."
input_: "meditation?"
output: "yes, meditation is a powerful tool to quiet the mind and connect with your true nature. but it's not just about sitting still, it's about cultivating mindfulness and compassion in every moment."
input_: "What should I think about when I sit quietly?"
output: "When you sit quietly, focus on your breath and let go of all thoughts and distractions. this will help you cultivate mindfulness and inner peace."
input_: "how many times should i spend on it?"
output: "It is not about the quantity of time, but the quality of attention. take a few moments each day to reflect on your thoughts and actions, and you will find that inner peace is always within reach."
- Downloads last month
- 20
We're not able to determine the quantization variants.
