The LLMJob Earn miner can run a local AI model (an LLM) on your rig's GPUs while it mines. On HiveOS it is off by default, so your rig only mines until you turn it on. This page shows how to turn it on, check it is working, and use the model.

The short version

1. What it does

With --mode auto the miner starts a model server (llama.cpp's llama-server) next to the miner. The default model is Gemma 4 E4B, about 5 GB. It is downloaded the first time and kept on the rig's drive.

The miner gives each card a model only if the card has enough free memory left after mining. On a card with lots of memory it may pick a bigger model, and then switch that card between mining and answering as requests come in.

While a card's model answers a request, that card stops mining. It starts mining again 10 seconds after the last request ends. Your other cards keep mining, and the pool connection stays open. HiveOS and the network page show that card at 0 TH/s while it is paused.

The rig also answers requests from the LLMJob network, which is what "LLM co-mining" means. There are no extra earnings for this yet.

2. Turn it on

  1. Open your flight sheet with the llmjob-earn custom miner (set up as on the download page).
  2. Open the miner's settings and find Extra config arguments.
  3. Add --mode auto. If there is already something in the box, add it after a space.
  4. Save the flight sheet and apply it to the rig.

On a rig with a small CPU or little RAM (for example an Octominer), run the model on one card only. Each model server needs some CPU and memory:

--mode auto --llm-max-instances 1

3. Check it is working

Open the miner's log in HiveOS. The first start downloads the model, which can take a few minutes. When the model is up, the log says:

local LLM ready — OpenAI endpoint http://127.0.0.1:8080/v1

On the network page, your rig's cards show the model they are running next to the hashrate.

If the log says there is not enough free VRAM, that card is too full to run the model next to the miner. Mining carries on as normal on it.

4. Use the model

The model speaks the OpenAI API, so most apps that work with OpenAI can use it.

On the rig itself

The model answers on http://127.0.0.1:8000/v1. Paste this into the HiveOS shell. It is one line, because Hive Shell's web terminal can break a command pasted over several lines:

curl http://127.0.0.1:8000/v1/chat/completions -H "Content-Type: application/json" -d '{"messages":[{"role":"user","content":"Say hello"}]}'

From another computer on your network

With --mode auto or --mode llm, the miner opens port 8000 to your local network. Use http://<your rig's IP>:8000/v1 from any computer on the same network, with http, not https. The miner's log gives the address:

other computers on your network: http://192.168.1.20:8000/v1

To test it from that computer, put your rig's IP in place of the one here:

curl http://192.168.1.20:8000/v1/models

Up to v0.7.6, --mode auto opened port 8000 only when a card switched between mining and the model. A model running beside the miner could be reached from the rig only.

Port 8000 has no password. Anyone who can reach it can use the model, so keep it on your home network and don't forward it to the internet.

5. Options

All of these go in Extra config arguments, after a space:

6. What it needs

7. Turn it off

Remove --mode auto from Extra config arguments (or change it to --mode mining) and apply the flight sheet. The rig goes back to mining only.

Questions? Ask in our Discord.