langtrace-python-sdk 2.1.0__tar.gz → 2.1.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.
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/PKG-INFO +7 -8
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/pyproject.toml +6 -7
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/pinecone_example/basic.py +19 -5
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/pinecone/instrumentation.py +1 -11
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/pinecone/patch.py +8 -7
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/weaviate/instrumentation.py +1 -1
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/with_root_span.py +9 -9
- langtrace_python_sdk-2.1.2/src/langtrace_python_sdk/version.py +1 -0
- langtrace_python_sdk-2.1.0/src/langtrace_python_sdk/version.py +0 -1
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/.gitignore +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/LICENSE +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/README.md +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/anthropic_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/anthropic_example/completion.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/chroma_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/chroma_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/chat.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/chat_stream.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/embed.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/rerank.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/tools.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/fastapi_example/basic_route.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/hiveagent_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/groq_example.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/langgraph_example.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/tool.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/agent.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/data/abramov.txt +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/async_tool_calling_nonstreaming.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/async_tool_calling_streaming.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/chat_completion.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/embeddings_create.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/function_calling.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/images_generate.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/tool_calling.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/tool_calling_nonstreaming.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/tool_calling_streaming.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/perplexity_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/pinecone_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/qdrant_example/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/qdrant_example/basic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/weaviate_example/query_text.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/exporter/langtrace_exporter.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/anthropic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/chroma.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/cohere.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/common.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/groq.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/openai.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/pinecone.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/qdrant.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/constants/instrumentation/weaviate.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/extensions/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/extensions/langtrace_exporter.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/anthropic/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/anthropic/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/anthropic/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/chroma/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/chroma/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/chroma/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/cohere/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/cohere/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/cohere/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/groq/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/groq/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/groq/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_community/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_community/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_community/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_core/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_core/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langchain_core/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langgraph/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langgraph/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/langgraph/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/llamaindex/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/llamaindex/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/llamaindex/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/openai/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/openai/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/openai/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/pinecone/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/qdrant/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/qdrant/instrumentation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/qdrant/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/weaviate/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/instrumentation/weaviate/patch.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/langtrace.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/types/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/llm.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/misc.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/prompt_registry.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/silently_fail.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/types.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/run_example.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/__init__.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/cassettes/test_anthropic.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/cassettes/test_anthropic_streaming.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/cassettes/test_async_anthropic_streaming.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/test_anthropic.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/chroma/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/chroma/test_chroma.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/cassettes/test_cohere_chat.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/cassettes/test_cohere_chat_streaming.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/cassettes/test_cohere_embed.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/cassettes/test_cohere_rerank.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_chat.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_embed.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_rerank.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/langchain/test_langchain.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/langchain/test_langchain_community.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/langchain/test_langchain_core.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/cassettes/test_async_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/cassettes/test_async_image_generation.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/cassettes/test_chat_completion.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/cassettes/test_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/cassettes/test_image_generation.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_chat_completion.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_embeddings.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_image_generation.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/pinecone/cassettes/test_query.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/pinecone/cassettes/test_upsert.yaml +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/pinecone/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/pinecone/test_pinecone.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/qdrant/conftest.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/qdrant/test_qdrant.py +0 -0
- {langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/utils.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: langtrace-python-sdk
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.2
|
|
4
4
|
Summary: Python SDK for LangTrace
|
|
5
5
|
Project-URL: Homepage, https://github.com/Scale3-Labs/langtrace-python-sdk
|
|
6
6
|
Author-email: Scale3 Labs <engineering@scale3labs.com>
|
|
@@ -10,15 +10,13 @@ Classifier: License :: OSI Approved :: Apache Software License
|
|
|
10
10
|
Classifier: Operating System :: OS Independent
|
|
11
11
|
Classifier: Programming Language :: Python :: 3
|
|
12
12
|
Requires-Python: >=3.9
|
|
13
|
-
Requires-Dist: opentelemetry-api
|
|
13
|
+
Requires-Dist: opentelemetry-api>=1.24.0
|
|
14
14
|
Requires-Dist: opentelemetry-exporter-otlp-proto-grpc>=1.24.0
|
|
15
15
|
Requires-Dist: opentelemetry-exporter-otlp-proto-http>=1.24.0
|
|
16
|
-
Requires-Dist: opentelemetry-instrumentation
|
|
17
|
-
Requires-Dist: opentelemetry-sdk
|
|
18
|
-
Requires-Dist:
|
|
19
|
-
Requires-Dist:
|
|
20
|
-
Requires-Dist: trace-attributes>=4.0.2
|
|
21
|
-
Requires-Dist: weaviate-client
|
|
16
|
+
Requires-Dist: opentelemetry-instrumentation>=0.45b0
|
|
17
|
+
Requires-Dist: opentelemetry-sdk>=1.24.0
|
|
18
|
+
Requires-Dist: tiktoken>=0.1.1
|
|
19
|
+
Requires-Dist: trace-attributes>=4.0.4
|
|
22
20
|
Provides-Extra: dev
|
|
23
21
|
Requires-Dist: anthropic; extra == 'dev'
|
|
24
22
|
Requires-Dist: chromadb; extra == 'dev'
|
|
@@ -27,6 +25,7 @@ Requires-Dist: langchain; extra == 'dev'
|
|
|
27
25
|
Requires-Dist: langchain-community; extra == 'dev'
|
|
28
26
|
Requires-Dist: langchain-openai; extra == 'dev'
|
|
29
27
|
Requires-Dist: openai; extra == 'dev'
|
|
28
|
+
Requires-Dist: pinecone-client; extra == 'dev'
|
|
30
29
|
Requires-Dist: python-dotenv; extra == 'dev'
|
|
31
30
|
Requires-Dist: qdrant-client; extra == 'dev'
|
|
32
31
|
Requires-Dist: weaviate-client; extra == 'dev'
|
|
@@ -18,15 +18,13 @@ classifiers=[
|
|
|
18
18
|
"Operating System :: OS Independent",
|
|
19
19
|
]
|
|
20
20
|
dependencies = [
|
|
21
|
-
'trace-attributes>=4.0.
|
|
22
|
-
'opentelemetry-api',
|
|
23
|
-
'opentelemetry-sdk',
|
|
24
|
-
'opentelemetry-instrumentation',
|
|
25
|
-
'
|
|
26
|
-
'tiktoken',
|
|
21
|
+
'trace-attributes>=4.0.4',
|
|
22
|
+
'opentelemetry-api>=1.24.0',
|
|
23
|
+
'opentelemetry-sdk>=1.24.0',
|
|
24
|
+
'opentelemetry-instrumentation>=0.45b0',
|
|
25
|
+
'tiktoken>=0.1.1',
|
|
27
26
|
'opentelemetry-exporter-otlp-proto-http>=1.24.0',
|
|
28
27
|
'opentelemetry-exporter-otlp-proto-grpc>=1.24.0',
|
|
29
|
-
'weaviate-client',
|
|
30
28
|
]
|
|
31
29
|
|
|
32
30
|
requires-python = ">=3.9"
|
|
@@ -38,6 +36,7 @@ dev = [
|
|
|
38
36
|
"chromadb",
|
|
39
37
|
'qdrant-client',
|
|
40
38
|
"python-dotenv",
|
|
39
|
+
'pinecone-client',
|
|
41
40
|
"langchain",
|
|
42
41
|
'langchain-community',
|
|
43
42
|
"langchain-openai",
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/pinecone_example/basic.py
RENAMED
|
@@ -2,13 +2,12 @@
|
|
|
2
2
|
This example demonstrates how to use Pinecone with Langtrace.
|
|
3
3
|
"""
|
|
4
4
|
|
|
5
|
-
from langtrace_python_sdk import langtrace
|
|
6
5
|
from dotenv import find_dotenv, load_dotenv
|
|
7
6
|
from openai import OpenAI
|
|
8
|
-
from pinecone import Pinecone
|
|
7
|
+
from pinecone import Pinecone, ServerlessSpec
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
from langtrace_python_sdk import
|
|
9
|
+
from langtrace_python_sdk import langtrace, with_langtrace_root_span
|
|
10
|
+
from langtrace_python_sdk.utils.with_root_span import send_user_feedback
|
|
12
11
|
|
|
13
12
|
_ = load_dotenv(find_dotenv())
|
|
14
13
|
|
|
@@ -17,6 +16,17 @@ langtrace.init()
|
|
|
17
16
|
client = OpenAI()
|
|
18
17
|
pinecone = Pinecone()
|
|
19
18
|
|
|
19
|
+
PINECONE_INDEX_NAME = "test-index"
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def create_index():
|
|
23
|
+
pinecone.create_index(
|
|
24
|
+
name=PINECONE_INDEX_NAME,
|
|
25
|
+
dimension=1536,
|
|
26
|
+
metric="cosine",
|
|
27
|
+
spec=ServerlessSpec(cloud="aws", region="us-east-1"),
|
|
28
|
+
)
|
|
29
|
+
|
|
20
30
|
|
|
21
31
|
@with_langtrace_root_span()
|
|
22
32
|
def basic(span_id, trace_id):
|
|
@@ -32,7 +42,7 @@ def basic(span_id, trace_id):
|
|
|
32
42
|
unique_id = "unique_random_id"
|
|
33
43
|
data_to_upsert = {"id": unique_id, "values": embedding}
|
|
34
44
|
|
|
35
|
-
index = pinecone.Index(
|
|
45
|
+
index = pinecone.Index(PINECONE_INDEX_NAME)
|
|
36
46
|
res = index.upsert(vectors=[data_to_upsert], namespace="test-namespace")
|
|
37
47
|
print("res", res)
|
|
38
48
|
|
|
@@ -43,3 +53,7 @@ def basic(span_id, trace_id):
|
|
|
43
53
|
{"spanId": span_id, "traceId": trace_id, "userScore": 1, "userId": "123"}
|
|
44
54
|
)
|
|
45
55
|
print(resp)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
# create_index()
|
|
59
|
+
basic("span_id", "trace_id")
|
|
@@ -18,7 +18,6 @@ import importlib.metadata
|
|
|
18
18
|
import logging
|
|
19
19
|
from typing import Collection
|
|
20
20
|
|
|
21
|
-
import pinecone
|
|
22
21
|
from langtrace.trace_attributes import PineconeMethods
|
|
23
22
|
from opentelemetry.instrumentation.instrumentor import BaseInstrumentor
|
|
24
23
|
from opentelemetry.trace import get_tracer
|
|
@@ -42,21 +41,12 @@ class PineconeInstrumentation(BaseInstrumentor):
|
|
|
42
41
|
tracer = get_tracer(__name__, "", tracer_provider)
|
|
43
42
|
version = importlib.metadata.version("pinecone-client")
|
|
44
43
|
for operation_name, details in APIS.items():
|
|
45
|
-
method_ref = details["METHOD"]
|
|
46
|
-
method = None
|
|
47
|
-
if method_ref is PineconeMethods.UPSERT.value:
|
|
48
|
-
method = pinecone.Index.upsert
|
|
49
|
-
elif method_ref is PineconeMethods.QUERY.value:
|
|
50
|
-
method = pinecone.Index.query
|
|
51
|
-
elif method_ref is PineconeMethods.DELETE.value:
|
|
52
|
-
method = pinecone.Index.delete
|
|
53
44
|
operation = details["OPERATION"]
|
|
54
|
-
|
|
55
45
|
# Dynamically creating the patching call
|
|
56
46
|
wrap_function_wrapper(
|
|
57
47
|
"pinecone.data.index",
|
|
58
48
|
f"Index.{operation}",
|
|
59
|
-
generic_patch(
|
|
49
|
+
generic_patch(operation_name, version, tracer),
|
|
60
50
|
)
|
|
61
51
|
|
|
62
52
|
def _uninstrument(self, **kwargs):
|
|
@@ -14,9 +14,9 @@ See the License for the specific language governing permissions and
|
|
|
14
14
|
limitations under the License.
|
|
15
15
|
"""
|
|
16
16
|
|
|
17
|
+
import json
|
|
18
|
+
|
|
17
19
|
from langtrace.trace_attributes import DatabaseSpanAttributes
|
|
18
|
-
from langtrace_python_sdk.utils import set_span_attribute
|
|
19
|
-
from langtrace_python_sdk.utils.silently_fail import silently_fail
|
|
20
20
|
from opentelemetry import baggage
|
|
21
21
|
from opentelemetry.trace import SpanKind
|
|
22
22
|
from opentelemetry.trace.status import Status, StatusCode
|
|
@@ -26,15 +26,16 @@ from langtrace_python_sdk.constants.instrumentation.common import (
|
|
|
26
26
|
SERVICE_PROVIDERS,
|
|
27
27
|
)
|
|
28
28
|
from langtrace_python_sdk.constants.instrumentation.pinecone import APIS
|
|
29
|
-
import
|
|
29
|
+
from langtrace_python_sdk.utils import set_span_attribute
|
|
30
|
+
from langtrace_python_sdk.utils.silently_fail import silently_fail
|
|
30
31
|
|
|
31
32
|
|
|
32
|
-
def generic_patch(
|
|
33
|
+
def generic_patch(operation_name, version, tracer):
|
|
33
34
|
"""
|
|
34
35
|
A generic patch method that wraps a function with a span"""
|
|
35
36
|
|
|
36
37
|
def traced_method(wrapped, instance, args, kwargs):
|
|
37
|
-
api = APIS[
|
|
38
|
+
api = APIS[operation_name]
|
|
38
39
|
service_provider = SERVICE_PROVIDERS["PINECONE"]
|
|
39
40
|
extra_attributes = baggage.get_baggage(LANGTRACE_ADDITIONAL_SPAN_ATTRIBUTES_KEY)
|
|
40
41
|
|
|
@@ -56,7 +57,7 @@ def generic_patch(original_method, method, version, tracer):
|
|
|
56
57
|
|
|
57
58
|
if span.is_recording():
|
|
58
59
|
set_span_attribute(span, "server.address", instance._config.host)
|
|
59
|
-
if
|
|
60
|
+
if operation_name == "QUERY":
|
|
60
61
|
set_query_input_attributes(span, kwargs)
|
|
61
62
|
|
|
62
63
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
@@ -64,7 +65,7 @@ def generic_patch(original_method, method, version, tracer):
|
|
|
64
65
|
span.set_attribute(field, value)
|
|
65
66
|
try:
|
|
66
67
|
# Attempt to call the original method
|
|
67
|
-
result =
|
|
68
|
+
result = wrapped(*args, **kwargs)
|
|
68
69
|
if result:
|
|
69
70
|
if span.is_recording():
|
|
70
71
|
set_query_response_attributes(span, result)
|
|
@@ -26,7 +26,7 @@ from langtrace_python_sdk.instrumentation.weaviate.patch import (
|
|
|
26
26
|
generic_collection_patch,
|
|
27
27
|
generic_query_patch,
|
|
28
28
|
)
|
|
29
|
-
from
|
|
29
|
+
from langtrace_python_sdk.constants.instrumentation.weaviate import APIS
|
|
30
30
|
|
|
31
31
|
logging.basicConfig(level=logging.FATAL)
|
|
32
32
|
|
|
@@ -15,25 +15,25 @@ limitations under the License.
|
|
|
15
15
|
"""
|
|
16
16
|
|
|
17
17
|
import asyncio
|
|
18
|
+
import os
|
|
18
19
|
from functools import wraps
|
|
19
20
|
from typing import Optional
|
|
20
21
|
|
|
22
|
+
import requests
|
|
23
|
+
from opentelemetry import baggage, context, trace
|
|
24
|
+
from opentelemetry.trace import SpanKind
|
|
25
|
+
|
|
21
26
|
from langtrace_python_sdk.constants.exporter.langtrace_exporter import (
|
|
22
27
|
LANGTRACE_REMOTE_URL,
|
|
23
28
|
)
|
|
29
|
+
from langtrace_python_sdk.constants.instrumentation.common import (
|
|
30
|
+
LANGTRACE_ADDITIONAL_SPAN_ATTRIBUTES_KEY,
|
|
31
|
+
)
|
|
24
32
|
from langtrace_python_sdk.utils.types import (
|
|
25
33
|
EvaluationAPIData,
|
|
26
34
|
LangTraceApiError,
|
|
27
35
|
LangTraceEvaluation,
|
|
28
36
|
)
|
|
29
|
-
from opentelemetry import baggage, context, trace
|
|
30
|
-
from opentelemetry.trace import SpanKind
|
|
31
|
-
|
|
32
|
-
from langtrace_python_sdk.constants.instrumentation.common import (
|
|
33
|
-
LANGTRACE_ADDITIONAL_SPAN_ATTRIBUTES_KEY,
|
|
34
|
-
)
|
|
35
|
-
import os
|
|
36
|
-
import requests
|
|
37
37
|
|
|
38
38
|
|
|
39
39
|
def with_langtrace_root_span(
|
|
@@ -161,7 +161,7 @@ def _get_evaluation(span_id: str) -> Optional[LangTraceEvaluation]:
|
|
|
161
161
|
headers={"x-api-key": os.environ["LANGTRACE_API_KEY"]},
|
|
162
162
|
timeout=None,
|
|
163
163
|
)
|
|
164
|
-
evaluations = response.json()
|
|
164
|
+
evaluations = response.json().get("evaluations", [])
|
|
165
165
|
response.raise_for_status()
|
|
166
166
|
return None if not evaluations else evaluations[0]
|
|
167
167
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "2.1.2"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "2.1.0"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/anthropic_example/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/chroma_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/chroma_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/chat.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/chat_stream.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/embed.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/rerank.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/cohere_example/tools.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/hiveagent_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/langchain_example/tool.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/agent.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/llamaindex_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/openai_example/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/perplexity_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/pinecone_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/qdrant_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/examples/qdrant_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/langtrace.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/types/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/llm.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/misc.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/langtrace_python_sdk/utils/types.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/anthropic/test_anthropic.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_chat.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_embed.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/cohere/test_cohere_rerank.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/langchain/test_langchain.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/langchain/test_langchain_core.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_chat_completion.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_embeddings.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/openai/test_image_generation.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.1.0 → langtrace_python_sdk-2.1.2}/src/tests/pinecone/test_pinecone.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|