Code
gcs.py
Usage
1
Install libraries
2
Configure Google Cloud credentials
Set up your GCS credentials using one of these methods:
- Service Account Key: Set
GOOGLE_APPLICATION_CREDENTIALS
environment variable - gcloud CLI:
gcloud auth application-default login
- Workload Identity (if running on Google Cloud)
3
Run PgVector
4
Run the example
Params
Parameter | Type | Default | Description |
---|---|---|---|
bucket_name | str | - | Name of the GCS bucket containing the file. |
blob_name | str | - | Name of the blob (file) within the bucket. |
prefix | Optional[str] | - | Path prefix for organizing files in the bucket. |
bucket | Optional[Any] | - | Pre-configured GCS bucket object. |