Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add CarbeneAI/Forge --skill semanticmemorygit clone --depth 1 https://github.com/CarbeneAI/ForgeWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/carbeneai/forge/semanticmemory)<a href="https://agentmods.dev/skills/carbeneai/forge/semanticmemory"><img src="https://agentmods.dev/badge/skills/carbeneai/forge/semanticmemory/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/carbeneai/forge/semanticmemory"><img src="https://agentmods.dev/badge/skills/carbeneai/forge/semanticmemory.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00090 | $0.02009 |
| Opus 5 | $0.00045 | $0.01005 |
| Sonnet 5 | $0.00018 | $0.00402 |
| Haiku 4.5 | $0.00009 | $0.00201 |
Grade A, and why
SemanticMemory scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 208 lines — stays where its author put it; the contents beside it link to each section on GitHub.
SemanticMemory
Hybrid BM25 + vector search across all PAI knowledge sources. Combines keyword matching (FTS5) with semantic understanding (OpenAI embeddings) to find relevant past work, sessions, learnings, research, and notes.
Workflow Routing
When executing a workflow, call the notification script via Bash:
${PAI_DIR}/tools/skill-workflow-notification WorkflowName SemanticMemory
| Action | Trigger | Behavior |
|---|---|---|
| Search | "what did we do about X", "find past work on Y" | workflows/Search.md |
| Setup | "set up semantic memory", "first sync" | workflows/Setup.md |
| Knowledge Graph | "add fact", "who works on X", "timeline for Y" | tools/KnowledgeGraph.ts |
| Context Load | "wake up", "load context", "essential story" | tools/ContextLoader.ts |
| Tunnels | "find connections", "what topics bridge X and Y" | tools/Tunnels.ts |
Source Types Indexed
| Source | Directory | Content |
|---|---|---|
session |
${PAI_DIR}/history/sessions/ |
Session summaries |
learning |
${PAI_DIR}/history/learnings/ |
Problem-solving narratives |
research |
${PAI_DIR}/history/research/ |
Research outputs |
obsidian |
~/Nextcloud/PAI/Obsidian/ |
Personal knowledge base |
memory |
${PAI_DIR}/memory/ |
Project-specific knowledge |
raw-output |
${PAI_DIR}/history/raw-outputs/ |
Session event logs (JSONL) |
CLI Tools
SemanticSearch.ts - Search memory
# Basic search
bun ${PAI_DIR}/skills/SemanticMemory/tools/SemanticSearch.ts "How did we set up Traefik SSL?"
# Filter by source
bun ${PAI_DIR}/skills/SemanticMemory/tools/SemanticSearch.ts "auth flow" --source session,learning
# JSON output for scripting
bun ${PAI_DIR}/skills/SemanticMemory/tools/SemanticSearch.ts "infrastructure" --json --limit 5
# Sync before searching
bun ${PAI_DIR}/skills/SemanticMemory/tools/SemanticSearch.ts "recent work" --sync
IndexManager.ts - Manage the index
What ships with it
27 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- bun.lock 2.5 KB
- identity.txt 221 B
- package.json 279 B
- src/chunker.ts 10 KB runs code
- src/config.ts 7.9 KB runs code
- src/db.ts 7.8 KB runs code
- src/embeddings-gemini.ts 5.8 KB runs code
- src/embeddings-openai.ts 4.0 KB runs code
- src/embeddings.ts 5.1 KB runs code
- src/index-manager.ts 19 KB runs code
- src/knowledge-graph.ts 13 KB runs code
- src/layers.ts 13 KB runs code
- src/search.ts 9.8 KB runs code
- src/tunnels.ts 17 KB runs code
- src/types.ts 5.3 KB runs code
- src/usage-tracker.ts 4.2 KB runs code
- src/watcher.ts 8.4 KB runs code
- tests/smoke-test.ts 10 KB runs code
- tools/ContextLoader.ts 12 KB runs code
- tools/IndexManager.ts 20 KB runs code
- tools/KnowledgeGraph.ts 13 KB runs code
- tools/MemorySync.ts 7.6 KB runs code
- tools/SemanticSearch.ts 9.1 KB runs code
- tools/StatsServer.ts 1.5 KB runs code
- tools/Tunnels.ts 19 KB runs code
- workflows/Search.md 1.9 KB
- workflows/Setup.md 2.7 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 208 lines · 90 tokens per session scan A 53a31ad2c769
SemanticMemory is a skill published in the GitHub repository CarbeneAI/Forge (9 stars, last pushed 1mo ago), licensed MIT. It adds 90 tokens to every session and 2,009 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
knowledge-management
../../../governance/knowledge-management/SKILL.md.
analyzing-memory-forensics-with-lime-and-volatility
Performs Linux memory acquisition using LiME (Linux Memory Extractor) kernel module and analysis with Volatility 3 framework. Extracts process lists, network connections, bash history, loaded kernel modules, and injected code from Linux memory images. Use when performing incident response on compromised Linux systems.
wiki-retrieve
Build and query a vault-local contextual BM25 retrieval index with optional multilingual Nomic cosine reranking; use for retrieve, hybrid retrieval, BM25, rerank, contextual retrieval, chunk search, vault search, semantic search, find relevant passages, or retrieval diagnostics. Derived caches stay under .vault-meta…
obsidian-bases
Explain, draft, and validate Obsidian Bases .base files with filters, formulas, properties, summaries, and table, card, or list views. Use for Obsidian Bases, database-like vault views, dynamic tables, reading lists, task trackers, filters, formulas, summaries, and .base file edits.
commonly
You are a member of a Commonly workspace — a shared space where humans and AI agents from any origin collaborate in pods (chat rooms with memory). Use this whenever you are connected to Commonly via the commonly MCP tools: to read what's happening, post, remember things across sessions, react, DM other agents, and…
daily-briefing
Proactive daily briefing that fires on a recurring schedule, pulls recent memory and workspace context, composes a structured summary (action items, progress, radar, next steps), and delivers it to all active channels. Enable with a time like "set up my daily briefing at 9am". Disable, reschedule, or check status at…