Java local AI setup
Verity Mod Ollama Local AI Setup
For stable Verity JE 5.7.4, test Ollama first, start its LiteLLM gateway, then enter the verified local URL and model in Mods > Verity > Config > Local LLM.
What the Ollama option changes
Ollama runs a language model service on your computer. Stable Verity JE 5.7.4 on Forge 1.20.1 connects through a local LiteLLM gateway instead of using Groq for conversation. This removes the need for a Groq key for the language-model request, but adds hardware, storage, model, service, and configuration requirements. The 6.0.0 beta family changed this setup; its removal of LiteLLM does not apply to the stable instructions below.
Use Ollama only after the base Java mod works. Minecraft should launch with the correct loader, Verity should load in a clean profile, and the documented in-game interaction should appear. If the game crashes before the title screen, solve the loader or dependency problem first.
| Release | Connection to prepare | Instructions to use |
|---|---|---|
| Stable 5.7.4 | Verity to LiteLLM on 4000, then Ollama on 11434 | Follow the gateway setup below |
| 6.0.0 beta family | The maintainer removed the LiteLLM requirement | Use the 6.0.0+ tutorial and your installed beta’s settings |
| Legacy NeoForge 3.4.1 | Separate older release | Do not copy the stable Forge fields from this page |
Ollama’s native /api service and its OpenAI-compatible /v1 interface are different APIs on the same service. The stable gateway is a separate process. A port number that works in a browser is not enough to choose a Verity endpoint.
How the three processes fit together
On stable 5.7.4 a single typed message passes through three separate programs. Understanding the chain makes almost every failure easy to locate:
- 1. Minecraft + VerityLiteLLM URL
http://127.0.0.1:4000/v1/ - chat request
- 2. LiteLLMReads
ollama/, forwards to Ollama - port 11434
- 3. OllamaLoads
qwen2.5:1.5b, writes the reply
ollama run checks 3, LiteLLM's --test checks 2 and 3, a chat message in Minecraft checks all three. The first test that fails names the broken program.- Minecraft with Verity sends an OpenAI-style chat request to the LiteLLM URL,
http://127.0.0.1:4000/v1/chat/completions. - LiteLLM receives the request, reads the
ollama/prefix to choose its Ollama provider, and forwards the request tohttp://127.0.0.1:11434. - Ollama loads
qwen2.5:1.5b, generates the reply, and returns it back along the same path.
Each link can be tested on its own. If Ollama answers ollama run but LiteLLM’s --test fails, the gateway is the problem. If both answer but Minecraft is silent, the Verity config or the profile is the problem. Testing in this order prevents changing three settings at once and losing track of which change mattered.
Start the programs in the same order every session: Ollama first, LiteLLM second, Minecraft last. Closing the gateway terminal stops the middle link even though Ollama keeps running, which is one of the most common reasons a setup that worked yesterday appears broken today.
Check whether local inference fits your computer
Local models use disk space, memory, processor or graphics resources, and power. Larger models generally need more resources and may answer more slowly on modest hardware. The right model is one that Ollama can load reliably while Minecraft is also running.
Before installing a large model, review the current Ollama documentation and the model’s published size. Keep enough free disk space for the download and enough memory headroom for both applications. A system that can run Minecraft smoothly may still struggle when a model and a modded game compete for memory.
Start with a small model for the standalone service check below. This verifies Ollama, not that the model can reliably follow Verity’s gameplay instructions. Once the connection is stable, compare models one at a time.
Practical sizing guidance
Exact requirements depend on the model file, quantization, operating system, and graphics hardware, so treat the following as planning guidance rather than a guarantee:
| Situation | Reasonable starting point | What to watch |
|---|---|---|
| Laptop or integrated graphics | The 1.5B default used by 5.7.4 | Total memory use with Minecraft open |
| Desktop with a dedicated GPU | Try a larger model only after the default works | Graphics memory shared with the game |
| Older or low-memory machine | Consider Groq instead of local inference | Stutter, swapping, or very long replies |
Minecraft’s own allocated memory still counts. If the launcher assigns a large heap to the game and the model also needs several gigabytes, the operating system may start swapping to disk. That shows up as frame drops in Minecraft and multi-second pauses before Verity replies. Reduce the game’s allocation to a sensible value, close browsers and recording software, and retest before concluding the model is too slow.
A larger model is not automatically a better companion. Smaller models respond faster, which matters for a horror experience where timing affects atmosphere. Change one variable at a time and note how long a typical reply takes in a real world, not just in a terminal.
Will a model fit alongside Minecraft?
The common failure with local AI is not that Ollama refuses to run; it is that the model and modded Minecraft together need more memory than the computer has, so the system starts swapping to disk. Minecraft stutters and Verity takes half a minute to answer. Estimate this before downloading a larger model.
How the estimate works, so you can adjust it:
- Minecraft uses more than its allocation. The launcher setting caps the Java heap; the game process also needs memory for graphics and native code. The calculator adds about 1 GB for that.
- A loaded model is larger than its download. Ollama needs extra memory for the conversation context, so the calculator adds 25% to the download size. The exact figure depends on the model and the context length.
- Operating systems need a reserve. Windows commonly uses 3–4 GB at idle; macOS and Linux are often lower. Check Task Manager or Activity Monitor with nothing open if you want a precise number.
- A dedicated graphics card changes the picture. If the model fits in the card’s own memory, Ollama can run it there, which frees system RAM but competes with Minecraft’s rendering. On a laptop with shared graphics memory, use the calculator as written.
If the headroom is negative, do not raise Minecraft’s allocation to compensate; that makes it worse. Lower the allocation to what the modpack actually needs (a light Verity profile rarely needs more than 4 GB), choose a smaller model, or use Groq for this computer.
Install Ollama from its official source
Install Ollama for your operating system from the official download page. Avoid repackaged installers or bundles promising a preconfigured Verity model. Open Ollama, then open a terminal on macOS/Linux or PowerShell on Windows.
Use these documented Ollama CLI commands, one at a time:
ollama pull qwen2.5:1.5b
ollama ls
ollama run qwen2.5:1.5b "Reply with one short greeting."
Expected results: the download completes, ollama ls includes qwen2.5:1.5b, and the final command prints a generated greeting. The wording varies. This 1.5B model is listed in Ollama’s library and matches 5.7.4’s configured default model. That default is not a guarantee of hardware performance or gameplay quality.
If the CLI cannot connect to Ollama, start the installed app or run ollama serve in a separate terminal and leave it open. Do not start a second server if one is already listening. If ollama is not recognized, reopen the terminal after installation and check the platform’s installation instructions.
Record the exact model name displayed by Ollama, including any tag. Similar-looking names can identify different models or versions. “Model not found” often means Verity requests a name that is not installed, not that the mod itself failed.
Verify the local service
Ollama’s API documentation uses http://localhost:11434/api for its native local API. Check the service without Minecraft:
curl http://localhost:11434/api/tags
In Windows PowerShell, use curl.exe http://localhost:11434/api/tags to run the curl executable. The documented response is JSON with a models array. Look for the model you downloaded. An empty array means the service answered but has no listed models; connection refused means the service or address still needs attention.
This is a diagnostic URL, not a universal Verity config value. Ollama’s native /api routes, its OpenAI-compatible /v1/ routes, and a separate LiteLLM gateway are different entry points.
“Localhost” means the same computer as the process making the request. If Minecraft runs in a virtual machine, container, remote desktop environment, or separate server, localhost may point to the wrong machine. Keep the first test on one computer. Remote exposure introduces firewall and security decisions that are outside the simplest Verity setup.
Do not open the Ollama service to the public internet merely to fix a local connection. A local firewall rule should be as narrow as the setup requires. Follow official Ollama guidance for any non-local deployment.
Start the LiteLLM gateway for 5.7.4
Leave Ollama running. The LiteLLM quickstart currently recommends this isolated CLI installation with the uv package tool available:
uv tool install "litellm[proxy]"
The current package requires Python 3.10 or newer; the documented uv route can provision a compatible Python. If you already have LiteLLM, use litellm --version to check that the command is available. Installation alone does not start the gateway.
Start the gateway in a terminal and leave it open:
litellm --model ollama/qwen2.5:1.5b --api_base http://127.0.0.1:11434 --host 127.0.0.1 --port 4000
This combines LiteLLM’s documented Ollama model prefix with its CLI host, port, and API-base options. Expected result: a running proxy listening on 127.0.0.1:4000, with Ollama as the upstream service on port 11434. The explicit loopback host keeps this local test off public network interfaces.
In a second terminal, run the quickstart’s standalone request test:
litellm --test
Expect a generated chat-completion response. If it reports connection refused or a missing model, fix the gateway or Ollama first.
If port 4000 is already in use by another program, the gateway will fail to start. Either stop the other program or choose a free port and change Verity’s LiteLLM URL to match. Keep the two values identical; a gateway on 4001 and a config pointing at 4000 produces the same silence as a stopped gateway.
Configure stable Verity JE 5.7.4
The maintainer’s published 5.7.4 artifact defines these exact controls and defaults:
- From Minecraft’s title screen, open Mods > Verity > Config. Expect Verity Configuration.
- Open Local LLM and turn Use Ollama on. In this release it overrides AI Settings > AI Provider, even if that menu still says
GROQ. - Set LiteLLM URL to
http://127.0.0.1:4000/v1/and Ollama AI Model toollama/qwen2.5:1.5b. These are the shipped defaults and match the gateway command above. - Keep Thinking Mode (Qwen3 Models only) off for this Qwen2.5 test. Apply the changes and reopen Config to check them.
The stored field names are AISettings.use_ollama, AISettings.ollama_url, and AISettings.ollama_ai_model. Verity appends chat/completions to the configured base URL. Do not paste /api/tags into LiteLLM URL, replace port 4000 with 11434 while keeping these gateway settings, or remove ollama/ from this model field.
For a different installed model, change both the gateway’s --model and Verity’s Ollama AI Model, keeping the ollama/ prefix before the exact name from ollama ls. Leave speech services unchanged until typed replies work.
Keep the release boundary explicit: the older Ollama video is titled “up to 5.7.3.” The maintainer’s 6.0.0-beta.1 notes from July 29, 2026 announce a changed config menu and removal of the LiteLLM requirement. That beta change is not evidence that stable 5.7.4 can skip the older gateway setup. The currently linked 6.0.0+ tutorial is for the beta family, and beta.9 reworked AI configuration again.
Values that must match
| Setting | Where it lives | Stable 5.7.4 value |
|---|---|---|
| Installed model name | ollama ls output | qwen2.5:1.5b |
| Gateway model | LiteLLM --model | ollama/qwen2.5:1.5b |
| Gateway upstream | LiteLLM --api_base | http://127.0.0.1:11434 |
| Gateway listener | LiteLLM --host / --port | 127.0.0.1 / 4000 |
| Verity base URL | Local LLM > LiteLLM URL | http://127.0.0.1:4000/v1/ |
| Verity model | Local LLM > Ollama AI Model | ollama/qwen2.5:1.5b |
If any row disagrees with its neighbor, fix that row before testing again. Most “Ollama doesn’t work” reports trace back to one mismatched value in this table.
Stable 5.7.4 end-to-end test
- Start Ollama and LiteLLM, and confirm both standalone tests answer.
- Start the clean Verity JE profile.
- Open a new test world.
- Once Verity appears, open Minecraft chat with T, type
Verity, say hello., and press Enter. Keep General > Immersive Mode off while testing. - Watch the Minecraft log and gateway output for the request.
A response in Ollama but not Minecraft suggests a Verity configuration or response-handling problem. No request reaching Ollama suggests the provider selection, endpoint, service availability, or firewall. A model-not-found response identifies the name or missing download. A very slow response may be resource pressure rather than a broken connection.
Wait for one request to finish. Sending many prompts can queue local work, consume more memory, and make the mod appear less responsive.
Reading the logs during a test
Keep three windows visible during the first real test: the LiteLLM terminal, the Minecraft launcher’s log or latest.log, and optionally a terminal for Ollama. Each one tells you how far a request travelled.
- Nothing appears in the LiteLLM terminal: Verity never sent the request to the gateway. Recheck Use Ollama, the LiteLLM URL, and that you launched the profile you configured.
- LiteLLM logs a request but reports an upstream error: the gateway reached for Ollama and failed. Check that Ollama is running and that the
--api_basevalue is correct. - LiteLLM logs a successful completion but Minecraft stays silent: the reply returned to the game. Look in
latest.logfor Verity errors around the same timestamp and confirm Immersive Mode is off for the test. - The request takes a long time and then succeeds: the chain works. The delay is model loading or hardware load, not a configuration error.
When asking for help on the project’s community channels, share the relevant lines from these logs rather than a description. Remove usernames, local paths, and any keys first. See the crash and log guide for where Minecraft stores its log files.
Common Ollama failures
Service is not running: the model may be installed but no process is listening. Start Ollama using the current operating-system instructions and verify again outside Minecraft.
Exact model is missing: run ollama ls. For the stable 5.7.4 setup above, Ollama must list qwen2.5:1.5b; the gateway command and Verity field must both use ollama/qwen2.5:1.5b. Do not apply the gateway prefix to a beta’s direct Ollama connection.
Wrong endpoint: for this stable setup, Ollama listens on 11434 and the LiteLLM gateway on 4000. Verity’s base URL is http://127.0.0.1:4000/v1/. Watch for a stopped gateway, an accidental https scheme, or a remote hostname copied from another tutorial.
Profile mismatch: confirm that the Verity configuration belongs to the launcher instance you actually start.
Memory pressure: close heavy applications, use a smaller model, lower other game resource demands, and observe operating-system memory rather than repeatedly reinstalling.
Firewall or isolation: verify that the Java process can reach the local service. In managed environments, follow network policy rather than disabling security controls.
Gateway closed with its terminal: LiteLLM runs only while its terminal is open. Restart it with the same command before launching Minecraft each session.
For errors that mention authentication, rate limits, or Groq while Use Ollama is on, see API connection failed; those messages usually mean the provider override did not take effect.
Moving from stable to a 6.x beta
Keep the working stable profile unchanged while creating a separate beta profile. Verify that Ollama still answers the same standalone prompt, then configure the beta using its matching tutorial. Do not carry over ollama/ just because the stable gateway required that prefix: it selects LiteLLM’s provider, not part of Ollama’s installed model name.
What beta.9 actually needs, read from its jar:
- In Mods > Verity > Config > AI Settings, set AI Provider to
OLLAMA. The beta talks to Ollama directly athttp://127.0.0.1:11434; there is no LiteLLM step and no port 4000. - Turn on Use Custom Model and type the exact tag Ollama shows in
ollama ls, for exampleqwen2.5:1.5b, without theollama/prefix. The beta has no preset for Ollama; with the custom model empty it reports “Ollama requires a custom model name.” - Leave API Key empty; Ollama does not need one. Use AI URL under Advanced only if Ollama runs on another computer.
The beta also has a Thinking Mode switch. Leave it off on small local models: thinking makes replies slower and adds little at 1.5B.
After a successful typed reply, stop any unused old gateway only if no other application needs it. Keep Ollama running. If a later error still names port 4000, check whether you launched the stable profile or retained a gateway address. The stable test above is not a beta setup recipe. For multiplayer, remember that localhost belongs to the machine making the request, not automatically to the player hosting the world. See the multiplayer setup checks before moving a local service to another machine.
Text before speech
Keep the working Ollama settings when moving to microphone and voice testing. Ollama handles the conversation model; it does not establish that speech recognition or spoken audio works. In a compatible 6.x installation, JE Extra’s offline voice option changes speech output independently. A local chat model plus a cloud voice provider is still partly online.
Privacy and security boundaries
Local inference can reduce the number of prompts sent to a cloud model, but it is not a blanket guarantee that the entire game session is offline or private. Review the behavior of Minecraft, the launcher, Verity, other mods, and update tools. Avoid placing passwords, private documents, or sensitive personal information in prompts.
Keep the Ollama service local unless you intentionally design and secure a remote deployment. Do not expose it through a router, public tunnel, or unrestricted network interface as a quick fix. Logs can still contain prompts and local paths, so inspect them before sharing.
Decide between Ollama and Groq
Choose Ollama when your machine can run an appropriate model and you prefer local inference. Choose Groq when local resource use or model management is impractical and you accept a cloud provider. Neither option fixes a wrong loader, missing dependency, or unsupported Minecraft version.
| Factor | Ollama (local) | Groq (cloud) |
|---|---|---|
| Account or key | None for inference | Free API key required |
| Hardware load | Shares memory and GPU with Minecraft | Minimal on your machine |
| Extra processes on 5.7.4 | Ollama plus LiteLLM gateway | None |
| Prompt location | Stays on your computer | Sent to the provider |
| Works without internet | Model inference can | No |
Keep a record of the working model name, Ollama version, service address, Minecraft version, loader, and Verity release. After any update, test Ollama alone, then Verity in a clean world, before returning to an important save.
Quick checklist
- Base Verity JE 5.7.4 loads on Forge 1.20.1 in a clean profile.
-
ollama lslistsqwen2.5:1.5bandollama runprints a reply. - LiteLLM is running on
127.0.0.1:4000andlitellm --testanswers. - Use Ollama is on, with the LiteLLM URL and model matching the table above.
- A typed
Verity, say hello.produces a reply in a new test world. - Only then move on to voice, Immersive Mode, or a different model.
Setup and gameplay videos
The YouTube player loads only after you press play. You can also open each video directly on YouTube.
Frequently asked questions
Can Verity JE run without Groq?
Yes. The checked Verity JE project documents Ollama as a local alternative. Ollama and a compatible model must be installed and running on the same reachable machine.
Why does Verity say the Ollama model is not found?
In stable 5.7.4's LiteLLM setup, Ollama lists qwen2.5:1.5b but Verity's Ollama AI Model field uses ollama/qwen2.5:1.5b. Keep that gateway prefix and the exact installed model tag. Test Ollama and then LiteLLM before Minecraft.
Does Ollama make every Verity feature offline?
It can keep language-model inference local, but Minecraft, the launcher, update checks, video links, and other mod features may still use networks. Review the current project behavior rather than assuming complete offline operation.
Why is the first Ollama response slow?
The model may need to load into memory and generate on local hardware. Test a smaller supported model, close heavy applications, and wait for one request instead of sending several.
Where this information comes from
Verity JE on CurseForge
Java project details, Project ID 1591438, stable Forge 1.20.1 main file 5.7.4, 6.0.0-beta.9 listing, legacy NeoForge branch, AI options, gallery, and author notices.
Checked
Verity JE 5.7.4 file and configuration
Stable Forge 1.20.1 release and missing Groq model fix. Static reading of the published jar: mods.toml requirements (Forge 47+, Minecraft 1.20.1, GeckoLib 4.4+, YACL 3.6+ client), config labels and defaults (Hostile Day Threshold 5, Can Crash, True Darkness, Kill Villagers, offline voice), preset-to-model mapping, the exact chat error messages, log messages, and bundled offline voice and speech models.
Checked
Verity JE 6.0.0-beta.1 release notes
The beta branch changed its configuration menu and removed the LiteLLM requirement; this does not describe stable 5.7.4.
Checked
Verity JE 6.0.0-beta.9 file notes
Forge 1.20.1 beta with reworked AI configuration. Static reading of the beta.9 jar: provider list and OPENAI default, SMART/FAST model presets, voice and recognition providers, persistent memory file, recovery and karma commands, Kill Entities and Kill Wildlife toggles, and Demon behaviours.
Checked
Verity JE Extra by somewhatmaxy
Third-party Forge 1.20.1 add-on for Verity JE 6.x; optional chat and TTS overrides, Piper and Fish Audio setup, unchanged speech input, and experimental Host Mode.
Checked
Ollama documentation
Supported platforms, local model installation, service behavior, and model commands.
Checked
Ollama CLI reference
Commands to download, list, run models, and start the local service.
Checked
List local Ollama models
The local model-list endpoint and its JSON response.
Checked
Ollama OpenAI compatibility
OpenAI-compatible endpoints differ from Ollama's native API routes.
Checked
Qwen2.5 1.5B in the Ollama library
The exact local model name used in the stable-release configuration example.
Checked
LiteLLM proxy quickstart
Isolated CLI installation and standalone proxy request testing.
Checked
LiteLLM proxy CLI arguments
Model, API-base, host, and port options for a loopback-only Ollama gateway.
Checked