Spaces:
Sleeping
Sleeping
Download env.example from fmbishu/image-search-api: direct link, hf CLI and curl.
- Browser
- Download file 3.73 kB
-
https://huggingface.co/spaces/fmbishu/image-search-api/resolve/main/env.example
- Command line
-
hf download hf://spaces/fmbishu/image-search-api/env.example
-
curl -L -o env.example https://huggingface.co/spaces/fmbishu/image-search-api/resolve/main/env.example
3.73 kB
| # Vector Store Configuration | |
| # Options: chromadb, pinecone, qdrant, weaviate, pgvector | |
| # Set to pgvector when using PostgreSQL (e.g., Neon) | |
| # VECTOR_STORE_TYPE=pgvector | |
| # Vector Store Collection Name | |
| COLLECTION_NAME=demo_products | |
| # Auto-Monitoring (automatically index new products) | |
| # Set to 'true' to enable automatic product monitoring | |
| ENABLE_AUTO_MONITOR=true | |
| # Monitoring interval in seconds (how often to check for new products) | |
| MONITOR_INTERVAL=60 | |
| # ChromaDB Configuration (when VECTOR_STORE_TYPE=chromadb) | |
| # Mode: 'local' for persistent file storage (default), 'server' for remote ChromaDB server | |
| CHROMADB_MODE=local | |
| # CHROMADB_PATH=./app/data/chroma_db | |
| # Pinecone Configuration (when VECTOR_STORE_TYPE=pinecone) | |
| # PINECONE_API_KEY=your-pinecone-api-key | |
| # PINECONE_ENVIRONMENT=us-west1-gcp | |
| # PINECONE_INDEX_NAME=product-embeddings | |
| # Qdrant Configuration (when VECTOR_STORE_TYPE=qdrant) | |
| # QDRANT_URL=http://localhost:6333 | |
| # QDRANT_API_KEY=your-qdrant-api-key | |
| # Weaviate Configuration (when VECTOR_STORE_TYPE=weaviate) | |
| # WEAVIATE_URL=http://localhost:8080 | |
| # WEAVIATE_API_KEY=your-weaviate-api-key | |
| # pgVector Configuration (when VECTOR_STORE_TYPE=pgvector) | |
| # For Neon PostgreSQL, use the connection string from your Neon dashboard: | |
| # Note: If PGVECTOR_CONNECTION_STRING is not set and DATABASE_CONNECTION_STRING is PostgreSQL, | |
| # it will automatically use DATABASE_CONNECTION_STRING for pgvector | |
| PGVECTOR_CONNECTION_STRING=postgresql://neondb_owner:npg_5efnsy8gGbxt@ep-noisy-waterfall-ahqv16r5-pooler.c-3.us-east-1.aws.neon.tech/neondb?sslmode=require&channel_binding=require | |
| # For local PostgreSQL: | |
| # PGVECTOR_CONNECTION_STRING=postgresql://postgres:password@localhost:5432/products_db | |
| # Database Configuration | |
| # Standard database connection string | |
| # SQLite: sqlite:///path/to/database.db | |
| # PostgreSQL: postgresql://user:password@host:port/database | |
| # MySQL: mysql://user:password@host:port/database | |
| # MongoDB: mongodb://user:password@host:27017/database | |
| # When using PostgreSQL, set VECTOR_STORE_TYPE=pgvector to use the same database for vectors | |
| # or provide a separate PGVECTOR_CONNECTION_STRING for a different database | |
| # DATABASE_CONNECTION_STRING=postgresql://neondb_owner:npg_5efnsy8gGbxt@ep-noisy-waterfall-ahqv16r5-pooler.c-3.us-east-1.aws.neon.tech/neondb?sslmode=require&channel_binding=require | |
| # DATABASE_NAME=products # Required for MongoDB if not included in connection string | |
| # For SQLite (local development): | |
| DATABASE_CONNECTION_STRING=sqlite:///app/data/products.db | |
| # Database Schema Mapping (for custom database schemas) | |
| # DATABASE_TABLE_NAME=products | |
| # DATABASE_ID_COLUMN=id | |
| # DATABASE_TITLE_COLUMN=title | |
| # DATABASE_IMAGE_URL_COLUMN=image_url | |
| # DATABASE_CATEGORY_COLUMN=category | |
| # DATABASE_BRAND_COLUMN=brand | |
| # DATABASE_PRICE_COLUMN=price | |
| # DATABASE_RATING_COLUMN=rating | |
| # DATABASE_DESCRIPTION_COLUMN=description | |
| # CLIP Model Configuration | |
| # Options: clip-ViT-B-32, clip-ViT-L-14 | |
| CLIP_MODEL_NAME=clip-ViT-L-14 | |
| # API Security | |
| # Require API keys for search/products endpoints | |
| API_KEY_REQUIRED=false | |
| # Enforce HTTPS redirects (set true when running behind TLS terminator) | |
| FORCE_HTTPS=false | |
| # Trusted hosts (comma separated). Leave empty to allow all (development). | |
| TRUSTED_HOSTS=api.example.com | |
| # API Configuration | |
| API_HOST=0.0.0.0 | |
| API_PORT=8000 | |
| # Data Directory | |
| DATA_DIR=./app/data | |
| # Observability & telemetry | |
| PROMETHEUS_ENABLED=true | |
| TRACING_ENABLED=false | |
| TRACING_EXPORTER_ENDPOINT=http://localhost:4318/v1/traces | |
| ENABLE_STRUCTURED_LOGGING=true | |
| METRICS_RETENTION_SEC=300 | |
| # Cache and job queue | |
| REDIS_CACHE_URL=redis://localhost:6379/0 | |
| REDIS_CACHE_PREFIX=image_search | |
| REDIS_CACHE_TTL=300 | |
| JOB_QUEUE_URL=redis://localhost:6379/1 | |
| JOB_QUEUE_NAME=image-search-tasks | |
| JOB_QUEUE_TIMEOUT=600 | |