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 (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -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 serve -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 serve -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 serve -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
- Atomic Chat new
- OpenClaw new
How to use aneeq-hashmi/SalesforceCoder-Qwen3.5-9B with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "aneeq-hashmi/SalesforceCoder-Qwen3.5-9B:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- 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
| license: apache-2.0 | |
| language: | |
| - en | |
| base_model: | |
| - Qwen/Qwen3.5-9B | |
| # ποΈ SalesforceCoder Qwen 3.5 (9B) - Structured Repository | |
| > [!IMPORTANT] | |
| > **REPOSITORY RENAMED:** This repository was formerly `SalesforceCoder-Qwen3.5-9B-Q4_K_M-GGUF`. All structured paths inside `files/` remain unchanged. | |
| > [!IMPORTANT] | |
| > **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: | |
| 1. **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 | |
| ``` | |
| 2. **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 | |
| ``` | |
| 3. **Create & Run:** | |
| ``` | |
| PowerShell | |
| ollama create SalesforceCoder -f Modelfile | |
| ollama run SalesforceCoder | |
| ``` | |
| --- | |
| ## π Table of Contents | |
| - [ποΈ Model Overview](#-salesforcecoder-qwen-35-9b---structured-repository) | |
| - [π Repository Structure](#-repository-structure) | |
| - [π¦ Ollama Quick Start](#-ollama--local-inference-quick-run) | |
| - [π Model Information](#model-information) | |
| - [Technical Profile](#technical-profile) | |
| - [π οΈ System Prompt (Apex Rules)](#system-prompt-apex-rules) | |
| - [Code Quality & Security](#2-code-quality--security) | |
| - [Testing Requirements](#3-testing-requirements) | |
| - [βοΈ Inference & Runtime Config](#inference--runtime-config) | |
| - [π Deployment Guides](#deployment-guides) | |
| - [llama.cpp](#-llamacpp) | |
| - [LM Studio](#-lm-studio) | |
| - [Ollama](#-ollama) | |
| - [π Execution via Docker](#-execution-via-docker-the-no-install-way) | |
| - [ποΈ Architecture Note](#οΈ-architecture-note) | |
| - [βοΈ Acknowledgments & Licensing](#οΈ-acknowledgments--licensing) | |
| - [Dataset Attribution](#dataset-attribution) | |
| --- | |
| # 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](https://huggingface.co/datasets/Gianloko/apex-coder-training-data), 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 sharing` for 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 `escapeSingleQuotes` for dynamic SOQL. | |
| ### 3. Testing Requirements | |
| - Provide comprehensive test classes with **β₯ 90% coverage**. | |
| - Verify positive, negative, and bulk scenarios. | |
| - Use `Test.startTest()` and `Test.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 | |
| ```bash | |
| ./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 | |
| 1. **Import:** Move the model folder into your LM Studio models directory. | |
| 2. **Context:** Under **Hardware Settings**, set the context limit to the maximum supported by your VRAM (up to 200k). | |
| 3. **Parameters:** Set **Temperature** to `0.1` and **Repeat Penalty** to `1.1`. | |
| 4. **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: | |
| ```bash | |
| 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. | |
| ```powershell | |
| 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. | |
| ```powerShell | |
| 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](https://huggingface.co/datasets/Gianloko/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.* |