MCPcopy Create free account
hub / github.com/FSoft-AI4Code/HyperAgent / __init__

Method __init__

src/hyperagent/tools/nav_tools.py:64–74  ·  view source on GitHub ↗
(self, path: str, language: str, index_path: Optional[str] = None, build: bool = False)

Source from the content-addressed store, hash-verified

62 backend: ZoektServer = None
63
64 def __init__(self, path: str, language: str, index_path: Optional[str] = None, build: bool = False):
65 super().__init__()
66 self.path = path
67 self.language = language
68 if build:
69 if not os.path.exists(index_path):
70 os.makedirs(index_path)
71 self.backend = ZoektServer(language)
72 self.backend.setup_index(path, index_path=index_path)
73 else:
74 self.backend = ZoektServer(language, repo_path=path, index_path=index_path)
75
76
77 def _run(self, names: list[str], verbose: bool = True):

Callers

nothing calls this directly

Calls 3

ZoektServerClass · 0.90
setup_indexMethod · 0.80
__init__Method · 0.45

Tested by

no test coverage detected