Agentic Coding
A software development approach where an AI agent:
- Plans the development steps
- Writes the code
- Tests the implementation
- Modifies based on feedback
user request → LLM answer → execution
Local AI Agents with llama-cpp & open-code
2026.06.29
A software development approach where an AI agent:
user request → LLM answer → execution
AI coding agent orchestrator (open-source).
Runs LLM inference locally on consumer hardware.
→ offline environment · free · experimental
Use baobab to understand disk usage.
Clean your computer. Make space for GGUF models.
Example: Gemma-4-31B-it-QAT by Google DeepMind.
Source: HuggingFace — unsloth/gemma-4-31B-it-qat-GGUF
Lowers model precision to reduce memory usage.
Suffixes: 4-bit, 6-bit, 8-bit, etc.
Measure of LLM uncertainty.
| 4-bit (Q4) | ~8 GB |
| 6-bit (Q6) | ~12 GB |
| 8-bit (Q8) | ~16 GB |
| 7B model | ~4–8 GB |
| 31B model | ~17–32 GB |
| 70B model | ~40–80 GB |
| Q4_K_M | ~7–15 GB |
| Q8_0 | ~15–30 GB |
| Context window ≈ 20% extra RAM | |
| RAM ≈ model file size |
Probabilistic model: predicts the next token in a sequence.
P(x
where x
Step 5: Build & verify the binaries.
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"llama.cpp": {
"name": "llama-server (local)",
"npm": "@ai-sdk/openai-compatible",
"options": {"baseURL": "http://localhost:8080/v1"},
"models": {
"gemma-4-31B": {
"name": "gemma-4-31B",
"mode": "primary",
"limit": {"context": 256000, "output": 65536},
"modalities": {
"input": ["text", "image"],
"output": ["text"]
}
}
}
}
}
}
without modalities it often won't believe it can read images
File path for standard user configuration.
~/.config/opencode/opencode.json
Path: /Users/mecatronik/.config/opencode/opencode.json
Verify with: cat .config/opencode/opencode.json
Users cannot access another user's files (except admin/root).
Local network connection within the computer.
http://localhost:8080
http://127.0.0.1:8080/v1
./build/bin/llama-cli./build/bin/llama-serverAdmin terminal command.
./build/bin/llama-server -m models/model.gguf
Standard user terminal command.
opencode
Shortcuts: Ctrl+P → switch model
An LLM needs 'context' to work.
Context via: copy-paste docs, detailed prompts, context engineering
| Time | 41m 46s |
| Status | HTML output |
| Time | 31m 45s |
| Status | Error → server crash |
| Time | 4h 05m |
| Status | HTML output ✓ |
| MacBook Pro | M1 Max, 32GB, 8 cores |
Source: not accurate, but conveying the trend
Universal interface for external service APIs.
get, post recordsStructured instructions to condition the LLM.
Welcome to the era of Agentic Coding.
Press S speaker notes · F fullscreen