diff --git a/config/config.yaml b/config/config.yaml index a2653af..b7f12ff 100644 --- a/config/config.yaml +++ b/config/config.yaml @@ -14,11 +14,54 @@ repository: - "__pycache__" - "node_modules" - ".git" + - ".git/*" - "*.min.js" - "*.bundle.js" - "dist/*" - "build/*" - "*.lock" + # OmniLore workspace size control (avoid indexing generated/runtime trees) + - ".backup-*" + - ".backup-*/*" + - ".omnilore" + - ".omnilore/*" + - ".omnilore_persist" + - ".omnilore_persist/*" + - ".venv" + - ".venv/*" + - ".venv-*" + - ".venv-*/*" + - "venv*" + - "venv*/*" + - "output" + - "output/*" + - "out" + - "out/*" + - "reports" + - "reports/*" + - "docs" + - "docs/*" + - "external" + - "external/*" + - "node_modules/*" + - ".mypy_cache" + - ".mypy_cache/*" + - ".pytest_cache" + - ".pytest_cache/*" + - ".hypothesis" + - ".hypothesis/*" + - "htmlcov" + - "htmlcov/*" + - "logs" + - "logs/*" + - "artifacts" + - "artifacts/*" + - "archives" + - "archives/*" + - "data" + - "data/*" + - "chroma" + - "chroma/*" supported_extensions: - .py - .js @@ -38,14 +81,7 @@ repository: - .kt - .pyx - .toml - - .md - - .txt - .yaml - - .rst - - .json - - .html - - .css - - .xml # Parser Settings parser: @@ -116,7 +152,7 @@ retrieval: max_files_to_search: 15 # Agency mode for accurate and comprehensive retrieval - enable_agency_mode: true # Enable agent-based retrieval + enable_agency_mode: false # Prefer deterministic retrieval for local stability # Query Processing @@ -129,8 +165,8 @@ query: detect_intent: true # Detect query type (how/what/where/debug/implement) # LLM-Enhanced Processing - use_llm_enhancement: true # Enable LLM-based query understanding - llm_enhancement_mode: "always" # Options: "adaptive", "always", "off" + use_llm_enhancement: false # Disable LLM rewrite for deterministic local routing + llm_enhancement_mode: "off" # Options: "adaptive", "always", "off" # - adaptive: Use LLM only for complex/implementation queries (recommended) # - always: Use LLM for all queries (slower, more accurate) # - off: Disable LLM enhancement (faster, rule-based only) diff --git a/fastcode/loader.py b/fastcode/loader.py index a04d328..a4e42ac 100644 --- a/fastcode/loader.py +++ b/fastcode/loader.py @@ -195,14 +195,26 @@ def scan_files(self) -> List[Dict[str, Any]]: max_file_size_bytes = self.max_file_size_mb * 1024 * 1024 for root, dirs, filenames in os.walk(self.repo_path): - # Filter out ignored directories - dirs[:] = [d for d in dirs if not should_ignore_path( - os.path.join(root, d), self.ignore_patterns - )] + # Filter ignored directories using paths relative to repo root. + # Matching absolute paths can miss gitwildmatch patterns such as + # "output/" or ".venv/". + filtered_dirs = [] + for d in dirs: + abs_dir_path = os.path.join(root, d) + rel_dir_path = normalize_path( + os.path.relpath(abs_dir_path, self.repo_path) + ) + rel_dir_with_trailing = f"{rel_dir_path}/" + if should_ignore_path(rel_dir_path, self.ignore_patterns) or should_ignore_path( + rel_dir_with_trailing, self.ignore_patterns + ): + continue + filtered_dirs.append(d) + dirs[:] = filtered_dirs for filename in filenames: file_path = os.path.join(root, filename) - relative_path = os.path.relpath(file_path, self.repo_path) + relative_path = normalize_path(os.path.relpath(file_path, self.repo_path)) # Check if should ignore if should_ignore_path(relative_path, self.ignore_patterns): @@ -312,4 +324,3 @@ def cleanup(self): def __del__(self): """Cleanup on deletion""" self.cleanup() -