Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
File size: 353 Bytes
7217024 |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
import sqlite3
import os
db_path = os.path.join("chromadb-store", "chroma.sqlite3") # adjust if different
if os.path.exists(db_path):
conn = sqlite3.connect(db_path)
conn.execute("VACUUM;")
conn.close()
print("✅ Vacuumed Chroma SQLite DB — space reclaimed.")
else:
print("⚠️ No chroma.sqlite3 found — skipping vacuum.")
|