← Back to Skills Marketplace
jpengcheng523-netizen

episodic-memory-debugger

by jpengcheng523-netizen · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
122
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install jpeng-episodic-memory-debugger
Description
Provides tools for debugging episodic memory systems including recall precision analysis, multi-modal encoding validation, indexing efficiency checks, and ir...
README (SKILL.md)

Episodic Memory Debugger

Diagnose and fix episodic memory issues including recall precision, multi-modal encoding, and indexing problems.

When to Use

  • Debugging low recall precision in memory systems
  • Validating multi-modal encoding consistency
  • Checking indexing efficiency
  • Detecting irrelevant recall patterns
  • Analyzing memory drift over time
  • Optimizing retrieval ranking

Usage

const debugger = require('./skills/episodic-memory-debugger');

// Analyze recall precision
const analysis = debugger.analyzeRecallPrecision(memories, queries, groundTruth);
console.log('Precision:', analysis.overallPrecision);
console.log('Recall:', analysis.overallRecall);

// Detect encoding issues
const issues = debugger.detectEncodingIssues(memories);
console.log('Encoding consistency:', issues.consistency.consistency);

// Check indexing efficiency
const indexing = debugger.checkIndexingEfficiency(memories, indexStats);
console.log('Index coverage:', indexing.efficiency.coverage);

// Generate full diagnostic report
const report = debugger.generateDiagnosticReport(memories, queries, results, groundTruth);
console.log('Health score:', report.summary.healthScore);

API

analyzeRecallPrecision(memories, queries, groundTruth)

Analyze recall precision for a set of queries.

const queries = [
  { id: 'q1', text: 'meeting notes', results: [{ id: 'm1' }, { id: 'm2' }] }
];

const groundTruth = {
  'q1': ['m1', 'm3']  // m2 is irrelevant
};

const analysis = analyzeRecallPrecision(memories, queries, groundTruth);
// {
//   overallPrecision: 0.5,
//   overallRecall: 0.5,
//   f1Score: 0.5,
//   perQueryMetrics: [...],
//   issues: [{ type: 'low_precision', queryId: 'q1', ... }]
// }

detectEncodingIssues(memories)

Detect multi-modal encoding issues.

const issues = detectEncodingIssues(memories);
// {
//   consistency: { modalityStats: {...}, issues: [], consistency: 0.95 },
//   embeddingQuality: { stats: {...}, issues: [] },
//   crossModalAlignment: { alignments: [...], issues: [], avgAlignment: 0.8 }
// }

checkIndexingEfficiency(memories, indexStats)

Check indexing efficiency and detect issues.

const result = checkIndexingEfficiency(memories, {
  fragmentationRatio: 0.1,
  avgLookupTime: 50
});
// {
//   efficiency: { coverage: 0.98, indexedCount: 980, totalCount: 1000, issues: [] },
//   structure: { depth: 3, branchFactor: 100, utilization: 0.85, issues: [] },
//   duplicates: { duplicateCount: 5, duplicateRate: 0.005, duplicates: [...] }
// }

detectIrrelevantRecall(queries, groundTruth)

Detect patterns in irrelevant recalls.

const patterns = detectIrrelevantRecall(queries, groundTruth);
// {
//   byModality: { text: 10, image: 5 },
//   byTimeRange: { '\x3C1d': 3, '\x3C1w': 7, '>1m': 5 },
//   bySource: { email: 8, chat: 7 }
// }

generateDiagnosticReport(memories, queries, results, groundTruth)

Generate comprehensive diagnostic report.

const report = generateDiagnosticReport(memories, queries, results, groundTruth);
// {
//   timestamp: '2026-03-25T08:30:00.000Z',
//   summary: {
//     avgPrecision: 0.85,
//     avgRecall: 0.78,
//     f1Score: 0.81,
//     encodingConsistency: 0.95,
//     indexCoverage: 0.98,
//     healthScore: 0.87
//   },
//   details: { ... },
//   recommendations: [
//     { priority: 'high', area: 'recall_precision', recommendation: '...' }
//   ]
// }

Classes

RecallPrecisionAnalyzer

Analyze recall precision metrics.

const analyzer = new RecallPrecisionAnalyzer();

const analysis = analyzer.analyzeRecallPrecision(memories, queries, groundTruth);
const mrr = analyzer.calculateMRR(queries, groundTruth);
const ndcg = analyzer.calculateNDCG(queries, groundTruth, relevanceScores, 10);

