Text Generation
PEFT
Safetensors
Transformers
qwen2
lora
coding
code-generation
conversational
text-generation-inference
Run this model with HF Jobs
Run girish00/ConicAI_LLM_model on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/girish00/ConicAI_LLM_model. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/girish00/ConicAI_LLM_model on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/girish00/ConicAI_LLM_model. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/girish00/ConicAI_LLM_model. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use girish00/ConicAI_LLM_model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use girish00/ConicAI_LLM_model with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-Coder-0.5B-Instruct") model = PeftModel.from_pretrained(base_model, "girish00/ConicAI_LLM_model") - Transformers
How to use girish00/ConicAI_LLM_model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="girish00/ConicAI_LLM_model") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("girish00/ConicAI_LLM_model") model = AutoModelForCausalLM.from_pretrained("girish00/ConicAI_LLM_model", device_map="auto") 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use girish00/ConicAI_LLM_model with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "girish00/ConicAI_LLM_model" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "girish00/ConicAI_LLM_model", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/girish00/ConicAI_LLM_model
- SGLang
How to use girish00/ConicAI_LLM_model 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 "girish00/ConicAI_LLM_model" \ --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": "girish00/ConicAI_LLM_model", "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 "girish00/ConicAI_LLM_model" \ --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": "girish00/ConicAI_LLM_model", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use girish00/ConicAI_LLM_model with Docker Model Runner:
docker model run hf.co/girish00/ConicAI_LLM_model
update endpoint helper files
Browse files285 unmodified lines2862872882892902912922932942952892902912922932942952962972982993003013023033042 unmodified lines30730830930430530630730830931031131231331431531631731031131231331431531631731831932032132232332432532632732832933033133233333422 unmodified lines357358359346347348349350360361362363364365366367368369370371285 unmodified lines parser.add_argument("--base-model", type=str, default="Qwen/Qwen2.5-Coder-0.5B-Instruct")
parser.add_argument("--prompt", type=str, required=True)
parser.add_argument("--max-new-tokens", type=int, default=320)
parser.add_argument("--temperature", type=float, default=0.25)
parser.add_argument("--top-p", type=float, default=0.9)
parser.add_argument("--do-sample", action="store_true")
args = parser.parse_args()
if not os.path.exists(args.model_path):
raise FileNotFoundError(
parser.add_argument("--temperature", type=float, default=0.25) parser.add_argument("--top-p", type=float, default=0.9) parser.add_argument("--do-sample", action="store_true") parser.add_argument( "--allow-downloads", action="store_true", help="Allow Transformers to download missing model files from Hugging Face.", ) args = parser.parse_args() local_files_only = not args.allow_downloads
if not os.path.exists(args.model_path): raise FileNotFoundError( f"Model path not found: {args.model_path}. Train first using run_pipeline.py."
)
2 unmodified lines full_model_weights_present = has_full_model_weights(args.model_path)
if os.path.exists(adapter_config_path) and adapter_weights_present:
peft_config = PeftConfig.from_pretrained(args.model_path)
base_model_name = peft_config.base_model_name_or_path or args.base_model
tokenizer = AutoTokenizer.from_pretrained(base_model_name)
base_model = AutoModelForCausalLM.from_pretrained(
base_model_name,
torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32,
)
model = PeftModel.from_pretrained(base_model, args.model_path)
elif full_model_weights_present and not os.path.exists(adapter_config_path):
tokenizer = AutoTokenizer.from_pretrained(args.model_path)
model = AutoModelForCausalLM.from_pretrained(
args.model_path,
torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32,
)
peft_config = PeftConfig.from_pretrained(args.model_path) base_model_name = peft_config.base_model_name_or_path or args.base_model tokenizer = AutoTokenizer.from_pretrained( base_model_name, local_files_only=local_files_only, ) base_model = AutoModelForCausalLM.from_pretrained( base_model_name, torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32, local_files_only=local_files_only, ) model = PeftModel.from_pretrained(base_model, args.model_path) elif full_model_weights_present and not os.path.exists(adapter_config_path): tokenizer = AutoTokenizer.from_pretrained( args.model_path, local_files_only=local_files_only, ) model = AutoModelForCausalLM.from_pretrained( args.model_path, torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32, local_files_only=local_files_only, ) else:
# Graceful fallback when local model folder has config/tokenizer but no weight files.
fallback_base = args.base_model22 unmodified lines ),
file=sys.stderr,
)
tokenizer = AutoTokenizer.from_pretrained(fallback_base)
model = AutoModelForCausalLM.from_pretrained(
fallback_base,
torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32,
)
tokenizer = AutoTokenizer.from_pretrained( fallback_base, local_files_only=local_files_only, ) model = AutoModelForCausalLM.from_pretrained( fallback_base, torch_dtype=torch.float16 if torch.cuda.is_available() else torch.float32, local_files_only=local_files_only, ) if tokenizer.pad_token is None:
tokenizer.pad_token = tokenizer.eos_token
model.eval()infer_local.py+44-26