AI & LLM
LangChain / LlamaIndex Document JSON Example
A JSON example of a LangChain / LlamaIndex Document object — page_content plus metadata such as source, page, and ids. Copy-ready for RAG loaders, splitters, and vector stores.
Field Reference
page_contentrequiredstringThe text payload of the document — what gets embedded and retrievedmetadatarequiredobjectArbitrary key–value attributes carried alongside the text (source, page, ids, tags)metadata.sourceoptionalstringWhere the content came from — used for citations and filteringidoptionalstringStable document/node id; LlamaIndex calls it node_idtypeoptionalstringObject type marker used by serializers ('Document')Variants
LlamaIndex TextNodeLlamaIndex's node format with relationships and a hash.
Loader output (array)A document loader typically returns an array of Documents, one per chunk or file.
Common Use Cases
- →Loading and chunking files into a RAG pipeline with LangChain or LlamaIndex
- →Carrying source metadata through to citations in answers
- →Serializing documents to JSON for storage or transport between services
langchainllamaindexdocumentragloaderembeddings
Validate or format this JSON
One click loads this exact example into the tool — no copy-paste needed. Format it, validate it, explore the tree, or generate TypeScript types instantly.
Frequently Asked Questions
Related JSON Examples
AI & LLMRAG Document ChunkA RAG chunk with text, source metadata, embedding reference, and relevance score.AI & LLMEmbedding Vector ResponseEmbeddings API response with the vector array, model, and usage.AI & LLMVector Database Search QueryVector DB query with topK and filter, plus a ranked matches response.