Skip to content

Latest commit

 

History

History
19 lines (13 loc) · 442 Bytes

File metadata and controls

19 lines (13 loc) · 442 Bytes

Basic Example

Minimal GsRag setup with OpenAI providers and local JSON storage.

What It Demonstrates

  • Creating a GsRag instance
  • Inserting content with insertDocuments()
  • Querying with local, global, hybrid, naive, mix, and bypass modes
  • Gracefully finalizing storage backends

Run

export OPENAI_API_KEY=sk-...
bun examples/basic/index.ts

The example writes local data to ./lightrag-data/basic.