Insights · WiLine

Insights to power your business growth.

Expert takes, field notes, and real-world stories from the frontlines of business connectivity, AI infrastructure, and the edge - written by the WiLine team building it.

From the team engineering networks businesses trust.

WiLine · Insights
7
articles
3
case studies
2026
latest
Edge
focus
Articles · Case Studies
Insights AI Tutorials

AI Tutorials.

Hands-on, tested guides for self-hosting AI infrastructure on a WEC Instance - deploy agents, connect your own models, add channels, evals, and observability. Every guide is run from scratch on a real box, with the actual commands, versions, and fixes.

Level
Topic

Self-hosting Hermes2 guides

AI evals & observability8 guides

BeginnerPart 8

Add web search to your WEC Inference calls

Your RAG assistant answers great from your docs — but not about anything recent. WEC Inference now has a built-in web-search tool: add it to a chat call and the model pulls in current info. A quick before/after test.

3 min readaiinferenceweb-searchtool-use
Read tutorial
IntermediatePart 7

Component-level tracing: debugging agent tool calls

Your agent's thinking and its actions are two different layers. Build a tool-calling agent on WEC Inference, trace it with Langfuse, then debug two real failures from the trace — including the confident, wrong answer that never throws a stack trace.

13 min readaievalsobservabilitylangfuse
Read tutorial
AdvancedPart 6

Regression-test your RAG service with DeepEval — and settle a model debate with data

Wrap the RAG assistant from part 5 in a containerized DeepEval suite judged by gemma4 on the WEC Inference API — no OpenAI key anywhere. Then use it to answer a real question: should we swap our generation model? Same quality, 5.5× the tokens: the eval says no. Every command, number, and error is real.

19 min readaievalsdeepevalrag
Read tutorial
AdvancedPart 5

The capstone: build, evaluate, and observe a RAG docs assistant on the WEC API

Build a production-shaped RAG service in Docker: scrape a real docs site, embed locally, generate on the WEC Inference API — then catch a real hallucination, root-cause it to your own scraper, fix it, and pin it with a regression test. Every command, number, and error is real.

26 min readairagembeddingschromadb
Read tutorial
AdvancedPart 4

Catch what your tests miss: observe and score your WEC app in production with Langfuse

CI evals pass on a fixed test set — but production sends inputs you never tested. Self-host Langfuse on a WEC Instance, trace every real call, auto-score live traffic with an LLM judge, drill into the exact step that broke, and feed failures back to make your evals stronger. Every command — and every dead end — is real.

17 min readaiobservabilitylangfuseevals
Read tutorial
IntermediatePart 3

Stop hand-writing test cases: generate an eval dataset with the WEC API

Two hand-typed test cases aren't an eval. Use the WEC Inference API to generate a labeled evaluation dataset — then validate and curate it, because generated labels aren't automatically correct. The result is real test data at scale; feed it to your harness and coverage surfaces the misclassifications and debatable labels two cases would hide. Every command and result is real.

13 min readaievalspromptfooinference
Read tutorial
IntermediatePart 2

Trustworthy JSON: schema-validate your model's structured output

LLMs promise JSON and deliver markdown fences and reasoning. Build a Promptfoo eval that classifies support tickets into schema-validated JSON on the WEC Inference API — with transforms to recover messy output, a model-reliability matrix, and a CI gate. Every command and result is real.

14 min readaievalspromptfooinference
Read tutorial
BeginnerPart 1

Evaluate your models with Promptfoo on the WEC Inference API

Stop eyeballing LLM output. Build a real evaluation harness with Promptfoo pointed at the WEC Inference API — assertions, latency guardrails, JSON-schema checks, model-graded rubrics, an all-WEC model comparison, and a CI gate. Every command and result is real.

12 min readaievalspromptfooinference
Read tutorial

WhatsApp automation on WEC1 guide

Self-hosting OpenClaw6 guides

BeginnerPart 6

Add a WhatsApp channel to OpenClaw

