ci: fix docs build (#496)

python/python.md contains typos in the class references

---------

Co-authored-by: Chang She <chang@lancedb.com>
This commit is contained in:
Chang She
2023-09-18 16:07:21 -04:00
committed by GitHub
parent bc38abb781
commit c21f9cdda0
9 changed files with 99 additions and 32 deletions

View File

@@ -136,11 +136,9 @@ def test_ingest_iterator(tmp_path):
def run_tests(schema):
db = lancedb.connect(tmp_path)
tbl = db.create_table("table2", make_batches(), schema=schema, mode="overwrite")
tbl.to_pandas()
assert tbl.search([3.1, 4.1]).limit(1).to_df()["_distance"][0] == 0.0
assert tbl.search([5.9, 26.5]).limit(1).to_df()["_distance"][0] == 0.0
tbl_len = len(tbl)
tbl.add(make_batches())
assert tbl_len == 50

View File

@@ -35,7 +35,7 @@ def test_sentence_transformer(alias, tmp_path):
class Words(LanceModel):
text: str = func.SourceField()
vector: Vector(func.ndims) = func.VectorField()
vector: Vector(func.ndims()) = func.VectorField()
table = db.create_table("words", schema=Words)
table.add(
@@ -75,8 +75,8 @@ def test_openclip(tmp_path):
label: str
image_uri: str = func.SourceField()
image_bytes: bytes = func.SourceField()
vector: Vector(func.ndims) = func.VectorField()
vec_from_bytes: Vector(func.ndims) = func.VectorField()
vector: Vector(func.ndims()) = func.VectorField()
vec_from_bytes: Vector(func.ndims()) = func.VectorField()
table = db.create_table("images", schema=Images)
labels = ["cat", "cat", "dog", "dog", "horse", "horse"]

View File

@@ -385,7 +385,7 @@ def test_add_with_embedding_function(db):
class MyTable(LanceModel):
text: str = emb.SourceField()
vector: Vector(emb.ndims) = emb.VectorField()
vector: Vector(emb.ndims()) = emb.VectorField()
table = LanceTable.create(db, "my_table", schema=MyTable)