mcp-vector-search 0.7.6__py3-none-any.whl → 0.8.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of mcp-vector-search might be problematic. Click here for more details.

@@ -150,6 +150,18 @@ class PythonParser(BaseParser):
150
150
  # Extract docstring if present
151
151
  docstring = self._extract_docstring(node, lines)
152
152
 
153
+ # Enhancement 1: Calculate complexity
154
+ complexity = self._calculate_complexity(node, "python")
155
+
156
+ # Enhancement 4: Extract decorators
157
+ decorators = self._extract_decorators(node, lines)
158
+
159
+ # Enhancement 4: Extract parameters
160
+ parameters = self._extract_parameters(node)
161
+
162
+ # Enhancement 4: Extract return type
163
+ return_type = self._extract_return_type(node)
164
+
153
165
  chunk = self._create_chunk(
154
166
  content=content,
155
167
  file_path=file_path,
@@ -159,6 +171,11 @@ class PythonParser(BaseParser):
159
171
  function_name=function_name,
160
172
  class_name=class_name,
161
173
  docstring=docstring,
174
+ complexity_score=complexity,
175
+ decorators=decorators,
176
+ parameters=parameters,
177
+ return_type=return_type,
178
+ chunk_depth=2 if class_name else 1,
162
179
  )
163
180
  chunks.append(chunk)
164
181
 
@@ -180,6 +197,12 @@ class PythonParser(BaseParser):
180
197
  # Extract docstring if present
181
198
  docstring = self._extract_docstring(node, lines)
182
199
 
200
+ # Enhancement 1: Calculate complexity (for the entire class)
201
+ complexity = self._calculate_complexity(node, "python")
202
+
203
+ # Enhancement 4: Extract decorators
204
+ decorators = self._extract_decorators(node, lines)
205
+
183
206
  chunk = self._create_chunk(
184
207
  content=content,
185
208
  file_path=file_path,
@@ -188,6 +211,9 @@ class PythonParser(BaseParser):
188
211
  chunk_type="class",
189
212
  class_name=class_name,
190
213
  docstring=docstring,
214
+ complexity_score=complexity,
215
+ decorators=decorators,
216
+ chunk_depth=1,
191
217
  )
192
218
  chunks.append(chunk)
193
219
 
@@ -410,6 +436,59 @@ class PythonParser(BaseParser):
410
436
 
411
437
  return None
412
438
 
439
+ def _extract_decorators(self, node, lines: list[str]) -> list[str]:
440
+ """Extract decorator names from function/class node."""
441
+ decorators = []
442
+ for child in node.children:
443
+ if child.type == "decorator":
444
+ # Get decorator text (includes @ symbol)
445
+ dec_text = self._get_node_text(child).strip()
446
+ decorators.append(dec_text)
447
+ return decorators
448
+
449
+ def _extract_parameters(self, node) -> list[dict]:
450
+ """Extract function parameters with type annotations."""
451
+ parameters = []
452
+ for child in node.children:
453
+ if child.type == "parameters":
454
+ for param_node in child.children:
455
+ if param_node.type in ("identifier", "typed_parameter", "default_parameter"):
456
+ param_info = {
457
+ "name": None,
458
+ "type": None,
459
+ "default": None
460
+ }
461
+
462
+ # Extract parameter name
463
+ if param_node.type == "identifier":
464
+ param_info["name"] = self._get_node_text(param_node)
465
+ else:
466
+ # For typed or default parameters, find the identifier
467
+ for subchild in param_node.children:
468
+ if subchild.type == "identifier":
469
+ param_info["name"] = self._get_node_text(subchild)
470
+ elif subchild.type == "type":
471
+ param_info["type"] = self._get_node_text(subchild)
472
+ elif "default" in subchild.type:
473
+ param_info["default"] = self._get_node_text(subchild)
474
+
475
+ if param_info["name"] and param_info["name"] not in ("self", "cls", "(", ")", ","):
476
+ parameters.append(param_info)
477
+ return parameters
478
+
479
+ def _extract_return_type(self, node) -> str | None:
480
+ """Extract return type annotation from function."""
481
+ for child in node.children:
482
+ if child.type == "type":
483
+ return self._get_node_text(child)
484
+ return None
485
+
486
+ def _get_node_text(self, node) -> str:
487
+ """Get text content of a node."""
488
+ if hasattr(node, 'text'):
489
+ return node.text.decode('utf-8')
490
+ return ""
491
+
413
492
  def get_supported_extensions(self) -> list[str]:
414
493
  """Get supported file extensions."""
415
494
  return [".py", ".pyw"]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mcp-vector-search
3
- Version: 0.7.6
3
+ Version: 0.8.2
4
4
  Summary: CLI-first semantic code search with MCP integration
5
5
  Project-URL: Homepage, https://github.com/bobmatnyc/mcp-vector-search
6
6
  Project-URL: Documentation, https://mcp-vector-search.readthedocs.io
@@ -1,24 +1,25 @@
1
- mcp_vector_search/__init__.py,sha256=uCiRqZa2nOSwiJn4R2PLaOCVCAktfKrSkfvuFMeIUjQ,299
1
+ mcp_vector_search/__init__.py,sha256=SJWzBn_EMpgwyAGK_RAudIBKV_lD9imaFJvi0dh62pc,299
2
2
  mcp_vector_search/py.typed,sha256=lCKeV9Qcn9sGtbRsgg-LJO2ZwWRuknnnlmomq3bJFH0,43
3
3
  mcp_vector_search/cli/__init__.py,sha256=TNB7CaOASz8u3yHWLbNmo8-GtHF0qwUjVKWAuNphKgo,40
4
4
  mcp_vector_search/cli/didyoumean.py,sha256=F_ss-EX4F9RgnMsEhdTwLpyNCah9SqnBZc2tBtzASck,15918
5
5
  mcp_vector_search/cli/export.py,sha256=iluxuRT2KELdKlQeDAlVkteiel4GGrng153UAw9H0as,10804
6
6
  mcp_vector_search/cli/history.py,sha256=6wRrSfxpUe9hJXuaEeVxOVkFlcpqkIiGfwzDgd5N6c8,9323
7
7
  mcp_vector_search/cli/interactive.py,sha256=T7P4dAdvbglznzQYgiePv5YNyOx9FeE57Y3OKYnnbYE,12744
8
- mcp_vector_search/cli/main.py,sha256=nmnySb1PJpyzngR2ulvafa5zPtZ9faDKo_AFdkRBiU8,14507
8
+ mcp_vector_search/cli/main.py,sha256=oFyuocKZK9fN4XY1xejPgI3lMo4E0dplJ4SasfLZluo,14770
9
9
  mcp_vector_search/cli/output.py,sha256=7ShIk_UKzhDzRGxI6JluPu0gGkbmKOevqgIAKR4oCa0,12560
10
10
  mcp_vector_search/cli/suggestions.py,sha256=h-UaxoLcHmFbhZSm0WG7nKJXAIRIqhv7aGsXijp7vA8,13273
11
11
  mcp_vector_search/cli/commands/__init__.py,sha256=vQls-YKZ54YEwmf7g1dL0T2SS9D4pdQljXzsUChG_V4,42
12
12
  mcp_vector_search/cli/commands/auto_index.py,sha256=imVVbxWRlA128NPdK9BetNNl3ELrsdq-hqcsLqyAmoM,12712
13
13
  mcp_vector_search/cli/commands/config.py,sha256=mKE8gUgAOqCM__4yzEEu9HJPbx9X15lN264zkDJBRxg,12399
14
14
  mcp_vector_search/cli/commands/demo.py,sha256=MVfEkYmA2abRFwAbk-lpa6P14_SLJBHZAuHb9d6d02U,10630
15
- mcp_vector_search/cli/commands/index.py,sha256=K_5gmmgclfkyXDvucBPdnvbYzyfa53eVbPdkuWiqZUk,22106
15
+ mcp_vector_search/cli/commands/index.py,sha256=Amo8DOcp1WZrLcPqIWH8nrZU-mfDkjZIbumytFAx2Bw,22377
16
16
  mcp_vector_search/cli/commands/init.py,sha256=2kdjtIPPeutKUXs65-6W1VQPF_BQrbV6_U3TCE7U5mw,23242
17
17
  mcp_vector_search/cli/commands/install.py,sha256=phk7Eb7UOU5IsRfJyaDPdOfdUWli9gyA4cHjhgXcNEI,24609
