File-level node ID matching the skill.md spec: ``{parent_dir}_{stem}`` — one parent directory level, no extension. ``rel_path`` MUST be relative to the project root so top-level files collapse to a bare stem (``setup.py`` -> ``setup``) instead of picking up the root directory name. This
(rel_path: Path)
| 72 | |
| 73 | |
| 74 | def _file_node_id(rel_path: Path) -> str: |
| 75 | """File-level node ID matching the skill.md spec: ``{parent_dir}_{stem}`` — |
| 76 | one parent directory level, no extension. ``rel_path`` MUST be relative to |
| 77 | the project root so top-level files collapse to a bare stem (``setup.py`` -> |
| 78 | ``setup``) instead of picking up the root directory name. This must equal the |
| 79 | ID semantic subagents generate, or AST and semantic extraction split a file |
| 80 | into two disconnected ghost nodes (#1033).""" |
| 81 | return _make_id(_file_stem(rel_path)) |
| 82 | |
| 83 | |
| 84 | def _csharp_namespace_id(dotted_name: str) -> str: |