AI & automation7 min read · Updated 8 September 2026

Run a Local AI Agent on Your Own Machine: OpenClerq in About 15 Minutes

A local administrative agent that never sends your files anywhere. Install it, start the gateway, make the first call, and understand what it is actually doing.

Run a Local AI Agent on Your Own Machine: OpenClerq in About 15 Minutes

Most "AI assistant" tools work by sending your documents to somebody else's server. That is fine for a lot of work and completely unacceptable for some of it — client files, payroll, anything under a confidentiality clause.

OpenClerq is our open-source alternative: a small administrative agent that runs on your own machine. It keeps its tools, skills and context locally, exposes them through a gateway bound to 127.0.0.1, and does all arithmetic in a local engine. The AI explains; it does not calculate, and it does not need your files to leave the building.

This walkthrough gets it running and makes the first real call. It assumes you are comfortable in a terminal, but nothing more exotic than that.

Install and start the gateway

From source, the whole thing is four commands and a config copy. The gateway is the piece that holds the tools, so it is the piece you start first — the desktop app is a client of it, not the other way round.

terminal 1 — gateway
$ git clone https://github.com/paxamedia/OpenClerq.git && cd OpenClerq$ pnpm installPackages: +812  done in 24.1s$ cp .env.example .env$ pnpm build:gateway && pnpm build:coregateway  builtcalculation-core  compiled (rust, release)$ pnpm gatewaylistening on 127.0.0.1:18790bearer token written to ~/.clerq/gateway-tokenllm: local (ollama)   engine: rust-calc   skills: 0 loaded
The token line matters. From release 0.4 every endpoint except /health requires it, and there is no development bypass to fall back on.

Make the first call

Leave that terminal running and open a second one. /health is the only endpoint that answers without a token — which makes it the one you use to confirm the gateway is alive before anything else is configured.

terminal 2 — you
$ curl -s http://127.0.0.1:18790/health{"status":"ok","version":"0.4.0","llm":{"mode":"local","provider":"ollama"}}# everything else needs the bearer token$ curl -s http://127.0.0.1:18790/skillsHTTP 401  {"error":"missing or invalid bearer token"}$ curl -s -H "Authorization: Bearer $(cat ~/.clerq/gateway-token)" \>   http://127.0.0.1:18790/skills{"skills":[],"source":"~/clerq-workspace/skills"}# empty, because you have not written one yet — that is the next tutorial

Try the calculation engine

This is the part that distinguishes OpenClerq from a chat wrapper. Arithmetic goes to a local Rust engine, deterministically, and the model is only ever asked to explain the result. Ask the same question twice and you get the same number — which is not something you can say about asking a language model to do sums.

clerq gateway — 127.0.0.1:18790authed
OpenClerq gateway — simulated here, real on your machine at 127.0.0.1:18790.
Type a command, or pick one below. "help" lists them all.
The console below is a simulation of the gateway — but `calc` really is evaluated, here in your browser, by the same kind of deterministic parser. Try `calc 1200 * 19%`, then `token off` followed by `skills` to see the 401 for yourself.

What you have, and what you do not

  • You have a local gateway with an authenticated API, a deterministic calculator, and file-backed memory — all on your machine.
  • You have no skills yet. The open-source core ships none on purpose: no professions, no jurisdictions, no assumptions about your work.
  • Outbound HTTP is off until you set an allow-list, and file reads are confined to a root you nominate.
  • The desktop app is optional. pnpm desktop gives you the Control Tower — gateway health, skill editing, memory, dry-run — but everything is reachable over the API without it.

The next step is teaching it something. That is one Markdown file: see write your first skill. If you want to understand the category first, start with what a Model Context Server is.

Key takeaways

  • OpenClerq runs on your machine; the gateway binds to 127.0.0.1 and nothing is sent anywhere unless you configure a hosted model.
  • Every endpoint except /health needs a bearer token generated on first run — there is no development bypass.
  • Arithmetic runs in a local Rust engine, deterministically. The model explains results, it does not produce them.
  • The core ships zero skills by design. It does nothing useful until you teach it your own workflow.

Frequently asked questions

Do I need an API key or an internet connection?

Neither, to get this far. The gateway, the calculation engine and the tools are all local. You only need a model if you want explanations, and that can be a local one through Ollama.

Is this the same as the hosted Clerq product?

No. OpenClerq is the MIT-licensed open-source distribution you run yourself, with no warranty and no support obligation. The hosted product runs on our infrastructure with accounts, subscriptions and prebuilt modules.

What happens if the gateway crashes mid-task?

Nothing is lost that was written to file-backed memory, and no partial state is pushed anywhere, because there is nowhere for it to be pushed. Restart it and the token stays valid — it is a file on disk, not a session.

Want one of these built for your own workflow?

OpenClerq is open source and yours to run. If you would rather not build the module yourself, tell us what the work actually looks like and we will scope one — or tell you honestly that an off-the-shelf tool does it better.

Describe the workflow

A couple of sentences is enough to get a straight answer.

  • Fixed-scope quote — no obligation
  • Reply within 1 business day

By sending this, you agree that we may contact you about this inquiry.

Prefer to talk first? Reach us directly:WhatsApp+44 7400 733 299Contact page
private AI deployment

About the author

Paxa Media

Written by the Paxa Media delivery team — the same developers, marketers and strategists who build these systems for clients. We are a technology company based in Rijeka, Croatia, and we publish the real numbers we quote rather than "it depends".

Why you can trust this

  • Builds and operates the systems described here — websites, web and mobile apps, automation and integrations
  • Delivered by an in-team staff in Rijeka, Croatia; no outsourced or resold work
  • Price ranges published here are the ranges we actually quote

Keep reading

All tutorials
AI & automation

Private, Self-Hosted AI: When Your Data Is Too Sensitive for the Cloud

For most businesses, cloud AI is fine. But when your data is regulated, secret, or simply cannot leave your walls, private AI is the answer. Here is how to tell.

AI & automation

What Are AI Agents and How Businesses Use Them in 2026

A chatbot answers; an agent acts. AI agents can take multi-step actions and use tools to complete a task — here is what that really means, minus the hype.

AI & automation

Write Your First OpenClerq Skill: One Markdown File

A skill is a Markdown file with frontmatter. Here is the smallest one that does something useful, and how to check the routing actually works.