18
18
  mcp_vector_search/cli/commands/mcp.py,sha256=Mk4g43R9yRiJVMxsDFUsZldKqY0yi2coQmhAqIMPklo,38958
19
19
  mcp_vector_search/cli/commands/reset.py,sha256=bsIT6zjDf6gsvIkVaRaUClYzlTyNe--8t0NWkBY0ldU,13724
20
20
  mcp_vector_search/cli/commands/search.py,sha256=yyou7wO9qZ_w2oiKdyOrk2WUxvkFpc-Up8hpflxYlyw,24802
21
21
  mcp_vector_search/cli/commands/status.py,sha256=sa_0QHioCmPF5A7obqV2ls-9kmX_JYo7nq3XUe1dmrg,19630
22
+ mcp_vector_search/cli/commands/visualize.py,sha256=QLefmVaeRUbdnabtEuCTkZXtVlL4DLVk4zeITFDGPww,16579
22
23
  mcp_vector_search/cli/commands/watch.py,sha256=2pyWRoo4fIppFnyQ4sW4IBLHmpb_IwnTjRnzHkVBPcQ,8927
23
24
  mcp_vector_search/config/__init__.py,sha256=r_qAQkU5gc0EQ2pv8EQARACe4klhrR_WRJqCb9lfGc0,54
24
25
  mcp_vector_search/config/constants.py,sha256=afXR6SvLLd8QYY4MG4s1vq-hCJiQsE5PhnE-XG9lvb4,1092
@@ -32,8 +33,8 @@ mcp_vector_search/core/embeddings.py,sha256=wSMUNxZcuGPMxxQ1AbKqA1a3-0c6AiOqmuuI
32
33
  mcp_vector_search/core/exceptions.py,sha256=3bCjT8wmrLz_0e_Tayr90049zNTKYFWZa19kl0saKz8,1597
33
34
  mcp_vector_search/core/factory.py,sha256=tM6Ft-V9buF7nn9xbRMU1ngji-BJOKt6BhtfQhFLmF4,10384
34
35
  mcp_vector_search/core/git_hooks.py,sha256=xOfPpzgKoNTwM-vbhAihUucgudBQk45bCAVR5zJOFlQ,10878
35
- mcp_vector_search/core/indexer.py,sha256=ecGhoIGvdWfqkQuZrB5MeXoZOp-XZ1zbRum4pV9ICao,25428
36
- mcp_vector_search/core/models.py,sha256=fnZxvUkd9Afxmdwtw2BJX7uik6rQTwuWBTTqTeqDi0A,6697
36
+ mcp_vector_search/core/indexer.py,sha256=IpCzP50wLOttWuUI-NE0qwYq-LlbDo5lrGfVMFMzwAM,29089
37
+ mcp_vector_search/core/models.py,sha256=h54wTwwXR5qU-YOVi8q8NEFmpnQfC4S0ER2mMJqn4bk,8512
37
38
  mcp_vector_search/core/project.py,sha256=l81uc5B4CB8VXDbcHzF-_CagxIERDh23tH0iNqTePTs,10403
38
39
  mcp_vector_search/core/scheduler.py,sha256=PBSlu-ieDYCXOMGYY7QKv9UReFEDPHNmwnUv_xb4vxg,11761
39
40
  mcp_vector_search/core/search.py,sha256=9OC8-KwWdbw4y4QPQ-VXfz0encVHTJWYLtah3_chqG8,33682
@@ -42,12 +43,12 @@ mcp_vector_search/mcp/__init__.py,sha256=gfKR0QV7Jqvj5y0LMBe9gSghd5_rPsvm_rml0ry
42
43
  mcp_vector_search/mcp/__main__.py,sha256=KgwB59HM5pRLe2Aj-fvDFcTp95lyT0wfmS3ENcx9gPc,571
43
44
  mcp_vector_search/mcp/server.py,sha256=YmHyvJqg_CjxEN356ShFrTPLgDKzaLXyrt8tNHVryEY,28322
44
45
  mcp_vector_search/parsers/__init__.py,sha256=jr0Yqz1xMok4lnG7_aXnkZThGuefrlAj8PWVbfeT3QQ,228
