Instructions to use edoggy/commodities-crop-analyst-7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use edoggy/commodities-crop-analyst-7b with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-7B-Instruct") model = PeftModel.from_pretrained(base_model, "edoggy/commodities-crop-analyst-7b") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use edoggy/commodities-crop-analyst-7b 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 edoggy/commodities-crop-analyst-7b:Q4_K_M # Run inference directly in the terminal: llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M # Run inference directly in the terminal: llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_M
Use Docker
docker model run hf.co/edoggy/commodities-crop-analyst-7b:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use edoggy/commodities-crop-analyst-7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "edoggy/commodities-crop-analyst-7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "edoggy/commodities-crop-analyst-7b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/edoggy/commodities-crop-analyst-7b:Q4_K_M
- Ollama
How to use edoggy/commodities-crop-analyst-7b with Ollama:
ollama run hf.co/edoggy/commodities-crop-analyst-7b:Q4_K_M
- Unsloth Desktop
- Pi
How to use edoggy/commodities-crop-analyst-7b with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "edoggy/commodities-crop-analyst-7b:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use edoggy/commodities-crop-analyst-7b with Docker Model Runner:
docker model run hf.co/edoggy/commodities-crop-analyst-7b:Q4_K_M
- Lemonade
How to use edoggy/commodities-crop-analyst-7b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull edoggy/commodities-crop-analyst-7b:Q4_K_M
Run and chat with the model
lemonade run user.commodities-crop-analyst-7b-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use edoggy/commodities-crop-analyst-7b with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf edoggy/commodities-crop-analyst-7b: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 edoggy/commodities-crop-analyst-7b:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use edoggy/commodities-crop-analyst-7b with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf edoggy/commodities-crop-analyst-7b: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 "edoggy/commodities-crop-analyst-7b: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"
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M# Run inference directly in the terminal:
llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_MBuild from source code
git clone https://github.com/ggml-org/llama.cpp.git
cd llama.cpp
cmake -B build
cmake --build build -j --target llama-app# Start a local OpenAI-compatible server with a web UI:
./build/bin/llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M# Run inference directly in the terminal:
./build/bin/llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_MUse Docker
docker model run hf.co/edoggy/commodities-crop-analyst-7b:Q4_K_Mcommodities-crop-analyst-7b (v1)
A tool-calling LoRA on Qwen2.5-7B-Instruct that answers crop-supply questions only from data it queries — USDA CDL county acreage (11 states, 2018–2024), the 2022 Census of Agriculture, IBGE São Paulo yields, USDA report dates, and front-month futures for sugar, orange juice, corn, soybeans, wheat and cotton. It never states a number it didn't compute. Self-contained: the data, tools and runtime ship in this repo.
What it does
- Area, change, rankings, state comparisons from the CDL; sugarcane model-vs-CDL-vs-census validation by county.
- Price history and a statistical price projection (
price_forecast): seasonal drift + volatility cone with an 80% interval and the method's backtested error (6–11% at 30 days; interval coverage 78–84%). The point estimate has no directional edge and the model says so. "Should I buy?" gets context, not a call. - Next-year Louisiana sugarcane expansion from sugarcane-forecast-v2 (new-cane recall 0.95 / precision 0.83; removals under-predicted).
- Renders sugarcane probability maps for 20 LA/FL counties (sugarcane-classifier-v1) and price charts.
- Asks a clarifying question when a year or place is missing; says so when something is outside the data.
Evaluation (785 held-out questions whose phrasings never appeared in training)
| Q4_K_M GGUF (Ollama) | LoRA adapter (4-bit HF) | |
|---|---|---|
| Correct tool chosen | 95.2% | 95.6% |
| Exact arguments | 92.6% | 92.9% |
| Executed result identical to gold | 92.6% | 92.9% |
| Malformed tool calls | 0 | 0 |
| Underspecified / out-of-scope handled without a tool call | 177 / 177 | 177 / 177 |
Run it (Ollama — any machine with ~6 GB free RAM/VRAM)
pip install gradio requests pandas pyarrow rasterio matplotlib joblib scikit-learn
hf download edoggy/commodities-crop-analyst-7b --local-dir commodities-crop-analyst && cd commodities-crop-analyst
ollama create commodities-crop-analyst -f Modelfile
python runtime.py # chat UI at http://localhost:7860
Or with the LoRA adapter on a CUDA GPU (12 GB, 4-bit): pip install transformers peft bitsandbytes accelerate then
python runtime.py --backend hf --adapter .
Each reply shows the answer, any image, and the exact tool call + result underneath so every number can be checked.
Training
12,000 synthetic examples generated from the bundled tables (45_gen_v2.py): questions sampled from 24–66 LLM-paraphrased
phrasings per intent (44_paraphrase.py), gold tool calls, gold answers computed from the data, plus clarify/out-of-scope
cases. QLoRA r=16, 400 steps, lr 1e-4, on one RTX 5070.
Limits — read before using
- Not a trading tool. Satellite/CDL area for a year is only available after USDA's own reports; nothing here has a timing edge. Forecasts are baselines with error bars, not predictions of direction.
- Long-horizon price projections (>120 days) are under-calibrated in backtests for volatile contracts (e.g. orange juice); the tool flags this in its output.
- US coverage only (LA, FL, TX, IA, IL, IN, MN, NE, KS, ND, GA), 2018–2024; one Brazilian state's yields; no stocks, demand, FX or in-season weather.
- Acreage is map-derived; county year-over-year changes under ~5% are within mapping noise.
- A 7% tool-argument error rate means: check the tool call shown under each answer for anything that matters.
Base model: Qwen2.5-7B-Instruct (Apache-2.0). Data: USDA NASS (public domain), IBGE, NASA POWER, Yahoo Finance, Google Satellite Embedding V1 (CC-BY-4.0) via the linked models.
- Downloads last month
- 67
4-bit
Install (macOS, Linux)
# Start a local OpenAI-compatible server with a web UI: llama serve -hf edoggy/commodities-crop-analyst-7b:Q4_K_M# Run inference directly in the terminal: llama cli -hf edoggy/commodities-crop-analyst-7b:Q4_K_M