clearai-dsh README

The project's README from github.com/Clearailhc/clearai-dsh. As one markdown file: README.md.

ClearAI

English · 中文

Clearailhc%2Fclearai-dsh | Trendshift

Your research, grown into an ontology.

ClearAI is an ontology discovery and exploration platform, built on two core concepts:

Other knowledge graphs pile up edges by extraction and assertion; here every edge has to be earned through the loop.

# Install (npm package, prebuilt — no build step, no allowBuilds prompt)
dsh plugin --profile web add [email protected]
# or in the app: Plugins → Add plugin → [email protected]

Restart dsh web, then pick ClearAI in the preset picker at the top of a new session. That is the whole setup. Full install notes ↓

The epistemic loop (left) growing a domain ontology (right)

Left: the Epistemic Loop. Its emerald fact dot is also the first node of the domain ontology on the right. Right: the ontology graph — dark is a concept, light is a value form, emerald an instance; the instance carries two contradictory assertions — the two readings are tinted amber, marking that they do not agree. The system reports the conflict; retracting or keeping is a human decision.


What you get: a domain ontology

A domain ontology that grows as you research:

How you get it: the Epistemic Loop

Most agent loops track one thing: whether the task is done. The Epistemic Loop also tracks what makes a conclusion trustworthy:

Task loop Epistemic loop
Driving question What next? What do we know, and on what grounds?
Completion The model declares it The system computes it from delivered evidence
Verdict Whoever did it, says so Separated — above a level, the doer cannot judge themselves
Failure Deleted, retried, forgotten Kept: a refuted hypothesis is a result, not noise
What accumulates A chat transcript An ontology: every edge earned through the loop
The Epistemic Loop

Inside the ring is the instrument's read-out: the L0–L4 axis, the pre-registered threshold as a dashed line, and five observations with error bars — the supported one filled, the inconclusive drawn as a dashed circle, the refuted left in place with a slash through it (nothing is deleted). The emerald dot at the opening is the one reading that crossed the threshold and settled as a fact.

State is derived from the session record with no second store; the tools the model holds contain no field in which it could declare a step complete, and a goal completes only after independent evaluation. ClearAI does only what the host cannot — the epistemic contract, the domain ontology, presentation; goal continuation, subagents, asking you, deliverable cards and file history all come from DSH itself.

ClearAI does not claim recursive self-improvement. It provides the epistemic substrate a self-improving system would need. See Positioning and the OpenRSI survey.


Install and use

Requirements: DSH ≥ 0.1.7-alpha.1 — that generation introduced the composition declaration line this preset rides on. Verified against the host's 0.1.7-rc.2 and 0.2.0-rc.1.

Recommended — install it in the app, with the version pinned:

In the sidebar open Plugins → Add plugin, enter [email protected], and install. That is DSH's own plugin manager: it hands what you type to pnpm, checks that the package declares a bundle and is compatible with this host, and applies it live. (The Settings page 插件列表 / Plugins is the read-only inventory — installing happens on the sidebar's Plugins page.)

Or from a terminal — the same install:

dsh plugin --profile web add [email protected]

This installs the prebuilt package from the npm registry. Nothing is compiled on your machine, so there is no allowBuilds grant to approve — the plugin is ready the moment the command returns.

Why the version is pinned. pnpm ≥ 11 holds back newly published versions: minimumReleaseAge defaults to 1440 minutes, and because that built-in default is non-strict, a bare package name (or @latest) silently falls back to the newest version older than a day — right after a release, the previous release. DSH's plugin manager forwards your spec to pnpm unchanged and does not compare what landed against what you asked for, so this downgrade is reported as a success. Its preview card is no help either: it reads the package with pnpm view, which ignores the age policy, so it can show the newest release while pnpm installs the one before it. Two ways to be exact:

  • Pin the version, as both commands above do — pnpm then records the exception itself.

  • Or exempt the package once in the profile's pnpm-workspace.yaml; a bare name works from then on:

    minimumReleaseAgeExclude:
      - clearai-dsh
    

Also available — one-command installer (it resolves the current release and pins that version for you, so it is immune to the delay):

npx clearai-dsh install

Same install underneath; it resolves the DSH CLI from your PATH (or through npx), installs into the web profile, and reads the composed config back so you are not taking "success" on faith. Use this if you prefer a guided path, or --lang zh|en to force the installer's output language.

Community market (third-party): dsh-market lists whatever the curated awesome-dsh-plugin catalog carries and installs a pinned version for you; ClearAI's catalog entry is in review there. It is not part of DSH, and it is not needed to install this plugin.

Install from source (for development, not the normal path):

dsh plugin --profile web add github:Clearailhc/clearai-dsh

Git fetches source rather than build artifacts, so pnpm ≥10 will refuse to run the prepare script until you add an allowBuilds entry to the profile's pnpm-workspace.yaml. That grant means permission for this package's code to execute on your machine at install time — grant it only if you have read the source, and pin a commit. If you just want to use ClearAI, use the npm install above.

The installer's output follows your system language (--lang zh|en overrides it, doctor / seed / unseed take the same flag). Its only runtime dependency is zod; the graph stack is bundled into the client half at build time.

Restart dsh web afterwards (npx @deepseek-ai/dsh web), then create a session and switch to the ClearAI mode in the picker at the top:

  1. Open dsh web and click "New session";
  2. Click the current mode name at the top (default: Standard mode) to open the preset list;
  3. Pick ClearAI — its card reads "利用认识论循环构建可信本体。Build a trustworthy ontology through the epistemic loop.";
  4. Just ask your question. Ordinary Q&A runs as usual; once a goal is set and judgements are registered, the system enters knowledge mode by itself: what is already known comes to you, and conclusions earn their place through evidence. Only decisions only you can make are put to you.
The Ontology pane in ClearAI mode

The Ontology pane after the JEPA world model session: the question, the progress rail, the graph, and the conclusions grouped by status.

If pnpm is not on PATH: npm install -g pnpm (do not corepack enable — it installs a version forwarder that may download a pnpm it cannot launch).

From the repository:

npm test                       # 17 suites
node tools/build-package.mjs   # assemble dist/ from source
node tools/verify-package.mjs  # rebuild on the spot, byte-compare
node docs/diagrams/build-hero.mjs   # redraw the product hero (needs google-chrome)

dist/ is generated and never committed. See DSH integration.


What it looks like

One pane in the middle: Ontology. One pane on the right: World Tree. Next to the input box: "to handle N".

Ontology — one page for your four questions. At the top: the question, one line of counts, anything you need to handle ("to handle"), and a small progress rail: judgment → test → verified → in ontology. In the middle, the graph: the ontology graph (what your domain looks like) and the entity graph (the concrete things found) toggle with one click, and clicking a node filters by it. Below, the conclusion list, one line each, grouped by status: verified, awaiting check, testing, uncertain, refuted, replaced; open one to see which station it reached, how its trust changed, and its basis and scope. Two contradictory conclusions light up; retracting or keeping is your call.

World Tree — the plan's steps and gates, one line per step; open one to see which judgments it tested and what came out.

Deliverables — at close, the artefacts accepted for each step appear as DSH's native deliverable cards; what changed each turn is in DSH's native change cards.

Language — everything the system writes (tool results, the runtime card, questions to you, the files under clear/) follows the language you write in, Chinese or English. The panel follows the UI language.

The ontology graph, full screen

The ontology graph, full screen. The ontology graph and the entity graph come from one deterministic projection of the files under clear/ontology/, so the same files always give the same picture.

A refuted judgment, expanded

A refuted judgment from the Navier–Stokes session: it stopped at the test stage, and the record keeps why.


Cases

Both are real-model sessions run end to end without asking anything; the screenshots replay them in real DSH.


Documentation

Where it sits in DSH

ClearAI adds the epistemic layer on DSH's composition plane — one host package, one agent preset, one client module, with zero changes to the DSH engine. Working style is unrestricted, but nothing outside the governed path can write to the authoritative ledger (pinned by tests).

Work attribution

This project's work attribution unit is Jidian Qiyuan.

Star History

Star History Chart

License

Apache-2.0, see LICENSE.

Status

A local-first ontology discovery and exploration platform delivered as a DSH plugin. What is not yet implemented, and what has not been verified in a real browser, is written in Known gaps.

clearai-dsh (Clearailhc/clearai-dsh)

Searching Database…

这是什么?ClearAI 是面向 DSH 的本体优先的智能体预设,把一次研究会话变成持续增长、经证据检验的领域本体,通过它所谓的“认知循环”(Epistemic Loop)构建——提问、可证伪的判断、测试、证据,然后得出有边界的结论。
这是独立应用,还是其他东西的插件?它不是独立应用——它是一个安装到 DSH(DeepSeek Harness)宿主应用中的智能体预设/插件,添加一层认知评估和本体界面,但不改变 DSH 的核心引擎。
怎么安装并开始使用它?推荐方式:在 DSH 侧边栏进入 Plugins → Add plugin,输入 [email protected](固定版本),或在终端运行等效的 npm install,或使用单命令安装器。然后重启 'dsh web',开始新会话并在预设选择器中选 ClearAI。
除了 DSH 本身还需要什么吗?ClearAI 要求 DSH 宿主应用为 0.1.7-alpha.1 或更高版本(已对 0.1.7-rc.2 和 0.2.0-rc.1 验证);它自身的运行时依赖只有 'zod' 库,pnpm 仅在安装时需要。
安装时有什么需要留意的坑吗?不固定确切版本安装时可能悄悄装上旧版本:pnpm 的 minimumReleaseAge 默认值(1440 分钟)会让裸包名或 @latest 回退到最新发布之前的那个构建,而 DSH 的插件管理器不做检查就直接报告安装成功。
我的研究数据保留在本地吗?是的——ClearAI 被描述为本地优先的本体发现平台;其状态完全由会话记录推导而来,没有第二个存储,生成的文件位于你项目的 clear/ 目录下。
认知循环到底是什么?它是每个结论背后的工作流:提出问题,陈述一个可能被证明错误的判断,运行一个可能失败的测试,收集证据,然后得出一个有边界的结论并纳入本体;超过一定级别后,运行测试的人不能亲自评判。
这与其他知识图谱有什么不同?大多数知识图谱靠抽取和断言来生长。ClearAI 则要求本体中的每一条边都通过认知循环挣得,并经独立评估之后才算确立。
两个结论互相矛盾时会怎样?系统会自动呈现冲突,在图中把两个矛盾的读数都标为琥珀色,但不会替你解决——撤回或保留哪一个读数由人来决定。
已发布的示例研究会话是什么样的?展示了两个真实模型会话的完整过程:一个是 JEPA 世界模型文献综述,产出了包含 21 个概念、8 种关系和 27 个实体的本体;另一个是“纳维-斯托克斯方程被解决了吗?”会话,驳斥了两个流行说法,构建了包含 24 个概念、13 种关系和 59 个实体的本体。
Creator
Clearailhc
Size
23.1 MB
Stars
941
Age
1mo
Commits · 90 Days