45
- mcp_vector_search/parsers/base.py,sha256=kOurwRR4xlyIje9rHLlEVa-OCl1LK8ih_fAFWHFg78g,5395
46
+ mcp_vector_search/parsers/base.py,sha256=KS0bJeGoZamdqGS7KdAOGFxO_P_-TsjrlBnuzeu8B5U,8768
46
47
  mcp_vector_search/parsers/dart.py,sha256=li2JP0vwpSsZnMNq0PweZCD_o-y1jUwubHlSA8nm8KQ,21816
47
48
  mcp_vector_search/parsers/html.py,sha256=nzEVDV4oCBp3wpL8vp6WWx5eqiB39agu9E048JkuRJQ,13010
48
- mcp_vector_search/parsers/javascript.py,sha256=P7fT_tXCzUuXATTkTx_DyD4EuG0_KjIDlay09MhkKTE,9824
49
+ mcp_vector_search/parsers/javascript.py,sha256=WlEBDr773TM4D6KNpHQq93vtbzZ7xtXWNkOivLGMsAE,23386
49
50
  mcp_vector_search/parsers/php.py,sha256=1QjnE8SAQF86VQ7pNfn1Pmpg5Dni4M7KCLU7212DkXM,24774
50
- mcp_vector_search/parsers/python.py,sha256=IB4gQ6DD6Oqvws5p3LQtHTJOtmH6f9FWmO9fQRfGQx4,15688
51
+ mcp_vector_search/parsers/python.py,sha256=1KwubEIpyxHPCnlxN8EMb745A14JJ7J4YO2iVOeuHfs,19092
51
52
  mcp_vector_search/parsers/registry.py,sha256=L00EUp58ff_xatgQW-cBvE0AVBQi7cGtvr6zWV_NYbc,6457
52
53
  mcp_vector_search/parsers/ruby.py,sha256=xNn_z8txAWL7E1ULcFMiqn5idFhf5GQn8N3x1yE-c2k,23818
53
54
  mcp_vector_search/parsers/text.py,sha256=jvMdFspbmrrOR1GSGzf2gvBDCXz1cPN_xemoDK4fUvM,6084
@@ -56,8 +57,8 @@ mcp_vector_search/utils/__init__.py,sha256=Eq6lY-oPMfCt-GpPUbg9QbmTHuQVmTaVDBMU2
56
57
  mcp_vector_search/utils/gitignore.py,sha256=GiHQu9kv9PRLsWuNS8kbpXsTaBdhlsSHTu1NrZ8Ug5Y,8162
57
58
  mcp_vector_search/utils/timing.py,sha256=THC7mfbTYnUpnnDcblgQacYMzbEkfFoIShx6plmhCgg,11285
58
59
  mcp_vector_search/utils/version.py,sha256=d7fS-CLemxb8UzZ9j18zH0Y0Ud097ljKKYYOPulnGPE,1138
59
- mcp_vector_search-0.7.6.dist-info/METADATA,sha256=dYUERzUd9cC8KWmKNj_AtoEE2OoOPeiXqmSpN3qWf0k,19120
60
- mcp_vector_search-0.7.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
61
- mcp_vector_search-0.7.6.dist-info/entry_points.txt,sha256=y3Ygtc_JiBchNEIL-tPABo7EbzBExGAxwGdkkeP5D2I,86
62
- mcp_vector_search-0.7.6.dist-info/licenses/LICENSE,sha256=FqZUgGJH_tZKZLQsMCpXaLawRyLmyFKRVfMwYyEcyTs,1072
63
- mcp_vector_search-0.7.6.dist-info/RECORD,,
60
+ mcp_vector_search-0.8.2.dist-info/METADATA,sha256=hyZnlaTWcDJ5SmHpQNVADg26RpQxy9pO-iZXgD-kWiw,19120
61
+ mcp_vector_search-0.8.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
62
+ mcp_vector_search-0.8.2.dist-info/entry_points.txt,sha256=y3Ygtc_JiBchNEIL-tPABo7EbzBExGAxwGdkkeP5D2I,86
63
+ mcp_vector_search-0.8.2.dist-info/licenses/LICENSE,sha256=FqZUgGJH_tZKZLQsMCpXaLawRyLmyFKRVfMwYyEcyTs,1072
64
+ mcp_vector_search-0.8.2.dist-info/RECORD,,