Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
52584a171f | ||
|
|
efd6b5324b | ||
|
|
2baaa4549b | ||
|
|
35310ddd52 |
4
.github/workflows/build-reusable.yml
vendored
4
.github/workflows/build-reusable.yml
vendored
@@ -82,7 +82,7 @@ jobs:
|
|||||||
- name: Build packages
|
- name: Build packages
|
||||||
run: |
|
run: |
|
||||||
# Build core (platform independent)
|
# Build core (platform independent)
|
||||||
if [ "${{ matrix.os }}" == "ubuntu-latest" ]; then
|
if [[ "${{ matrix.os }}" == ubuntu-* ]]; then
|
||||||
cd packages/leann-core
|
cd packages/leann-core
|
||||||
uv build
|
uv build
|
||||||
cd ../..
|
cd ../..
|
||||||
@@ -107,7 +107,7 @@ jobs:
|
|||||||
cd ../..
|
cd ../..
|
||||||
|
|
||||||
# Build meta package (platform independent)
|
# Build meta package (platform independent)
|
||||||
if [ "${{ matrix.os }}" == "ubuntu-latest" ]; then
|
if [[ "${{ matrix.os }}" == ubuntu-* ]]; then
|
||||||
cd packages/leann
|
cd packages/leann
|
||||||
uv build
|
uv build
|
||||||
cd ../..
|
cd ../..
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ build-backend = "scikit_build_core.build"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "leann-backend-diskann"
|
name = "leann-backend-diskann"
|
||||||
version = "0.1.9"
|
version = "0.1.10"
|
||||||
dependencies = ["leann-core==0.1.9", "numpy"]
|
dependencies = ["leann-core==0.1.10", "numpy", "protobuf>=3.19.0"]
|
||||||
|
|
||||||
[tool.scikit-build]
|
[tool.scikit-build]
|
||||||
# Key: simplified CMake path
|
# Key: simplified CMake path
|
||||||
|
|||||||
@@ -81,7 +81,21 @@ def create_hnsw_embedding_server(
|
|||||||
with open(passages_file, "r") as f:
|
with open(passages_file, "r") as f:
|
||||||
meta = json.load(f)
|
meta = json.load(f)
|
||||||
|
|
||||||
passages = PassageManager(meta["passage_sources"])
|
# Convert relative paths to absolute paths based on metadata file location
|
||||||
|
metadata_dir = Path(
|
||||||
|
passages_file
|
||||||
|
).parent.parent # Go up one level from the metadata file
|
||||||
|
passage_sources = []
|
||||||
|
for source in meta["passage_sources"]:
|
||||||
|
source_copy = source.copy()
|
||||||
|
# Convert relative paths to absolute paths
|
||||||
|
if not Path(source_copy["path"]).is_absolute():
|
||||||
|
source_copy["path"] = str(metadata_dir / source_copy["path"])
|
||||||
|
if not Path(source_copy["index_path"]).is_absolute():
|
||||||
|
source_copy["index_path"] = str(metadata_dir / source_copy["index_path"])
|
||||||
|
passage_sources.append(source_copy)
|
||||||
|
|
||||||
|
passages = PassageManager(passage_sources)
|
||||||
logger.info(
|
logger.info(
|
||||||
f"Loaded PassageManager with {len(passages.global_offset_map)} passages from metadata"
|
f"Loaded PassageManager with {len(passages.global_offset_map)} passages from metadata"
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -6,10 +6,10 @@ build-backend = "scikit_build_core.build"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "leann-backend-hnsw"
|
name = "leann-backend-hnsw"
|
||||||
version = "0.1.9"
|
version = "0.1.10"
|
||||||
description = "Custom-built HNSW (Faiss) backend for the Leann toolkit."
|
description = "Custom-built HNSW (Faiss) backend for the Leann toolkit."
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"leann-core==0.1.9",
|
"leann-core==0.1.10",
|
||||||
"numpy",
|
"numpy",
|
||||||
"pyzmq>=23.0.0",
|
"pyzmq>=23.0.0",
|
||||||
"msgpack>=1.0.0",
|
"msgpack>=1.0.0",
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "leann-core"
|
name = "leann-core"
|
||||||
version = "0.1.9"
|
version = "0.1.10"
|
||||||
description = "Core API and plugin system for LEANN"
|
description = "Core API and plugin system for LEANN"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.9"
|
requires-python = ">=3.9"
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "leann"
|
name = "leann"
|
||||||
version = "0.1.9"
|
version = "0.1.10"
|
||||||
description = "LEANN - The smallest vector index in the world. RAG Everything with LEANN!"
|
description = "LEANN - The smallest vector index in the world. RAG Everything with LEANN!"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.9"
|
requires-python = ">=3.9"
|
||||||
|
|||||||
Reference in New Issue
Block a user