beaver-db 0.12.0__tar.gz → 0.12.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of beaver-db might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: beaver-db
3
- Version: 0.12.0
3
+ Version: 0.12.2
4
4
  Summary: Fast, embedded, and multi-modal DB based on SQLite for AI-powered applications.
5
5
  Requires-Python: >=3.13
6
6
  Description-Content-Type: text/markdown
@@ -9,8 +9,6 @@ Requires-Dist: faiss-cpu>=1.12.0
9
9
  Requires-Dist: numpy>=2.3.3
10
10
  Dynamic: license-file
11
11
 
12
- Of course, here is a rewritten README to explain the vector store uses a high performance FAISS-based implementation with in-memory and persistent indices, with an added small section on how is this implemented to explain the basic ideas behind the implementation of beaver.
13
-
14
12
  # beaver 🦫
15
13
 
16
14
  A fast, single-file, multi-modal database for Python, built with the standard `sqlite3` library.
@@ -1,5 +1,3 @@
1
- Of course, here is a rewritten README to explain the vector store uses a high performance FAISS-based implementation with in-memory and persistent indices, with an added small section on how is this implemented to explain the basic ideas behind the implementation of beaver.
2
-
3
1
  # beaver 🦫
4
2
 
5
3
  A fast, single-file, multi-modal database for Python, built with the standard `sqlite3` library.
@@ -560,6 +560,17 @@ class CollectionManager:
560
560
  for row in rows
561
561
  ]
562
562
 
563
+ def __len__(self) -> int:
564
+ """Returns the number of documents in the collection."""
565
+ cursor = self._conn.cursor()
566
+ cursor.execute(
567
+ "SELECT COUNT(*) FROM beaver_collections WHERE collection = ?",
568
+ (self._name,),
569
+ )
570
+ count = cursor.fetchone()[0]
571
+ cursor.close()
572
+ return count
573
+
563
574
 
564
575
  def rerank(
565
576
  *results: list[Document],
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: beaver-db
3
- Version: 0.12.0
3
+ Version: 0.12.2
4
4
  Summary: Fast, embedded, and multi-modal DB based on SQLite for AI-powered applications.
5
5
  Requires-Python: >=3.13
6
6
  Description-Content-Type: text/markdown
@@ -9,8 +9,6 @@ Requires-Dist: faiss-cpu>=1.12.0
9
9
  Requires-Dist: numpy>=2.3.3
10
10
  Dynamic: license-file
11
11
 
12
- Of course, here is a rewritten README to explain the vector store uses a high performance FAISS-based implementation with in-memory and persistent indices, with an added small section on how is this implemented to explain the basic ideas behind the implementation of beaver.
13
-
14
12
  # beaver 🦫
15
13
 
16
14
  A fast, single-file, multi-modal database for Python, built with the standard `sqlite3` library.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "beaver-db"
3
- version = "0.12.0"
3
+ version = "0.12.2"
4
4
  description = "Fast, embedded, and multi-modal DB based on SQLite for AI-powered applications."
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.13"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes