# Rust build artifacts and binaries
/target/*
**/*.rs.bk
*.pdb

# Cargo.lock is usually tracked for binary crates but not for libraries
# Since this is a database server (binary), we should keep Cargo.lock
# Uncomment the next line if you want to ignore it
# Cargo.lock

# Rust debug artifacts
**/*.dSYM/

# Development artifacts moved to keep root clean
/dev-artifacts/

# Executables
*.exe
*.dll
*.so
*.dylib

# Test binaries
*-test
*-test.exe

# Benchmark binaries
*-bench
*-bench.exe

# Workspace benchmark application source
!apps/proximadb-bench/
!apps/proximadb-bench/**

# Python client artifacts
__pycache__/
*.py[cod]
*$py.class
*.so
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
/MANIFEST
.pytest_cache/
.coverage
.tox/
.mypy_cache/
.dmypy.json
dmypy.json
.pyre/
.pytype/
.ruff_cache/

# Java client artifacts
clients/java/target/
*.class
*.jar
*.war
*.ear
*.iml
.mvn/
.gradle/
gradle/
gradlew
gradlew.bat

# JavaScript/Node.js client artifacts
node_modules/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.npm
.yarn
package-lock.json
yarn.lock


# IDE and editor files
.idea/
.vscode/
*.swp
*.swo
*~
.project
.classpath
.settings/
*.sublime-project
*.sublime-workspace
.history/

# OS files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
desktop.ini

# Environment and configuration
.env
.env.local
.env.*.local
*.env
!example.env

# Logs and databases
*.log
logs/
*.sqlite
*.sqlite3
*.db
current_error.log
test_error.log
*_server.log
*_results.txt
file_list.txt

# PID files
*.pid

# Temporary files
*.tmp
*.temp
*.bak
*.bak*
*.backup
*.migrated
*.old
*.obsolete
*.disabled
.victor/
**/.victor/
tmp/
temp/
demo/results/
test-data/
test_exists_dir/

# Storage and data directories (database files)
/data/*
!/data/.gitkeep
/storage/*
!/storage/.gitkeep

# Documentation build artifacts
docs/_build/
docs/.doctrees/
*.pdf
!docs/*.pdf
site/

# Coverage reports
coverage/
*.lcov
coverage.xml
*.cover
.hypothesis/

# Profiling data
*.prof
*.lprof
perf.data*
flamegraph.svg

# Core dumps
#/core
#core.*
#*.core
#!*/core.rs
#!src/storage/engines/viper/core.rs 
#!src/core/

# Security files
*.pem
*.key
*.crt
*.p12
*.pfx

# PlantUML temporary files
*.puml.tmp

# Keep image files generated from diagrams
!images/*.png
!images/*.svg

# Keep all documentation files
!*.md
!*.adoc
!*.rst
!*.txt

# Keep configuration examples
!examples/**/*.toml
!examples/**/*.yaml
!examples/**/*.yml
!examples/**/*.json

# Keep proto files
!*.proto

# Keep diagram source files
!*.puml
!*.dot
!*.mermaid

# Keep asset files
!assets/*.svg
!assets/*.png
!assets/*.jpg
!assets/*.jpeg

# Benchmark results
benches/target/
benches/venv/
benches/vectordbbench/
# criterion/ - commented out to allow target/criterion/ tracking

# Benchmark output files
benchmark_*.txt
*_benchmark_*.txt
system_monitor.txt
artifacts/proximadb_*/
artifacts/embedded_victor_shape*.json
artifacts/panic_policy/
artifacts/coverage/
artifacts/proximadb_embedded*/
artifacts/tmp_embedded_site*/
src/graph/rag/engine_impls_test.rs.disabled

# Serverless/Cloud function packages
*.zip
lambda-package/
function-package/

# Docker artifacts
.dockerignore
docker-compose.override.yml

# Terraform state files
*.tfstate
*.tfstate.*
.terraform/
.terraformrc
terraform.rc

# Misc
.cache/
.parcel-cache/
.turbo/
.vercel/
.netlify/

# Generated files
/archive/  # Root-level archive directory only
log/
localhost/
performance_metrics/
snapshots/
*.profraw
cobertura.xml
*.log
*.log.*

# Test data directories
test_100k_*/
test_10k_*/
test_*/
tests_new/
# misc/  # Uncommented to allow tracking misc folder
obsolete/
simple_wal_test

# Test-generated WAL and metadata files (not source code)
/metadata/
**/test_*/metadata/
**/data/metadata/
segment_*/
*.wal
*.bcwal
*.oplog

# Runtime directories (should not be in docs/)
docs/data/
docs/metadata/
docs/log/

# Generated test and benchmark data
*.json
!package.json
!config.json
# Versioned wire contracts (e.g. statistics-envelope.v1) must track without -f.
!docs/12-design/contracts/*.json
!config/tier-config.json
!config/tier-config.example.json
!docs/_internal/roadmap/PANIC_POLICY_BASELINE.json
!docs/_internal/roadmap/V1_PROTO_USAGE_BASELINE.json
!clients/**/package.json
!clients/**/tsconfig.json
!clients/**/tsconfig.*.json
!clients/python/tests/unit/grpc_drift_baseline.json
!clients/**/package-lock.json
!examples/**/*.json
bert_*.json
msmarco_*.json
viper_quantization_test_results_*.json
wal_*.json
corpus_*.json
*_benchmark_*.json
*_test_results_*.json

# Generated Python test scripts and data files
test_*.py
!tests/**/*.py
!clients/**/test_*.py
debug_*.py
analyze_*.py
check_*.py
# Negation: scripts/ holds committed repo-tooling guards (check_workspace_boundaries.py,
# check_tenant_path_guard.py, ...), not ad-hoc generated scripts. Keep them tracked.
!scripts/check_*.py
clean_*.py
comprehensive_*.py
concrete_*.py
final_*.py
layered_*.py
migrate_*.py
monitor_*.py
python_*.py
quick_*.py
run_*.py
show_*.py
simple_*.py

# Generated corpus and data files
bert_*.json
*_corpus.json
*.parquet

# Generated report files (specific patterns only)
*_REPORT.md
*_SUMMARY.md
*_PLAN.md
COMPREHENSIVE_*.md
CRITICAL_*.md
FINAL_*.md
GRPC_*.md
TEST_*.md
WAL_*.md
!docs/_archive/design/2026-05/GRPC_MIGRATION_PROGRESS_2026_05_14.md

# Generated HTML reports
reports/
*.html
!docs/**/*.html
# Embedded admin-dashboard asset is source (compiled in via include_str!), not a report.
!crates/platform/proximadb-admin-ui/assets/*.html
!target/criterion/**/*.html
!src/network/rest/dashboard.html
# CRA operator console entry assets are source, not generated reports.
!ui/public/index.html
!ui/public/manifest.json

# Generated configuration files (but keep examples)
#*_config.toml
#staging_*.toml
#test_*.toml
!examples/**/*.toml

# Generated shell scripts for testing (keep essential scripts)
test_*.sh
debug_*.sh
clean_*.sh
!scripts/**/*.sh
!examples/**/*.sh
!build.sh
!install.sh
!setup.sh
dead_code_inventory.md

# Build artifacts
target/*
# Allow Criterion HTML reports to be tracked
!target/criterion/
build_rs_cov.profraw

# Large binary tools
tools/minio
tools/fake-gcs-server
newcategory.txt
ml_prompt.txt
footer_cache.bin

# AI-assistant instruction files — per-developer / local-only (NOT committed).
# CLAUDE.md / GEMINI.md / AGENTS.md / AGENT.md at the repo root are each developer's own
# local copy; shared defaults ship committed under docs/agent-rules/*.seed — copy
# one to the root to seed a new machine (see docs/agent-rules/README.adoc).
# Remaining entries below ignore tooling artifacts that should never be committed.
CLAUDE.md
GEMINI.md
AGENTS.md
AGENT.md
CURSOR.md
COPILOT.md
.claude/
.cursor/
.github/copilot-instructions.md
*_INSTRUCTIONS.md

# AI-generated prompts, summaries, and snapshots
*prompt*.txt
*snapshot*
!src/**/snapshot.rs
# Rust SOURCE files whose name contains "snapshot" are code, not snapshot data
# artifacts — never ignore them (the broad `*snapshot*` above silently swallowed
# src/services/catalog_snapshot_store.rs once, landing a non-compiling develop).
!src/**/*snapshot*.rs
!crates/**/*snapshot*.rs
# Phase 8 snapshot-publish coordinator module (source, not a snapshot artifact)
!src/services/snapshot/
!src/services/snapshot/**
*_PROMPT.md
*_SNAPSHOT.md
*_summary.py
test_summary*.py
test_*_summary.py
*_summary_report.py

# Session work archives (development session notes and summaries)
docs/archive/sessions/

# Development planning and architecture documents (root level only)
/GLOBAL_MANIFEST_*.md
/RECOVERY_*.md
/WAL_*.md
/*_ARCHITECTURE.md
/*_INTEGRATION.md
/*_IMPLEMENTATION*.md
/*_VERIFICATION*.md
/*_PLAN.md
/*_FIXES.md

# Project root data and text files
*.dat
*.txt

# Consolidated config dir (configs/ merged into config/)
/configs/

# Stray root-level artifacts from test runs
/segment_0/
/test_exists_dir/
/test_metadata/
/test_metadata_atomic/

# Local secret/tooling audit logs (never commit — may contain access events)
/audit/
/test_size
/test_filter_debug.rs
/nohup.out
/=1.75.1
/file:

# Stray benchmark data at root
benchmark_report_*.csv
*.puml

# Coverage data at root (use .coverage/ dir)
/.coverage

# Obsolete files marked for removal
*.obsolete
/target/

# AI tool data folders
.victor/

# Root-level placeholder go.mod for tools that probe for it
# (real Go modules live at clients/go/go.mod and clients/go-embedded/go.mod)
/go.mod

# TD-126 Phase 4: the Python REST transport is GENERATED into this dir
# (openapi-python-client, regenerated by `make gen-python-sdk`, drift-gated by
# `python-sdk-codegen-drift`). Un-ignore it so repo-wide patterns above
# (e.g. *_summary.py, *.txt) cannot silently drop generated files from the
# committed artifact. The generator's own .ruff_cache / __pycache__ stay ignored
# by the global rules; only tracked .py sources are forced in here.
!clients/python/src/proximadb_sdk/_generated/
!clients/python/src/proximadb_sdk/_generated/**
# Keep the pinned codegen toolchain tracked despite the global *.txt rule.
!clients/python/codegen/requirements.txt
clients/python/src/proximadb_sdk/_generated/**/.ruff_cache/
clients/python/src/proximadb_sdk/_generated/**/__pycache__/