Put your self-hosted agent on WhatsApp. Add the channel, trust the plugin, scan a QR — and understand why a companion link makes the agent act as your account. Every command and error from a real run.

5 min readaiself-hostingopenclawwhatsapp
Read tutorial
BeginnerPart 5

Run OpenClaw on WEC Models

Swap the closed provider for WiLine's own inference: point your self-hosted OpenClaw agent at WEC Models — same box, a base-URL/key/model change, no per-token lock-in.

6 min readaiself-hostingopenclawwec-models
Read tutorial
IntermediatePart 4

Make OpenClaw private with a NetBird mesh VPN

Put OpenClaw on a private mesh with NetBird, repoint your hostname at the mesh IP, and close the public ports — so the same chat URL works only for your devices. Real commands and gotchas from a live run.

16 min readaiself-hostingopenclawnetbird
Read tutorial
BeginnerPart 3

Add a Telegram channel to OpenClaw

Talk to your self-hosted OpenClaw agent from your phone. Create a Telegram bot, connect it, clear the pairing gate, and chat — captured from a real run.

5 min readaiself-hostingopenclawtelegram
Read tutorial
IntermediatePart 2

Secure OpenClaw with a Caddy reverse proxy + HTTPS

Put Caddy in front of OpenClaw for real HTTPS and device-paired auth, then close the gateway's ports so the proxy is the only way in — gotchas and all.

7 min readaiself-hostingdockeropenclaw
Read tutorial
BeginnerPart 1

Deploy OpenClaw on a WEC Instance via Docker Compose

From a fresh WEC Instance to a self-hosted OpenClaw agent that actually answers — Docker Compose, your own model key, and every real error and fix from a live deploy.

10 min readaiself-hostingdockeropenclaw
Read tutorial

Self-hosting an LLM gateway5 guides

Part 5

Load test an LLM gateway and find the stall the median hides

Part 4 measured a blocking call in a callback at 200-350ms and said the real damage only shows under concurrency. This runs it: sixteen requests at once, with a control against the upstream so you can tell your gateway's fault from the model's. The medians of the two versions are almost identical. One version drops requests and silently stops masking.

18 min readllmgatewaylitellmperformance
Read tutorial
Part 4

Clean traces, untouched answers: masking PII in LiteLLM's logs without corrupting the response

Send a gateway's traffic to Langfuse and the model's own reply carries the PII straight back into your traces. Widen Presidio's scope and it masks the answer your users receive instead. Neither setting gives you both, so here is a forty-line callback that does — measured, and with the mistake that quietly makes it slower.

14 min readllmgatewaypiiprivacy
Read tutorial
Part 3

Mask PII at the gateway: set up Presidio, plus the one line the docs leave out

Set up PII masking on a self-hosted LLM gateway with Presidio. Masking can sit in three places — before the model, on the response, or only on the path to your logs — and only one keeps your app working. Follow the documented config and your model's answers come back redacted; here is why, and the single setting that fixes it.

19 min readllmgatewaypiiprivacy
Read tutorial
Part 2

LiteLLM complexity routing: the right model for each request, and what it costs in latency

How LiteLLM's complexity router decides which model answers a request — the seven scoring dimensions, the arithmetic on a real prompt, and a measured comparison of the free keyword scorer against an LLM classifier.

11 min readllmgatewayroutingcost
Read tutorial
IntermediatePart 1

One endpoint, many models: deploy an LLM gateway on a WEC Instance

Every app on a box holding the same API key is a problem waiting to happen. A gateway fixes that — one endpoint, scoped keys per app, per-key budgets, and a log of who spent what. Deployed for real on a host already running five other stacks, including the parts that surprised us.

13 min readllmgatewaydockerself-hosting
Read tutorial

Hardening self-hosted AI infra2 guides

Agent orchestration with LangGraph2 guides

Want a WEC Instance to run these on?

Every guide above was built on WiLine Edge Cloud - GPU and CPU instances, your own models, your own data, no per-token lock-in.