Skip to content

Commit

Permalink
chore: prepare packages to upload (#72)
Browse files Browse the repository at this point in the history
  • Loading branch information
mhordynski authored Oct 8, 2024
1 parent 428c7a1 commit 2e95436
Show file tree
Hide file tree
Showing 13 changed files with 128 additions and 47 deletions.
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2024 deepsense.ai sp. z o.o.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
6 changes: 3 additions & 3 deletions packages/ragbits-cli/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
authors = [
{ name = "deepsense.ai", email = "contact@deepsense.ai"}
{ name = "deepsense.ai", email = "ragbits@deepsense.ai"}
]
keywords = [
"Retrieval Augmented Generation",
Expand All @@ -18,7 +18,7 @@ keywords = [
"Prompt Management"
]
classifiers = [
"Development Status :: 1 - Planning",
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
Expand All @@ -29,10 +29,10 @@ classifiers = [
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
"Private :: Do Not Upload"
]
dependencies = [
"typer>=0.12.5",
"ragbits-core==0.1.0"
]

[project.scripts]
Expand Down
2 changes: 1 addition & 1 deletion packages/ragbits-core/examples/chromadb_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# requires-python = ">=3.10"
# dependencies = [
# "ragbits-document-search",
# "ragbits[litellm]",
# "ragbits-core[litellm]",
# ]
# ///
import asyncio
Expand Down
2 changes: 1 addition & 1 deletion packages/ragbits-core/examples/llm_example.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# /// script
# requires-python = ">=3.10"
# dependencies = [
# "ragbits[litellm]",
# "ragbits-core[litellm]",
# ]
# ///
import asyncio
Expand Down
2 changes: 1 addition & 1 deletion packages/ragbits-core/examples/prompt_example.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# /// script
# requires-python = ">=3.10"
# dependencies = [
# "ragbits",
# "ragbits-core",
# ]
# ///
from pydantic import BaseModel
Expand Down
7 changes: 3 additions & 4 deletions packages/ragbits-core/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[project]
name = "ragbits"
name = "ragbits-core"
version = "0.1.0"
description = "Building blocks for rapid development of GenAI applications"
readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
authors = [
{ name = "deepsense.ai", email = "contact@deepsense.ai"}
{ name = "deepsense.ai", email = "ragbits@deepsense.ai"}
]
keywords = [
"Retrieval Augmented Generation",
Expand All @@ -18,7 +18,7 @@ keywords = [
"Prompt Management"
]
classifiers = [
"Development Status :: 1 - Planning",
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
Expand All @@ -29,7 +29,6 @@ classifiers = [
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
"Private :: Do Not Upload"
]
dependencies = [
"jinja2>=3.1.4",
Expand Down
2 changes: 1 addition & 1 deletion packages/ragbits-document-search/examples/simple_text.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# requires-python = ">=3.10"
# dependencies = [
# "ragbits-document-search",
# "ragbits[litellm]",
# "ragbits-core[litellm]",
# ]
# ///
import asyncio
Expand Down
9 changes: 4 additions & 5 deletions packages/ragbits-document-search/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
authors = [
{ name = "deepsense.ai", email = "contact@deepsense.ai"}
{ name = "deepsense.ai", email = "ragbits@deepsense.ai"}
]
keywords = [
"Retrieval Augmented Generation",
Expand All @@ -18,7 +18,7 @@ keywords = [
"Document Search"
]
classifiers = [
"Development Status :: 1 - Planning",
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
Expand All @@ -29,13 +29,12 @@ classifiers = [
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
"Private :: Do Not Upload"
]
dependencies = [
"numpy~=1.24.0",
"ragbits",
"unstructured>=0.15.13",
"unstructured-client>=0.26.0",
"ragbits-core==0.1.0"
]

[project.optional-dependencies]
Expand All @@ -54,7 +53,7 @@ dev-dependencies = [
]

[tool.uv.sources]
ragbits = { workspace = true }
ragbits-core = { workspace = true }

[build-system]
requires = ["hatchling"]
Expand Down
1 change: 1 addition & 0 deletions packages/ragbits/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Ragbits
50 changes: 50 additions & 0 deletions packages/ragbits/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
[project]
name = "ragbits"
version = "0.1.0"
description = "Building blocks for rapid development of GenAI applications"
readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
authors = [
{ name = "deepsense.ai", email = "[email protected]"}
]
keywords = [
"Retrieval Augmented Generation",
"RAG",
"Large Language Models",
"LLMs",
"Generative AI",
"GenAI",
"Prompt Management"
]
classifiers = [
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"ragbits-document-search==0.1.0",
"ragbits-cli==0.1.0",
"ragbits-core==0.1.0"
]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.hatch.metadata]
allow-direct-references = true

[tool.hatch.build.targets.wheel]
packages = ["src/ragbits"]

[tool.pytest.ini_options]
asyncio_mode = "auto"
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description = "Ragbits development workspace"
readme = "README.md"
requires-python = ">=3.10"
dependencies = [
"ragbits[litellm,local,lab,chromadb]",
"ragbits-core[litellm,local,lab,chromadb]",
"ragbits-document-search[gcs]",
"ragbits-cli"
]
Expand All @@ -21,7 +21,7 @@ dev-dependencies = [
]

[tool.uv.sources]
ragbits = { workspace = true }
ragbits-core = { workspace = true }
ragbits-document-search = { workspace = true }
ragbits-cli = { workspace = true }

Expand Down
4 changes: 2 additions & 2 deletions scripts/update_ragbits_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,9 @@ def run(pkg_name: Optional[str] = typer.Argument(None), update_type: Optional[st
for pkg in [pkg for pkg in packages if pkg != "ragbits-core"]:
pkg_pyproject = tomlkit.parse((PACKAGES_DIR / pkg / "pyproject.toml").read_text())
pkg_pyproject["project"]["dependencies"] = [
dep for dep in pkg_pyproject["project"]["dependencies"] if "ragbits" not in dep
dep for dep in pkg_pyproject["project"]["dependencies"] if "ragbits-core" not in dep
]
pkg_pyproject["project"]["dependencies"].append(f"ragbits=={new_ragbits_version}")
pkg_pyproject["project"]["dependencies"].append(f"ragbits-core=={new_ragbits_version}")
_update_pkg_version(pkg, pkg_pyproject, update_type=casted_update_type)

else:
Expand Down
Loading

0 comments on commit 2e95436

Please sign in to comment.