🚀. Socket Launch Week Day 3:Socket Firewall Now Blocks Malicious VS Code and Open VSX Extensions.Learn more
Sign In

@dewtech/dare-graphrag

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dewtech/dare-graphrag

DARE Framework GraphRAG - Knowledge graph with SQLite persistence and FTS5 search

latest
Source
npmnpm
Version
0.3.5
Version published
Weekly downloads
12
-40%
Maintainers
1
Weekly downloads
 
Created
Source

@dewtech/dare-graphrag

Knowledge graph engine for DARE Framework with SQLite persistence (via sql.js) and semantic search.

Features

  • SQLite persistence via pure JavaScript (sql.js) without native compilation
  • 7 node types: task, file, schema, endpoint, component, entity, concept
  • 7 edge types: depends_on, implements, uses, references, related_to, contains, extends
  • LIKE-based full-text search for semantic queries
  • Graph traversal for dependency analysis
  • Import/export to JSON format

Installation

npm install @dewtech/dare-graphrag

Usage

import { GraphRAG } from '@dewtech/dare-graphrag';

const graph = new GraphRAG('.dare/graph.db');
await graph.init();

// Add nodes
graph.addNode({
  id: 'task-001',
  type: 'task',
  label: 'Implement authentication',
  description: 'JWT-based auth with refresh tokens',
  metadata: { status: 'PENDING', complexity: 'HIGH' }
});

graph.addNode({
  id: 'file-auth-rs',
  type: 'file',
  label: 'auth.rs',
  description: 'Authentication module',
  metadata: { path: 'src/auth.rs', language: 'rust' }
});

// Add edges
graph.addEdge({
  id: 'edge-001',
  sourceId: 'task-001',
  targetId: 'file-auth-rs',
  type: 'implements'
});

// Semantic search (saves tokens vs reading full files)
const results = graph.searchNodes('authentication JWT', 5);
results.forEach(r => console.log(r.node.label, r.score));

// Get dependencies
const deps = graph.getNodeDependencies('task-003', 2);

// Statistics
const stats = graph.getStatistics();
console.log(`${stats.totalNodes} nodes, ${stats.totalEdges} edges`);

// Export/Import
const json = graph.exportToJson();
graph.importFromJson(json);

graph.close();

Node Types

TypeDescription
taskDARE task from dare-dag.yaml
fileSource code file
schemaDatabase table/schema
endpointAPI endpoint
componentUI component
entityDomain entity
conceptAbstract concept

Edge Types

TypeDescription
depends_onTask/file dependency
implementsTask implements file/endpoint
usesComponent uses schema/endpoint
referencesFile references another file
related_toGeneral relation
containsParent-child containment
extendsInheritance/extension

Performance

  • sql.js: pure JavaScript, no C compiler required
  • LIKE-based search for cross-platform compatibility
  • Indexes: type/label queries in O(log n)
  • Cache: 10k pages in memory

Keywords

dare

FAQs

Package last updated on 04 May 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts