llama.cpp Local AI Ollama OpenCode Qwen Operational

SOAR Local Agent Harness

A practical local coding-agent stack that pairs open-source models and serving tools with an iterative tool loop, demonstrating useful agentic workflows without recurring per-token API costs.

SOAR Local Agent Harness project preview

Overview

SOAR Local Agent Harness is a working reference setup for running a coding-focused agent loop on owned hardware. It combines a local language model, an OpenAI-compatible serving layer, and a tool-capable coding interface so the model can inspect a task, act through tools, read the result, and continue iterating without depending on a flagship hosted harness.

The Access Problem

Agentic coding systems are useful, but recurring subscriptions and per-token API charges can make experimentation expensive. This project asks a practical question: how much of that workflow can be reproduced with open-source components, a capable local model, and hardware the user already owns?

Reference Architecture

  • Qwen2.5-Coder 7B Instruct as the local coding model
  • Q4_K_M quantization for a useful quality-to-memory balance
  • 16,384-token context and a 4,096-token output budget
  • Ollama through an OpenAI-compatible local endpoint
  • An alternative llama.cpp server path with GPU offload and flash attention
  • OpenCode as the tool-capable agent interface
  • PowerShell launch scripts for repeatable startup on Windows

The Agentic Loop

The important part is not a chat window; it is the feedback loop. The model receives a task, selects an available tool, inspects files or runs a command, evaluates the returned evidence, and chooses the next action. A deliberately scoped system prompt emphasizes artifact inspection, reversible changes, explicit evidence, and verification instead of ungrounded claims.

Why Run It Locally?

  • No recurring per-token API charges after the model and tools are installed
  • Source code and task context remain on the local machine
  • The serving backend, model, prompt, context size, and tool policy remain replaceable
  • The setup becomes a transparent learning environment for understanding how agent loops work

Tradeoffs

Local does not mean unlimited. Capability and speed depend on the selected model and available CPU, GPU, memory, and storage. Smaller models require tighter prompts and narrower tool sets, and any agent with file or shell access still needs clear permissions and review. The project makes those constraints visible instead of hiding them behind a hosted service.

Current Status

The reference configuration and launch paths are operational. The next step is turning the setup into a cleaner public guide with hardware profiles, model alternatives, security boundaries, and reproducible verification tasks for people building their first local agent workflow.

This project configures and integrates open-source components including Qwen, OpenCode, Ollama, and llama.cpp. Those projects remain the work of their respective authors; SOAR Studios does not claim authorship or endorsement by them.