001-entity-resolution

A software agent that extracts named things and links between them from Markdown files using matching rules and lightweight language processing, without using an AI language model.

In plain words
What is it for?
Use it to find plans, agents, features, files, and dependencies in Markdown and prepare them for a knowledge graph.
Why use it?
It makes extraction fast, reproducible, and free from model-generated guesses for information that follows recognizable text patterns.

Agent

Install

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.

agentmods
npx agentmods add agents/paulbreuler/limps/001-entity-resolution
Clone the repo
git clone --depth 1 https://github.com/paulbreuler/limps
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,380 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01380
Opus 5 $0.00000 $0.00690
Sonnet 5 $0.00000 $0.00276
Haiku 4.5 $0.00000 $0.00138

Measured 2d ago against content hash 28a9da5e3e96, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

001-entity-resolution 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 2d 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.

plans/0042-Knowledge Graph Foundation/agents/001-entity-resolution.agent.md · 180 lines

How it starts

The opening of the file, as written. The whole thing — 180 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent 001: Dependency-Based Entity Extraction

Objective

Extract entities and relationships from markdown using regex patterns and lightweight NLP. No LLM calls.

Context

The arxiv paper (2507.03226) demonstrates dependency parsing achieves 94% of LLM performance. We apply this principle: use deterministic extraction that's fast, free, and reproducible.

Philosophy: If regex can do it, use regex. If NLP helps, use lightweight NLP (compromise.js). Never use LLM for extraction.

Tasks

1. Pattern Definitions (src/graph/patterns.ts)

export const PATTERNS = {
  // Plan references
  planId: /(?:plan\s*)?(\d{4})(?:[-\s]+([\w-]+))?/gi,
  planRef: /(?:plan\s+)?(\d{4})(?:#(\d{3}))?/gi,
  
  // Agent references  
  agentId: /(\d{4})#(\d{3})/g,
  agentHeader: /^#\s*Agent\s+(\d{3}):\s*(.+)$/gm,
  
  // Features
  featureHeader: /^###\s*(?:#(\d+):?\s*)?(.+)$/gm,
  featureStatus: /Status:\s*`?(GAP|WIP|PASS|BLOCKED)`?/gi,
  
  // Files (in frontmatter or inline)
  frontmatterFiles: /^files:\s*\[([^\]]+)\]/m,
  inlineFile: /`([\w\/\.-]+\.(ts|js|tsx|jsx|md|json|py|rs|go|sql))`/g,
  
  // Dependencies
  frontmatterDepends: /^depends:\s*\[([^\]]+)\]/m,
  inlineDepends: /depends\s+(?:on\s+)?(?:agent\s+)?(\d{4}#\d{3}|\d{3})/gi,
  
  // Tags
  frontmatterTags: /^tags:\s*\[([^\]]+)\]/m,
  inlineTag: /#([\w-]+)/g,
  
  // Status
  frontmatterStatus: /^status:\s*(\w+)/m,
};

2. Frontmatter Parser (src/graph/parser.ts)

export interface ParsedFrontmatter {
  title?: string;
  status?: 'GAP' | 'WIP' | 'PASS' | 'BLOCKED' | 'draft';
  depends?: string[];
  files?: string[];
  tags?: string[];
  persona?: string;
}

export function parseFrontmatter(content: string): ParsedFrontmatter {
  const match = content.match(/^---\n([\s\S]*?)\n---/);
  if (!match) return {};
  
  const yaml = match[1];
  const result: ParsedFrontmatter = {};
  
  // Parse each field with regex (faster than full YAML parse)
  const titleMatch = yaml.match(/^title:\s*(.+)$/m);
  if (titleMatch) result.title = titleMatch[1].trim();
  
  const statusMatch = yaml.match(/^status:\s*(\w+)$/m);
  if (statusMatch) result.status = statusMatch[1] as any;
  
  // Parse arrays
  const dependsMatch = yaml.match(/^depends:\s*\[([^\]]*)\]/m);
  if (dependsMatch) result.depends = parseArray(dependsMatch[1]);
  
  const filesMatch = yaml.match(/^files:\s*\[([^\]]*)\]/m);
  if (filesMatch) result.files = parseArray(filesMatch[1]);
  
  const tagsMatch = yaml.match(/^tags:\s*\[([^\]]*)\]/m);
  if (tagsMatch) result.tags = parseArray(tagsMatch[1]);
  
  return result;
}

function parseArray(str: string): string[] {
  return str.split(',').map(s => s.trim().replace(/['"]/g, '')).filter(Boolean);
}

Read the full file on GitHub · 180 lines

Changes

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.

  1. 2d ago First seen · 180 lines · 0 tokens per session scan A 28a9da5e3e96

Subscribe to this mod's changes

001-entity-resolution is an agent published in the GitHub repository paulbreuler/limps (10 stars, last pushed 6mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,380 tokens. 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-08-31.