MCPcopy Create free account
hub / github.com/AQ-MedAI/MedMemoryBench / _create_embeddings

Method _create_embeddings

methods/graph_rag.py:177–180  ·  view source on GitHub ↗

Create embeddings for document splits.

(self, splits: List, embedding_model)

Source from the content-addressed store, hash-verified

175 self.graph.add_node(i, content=split.page_content)
176
177 def _create_embeddings(self, splits: List, embedding_model) -> np.ndarray:
178 """Create embeddings for document splits."""
179 texts = [split.page_content for split in splits]
180 return embedding_model.embed_documents(texts)
181
182 def _extract_concepts(self, splits: List, llm) -> None:
183 """Extract concepts from all splits using multi-threading."""

Callers 1

build_graphMethod · 0.95

Calls 1

embed_documentsMethod · 0.80

Tested by

no test coverage detected