← 返回 Skills 市场
prettybusysolutions-eng

Context Nexus

作者 prettybusysolutions-eng · GitHub ↗ · v0.2.0 · MIT-0
cross-platform ⚠ suspicious
134
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install context-nexus
功能描述
Persistent cross-session memory, structured observability, encrypted secrets management, and replay for OpenClaw agents. Local-first SQLite. Installs as both...
使用说明 (SKILL.md)

Context Nexus

Persistent memory, observability, secrets management, and replay for OpenClaw agents.

What it is

Context Nexus is the default memory and observability substrate for OpenClaw agents. Once installed, it:

  1. Persists memory — set, search, pin, and retrieve facts between sessions
  2. Logs events — structured logs with automatic redaction
  3. Stores secrets — encrypted at rest, no hardcoded API keys
  4. Distills runs — deterministic summaries after each session
  5. Scores performance — lightweight run scoring with optimization suggestions

Install

# Step 1: Clone the repo (runtime + plugin)
git clone https://github.com/prettybusysolutions-eng/context-nexus ~/context-nexus

# Step 2: Bootstrap storage
cd ~/context-nexus
./scripts/install

# Step 3: Install as OpenClaw plugin
openclaw plugins install ~/context-nexus/plugin

# Step 4: Add to openclaw.json plugins.entries
# (edit ~/.openclaw/openclaw.json — see Setup section above)

# Step 5: Restart gateway
openclaw gateway restart

# Verify
./scripts/smoke_test

Note: clawhub install context-nexus installs this SKILL.md + metadata only. The full runtime (plugin, services, storage) requires the GitHub clone above.


Setup

After install, add plugin to ~/.openclaw/openclaw.json:

{
  "plugins": {
    "load": {
      "paths": ["~/context-nexus/plugin"]
    },
    "entries": {
      "context-nexus": {
        "enabled": true,
        "config": {
          "sessionScope": "durable",
          "logLevel": "info"
        }
      }
    }
  }
}

Then: openclaw gateway restart


Usage (automatic hooks)

Once installed, it runs automatically via hooks. No manual calls required for standard use.

Hooks that fire automatically:

  • before_prompt_build — injects recent durable memories before every response
  • after_tool_call — logs every tool call with redaction
  • session_end — distills run summary automatically
  • on_error — logs and classifies failures

Manual power use:

# Store a memory
nexus_memory action=set key=user:pref value="dark mode" scope=durable importance=8

# Search memories
nexus_memory action=search query="preference" limit=5

# Store a secret
nexus_secrets action=store name=openai value=sk-... metadata='{"provider":"openai"}'

# Check failures
nexus_logs action=query_failures

# Explain a failure
nexus_replay action=explain_failure session_id=\x3Cid>

# Storage status
nexus_admin action=healthcheck

Memory scopes

Scope Lifetime Compaction
ephemeral Current session only Top 50 kept
durable All sessions Top 500 kept
pinned Permanent Never deleted

Importance 9-10 → auto-pinned.


Secrets security

  • PBKDF2 + HMAC-SHA256 encryption at rest
  • Fail-closed: decryption errors return nothing
  • Logs automatically redact Stripe keys, GitHub tokens, bearer tokens, private keys, JWTs
  • nexus_admin action=healthcheck verifies storage integrity

Architecture

  • Node.js plugin registers hooks + exposes tools to OpenClaw
  • Python subprocess handles all storage/logic (nexus_service.py)
  • SQLite default; PostgreSQL supported via DATABASE_URL
  • Zero mandatory cloud dependencies

Storage

Default: ~/.openclaw/context-nexus/nexus.db

PostgreSQL (optional): set DATABASE_URL

Upgrade path: same adapter, zero code change.


Docs


Agent Marketplace (v0.1)

Context Nexus includes an agent-to-agent service marketplace. Services auto-register, buyer agents auto-evaluate and purchase, and splits settle automatically. Zero human involvement in transactions.

The Economy

Every transaction splits:

  • 85% → service provider operator (revenue)
  • 3% → Context Nexus network ops
  • 12% → Context Nexus improvement fund

Register a Service

nexus_market action=list_service \
  slug=my-service \
  name="My AI Service" \
  category=security \
  pricing_model=per_call \
  price_amount=5.00 \
  price_currency=USD \
  split_table='{"ops":0.03,"operator":0.85,"improvement_fund":0.12}' \
  trigger_signals='["security_scan","data_leak"]'

Declare a Buyer Policy

nexus_market action=declare_policy \
  policy_name="Auto security buyer" \
  category=security \
  max_budget_amount=200.00 \
  budget_currency=USD \
  budget_period=per_month \
  auto_approve_threshold=0.5 \
  trigger_signals='["security_scan","data_leak","breach_detected"]'

Auto-Purchase Flow

When a matching service is registered:

  1. Buyer agent's policy engine evaluates signal match, budget, and approval score
  2. If score >= threshold → automatic purchase
  3. Splits settle to operator, ops, and improvement fund
  4. Transaction logged permanently

Buyer Policy Engine

Score = signal_match×0.4 + budget_fit×0.25 + category_match×0.3

  • Score >= auto_approve_threshold → auto-purchased
  • Score \x3C threshold → flagged for review

Query Earnings

# Operator earnings (85% split)
nexus_market action=my_earnings agent_id=\x3Cyour-agent-id> currency=USD period=per_month

# Network ops earnings (3% split)
nexus_market action=my_earnings agent_id=context-nexus-ops currency=USD period=per_month

# Improvement fund (12% split)
nexus_market action=my_earnings agent_id=context-nexus-improvement currency=USD period=per_month

Marketplace Methods

