Instructions to use Team-Aiko/TeamAiko-GPT-Neo-1.3B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Team-Aiko/TeamAiko-GPT-Neo-1.3B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Team-Aiko/TeamAiko-GPT-Neo-1.3B")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Team-Aiko/TeamAiko-GPT-Neo-1.3B") model = AutoModelForCausalLM.from_pretrained("Team-Aiko/TeamAiko-GPT-Neo-1.3B", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Team-Aiko/TeamAiko-GPT-Neo-1.3B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Team-Aiko/TeamAiko-GPT-Neo-1.3B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Team-Aiko/TeamAiko-GPT-Neo-1.3B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Team-Aiko/TeamAiko-GPT-Neo-1.3B
- SGLang
How to use Team-Aiko/TeamAiko-GPT-Neo-1.3B 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 "Team-Aiko/TeamAiko-GPT-Neo-1.3B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Team-Aiko/TeamAiko-GPT-Neo-1.3B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "Team-Aiko/TeamAiko-GPT-Neo-1.3B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Team-Aiko/TeamAiko-GPT-Neo-1.3B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Team-Aiko/TeamAiko-GPT-Neo-1.3B with Docker Model Runner:
docker model run hf.co/Team-Aiko/TeamAiko-GPT-Neo-1.3B
TeamAiko-GPT-Neo-1.3B
This is the TeamAiko-GPT-Neo-1.3B model, a customized version of the EleutherAI/gpt-neo-1.3B model. This model has been branded and configured for use by Team Aiko. Note: This is the base version of the model and has not been trained on any specific datasets.
Model Details
- Model Name: TeamAiko-GPT-Neo-1.3B
- Base Model: EleutherAI/gpt-neo-1.3B
- Architecture: GPT-Neo
- Parameters: 1.3 billion
- Tokenizer: AutoTokenizer
- Framework: PyTorch
Usage
To use this model, you can load it with the transformers library:
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
# Path to the model folder
model_path = "Team-Aiko/TeamAiko-GPT-Neo-1.3B"
# Set device to CPU to limit RAM usage
device = torch.device("cpu")
torch.set_num_threads(4) # Limit the number of threads used by PyTorch
# Load tokenizer and model
tokenizer = AutoTokenizer.from_pretrained(model_path)
model = AutoModelForCausalLM.from_pretrained(model_path)
model.to(device) # Move model to CPU
# Test the model with a sample input
input_text = "Once upon a time in a land far, far away"
inputs = tokenizer(input_text, return_tensors="pt").to(device)
outputs = model.generate(inputs["input_ids"], max_length=50, num_return_sequences=1, no_repeat_ngram_size=2, early_stopping=True)
generated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
print("Generated text:", generated_text)
- Downloads last month
- 12