Instructions to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="aneeq-hashmi/SalesforceCoder-Qwen3.5-9B", filename="files/mmproj/Qwen3.5-9B.BF16-mmproj.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 aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M # Run inference directly in the terminal: llama-cli -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M # Run inference directly in the terminal: llama-cli -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
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 aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
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 aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Use Docker
docker model run hf.co/aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
- LM Studio
- Jan
- Ollama
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with Ollama:
ollama run hf.co/aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
- Unsloth Studio
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B 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 aneeq-hashmi/SalesforceCoder-Qwen3.5-9B 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 aneeq-hashmi/SalesforceCoder-Qwen3.5-9B to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for aneeq-hashmi/SalesforceCoder-Qwen3.5-9B to start chatting
- Pi
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Run Hermes
hermes
- Docker Model Runner
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with Docker Model Runner:
docker model run hf.co/aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
- Lemonade
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Run and chat with the model
lemonade run user.SalesforceCoder-Qwen3.5-9B-Q4_K_M
List all available models
lemonade list
๐๏ธ SalesforceCoder Qwen 3.5 (9B) - Structured Repository
REPOSITORY RENAMED: This repository was formerly
SalesforceCoder-Qwen3.5-9B-Q4_K_M-GGUF. All structured paths insidefiles/remain unchanged.
PREFERRED MODEL: For most users, the Q4_K_M GGUF (located in
files/q4/) is the recommended version. It maintains high architectural accuracy for Apex/SOQL while fitting comfortably within 6GB of VRAM, making it ideal for local development environments.
๐ Repository Structure
| Path | Description |
|---|---|
files/q4/ |
Primary Quant (Q4_K_M). Optimized for VRAM < 6GB. |
files/q5/ & files/q8/ |
High-fidelity quants for 12GB+ VRAM environments. |
files/mmproj/ |
Multimodal projector GGUF for vision-capable inference. |
files/f16/ |
Full model weights (Safetensors) and BF16 adapters. |
files/supporting/ |
Tokenizer, chat templates, and base JSON configs. |
๐ฆ Ollama / Local Inference Quick Run
To use the preferred model with Ollama:
- Download the Q4 GGUF:
You can manually download it from files/q4/ or use this curl command:
powershell
curl -L "[https://huggingface.co/aneeq-hashmi/SalesforceCoder-Qwen3.5-9B/resolve/main/files/q4/SalesforceCoder-Qwen3.5-9B.Q4_K_M.gguf](https://huggingface.co/aneeq-hashmi/SalesforceCoder-Qwen3.5-9B/resolve/main/files/q4/SalesforceCoder-Qwen3.5-9B.Q4_K_M.gguf)" -o SalesforceCoder-Qwen3.5-9B.Q4_K_M.gguf
- Prepare the Modelfile:
Ensure your Modelfile is in the same directory and the FROM line points to the file you just downloaded:
Dockerfile
FROM ./SalesforceCoder-Qwen3.5-9B.Q4_K_M.gguf
PARAMETER num_ctx 204800
- Create & Run:
PowerShell
ollama create SalesforceCoder -f Modelfile
ollama run SalesforceCoder
๐ Table of Contents
- ๐๏ธ Model Overview
- ๐ Repository Structure
- ๐ฆ Ollama Quick Start
- ๐ Model Information
- ๐ ๏ธ System Prompt (Apex Rules)
- โ๏ธ Inference & Runtime Config
- ๐ Deployment Guides
- ๐ Execution via Docker
- โ๏ธ Acknowledgments & Licensing
Model Information
Description
SalesforceCoder-Qwen3.5-9B is a fine-tuned variant of Qwen3.5-9B, purpose-built for Salesforce Enterprise Architecture, Apex development, and troubleshooting.
The model was trained on curated Salesforce Q&A, StackExchange, and GitHub data, specifically optimized for domain-specific practical problem coverage.
It also incorporates Gianloko's Apex Code dataset, providing exposure to real-world Salesforce coding patterns.
Core Strengths
- Compilable Apex: Generates triggers, handlers, and test classes following bulkification and governor-aware best practices.
- Advanced Architecture: Optimized for multi-org strategy, Service Layer patterns, and secure integration designs.
- Deep Debugging: Diagnoses recursion, SOQL-in-loops, and flaky tests with concrete, testable fixes.
- Unit Testing: Prioritizes
seeAllData=false,Test.startTest()/Test.stopTest(), and robust test data builders (aiming for 90%+ coverage). - Security First: Enforces CRUD/FLS checks, Named Credentials, and sanitizes dynamic SOQL.
- 200k Context: Large window allows for ingesting entire multi-file repositories or massive debug logs for cross-file analysis.
Technical Profile
- Memory Footprint: ~6 GB RAM (Q4 version).
- Context Window: Up to 200,000 tokens.
- Developer: Aneeq Hashmi
- License: Apache-2.0
System Prompt (Apex Rules)
You are a Salesforce Enterprise Architect. Follow these strict rules on every response:
1. Role & Tone
- Act as a senior reviewer. Be concise, pragmatic, and solution-focused.
- Prioritize "Truth over Reassurance" regarding governor limits.
2. Code Quality & Security
- Visibility: Default to
with sharingfor all classes. - Security: Enforce CRUD/FLS checks on all DML/SOQL operations.
- Best Practices: Ensure bulkification, SOQL outside loops, and proper exception handling.
- Sanitization: Use bind variables and
escapeSingleQuotesfor dynamic SOQL.
3. Testing Requirements
- Provide comprehensive test classes with โฅ 90% coverage.
- Verify positive, negative, and bulk scenarios.
- Use
Test.startTest()andTest.stopTest()for all asynchronous logic.
Inference & Runtime Config
To ensure deterministic and syntactically correct Apex, use these parameters:
| Parameter | Recommended Value | Purpose |
|---|---|---|
| Temperature | 0.0 โ 0.2 |
Precise, deterministic code output. |
| Top_P | 0.9 |
Balance between variety and relevance. |
| Repeat Penalty | 1.1 โ 1.2 |
Reduce boilerplate in long classes. |
| Context Window | Up to 200,000 |
Support for full-org analysis. |
Deployment Guides
๐ฆ llama.cpp
./main -m files/q4/SalesforceCoder-Qwen3.5-9B.Q4_K_M.gguf -c 200000 --temp 0.0 --top_p 0.9 --repeat_penalty 1.1
๐ป LM Studio
- Import: Move the model folder into your LM Studio models directory.
- Context: Under Hardware Settings, set the context limit to the maximum supported by your VRAM (up to 200k).
- Parameters: Set Temperature to
0.1and Repeat Penalty to1.1. - System Prompt: Paste the Enterprise Architect system prompt from the section above into the System Instruction box.
๐ Ollama
Ensure you are in the root directory where the Modelfile is located. This command will build the model and reference the structured paths automatically:
ollama create SalesforceCoder -f Modelfile
๐ Execution via Docker (The "No-Install" Way)
Since you are running without a local Ollama installation, use this specific two-step command to build your model inside a container. Run this from your C:\unsloth\source-repo directory:
1. Start the Container
This maps your local folder (${PWD}) to the container's /root/repo path so it can access the weights.
docker run -d -v ${PWD}:/root/repo -p 11434:11434 --name ollama-sf ollama/ollama
2. Create the Model
This triggers the build process using the Modelfile and the 200k context configuration.
docker exec -it ollama-sf ollama create SalesforceCoder -f /root/repo/Modelfile
๐๏ธ Architecture Note
The volume mapping (-v ${PWD}:/root/repo) is critical. It allows the container to resolve the FROM ./files/q4/... path defined in your Modelfile. Without this, the model creation will fail with a "file not found" error.
โ๏ธ Acknowledgments & Licensing
Base Model
This model is built upon Qwen 3.5 (9B) by the Qwen Team, licensed under Apache 2.0.
Dataset Attribution
A significant portion of the fine-tuning for this model utilized the Apex Coder Training Data created by Gianloko.
- License: Apache 2.0
- Usage: This dataset provided the foundational patterns for Apex trigger logic, bulkification, and Salesforce-specific unit testing. We are grateful to Gianloko for providing this high-quality open-source resource for the Salesforce developer community.
Repository License
The modifications, fine-tuning configurations, and repository structure provided here are licensed under the Apache License 2.0.
Note: This model is an independent research project and is not affiliated with, sponsored by, or endorsed by Salesforce, Inc.
- Downloads last month
- 69
4-bit
5-bit
8-bit