@mastra/rag
TypeScript icon, indicating that this package has built-in type declarations

0.1.22 • Public • Published

@mastra/rag

The Retrieval-Augmented Generation (RAG) module contains document processing and embedding utilities.

Installation

npm install @mastra/rag

Components

Document

The MDocument class represents text content with associated metadata:

import { MDocument } from '@mastra/rag';

const doc = new MDocument({
  text: 'Document content',
  metadata: { source: 'example.txt' },
});

Documentation

Package Sidebar

Install

npm i @mastra/rag

Weekly Downloads

7,567

Version

0.1.22

License

Elastic-2.0

Unpacked Size

932 kB

Total Files

60

Last publish

Collaborators

  • smthomas
  • abhiaiyer
  • ifedayo
  • adeleke5140
  • taofeeq-deru
  • ehindero
  • calcsam
  • rase-
  • wardpeet
  • tylerbarnes
  • nikaiyer