Skip to content

Instantly share code, notes, and snippets.

@salvatorecapolupo
Created August 18, 2025 11:19
Show Gist options
  • Save salvatorecapolupo/8f2915059b4ffcbbf47a8c2c032ed961 to your computer and use it in GitHub Desktop.
Save salvatorecapolupo/8f2915059b4ffcbbf47a8c2c032ed961 to your computer and use it in GitHub Desktop.
A Llama-3.1-8B-Instruct basic demo in Python
# Requires: pip install regolo
import os
import regolo
# --- Configuration ---------------------------------------------------------
API_KEY = "sk-123456" # fake, replace with your own regolo.ai key
# Choose a LLaMA model identifier (change if you prefer a different variant)
regolo.default_key = API_KEY
regolo.default_model = "Llama-3.1-8B-Instruct" # Llama model
# --- Simple completion (non-chat) -----------------------------------------
resp = regolo.static_completions(
prompt="Summarise the main advantages of transformer models in production.",
max_tokens=120,
temperature=0.2
)
print("=== Completion (static_completions) ===")
print(resp)
print()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment