OpenLore

OpenLore

A frontier knowledge base that’s minimal extensible and agent-native. Built to keep your team’s shared context current and inspectable.

Category
访问服务器

README

📜 OpenLore

Release Go Reference

Sponsored by <a href="https://oiya.ai/?utm_source=github&utm_medium=referral&utm_campaign=openlore&utm_content=sponsor_logo"><img src="assets/oiya-logo.svg" alt="Oiya" height="24" align="absmiddle"></a>

Serve your docs to AI agents over SSH.

OpenLore is a minimal, extensible, agent-native knowledge base that keeps shared context current and inspectable.


About

AI coding agents already know how to explore files with ls, cat, grep, find, pipes, and shell loops. OpenLore gives them that same interface over SSH, backed by your documentation instead of a real machine.

Agent ──SSH or MCP──▶ OpenLore ──▶ docs, knowledge, and artifacts

It starts as a single-binary, zero-config, read-only documentation server. When you need a live knowledge base, you can add identity-scoped access, controlled publishing, atomic writes, validation, and human approval without changing how agents read or navigate the content.

Store and retrieve Markdown

Put documentation, runbooks, project context, or agent-authored notes in ordinary Markdown files. There is no ingestion pipeline: point OpenLore at a directory and it serves the existing hierarchy directly. Organize documents with folders, connect them with standard Markdown links, and group them into docsets when different people or agents need different access. OpenLore is read-only by default; enable writing when you want agents to create and update Markdown too.

OpenLore Skills import demo

Quick Start

The fastest path is to let your agent set up OpenLore:

# Teach your agent how to install, configure, and bundle OpenLore
ssh openlore.sh teach | your-agent-cli

# Add documentation access instructions to AGENTS.md
ssh openlore.sh agents >> AGENTS.md

Or install and run it directly:

go install github.com/aakarim/go-openlore/cmd/openlore@latest

openlore ./docs

ssh -p 2222 localhost
ssh -p 2222 localhost "grep -r 'authentication' /docs"

By default this starts:

  • SSH on localhost:2222
  • the human-facing web view on http://localhost:8080
  • MCP over HTTP on http://localhost:8080/mcp

See Installation for more ways to install and package OpenLore.

Features

  • Agent-native retrieval — Agents use the shell tools and composition patterns they already understand instead of learning a bespoke retrieval API.
  • One knowledge surface, multiple transports — Serve the same virtual filesystem over SSH, SFTP/SSHFS, MCP, and a human-friendly web view.
  • Live, governed knowledge — Keep content read-only, allow scoped publishing, or enable full writes per docset. Writes are atomic, conflict-aware, and can require human approval.
  • Identity-scoped views — Give each person or agent only the docsets it needs, with role-based ro, publish, and rw grants, path aliases, and private home directories.
  • Safe by construction — The shell is an in-memory Go interpreter, not a real operating-system shell. There is no shell escape, arbitrary process execution, or ambient network access in a normal session.
  • Portable knowledge bundles — Embed docs into a self-contained binary, build cross-platform bundles with the GitHub Action, or package them as a desktop MCP extension.
  • Structured knowledge without a new query language — Inspect frontmatter as NDJSON with lore meta, query it with jq, and validate Google's Open Knowledge Format (OKF) bundles and Agent Skills close to the write path.
  • Extensible policy and processing — Plugins can add validation, grants, read/write middleware, metadata, and post-commit processing while preserving the same filesystem interface.

Use Cases

  • Continuous Learning repository - store sessions and learnings in one shared server. Add metrics so you can optimise. Allow agents to share learnings with each other while maintaining user isolation.
  • Team Artifact Repository - share markdown, HTML, JSON, Excel etc. documents you've created while maintaining access controls. Much more natural than git, more agent-native than Confluence/Notion.
  • Documentation for coding agents — Put internal API docs, runbooks, product context, and architecture notes behind a familiar, greppable interface.
  • A shared live memory for teams of agents — Give agents separate or shared docsets so they can publish findings, hand off work, and accumulate durable context across sessions.
  • Public docs site - add any files to your public docset, enable public access and it will be shown to any agent that stumbles across your site. Improves AEO/GEO with no need to edit your existing docs.
  • Skills sharing — Publish Agent Skills into shared collections so every authorized agent can discover and use the same governed procedures.
  • Agent Plugins repository — Version-pin Agent Plugins repos from GitHub and serve them to your team's agents. Skills packaged in the open standard stay current automatically.
  • Governed knowledge contribution — Let contributors publish into inboxes while reserving sensitive paths for approvers and preventing accidental overwrites.
  • Remote review of agent artifacts — Expose reports, logs, screenshots, and generated files through the browser or SSH without building a custom artifact viewer or granting access to the agent's machine.
  • Identity-specific workspaces — Mount a private home for each agent plus shared team knowledge, all through one server and one authorization model.
  • Portable customer or project knowledge — Ship a versioned executable with the relevant docs embedded, or distribute the same knowledge as an MCPB desktop extension.
  • Validated knowledge catalogs — Enforce frontmatter and bundle conventions, inspect metadata cheaply, and stop malformed knowledge at admission time.

How It Works

OpenLore is built on Wish for SSH transport. A connection is handled entirely against a virtual filesystem:

  1. Authenticate — connect keylessly or resolve an SSH key, certificate, passkey, or OAuth login to an identity.
  2. Compose a view — mount only the docsets and paths granted to that identity.
  3. Explore — run shell commands implemented as pure Go functions over that view, or use the equivalent MCP shell tool.
  4. Contribute safely — if writing is enabled, authorize and validate a whole-file change before committing it atomically or routing it for approval.

OAuth clients use delegated identities, so durable write provenance distinguishes direct work by adil from work performed as adil/claude@claude.ai. Delegates can inherit no more authority than their principal and can be narrowed by docset and capability deny lists. CIMD clients can additionally authenticate with vendor-hosted metadata and private_key_jwt; see Authenticated OAuth Clients.

The normal shell cannot invoke bash, exec, curl, or arbitrary host processes. Embedded documentation is always read-only. Explicitly trusted identities can be granted narrowly scoped asynchronous processing through the spawn capability.

Governed Writing

OpenLore is read-only by default. Writable deployments keep a single, policy-controlled write path for redirects, append, tee, patch, sed -i, file moves, publishing, and approved external jobs.

echo "# Research" | publish backend findings.md
cat change.diff | patch /backend/api.md
sed -i 's/old/new/g' /backend/runbook.md

Writes are whole-object atomic swaps. Compare-and-swap protection rejects stale edits by default, docset grants constrain the target, and selected paths can produce reviewable changesets under /requests instead of committing directly.

See Writing and publishing for user-facing setup and Write system internals for the implementation model.

Installation

Install with Go

Requires Go 1.26 or later:

go install github.com/aakarim/go-openlore/cmd/openlore@latest

Build from source

git clone https://github.com/aakarim/go-openlore.git
cd go-openlore
go build -o openlore ./cmd/openlore

Embed docs in a binary

Place documentation in assets/lore/ and build. The resulting binary contains the docs and serves them read-only at /docs when run with no directory argument:

go build -o my-docs ./cmd/openlore

Build with the GitHub Action

Produce cross-platform binaries with your docs embedded:

- uses: aakarim/openlore@v1
  with:
    docs-dir: ./docs
    config: ./openlore.yml

See Ways to use OpenLore for MCP stdio, MCPB desktop packaging, SSHFS, and Go library usage.

HTTP inbox uploads

Configure a docset inbox and a role with its publish grant, then create a credential for an existing identity (the server configuration must name auth_file so the CLI can validate it):

openlore inbox token create --identity alice --label webhook --config openlore.yml
curl -H 'Authorization: Bearer olin_ID_SECRET' -H 'Content-Type: text/markdown' \
  --data-binary @note.md 'https://docs.example.com/inbox/docs?name=note.md'

POST /inbox/{docset} accepts bearer credentials or an exact-body HMAC using X-OpenLore-Token-Id and X-OpenLore-Signature. OAuth access tokens are used only for POST/GET /inbox/tokens and DELETE /inbox/tokens/{id}; inbox credentials are separate and revocable. See Configuration and identity.

Documentation

Guide Contents
Ways to use OpenLore SSH, MCP, web, SSHFS, embedded binaries, GitHub Action, MCPB, and library usage
Command reference Complete shell, introspection, publishing, syntax, CLI command, and flag reference
Configuration and identity openlore.yml, authentication, roles, docsets, aliases, homes, and host verification
Workload identity federation Authenticate CI and agents with short-lived external identity tokens
Writing and publishing Write modes, inboxes, conflict handling, approvals, and jobs
Plugins and knowledge formats Plugin installation, interfaces, OKF validation, lore validate, and lore meta
Write system internals Filesystem layering, write seam, changesets, hooks, and async jobs
Security evaluation Threat model and security properties

Security

  • Commands run in a pure-Go interpreter, not through os/exec.
  • The virtual filesystem cleans paths and enforces docset boundaries.
  • Allowed file patterns and ignored directories keep secrets out of the view.
  • RBAC controls reads, publishing, writes, approvals, and trusted capabilities.
  • The web endpoint can publish the SSH host key over TLS to avoid blind trust on first use; SSH user and host certificates are also supported.

See SECURITY.md for the full security evaluation.

License

MIT — Adil Karim

OpenLore bundles third-party open-source components. Their licenses and required notices are listed in assets/legal/THIRD_PARTY_NOTICES.md, with full license texts in assets/legal/licenses/. These are embedded in the binary and served by the running service at /legal.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选
mcp-server-qdrant

mcp-server-qdrant

这个仓库展示了如何为向量搜索引擎 Qdrant 创建一个 MCP (Managed Control Plane) 服务器的示例。

官方
精选