MCPcopy Create free account
hub / github.com/KnowledgeXLab/LeanRAG / wrap_embedding_func_with_attrs

Function wrap_embedding_func_with_attrs

tools/_utils.py:254–261  ·  view source on GitHub ↗

Wrap a function with attributes

(**kwargs)

Source from the content-addressed store, hash-verified

252
253
254def wrap_embedding_func_with_attrs(**kwargs):
255 """Wrap a function with attributes"""
256
257 def final_decro(func) -> EmbeddingFunc:
258 new_func = EmbeddingFunc(**kwargs, func=func)
259 return new_func
260
261 return final_decro

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected