Local Knowledge Graph
A local model reasons step by step, and the reasoning becomes a knowledge graph that is used, not just drawn. Everything runs on your machine.
Run it
pip install mpe-lkg
mpe-lkg
Open http://localhost:5100. It talks to a local model through
Ollama and will tell you what is missing and the one command that
fixes it. The model matters more than anything else — measured, qwen3:4b-instruct-2507
answers 82.5% of the arithmetic battery against llama3.2:3b's 40%:
ollama pull qwen3:4b-instruct-2507-q4_K_M
Harder questions: mode=explore answers each sub-question with its own run; mode=settle
finishes only when two independent runs agree. Any run can be taken as RDF:
curl -sX POST localhost:5100/jobs -H 'content-type: application/json' \
-d '{"query":"How many seconds are there in 23 weeks?","mode":"settle"}'
curl -s localhost:5100/jobs/<id>/rdf
More
| How it works, and what the graph is for | the load-bearing measurements, the modules, the strongest-path search |
| Modes, jobs and RDF | reason / explore / settle, the vote, the probes, the vocabulary |
| Models and configuration | choosing models, every environment variable, troubleshooting |
| Embeddings from inside a model | reading a chosen layer instead of an embedding endpoint |
| Development | tests, the battery, and the gate that checks this documentation against measured data |
Licence
The mpedb License 1.0 — the same licence as mpedb and MPEqs, byte for byte.
Free of charge for every person and every organization, with one exception: a group whose revenue or valuation exceeds five billion dollars owes a one-time fee of seven US cents per device. Not an OSI-approved licence.
Published to PyPI as mpe-lkg — Morten Punnerud-Engelstad Local
Knowledge Graph.
Release files for mpe-lkg 0.9.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mpe_lkg-0.9.1.tar.gz | 796.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mpe_lkg-0.9.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.1 MB
Release files / mpe_lkg-0.9.1.tar.gz
| Download URL | mpe_lkg-0.9.1.tar.gz |
|---|---|
| Size | 796.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5c3231931a12541140704ab631c51a76310f9d4ab5fb07449cb35e3bc7dac5ce
|
|
BLAKE2b-256 checksum How to use checksums |
a85a90fd21db5c610d1b0cc1d9879ff3e4417deeea5ba577dcad7f3558c824ba
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.12
|
Release files / mpe_lkg-0.9.1-py3-none-any.whl
| Download URL | mpe_lkg-0.9.1-py3-none-any.whl |
|---|---|
| Size | 290.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
00c34dd2f0952d8cbd8a549834548e96bf37e2ebffeb740fb5b21e81d9cd4b5c
|
|
BLAKE2b-256 checksum How to use checksums |
8a19cf033954dbb844cf430660f8d138ca11231a13cd352a5c5704d093de3286
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.12
|