Skip to main content

Eve

Long-term memory for Vercel Eve agents using Hindsight. Eve is filesystem-first — an agent gains a capability by dropping a file under agent/connections/. The @vectorize-io/hindsight-eve package wraps Eve's defineMcpClientConnection, so one file gives your agent retain, recall, and reflect over Hindsight's MCP server and it remembers across sessions and deployments.

Install

npm install @vectorize-io/hindsight-eve

eve is a peer dependency you already have in an Eve project.

Quick Start

Create agent/connections/hindsight.ts:

import { defineHindsightConnection } from "@vectorize-io/hindsight-eve";

export default defineHindsightConnection();

The connection reads its defaults from the environment:

Env varPurpose
HINDSIGHT_API_KEYBearer token sent as Authorization: Bearer <key>
HINDSIGHT_MCP_URLMCP endpoint (defaults to Hindsight Cloud)
HINDSIGHT_MCP_BANK_IDOptional bank to scope memory to, sent as the X-Bank-Id header

The model discovers the tools via Eve's connection__search and calls them as connection__hindsight__recall, connection__hindsight__retain, and connection__hindsight__reflect. The connection's URL and token never reach the model.

Hindsight Cloud

Set HINDSIGHT_API_KEY from your Hindsight Cloud dashboard. The connection defaults to https://api.hindsight.vectorize.io/mcp, so no URL is needed.

Self-hosted

Point at your own server, optionally scoping to a bank. Use apiKey: null for a no-auth local server:

import { defineHindsightConnection } from "@vectorize-io/hindsight-eve";

export default defineHindsightConnection({
url: "http://localhost:8000/mcp",
apiKey: null,
});

Options

defineHindsightConnection({
url, // MCP endpoint; defaults to HINDSIGHT_MCP_URL, then Cloud
apiKey, // bearer token; null = no auth (local dev)
bankId, // scope memory to a bank (X-Bank-Id header)
description, // override the model-facing description
tools, // { allow } | { block } — narrow which Hindsight tools the model sees
approval, // human-in-the-loop policy, e.g. once() from "eve/tools/approval"
});

Restrict the agent to read-only recall and require approval the first time:

import { defineHindsightConnection } from "@vectorize-io/hindsight-eve";
import { once } from "eve/tools/approval";

export default defineHindsightConnection({
tools: { allow: ["recall", "reflect"] },
approval: once(),
});