World's first open-source enterprise world model.
Rust agent-memorybitemporalgraphragknowledge-baseknowledge-graphllmontologypgvectorpostgresqlragrustself-hostedsemantic-searchtemporal-knowledge-graphworld-model
The philosophy section keeps one law and sends the rest to the site
WaylandYangaa2440a28a28
diff --git a/README.md b/README.mdindex bad8f09e..4ead04ac 100644--- a/README.md+++ b/README.md@@ -39,89 +39,17 @@ https://github.com/user-attachments/assets/PLACEHOLDER## Philosophy-> **We strongly recommend reading this chapter.** About 5 minutes.+What we set out to build is a knowledge world model: it understands the people, events, rules and relations inside a company, how they change over time, why they hold and when they cease to, how each decision came about and what it returned, cause and effect, all of it. So we gave it a somewhat romantic name — **Utopia**: a hub for knowledge, a foundation for decisions, a gate for controlled execution, a proving ground for reasoning about what comes next.-**An agent memory? Another Graph RAG? Or one more DAG?** It can be any of those, and it doesn't stop there.+Keeping an ideal world running takes some serious design, and there is room here for only one of them — the system's sense of time. Ptolemy's geocentric model was long held to be a reasonable account of cosmic order, then revised and displaced step by step by Copernicus, Kepler, Galileo and Newton. Notice that what we keep is not merely "ah, heliocentrism is the right one"; it is the whole arc along which understanding moved, a history in full.-What we set out to build is a world model that belongs to your company: it understands the people, events, rules and relations inside it, and equally how they change over time, why they hold, and when they cease to. Memory, knowledge, rules, reasoning and action are each only a part of it.+Here a piece of knowledge is never overwritten because a new fact turned up. The system records when it was ingested, when it changed, the span over which it held, a chronological chain of revisions and of how our reading of it shifted, which is what makes a decision genuinely traceable: review an approval a year on, and what comes back is the full course and grounds of that decision chain as it stood at the time. In engineering terms, a bitemporal knowledge graph. To make it hold up in practice, we have iterated at length against public corpora spanning enterprise records, education, finance, law and research.-So we gave it a somewhat romantic name: **Utopia**. Put in engineering terms, it is a passively evolving enterprise world model — **a hub for knowledge, a foundation for decisions, a gate for controlled execution, a proving ground for reasoning about what comes next.**--But you find out on maintaining it that building a world is not the hard part; keeping it running for years, steadily and credibly, is. An ideal state needs great institutions. Hence the laws that follow.--| Law | |-|---|---|-| **Zeus's Law** | Treat every piece of knowledge that arrives well |-| **Law of History** | Knowledge is not a static table of facts but a history still unfolding |-| **Law of Deduction** | From understanding the present toward reasoning about the future |-| **The Iron Gate** | Let rules hold up intelligence; let logic bound action |--### Zeus's Law--> **Treat every piece of knowledge that arrives well.**--In ancient Greece, Zeus guarded strangers and travellers. Wherever they came from, they were to be received before they were known. Utopia hopes to treat every piece of knowledge entering this world the same way.--It may come from a document, or from a database, a warehouse, a web page, a running subscription; it may be fully structured, or it may be nothing more than a new way of putting something. We will not turn it away merely because it does not yet fit an existing shape.--The system tries to recognise entities, facts and relations within it, forming its own ontology through the cold-start phase. New predicates may appear; old ones are not casually discarded; and when a fact changes, the trace of what it once was is kept along with the chain of that change.--Treating knowledge well does not mean understanding everything at any cost. We aim for a four-way balance between accuracy, extraction throughput, cost, and human involvement.--This is Utopia's Law of Zeus: treat well every piece of knowledge that comes into this world.--### Law of History--> **Knowledge is not a static table of facts but a history still unfolding.**--Knowledge graphs have tended to record settled facts, forever pursuing which knowledge is *correct*. Yet whether something is correct is at times a question only time can answer.--Ptolemy's geocentric system was long held to be a reasonable account of cosmic order; then Copernicus proposed the heliocentric one, Kepler corrected the model of planetary motion, Galileo brought new observational evidence, and Newton reinterpreted celestial movement under a unified mechanics. Today we of course know that geocentrism is no longer the correct model of the solar system.--And yet we remember it.--We remember not only that geocentrism existed, but why it was believed, in what age it was accepted, and how observation, theory and evidence revised and displaced it step by step. Because a truthful world needs to record more than *what is correct*; it needs to record what we once believed, and how we got from there to here.--So in Utopia a piece of knowledge is not simply overwritten or deleted because a new fact appeared. The system records when it was ingested, when it changed, the span over which it held in the real world, and the moment we learned of that change. We can therefore ask not only "what is true now?" but also:--```-"What did we believe was true at the time?"-"When did this begin to hold?"-"And when did we learn that it had changed?"-```--Only by preserving these changes can knowledge take real part in the unfolding of history. In engineering terms we call it a **bitemporal knowledge graph**.--### Law of Deduction--> **From understanding the present toward reasoning about the future.**--Laplace imagined an intellect vast enough to know, at a single moment, the state of every particle in the universe together with all the laws governing their motion; in principle it could then derive the entire past and future. Which is to say it could predict not only the courses of the stars, but what the one writing this README is thinking, and what thought will arise in you reading it a second from now.--In Utopia we try to approach that ideal by engineering: forward chaining drives facts to keep deriving, a symbolic system expresses rules, states and causal relations, and a language model handles the reasoning that resists full formalisation. Given enough facts, rules and causes, perhaps the system can move from understanding the present toward reasoning about the future.--### The Iron Gate--> **Let rules hold up intelligence; let logic bound action.**--An ideal state does not mean doing as one pleases. Quite the opposite: here every action should run within law, rule and boundary. What we least want to see is a model's hallucination, a human oversight or a flaw in reasoning turning into a logical error, an overreach of authority, or worse, an irreversible action.--So in Utopia an agent's judgement is not by itself an action. Every call to a downstream service must, before it actually runs, pass a joint check by ontology rules, constraints and symbolic logic:--```-Does it agree with the facts? Are its preconditions met?-Does it hold the authority? Does it cross a set boundary?- Is its outcome consistent with the current state of the world?-```--Only through these rules can reasoning become action. A model may think boldly, but execution must be restrained; an agent may explore the unknown, but it may not cross the iron law of this world.--> Go on, agent.-> Catch every task steadily, and hold every boundary just as steadily.+Time is only one such design. Others centre on how knowledge is taken in, how the future is reasoned about, and how logic bounds action: [utopia.bi/philosophy](https://utopia.bi/philosophy)## Features-The whole system is a crab and an elephant. By bringing in pgvector and a queue-table design, we cut the weight of the stack and its service dependencies — deployment is over in a blink.+The whole system is a Rust binary and a Postgres service. By bringing in pgvector and a queue-table design, we cut the weight of the stack and its service dependencies — deployment is over in a blink.| | ||---|---|diff --git a/README.zh-CN.md b/README.zh-CN.mdindex 1bc973e1..dc86d042 100644--- a/README.zh-CN.md+++ b/README.zh-CN.md@@ -21,7 +21,7 @@</div>-**由 [DeepLethe 深纪元](https://deeplethe.com) 构建的企业世界模型。** 它是人类首个被动学习、自我治理的知识工程基座——把时态与本体一起做进底层,语料涌入时迭代本体定义,记忆认知变化的历程,依据公理解决冲突,回溯任意时刻的世界观。可以跑在企业内网里,可以跑在云服务器上,也可以就跑在你的笔记本上——拿它建企业的知识基座、智能体的可信决策中枢,或者属于你个人的史诗。+**由 [DeepLethe 深纪元](https://deeplethe.com) 构建的企业知识世界模型。** 它是人类首个基于本体的被动学习、自我治理的开源知识工程基座——把时态与本体一起做进底层,语料涌入时迭代本体定义,记忆认知变化的历程,依据公理解决冲突,回溯任意时刻的世界观。可以跑在企业内网里,可以跑在云服务器上,也可以就跑在你的笔记本上——拿它建企业的知识基座、智能体的可信决策中枢,或者属于你个人的史诗。---@@ -39,89 +39,17 @@ https://github.com/user-attachments/assets/PLACEHOLDER## 项目的世界观-> **我们强烈建议阅读本章节**,约 5 分钟。+我们的愿景是建立一个知识世界模型,它理解企业中的人、事、规则与关系,理解它们如何随时间变化、为何成立、何时失效,每一个决策如何产生,决策带来的收益,因与果,一切的一切。我们给它取了一个稍显浪漫的名字——**乌托邦(Utopia)**,一个知识的枢纽,一个决策的基座,一个受控执行的闸门,或是推演未来的试验场。-**一个 Agent Memory?又一个 Graph RAG?或者,又一套 DAG?** 都可以是,但又不止于此。+要维持一个理想世界当然需要一些伟大的设计,限于篇幅,这里仅展开讲系统独特的时间感知功能:托勒密的地心体系曾被视作对宇宙秩序的合理解释,后来被哥白尼、开普勒、伽利略与牛顿一步步修正和取代。——你看,我们记住的不止是「哦!日心说是对的」,而是整个认知的变化过程,是一个完整的历史。-我们想搭建的,是一个属于企业自己的世界模型:它理解企业中的人、事、规则与关系,也理解它们如何随时间变化、为何成立、何时失效。记忆、知识、规则、推理与行动,都是这个世界模型的一部分。+在本系统中,一条知识不会因为新事实出现就被覆盖。系统会记录它何时被摄入、何时变更、有效期,一个时序的修订链路与认知变更过程,从而实现真正的决策追溯——一年后复盘某笔审批,系统还原的是当时那条决策链完整的过程与依据。工程上,我们称之为双时态知识图谱。为了提升可用性,我们基于公开的企业信息、教育、金融、法律、科研等领域语料库做了大量迭代。-所以我们给它取了一个稍显浪漫的名字:**乌托邦(Utopia)**。工程上的说法则是:一个被动演化的企业世界模型——**知识的枢纽,决策的基座,受控执行的闸门,推演未来的试验场。**--但真正维护起来才会发现:建立一个世界并不难,难的是让它长期、稳定而可信地运转下去。要维持一个理想国度,需要一些伟大的制度。于是有了下面这些属于「乌托邦」的法则。--| 法则 | |-|---|---|-| **宙斯之律**<br/>Zeus's Law | 善待每一条来到这个世界的知识 |-| **历史法则**<br/>Law of History | 知识不是一张静止的事实表,而是一段不断发生的历史 |-| **理想演绎**<br/>Law of Deduction | 从「理解现在」,进一步走向「推演未来」 |-| **世界铁律**<br/>The Iron Gate | 让规则托住智能,让逻辑约束行动 |--### 宙斯之律(Zeus's Law)--> **善待每一条来到这个世界的知识。**--在古希腊,宙斯守护陌生人与旅人。无论来者从哪里出发,在被了解之前,都应先得到接纳。「乌托邦」也希望如此对待每一条进入世界的知识。--它可以来自文档,也可以来自数据库、数据仓库、网页与持续订阅;可以结构完整,也可以只是一次新的表达。我们不会因为它暂时无法归入既有结构,就将它拒之门外。--系统会尝试从知识中识别实体、事实与关系,在冷启动阶段逐渐形成自己的本体;新的谓语可以出现,旧的谓语不会轻易消失,事实发生变化时,也会保留它曾经存在过的痕迹与变更链。--而善待知识,并不意味着不计代价地理解一切。我们致力于在准确度、抽取效率、成本控制与人类介入之间取得四位一体的平衡。--这是「乌托邦」的宙斯之律:善待每一条来到这个世界的知识。--### 历史法则(Law of History)--> **知识不是一张静止的事实表,而是一段不断发生的历史。**--传统的知识图谱,往往试图记录一个个确定的事实,并不断追求什么才是「正确」的知识。可是,知识是否正确,有时只有时间才能回答。--托勒密的地心体系曾在漫长的历史中被视作对宇宙秩序的合理解释;后来,哥白尼提出日心体系,开普勒修正行星运动模型,伽利略带来新的观测证据,牛顿又用统一的力学体系重新解释天体的运行。今天,我们当然知道地心说不再是描述太阳系结构的正确模型。--可是,我们依然记得它。--我们不仅记得地心说曾经存在,也记得它为什么会被相信、在什么时代被接受,又是如何被新的观测、理论与证据一步步修正和取代。因为一个真实的世界,需要记录的从来不只是「什么是正确的」,它还需要记录:我们曾经相信什么,又是如何走到今天的。--因此,在「乌托邦」中,一条知识不会因为新的事实出现便被简单覆盖或删除。系统会记录它何时被摄入、何时发生变更、在现实世界中的有效时间,以及我们在什么时候获知了这一变化。于是,我们不仅可以问「现在什么是真的?」,还可以追问:--```-「当时我们认为什么是真的?」-「这件事从什么时候起成立?」-「我们又是什么时候知道它变了?」-```--只有保存这些变化,知识才能真正参与历史进程的演绎。在工程上,我们称之为**双时态知识图谱(Bitemporal Knowledge Graph)**。--### 理想演绎(Law of Deduction)--> **从「理解现在」,进一步走向「推演未来」。**--拉普拉斯曾设想:如果存在一个足够强大的智能,能够在某一瞬间知晓宇宙中所有粒子的状态,以及支配它们运动的全部规律,那么理论上,它便可以推演整个宇宙的过去与未来。这意味着,它不仅能够预测星辰的运行,也能够推演此刻正在编写 README 的我在想什么,以及正在阅读 README 的你,下一秒又会产生怎样的念头。--在我们的「乌托邦」中,我们试图以一种工程化的方式逼近这一理想:通过前向链(Forward Chaining)驱动事实不断演绎,以符号系统表达规则、状态与因果关系,再辅以大语言模型处理难以被完全形式化的推理过程。如果能够掌握足够多的事实、规则与因果关系,我们或许可以让系统从「理解现在」,进一步走向「推演未来」。--### 世界铁律(The Iron Gate)--> **让规则托住智能,让逻辑约束行动。**--理想乡并不意味着随心所欲。恰恰相反,在这里,一切行为都应当运行于规律、规则与边界之内。我们最不希望看到的,是大模型的幻觉、人为疏忽或推理偏差,最终演变成逻辑错误、越权操作,甚至不可逆的错误执行。--因此,在「乌托邦」中,Agent 的判断并不天然等于行动。任何对下游服务的调用,在真正执行之前,都必须经过本体规则、约束条件与符号逻辑的共同校验:--```-它是否符合事实? 是否满足前置条件?-是否拥有相应权限? 是否触碰既定边界?- 其结果是否与当前世界状态相容?-```--只有通过这些规则,推理才能成为行动。大模型可以大胆思考,但执行必须克制;Agent 可以探索未知,但不能越过世界的铁律。让规则托住智能,让逻辑约束行动。--> 加油,Agent。-> 稳稳地接住每一个任务,也稳稳地守住每一道边界。+时间感知只是其中的一点,仍有很多设计聚焦于如何接纳知识、如何推演未来、如何让逻辑约束行动:[utopia.bi/philosophy](https://utopia.bi/philosophy)## 功能-整个系统就是一只螃蟹和一头大象。我们通过引入 pgvector 和队列表设计减轻了技术栈和服务依赖的负担 —— 咻的一下就部署好。+整个系统由 Rust 二进制和 Postgres 服务组成。我们通过引入 pgvector 和队列表设计减轻了技术栈和服务依赖的负担 —— 咻的一下就部署好。| | ||---|---|