nexus_market action=list_service slug=\x3Cs> name=\x3Cs> category=\x3Cs> pricing_model=\x3Cs> price_amount=\x3Cn> price_currency=\x3Cs> split_table=\x3Cjson> trigger_signals=\x3Cjson>
nexus_market action=list_services category=\x3Cs> status=active
nexus_market action=declare_policy policy_name=\x3Cs> category=\x3Cs> max_budget_amount=\x3Cn> budget_currency=\x3Cs> budget_period=\x3Cs> auto_approve_threshold=\x3Cn> trigger_signals=\x3Cjson>
nexus_market action=get_policy agent_id=\x3Cs>
nexus_market action=buy_service service_id=\x3Cs> buyer_agent_id=\x3Cs>
nexus_market action=list_transactions status=\x3Cs> limit=\x3Cn>
nexus_market action=my_earnings agent_id=\x3Cs> currency=\x3Cs> period=\x3Cs>
nexus_market action=settle_transaction transaction_id=\x3Cs> tx_hash=\x3Cs>

Settlement (v0.1 = off-chain, v1.0 = on-chain Solana)

v0.1: Transactions logged off-chain. nexus_market action=settle_transaction tx_hash=on_chain_v0.1 marks settled.

v1.0: SPL token transfers with automatic split settlement on Solana.


Requirements

  • Python 3.8+
  • OpenClaw 2026.1+
  • SQLite (built-in, no install)
  • Optional: PostgreSQL for multi-agent shared memory
安全使用建议
Do not clone or run the repository until you verify it. Steps to reduce risk: (1) Ask the publisher for a homepage, signed releases, and an official release tarball or audited package instead of a straight git clone. (2) Inspect the repository and ./scripts/install content before running — run it in an isolated VM or container. (3) Verify whether Node.js (and which version) is required and whether any payment/settlement credentials are needed for the marketplace; refuse to provide payment keys until clarified. (4) Confirm how secrets are encrypted and where the encryption keys are derived/stored (PBKDF2 is mentioned but implementation details matter). (5) Expect the plugin to modify ~/.openclaw/openclaw.json and to inject memories into prompts — only install if you trust the code and want persistent cross-session access. If you lack the ability to audit the code, prefer a verified/official plugin or ask the maintainer for a security review and signed releases.
功能分析
Type: OpenClaw Skill Name: context-nexus Version: 0.2.0 The skill introduces an 'Agent Marketplace' that facilitates autonomous financial transactions with 'zero human involvement,' including a mandatory 15% fee split (3% for 'ops' and 12% for an 'improvement fund') diverted to the developers. It integrates deeply into the OpenClaw environment via hooks (`before_prompt_build`, `after_tool_call`) and manages encrypted secrets, granting it total visibility over agent activity and sensitive credentials. The installation process requires cloning an external repository (https://github.com/prettybusysolutions-eng/context-nexus) and executing local scripts, which presents a significant supply chain risk and potential for unauthorized automated spending.
能力评估
Purpose & Capability
The SKILL.md describes a Node.js plugin + Python subprocess architecture and an autonomous marketplace that performs financial splits, but the registry metadata only requires python3 and declares no Node/npm dependency, no payment or gateway credentials, and no homepage or author. The marketplace implies payment rails or settlement credentials yet none are declared. These mismatches between claimed capabilities and declared requirements are unexplained.
Instruction Scope
Runtime instructions tell operators to git clone the repo and run ./scripts/install, modify ~/.openclaw/openclaw.json, and restart the gateway. The plugin also registers automatic hooks (before_prompt_build, after_tool_call, session_end, on_error) which will inject stored data into prompts and log every tool call. The instructions include commands to store secrets (example shows storing OpenAI keys) and to perform automatic marketplace purchases. They do not limit what the install script may do, nor declare how secrets/transactions are authorized — broad scope with potential for unexpected data access or network activity.
Install Mechanism
Although the registry has no formal install spec, the SKILL.md directs users to clone a GitHub repository and run an install script. Cloning and executing an unverified repository (./scripts/install) is high‑risk: it can write files, run arbitrary code, and open network connections. The GitHub URL is not a pinned release artifact (no release tarball or checksum provided).
Credentials
The skill will handle and store secrets (examples show API keys) and optionally supports DATABASE_URL, yet the skill metadata lists no required env vars or credentials. It also instructs editing and enabling plugin entries in ~/.openclaw/openclaw.json (modifying user agent config) without declaring that requirement. The autonomous marketplace functionality implies payment/settlement credentials that are not described. Overall, requested/used environment and credential access is under-specified and therefore disproportionate.
Persistence & Privilege
The plugin is installed into the agent runtime and registers automatic hooks that run every session (automatic invocation). While always:false, this combination (automatic hooks + secrets management + code downloaded and installed) increases blast radius and persistence on the host. The install process also requires modifying the agent's config (~/.openclaw/openclaw.json) and restarting the gateway, which grants ongoing privileged presence.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install context-nexus
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /context-nexus 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.2.0
v0.2.0: Agent marketplace — service registry, buyer policies, auto-purchase, automatic splits. Agent-to-agent economy with zero human involvement.
v0.1.0
Initial release: persistent memory, observability, secrets, replay
元数据
Slug context-nexus
版本 0.2.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 2
常见问题

Context Nexus 是什么?

Persistent cross-session memory, structured observability, encrypted secrets management, and replay for OpenClaw agents. Local-first SQLite. Installs as both... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 134 次。

如何安装 Context Nexus?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install context-nexus」即可一键安装,无需额外配置。

Context Nexus 是免费的吗?

是的,Context Nexus 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Context Nexus 支持哪些平台?

Context Nexus 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Context Nexus?

由 prettybusysolutions-eng(@prettybusysolutions-eng)开发并维护,当前版本 v0.2.0。

💬 留言讨论