MultiModalEncodingValidator

Validate multi-modal encoding consistency.

const validator = new MultiModalEncodingValidator();

const consistency = validator.validateEncodingConsistency(memories);
const quality = validator.checkEmbeddingQuality(memories, 'text');
const alignment = validator.detectCrossModalAlignment(memories);

IndexingEfficiencyChecker

Check indexing efficiency and structure.

const checker = new IndexingEfficiencyChecker();

const efficiency = checker.checkIndexingEfficiency(memories, indexStats);
const structure = checker.analyzeIndexStructure(memories, { branchFactor: 100 });
const duplicates = checker.checkDuplicates(memories, 0.99);

IrrelevantRecallDetector

Detect patterns in irrelevant recalls.

const detector = new IrrelevantRecallDetector();

const patterns = detector.detectIrrelevantPatterns(queries, groundTruth);
const scores = detector.scoreRelevance(query, memories);

MemoryDriftDetector

Detect memory drift over time.

const driftDetector = new MemoryDriftDetector();

// Set baseline
driftDetector.setBaseline(initialMemories);

// Detect drift
const drift = driftDetector.detectDrift(currentMemories);
// {
//   countDrift: 0.1,
//   embeddingDrift: 0.05,
//   modalityDrift: 0.02,
//   timeDrift: 0.15,
//   overallDrift: 0.08,
//   isSignificant: false
// }

Example: Full Memory System Diagnostic

const debugger = require('./skills/episodic-memory-debugger');

// Sample memories
const memories = [
  {
    id: 'm1',
    text: 'Meeting with John about project timeline',
    modalities: ['text'],
    embeddings: { text: [0.1, 0.2, 0.3, /* ... */] },
    timestamp: '2026-03-20T10:00:00Z',
    indexed: true
  },
  {
    id: 'm2',
    text: 'Lunch discussion about quarterly goals',
    modalities: ['text'],
    embeddings: { text: [0.4, 0.5, 0.6, /* ... */] },
    timestamp: '2026-03-21T12:00:00Z',
    indexed: true
  }
];

// Sample queries and ground truth
const queries = [
  {
    id: 'q1',
    text: 'project meeting',
    results: [{ id: 'm1' }, { id: 'm2' }]
  }
];

const groundTruth = {
  'q1': ['m1']  // Only m1 is relevant
};

// Generate diagnostic report
const report = debugger.generateDiagnosticReport(memories, queries, null, groundTruth);

console.log('=== Memory System Diagnostic Report ===');
console.log(`Health Score: ${(report.summary.healthScore * 100).toFixed(1)}%`);
console.log(`Precision: ${(report.summary.avgPrecision * 100).toFixed(1)}%`);
console.log(`Recall: ${(report.summary.avgRecall * 100).toFixed(1)}%`);
console.log(`Encoding Consistency: ${(report.summary.encodingConsistency * 100).toFixed(1)}%`);
console.log(`Index Coverage: ${(report.summary.indexCoverage * 100).toFixed(1)}%`);

if (report.recommendations.length > 0) {
  console.log('\
Recommendations:');
  for (const rec of report.recommendations) {
    console.log(`  [${rec.priority}] ${rec.area}: ${rec.recommendation}`);
  }
}

Example: Encoding Validation

const debugger = require('./skills/episodic-memory-debugger');

// Multi-modal memories
const memories = [
  {
    id: 'm1',
    text: 'Photo from vacation',
    modalities: ['text', 'image'],
    embeddings: {
      text: [0.1, 0.2, 0.3],
      image: [0.4, 0.5, 0.6]
    }
  },
  {
    id: 'm2',
    text: 'Voice memo',
    modalities: ['text', 'audio'],
    embeddings: {
      text: [0.7, 0.8, 0.9]
      // Missing audio embedding!
    }
  }
];

const issues = debugger.detectEncodingIssues(memories);

console.log('Encoding Consistency:', issues.consistency.consistency);
console.log('Issues found:', issues.consistency.issues.length);

for (const issue of issues.consistency.issues) {
  console.log(`  - ${issue.type}: ${issue.message}`);
}

// Check cross-modal alignment
console.log('\
Cross-modal Alignment:', issues.crossModalAlignment.avgAlignment);

