Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create trulens-semconv package. #1669

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,145 changes: 629 additions & 516 deletions poetry.lock

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"trulens-core",
"trulens-feedback",
"trulens-providers-cortex",
"trulens-semconv",
]

_TRULENS_EXTRA_STAGED_PACKAGES = [
Expand All @@ -33,6 +34,8 @@
"nest-asyncio",
"nltk",
"numpy",
"opentelemetry-api",
"opentelemetry-sdk",
"packaging",
"pandas",
"pip",
Expand Down
10 changes: 6 additions & 4 deletions src/core/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,16 +45,18 @@ alembic = "^1.8.1"
nest-asyncio = "^1.5"
python-dotenv = ">=0.21,<2.0"
importlib-resources = "^6.0"
trulens-semconv = { version = "^1.0.0", optional = true }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are we using trulens-semconv in core?

opentelemetry-api = { version = "^1.0.0", optional = true }
opentelemetry-sdk = { version = "^1.0.0", optional = true }

[tool.poetry.group.tqdm]
optional = true

[tool.poetry.group.tqdm.dependencies]
tqdm = { version = ">=4.2.0", optional = true }

[tool.poetry.group.otel]
[tool.poetry.group.dev]
optional = true

[tool.poetry.group.otel.dependencies]
opentelemetry-api = { version = ">=1", optional = true }
opentelemetry-sdk = { version = ">=1", optional = true }
[tool.poetry.group.dev.dependencies]
trulens-semconv = { path = "../semconv" }
3 changes: 3 additions & 0 deletions src/semconv/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Semantic Conventions for TruLens Spans

This package describes the conventions for attribute names and some attribute values present in spans produced or interpreted by TruLens.
34 changes: 34 additions & 0 deletions src/semconv/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[build-system]
build-backend = "poetry.core.masonry.api"
requires = [
"poetry-core",
]

[tool.poetry]
name = "trulens-semconv"
version = "1.2.8"
description = "Semantic conventions for spans produced by TruLens."
authors = [
"Snowflake Inc. <[email protected]>",
]
license = "MIT"
readme = "README.md"
packages = [
{ include = "trulens" },
]
homepage = "https://trulens.org/"
documentation = "https://trulens.org/getting_started/"
repository = "https://github.com/truera/trulens"
classifiers = [
"Programming Language :: Python :: 3",
"Operating System :: OS Independent",
"Development Status :: 3 - Alpha",
"License :: OSI Approved :: MIT License",
]

[tool.poetry.dependencies]
python = "^3.8.1,!=3.9.7"
# This package only has pre-releases:
opentelemetry-semantic-conventions = { version = ">=0.48b0", allow-prereleases = true }
# This package requires python 3.9 so we are avoiding using it for now:
# opentelemetry-semantic-conventions-ai = { version = ">=0.4.2", allow-prereleases=true }
7 changes: 7 additions & 0 deletions src/semconv/trulens/semconv/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from importlib.metadata import version

from trulens.core.utils import imports as import_utils

__version__ = version(
import_utils.safe_importlib_package_name(__package__ or __name__)
)
Loading
Loading