{"record":{"id":"43b98e2b0a2b64d8","repo":"run-llama/llama_index","slug":"vector-store-integrations-that-store-text-in-the-v","errorCode":null,"errorMessage":"Vector store integrations that store text in the vector store are not supported by ref_doc_info yet.","messagePattern":"Vector store integrations that store text in the vector store are not supported by ref_doc_info yet\\.","errorType":"exception","errorClass":"NotImplementedError","httpStatus":null,"severity":"error","filePath":"llama-index-core/llama_index/core/indices/vector_store/base.py","lineNumber":481,"sourceCode":"        \"\"\"Retrieve a dict mapping of ingested documents and their nodes+metadata.\"\"\"\n        if not self._vector_store.stores_text or self._store_nodes_override:\n            node_doc_ids = list(self.index_struct.nodes_dict.values())\n            nodes = self.docstore.get_nodes(node_doc_ids)\n\n            all_ref_doc_info = {}\n            for node in nodes:\n                ref_node = node.source_node\n                if not ref_node:\n                    continue\n\n                ref_doc_info = self.docstore.get_ref_doc_info(ref_node.node_id)\n                if not ref_doc_info:\n                    continue\n\n                all_ref_doc_info[ref_node.node_id] = ref_doc_info\n            return all_ref_doc_info\n        else:\n            raise NotImplementedError(\n                \"Vector store integrations that store text in the vector store are \"\n                \"not supported by ref_doc_info yet.\"\n            )\n\n\nGPTVectorStoreIndex = VectorStoreIndex\n","sourceCodeStart":463,"sourceCodeEnd":488,"githubUrl":"https://github.com/run-llama/llama_index/blob/afd0fef371831f9bda13e5af7167cf4e981278ab/llama-index-core/llama_index/core/indices/vector_store/base.py#L463-L488","documentation":"VectorStoreIndex.ref_doc_info raises NotImplementedError when the index's vector store has stores_text=True. When text lives in the vector store, ref-doc metadata (node ids, metadata per source doc) is not mirrored into the local docstore, and the framework has not implemented fetching it from the store, so the property refuses rather than returning wrong/empty data. With stores_text=False the property works via self.docstore.get_ref_doc_info.","triggerScenarios":"Reading index.ref_doc_info on an index backed by a stores_text=True store (default in-memory SimpleVectorStore path, most managed integrations); generic admin/dedup tooling that enumerates ingested docs via ref_doc_info across index types.","commonSituations":"Building a document-management dashboard that lists source docs; checking ingestion status after insert; code written against a docstore-backed index reused on a text-storing store.","solutions":["Track source documents yourself at insert time (you receive node ids from index.insert/ref_doc_id) instead of querying ref_doc_info.","If you need the property, use a stores_text=False configuration with a docstore (StorageContext with your own docstore) so ref-doc info lives locally.","Guard access: check index.vector_store.stores_text before touching ref_doc_info."],"exampleFix":"# before\ninfo = index.ref_doc_info  # NotImplementedError when stores_text=True\n\n# after\nif index.vector_store.stores_text:\n    info = {d.id_: d.metadata for d in my_tracked_docs}  # tracked at insert time\nelse:\n    info = index.ref_doc_info","handlingStrategy":"type-guard","validationCode":"def ref_doc_info_safe(index):\n    if index.vector_store.stores_text:\n        return None  # not supported for text-storing vector stores\n    return index.ref_doc_info","typeGuard":"def supports_ref_doc_info(index) -> bool:\n    return not index.vector_store.stores_text","tryCatchPattern":"try:\n    info = index.ref_doc_info\nexcept NotImplementedError:\n    info = None  # fall back to your own ingestion-time tracking","preventionTips":["Record source doc ids and metadata yourself at insert() time; do not rely on ref_doc_info for stores_text=True indexes.","Branch on index.vector_store.stores_text in generic admin tooling.","If ref_doc_info is essential, configure a docstore-backed (stores_text=False) deployment."],"tags":["vector-store","not-implemented","metadata","llama-index"],"backgroundTag":null,"analyzedSha":"afd0fef371831f9bda13e5af7167cf4e981278ab","analyzedAt":"2026-08-15T05:42:58.429Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}