Example: Index Optimization

const debugger = require('./skills/episodic-memory-debugger');

const memories = [/* ... */];

const result = debugger.checkIndexingEfficiency(memories, {
  fragmentationRatio: 0.15,
  avgLookupTime: 75
});

console.log('Index Coverage:', result.efficiency.coverage);
console.log('Duplicates Found:', result.duplicates.duplicateCount);

if (result.structure.issues.length > 0) {
  console.log('Structure Issues:');
  for (const issue of result.structure.issues) {
    console.log(`  - ${issue.message}`);
  }
}

Notes

  • Recall precision analysis requires ground truth labels
  • Multi-modal validation checks embedding consistency across modalities
  • Indexing efficiency includes duplicate detection
  • Memory drift detection helps identify concept drift
  • Diagnostic reports include prioritized recommendations
  • All metrics are calculated locally without external dependencies
Usage Guidance
The files shown look coherent with the skill's purpose and request no credentials, but the source preview is truncated and there is no homepage or clear author provenance. Before installing: 1) Inspect the full index.js for any network or I/O (look for fetch/axios/http/https/require('net')/require('fs')/child_process/process.env or hard-coded URLs/IPs). 2) Verify there are no calls that send memory contents to external endpoints or log sensitive data. 3) Run the package in a sandbox or isolated environment first. 4) If you need higher assurance, ask the publisher for the full repository or a cryptographic release (GitHub release or other verified source) and a brief explanation of telemetry or outbound connections. If you can't review the full source, treat it as untrusted code.
Capability Analysis
Type: OpenClaw Skill Name: jpeng-episodic-memory-debugger Version: 1.0.0 The episodic-memory-debugger skill provides a suite of analytical tools for evaluating AI memory systems, including metrics for recall precision, embedding quality, and indexing efficiency. The implementation in index.js consists of pure JavaScript logic for statistical calculations (e.g., cosine similarity, Jaccard index) and contains no network requests, file system access, or shell execution. The SKILL.md documentation accurately reflects the code's functionality without any evidence of prompt injection or malicious intent.
Capability Assessment
Purpose & Capability
Skill name, description, SKILL.md usage examples, and index.js functions (recall precision, encoding validation, indexing checks, drift detection) are aligned and coherent for an episodic-memory debugging utility.
Instruction Scope
SKILL.md instructs the agent to require the local module and call analysis functions; it does not ask the agent to read unrelated system files, environment variables, or send data to external endpoints in the visible text.
Install Mechanism
No install spec (instruction-only) is declared, but the package includes index.js and package.json. There's no external download or installer; the code will be written to disk when the skill is installed—this is expected but worth noting since no upstream homepage or repo is provided.
Credentials
The skill declares no required environment variables, credentials, or config paths; the visible code does not reference process.env or require secrets. This is proportionate to the described functionality.
Persistence & Privilege
Flags show always:false and normal autonomous-invocation settings. The skill does not request elevated or persistent platform privileges in metadata.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install jpeng-episodic-memory-debugger
  3. After installation, invoke the skill by name or use /jpeng-episodic-memory-debugger
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release: Episodic Memory Debugger skill for AI memory system analysis and diagnostics. - Analyze recall precision, recall, F1, and identify low-precision queries - Detect issues in multi-modal encoding, embedding quality, and cross-modal alignment - Check indexing efficiency, structure, and duplication in memory indices - Discover patterns in irrelevant recall by modality, time, and source - Generate comprehensive diagnostic reports with health scores and actionable recommendations - Includes tools and classes for recall analysis, encoding validation, index checks, irrelevant recall detection, and memory drift analysis
Metadata
Slug jpeng-episodic-memory-debugger
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is episodic-memory-debugger?

Provides tools for debugging episodic memory systems including recall precision analysis, multi-modal encoding validation, indexing efficiency checks, and ir... It is an AI Agent Skill for Claude Code / OpenClaw, with 122 downloads so far.

How do I install episodic-memory-debugger?

Run "/install jpeng-episodic-memory-debugger" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is episodic-memory-debugger free?

Yes, episodic-memory-debugger is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does episodic-memory-debugger support?

episodic-memory-debugger is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created episodic-memory-debugger?

It is built and maintained by jpengcheng523-netizen (@jpengcheng523-netizen); the current version is v1.0.0.

💬 Comments