langtrace-python-sdk 2.2.17__tar.gz → 2.2.18__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.2.17 → langtrace_python_sdk-2.2.18}/PKG-INFO +1 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/anthropic/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/chroma/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/cohere/patch.py +14 -4
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/crewai/patch.py +4 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/gemini/patch.py +3 -2
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/groq/patch.py +3 -2
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_community/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_core/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langgraph/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/llamaindex/patch.py +5 -2
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/ollama/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/openai/patch.py +8 -7
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/pinecone/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/qdrant/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/vertexai/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/weaviate/patch.py +2 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/llm.py +7 -0
- langtrace_python_sdk-2.2.18/src/langtrace_python_sdk/version.py +1 -0
- langtrace_python_sdk-2.2.17/src/langtrace_python_sdk/version.py +0 -1
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/.gitignore +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/LICENSE +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/README.md +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/pyproject.toml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/anthropic_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/anthropic_example/completion.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/chroma_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/chroma_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/chat.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/chat_stream.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/embed.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/rerank.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/tools.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/crewai_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/math_problems_cot.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/math_problems_cot_parallel.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/program_of_thought_basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/quiz_gen.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/react.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/fastapi_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/fastapi_example/basic_route.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/gemini_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/gemini_example/function_tools.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/gemini_example/main.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/hiveagent_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/inspect_ai_example/basic_eval.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/groq_example.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/langgraph_example.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/tool.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/agent.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/data/abramov.txt +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/ollama_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/ollama_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/async_tool_calling_nonstreaming.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/async_tool_calling_streaming.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/chat_completion.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/chat_completion_tool_choice.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/embeddings_create.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/function_calling.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/images_edit.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/images_generate.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/resources/lounge_flamingo.png +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/resources/mask.png +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/send_user_feedback.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/tool_calling.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/tool_calling_nonstreaming.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/openai_example/tool_calling_streaming.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/otlp_example/otlp_basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/otlp_example/otlp_with_langtrace.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/perplexity_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/pinecone_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/pinecone_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/qdrant_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/qdrant_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/routellm_example/basic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/vertexai_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/vertexai_example/main.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/weaviate_example/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/weaviate_example/query_text.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/exporter/langtrace_exporter.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/anthropic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/chroma.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/cohere.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/common.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/gemini.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/groq.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/ollama.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/openai.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/pinecone.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/qdrant.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/vertexai.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/constants/instrumentation/weaviate.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/extensions/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/extensions/langtrace_exporter.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/extensions/langtrace_filesystem.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/anthropic/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/anthropic/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/chroma/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/chroma/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/cohere/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/cohere/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/crewai/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/crewai/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/dspy/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/dspy/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/dspy/patch.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/gemini/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/gemini/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/groq/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/groq/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_community/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_community/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_core/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langchain_core/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langgraph/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/langgraph/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/llamaindex/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/llamaindex/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/ollama/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/ollama/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/openai/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/openai/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/pinecone/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/pinecone/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/qdrant/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/qdrant/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/vertexai/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/vertexai/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/weaviate/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/instrumentation/weaviate/instrumentation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/langtrace.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/types/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/langtrace_sampler.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/misc.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/prompt_registry.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/sdk_version_checker.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/silently_fail.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/types.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/with_root_span.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/run_example.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/__init__.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/anthropic/cassettes/test_anthropic.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/anthropic/cassettes/test_anthropic_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/anthropic/cassettes/test_async_anthropic_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/anthropic/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/anthropic/test_anthropic.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/chroma/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/chroma/test_chroma.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/cassettes/test_cohere_chat.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/cassettes/test_cohere_chat_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/cassettes/test_cohere_embed.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/cassettes/test_cohere_rerank.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/test_cohere_chat.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/test_cohere_embed.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/cohere/test_cohere_rerank.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/cassettes/test_async_chat_completion.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/cassettes/test_async_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/cassettes/test_chat_completion.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/cassettes/test_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/groq/test_groq.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/langchain/cassettes/test_langchain.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/langchain/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/langchain/test_langchain.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/cassettes/test_async_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/cassettes/test_async_image_generation.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/cassettes/test_chat_completion.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/cassettes/test_chat_completion_streaming.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/cassettes/test_image_generation.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/test_chat_completion.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/test_embeddings.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/openai/test_image_generation.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/pinecone/cassettes/test_query.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/pinecone/cassettes/test_upsert.yaml +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/pinecone/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/pinecone/test_pinecone.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/qdrant/conftest.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/qdrant/test_qdrant.py +0 -0
- {langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/tests/utils.py +0 -0
|
@@ -23,6 +23,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
23
23
|
get_langtrace_attributes,
|
|
24
24
|
get_llm_request_attributes,
|
|
25
25
|
get_llm_url,
|
|
26
|
+
get_span_name,
|
|
26
27
|
is_streaming,
|
|
27
28
|
set_event_completion,
|
|
28
29
|
set_event_completion_chunk,
|
|
@@ -64,7 +65,7 @@ def messages_create(original_method, version, tracer):
|
|
|
64
65
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
65
66
|
|
|
66
67
|
span = tracer.start_span(
|
|
67
|
-
APIS["MESSAGES_CREATE"]["METHOD"], kind=SpanKind.CLIENT
|
|
68
|
+
name=get_span_name(APIS["MESSAGES_CREATE"]["METHOD"]), kind=SpanKind.CLIENT
|
|
68
69
|
)
|
|
69
70
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
70
71
|
set_span_attribute(span, field, value)
|
|
@@ -16,6 +16,7 @@ limitations under the License.
|
|
|
16
16
|
|
|
17
17
|
from langtrace.trace_attributes import DatabaseSpanAttributes
|
|
18
18
|
from langtrace_python_sdk.utils import set_span_attribute
|
|
19
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
19
20
|
from langtrace_python_sdk.utils.silently_fail import silently_fail
|
|
20
21
|
from opentelemetry import baggage, trace
|
|
21
22
|
from opentelemetry.trace import SpanKind
|
|
@@ -60,7 +61,7 @@ def collection_patch(method, version, tracer):
|
|
|
60
61
|
attributes = DatabaseSpanAttributes(**span_attributes)
|
|
61
62
|
|
|
62
63
|
with tracer.start_as_current_span(
|
|
63
|
-
api["METHOD"],
|
|
64
|
+
name=get_span_name(api["METHOD"]),
|
|
64
65
|
kind=SpanKind.CLIENT,
|
|
65
66
|
context=set_span_in_context(trace.get_current_span()),
|
|
66
67
|
) as span:
|
|
@@ -21,6 +21,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
21
21
|
get_llm_request_attributes,
|
|
22
22
|
get_extra_attributes,
|
|
23
23
|
get_llm_url,
|
|
24
|
+
get_span_name,
|
|
24
25
|
set_event_completion,
|
|
25
26
|
set_event_completion_chunk,
|
|
26
27
|
set_usage_attributes,
|
|
@@ -57,7 +58,9 @@ def rerank(original_method, version, tracer):
|
|
|
57
58
|
|
|
58
59
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
59
60
|
|
|
60
|
-
span = tracer.start_span(
|
|
61
|
+
span = tracer.start_span(
|
|
62
|
+
name=get_span_name(APIS["RERANK"]["METHOD"]), kind=SpanKind.CLIENT
|
|
63
|
+
)
|
|
61
64
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
62
65
|
set_span_attribute(span, field, value)
|
|
63
66
|
try:
|
|
@@ -137,7 +140,10 @@ def embed(original_method, version, tracer):
|
|
|
137
140
|
|
|
138
141
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
139
142
|
|
|
140
|
-
span = tracer.start_span(
|
|
143
|
+
span = tracer.start_span(
|
|
144
|
+
name=get_span_name(APIS["EMBED"]["METHOD"]),
|
|
145
|
+
kind=SpanKind.CLIENT,
|
|
146
|
+
)
|
|
141
147
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
142
148
|
set_span_attribute(span, field, value)
|
|
143
149
|
try:
|
|
@@ -225,7 +231,9 @@ def chat_create(original_method, version, tracer):
|
|
|
225
231
|
# stringify the list of objects
|
|
226
232
|
attributes.llm_tool_results = json.dumps(kwargs.get("tool_results"))
|
|
227
233
|
|
|
228
|
-
span = tracer.start_span(
|
|
234
|
+
span = tracer.start_span(
|
|
235
|
+
name=get_span_name(APIS["CHAT_CREATE"]["METHOD"]), kind=SpanKind.CLIENT
|
|
236
|
+
)
|
|
229
237
|
|
|
230
238
|
# Set the attributes on the span
|
|
231
239
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
@@ -391,7 +399,9 @@ def chat_stream(original_method, version, tracer):
|
|
|
391
399
|
# stringify the list of objects
|
|
392
400
|
attributes.llm_tool_results = json.dumps(kwargs.get("tool_results"))
|
|
393
401
|
|
|
394
|
-
span = tracer.start_span(
|
|
402
|
+
span = tracer.start_span(
|
|
403
|
+
name=get_span_name(APIS["CHAT_STREAM"]["METHOD"]), kind=SpanKind.CLIENT
|
|
404
|
+
)
|
|
395
405
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
396
406
|
set_span_attribute(span, field, value)
|
|
397
407
|
try:
|
|
@@ -2,6 +2,7 @@ import json
|
|
|
2
2
|
from importlib_metadata import version as v
|
|
3
3
|
from langtrace_python_sdk.constants import LANGTRACE_SDK_NAME
|
|
4
4
|
from langtrace_python_sdk.utils import set_span_attribute
|
|
5
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
5
6
|
from langtrace_python_sdk.utils.silently_fail import silently_fail
|
|
6
7
|
from langtrace_python_sdk.constants.instrumentation.common import (
|
|
7
8
|
LANGTRACE_ADDITIONAL_SPAN_ATTRIBUTES_KEY,
|
|
@@ -143,7 +144,9 @@ def patch_crew(operation_name, version, tracer):
|
|
|
143
144
|
|
|
144
145
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
145
146
|
|
|
146
|
-
with tracer.start_as_current_span(
|
|
147
|
+
with tracer.start_as_current_span(
|
|
148
|
+
get_span_name(operation_name), kind=SpanKind.CLIENT
|
|
149
|
+
) as span:
|
|
147
150
|
_set_input_attributes(span, kwargs, attributes)
|
|
148
151
|
|
|
149
152
|
try:
|
|
@@ -10,6 +10,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
10
10
|
get_langtrace_attributes,
|
|
11
11
|
get_llm_request_attributes,
|
|
12
12
|
get_llm_url,
|
|
13
|
+
get_span_name,
|
|
13
14
|
is_streaming,
|
|
14
15
|
set_event_completion,
|
|
15
16
|
set_event_completion_chunk,
|
|
@@ -35,7 +36,7 @@ def patch_gemini(name, version, tracer: Tracer):
|
|
|
35
36
|
}
|
|
36
37
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
37
38
|
span = tracer.start_span(
|
|
38
|
-
name=name,
|
|
39
|
+
name=get_span_name(name),
|
|
39
40
|
kind=SpanKind.CLIENT,
|
|
40
41
|
context=set_span_in_context(trace.get_current_span()),
|
|
41
42
|
)
|
|
@@ -76,7 +77,7 @@ def apatch_gemini(name, version, tracer: Tracer):
|
|
|
76
77
|
}
|
|
77
78
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
78
79
|
span = tracer.start_span(
|
|
79
|
-
name=name,
|
|
80
|
+
name=get_span_name(name),
|
|
80
81
|
kind=SpanKind.CLIENT,
|
|
81
82
|
context=set_span_in_context(trace.get_current_span()),
|
|
82
83
|
)
|
|
@@ -29,6 +29,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
29
29
|
get_llm_request_attributes,
|
|
30
30
|
get_llm_url,
|
|
31
31
|
get_langtrace_attributes,
|
|
32
|
+
get_span_name,
|
|
32
33
|
set_event_completion,
|
|
33
34
|
set_event_completion_chunk,
|
|
34
35
|
set_usage_attributes,
|
|
@@ -107,7 +108,7 @@ def chat_completions_create(original_method, version, tracer):
|
|
|
107
108
|
# with tracer.start_as_current_span(APIS["CHAT_COMPLETION"]["METHOD"],
|
|
108
109
|
# kind=SpanKind.CLIENT) as span:
|
|
109
110
|
span = tracer.start_span(
|
|
110
|
-
APIS["CHAT_COMPLETION"]["METHOD"],
|
|
111
|
+
name=get_span_name(APIS["CHAT_COMPLETION"]["METHOD"]),
|
|
111
112
|
kind=SpanKind.CLIENT,
|
|
112
113
|
context=set_span_in_context(trace.get_current_span()),
|
|
113
114
|
)
|
|
@@ -335,7 +336,7 @@ def async_chat_completions_create(original_method, version, tracer):
|
|
|
335
336
|
# with tracer.start_as_current_span(APIS["CHAT_COMPLETION"]["METHOD"],
|
|
336
337
|
# kind=SpanKind.CLIENT) as span:
|
|
337
338
|
span = tracer.start_span(
|
|
338
|
-
APIS["CHAT_COMPLETION"]["METHOD"], kind=SpanKind.CLIENT
|
|
339
|
+
name=get_span_name(APIS["CHAT_COMPLETION"]["METHOD"]), kind=SpanKind.CLIENT
|
|
339
340
|
)
|
|
340
341
|
for field, value in attributes.model_dump(by_alias=True).items():
|
|
341
342
|
set_span_attribute(span, field, value)
|
|
@@ -18,6 +18,7 @@ import json
|
|
|
18
18
|
|
|
19
19
|
from langtrace.trace_attributes import FrameworkSpanAttributes
|
|
20
20
|
from langtrace_python_sdk.constants import LANGTRACE_SDK_NAME
|
|
21
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
21
22
|
from opentelemetry import baggage, trace
|
|
22
23
|
from opentelemetry.trace.propagation import set_span_in_context
|
|
23
24
|
from opentelemetry.trace import SpanKind, StatusCode
|
|
@@ -57,7 +58,7 @@ def generic_patch(
|
|
|
57
58
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
58
59
|
|
|
59
60
|
with tracer.start_as_current_span(
|
|
60
|
-
method_name,
|
|
61
|
+
name=get_span_name(method_name),
|
|
61
62
|
kind=SpanKind.CLIENT,
|
|
62
63
|
context=set_span_in_context(trace.get_current_span()),
|
|
63
64
|
) as span:
|
|
@@ -17,6 +17,7 @@ limitations under the License.
|
|
|
17
17
|
import json
|
|
18
18
|
|
|
19
19
|
from langtrace.trace_attributes import FrameworkSpanAttributes
|
|
20
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
20
21
|
from opentelemetry import baggage, trace
|
|
21
22
|
from opentelemetry.trace.propagation import set_span_in_context
|
|
22
23
|
|
|
@@ -55,7 +56,7 @@ def generic_patch(
|
|
|
55
56
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
56
57
|
|
|
57
58
|
with tracer.start_as_current_span(
|
|
58
|
-
method_name,
|
|
59
|
+
name=get_span_name(method_name),
|
|
59
60
|
kind=SpanKind.CLIENT,
|
|
60
61
|
context=set_span_in_context(trace.get_current_span()),
|
|
61
62
|
) as span:
|
|
@@ -17,6 +17,7 @@ limitations under the License.
|
|
|
17
17
|
import json
|
|
18
18
|
|
|
19
19
|
from langtrace.trace_attributes import FrameworkSpanAttributes
|
|
20
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
20
21
|
from opentelemetry import baggage, trace
|
|
21
22
|
from opentelemetry.trace import SpanKind, StatusCode
|
|
22
23
|
from opentelemetry.trace.status import Status
|
|
@@ -75,7 +76,7 @@ def generic_patch(
|
|
|
75
76
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
76
77
|
|
|
77
78
|
with tracer.start_as_current_span(
|
|
78
|
-
method_name,
|
|
79
|
+
name=get_span_name(method_name),
|
|
79
80
|
kind=SpanKind.CLIENT,
|
|
80
81
|
context=set_span_in_context(trace.get_current_span()),
|
|
81
82
|
) as span:
|
|
@@ -15,6 +15,7 @@ limitations under the License.
|
|
|
15
15
|
"""
|
|
16
16
|
|
|
17
17
|
import json
|
|
18
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
18
19
|
from opentelemetry.trace.propagation import set_span_in_context
|
|
19
20
|
|
|
20
21
|
from langtrace.trace_attributes import FrameworkSpanAttributes
|
|
@@ -52,7 +53,7 @@ def patch_graph_methods(method_name, tracer, version):
|
|
|
52
53
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
53
54
|
|
|
54
55
|
with tracer.start_as_current_span(
|
|
55
|
-
method_name,
|
|
56
|
+
name=get_span_name(method_name),
|
|
56
57
|
kind=SpanKind.CLIENT,
|
|
57
58
|
context=set_span_in_context(trace.get_current_span()),
|
|
58
59
|
) as span:
|
|
@@ -15,6 +15,7 @@ limitations under the License.
|
|
|
15
15
|
"""
|
|
16
16
|
|
|
17
17
|
from langtrace.trace_attributes import FrameworkSpanAttributes
|
|
18
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
18
19
|
from opentelemetry import baggage, trace
|
|
19
20
|
from opentelemetry.trace import SpanKind
|
|
20
21
|
from opentelemetry.trace.status import Status, StatusCode
|
|
@@ -49,7 +50,7 @@ def generic_patch(method, task, tracer, version):
|
|
|
49
50
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
50
51
|
|
|
51
52
|
with tracer.start_as_current_span(
|
|
52
|
-
method,
|
|
53
|
+
name=get_span_name(method),
|
|
53
54
|
kind=SpanKind.CLIENT,
|
|
54
55
|
context=set_span_in_context(trace.get_current_span()),
|
|
55
56
|
) as span:
|
|
@@ -94,7 +95,9 @@ def async_generic_patch(method, task, tracer, version):
|
|
|
94
95
|
|
|
95
96
|
attributes = FrameworkSpanAttributes(**span_attributes)
|
|
96
97
|
|
|
97
|
-
with tracer.start_as_current_span(
|
|
98
|
+
with tracer.start_as_current_span(
|
|
99
|
+
name=get_span_name(method), kind=SpanKind.CLIENT
|
|
100
|
+
) as span:
|
|
98
101
|
async for field, value in attributes.model_dump(by_alias=True).items():
|
|
99
102
|
if value is not None:
|
|
100
103
|
span.set_attribute(field, value)
|
|
@@ -5,6 +5,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
5
5
|
get_langtrace_attributes,
|
|
6
6
|
get_llm_request_attributes,
|
|
7
7
|
get_llm_url,
|
|
8
|
+
get_span_name,
|
|
8
9
|
set_event_completion,
|
|
9
10
|
set_event_completion_chunk,
|
|
10
11
|
)
|
|
@@ -35,7 +36,7 @@ def generic_patch(operation_name, version, tracer):
|
|
|
35
36
|
|
|
36
37
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
37
38
|
with tracer.start_as_current_span(
|
|
38
|
-
f'ollama.{api["METHOD"]}', kind=SpanKind.CLIENT
|
|
39
|
+
name=get_span_name(f'ollama.{api["METHOD"]}'), kind=SpanKind.CLIENT
|
|
39
40
|
) as span:
|
|
40
41
|
_set_input_attributes(span, kwargs, attributes)
|
|
41
42
|
|
|
@@ -37,6 +37,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
37
37
|
get_langtrace_attributes,
|
|
38
38
|
get_llm_request_attributes,
|
|
39
39
|
get_llm_url,
|
|
40
|
+
get_span_name,
|
|
40
41
|
get_tool_calls,
|
|
41
42
|
is_streaming,
|
|
42
43
|
set_event_completion,
|
|
@@ -64,7 +65,7 @@ def images_generate(original_method, version, tracer):
|
|
|
64
65
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
65
66
|
|
|
66
67
|
with tracer.start_as_current_span(
|
|
67
|
-
APIS["IMAGES_GENERATION"]["METHOD"],
|
|
68
|
+
name=get_span_name(APIS["IMAGES_GENERATION"]["METHOD"]),
|
|
68
69
|
kind=SpanKind.CLIENT,
|
|
69
70
|
context=set_span_in_context(trace.get_current_span()),
|
|
70
71
|
) as span:
|
|
@@ -127,7 +128,7 @@ def async_images_generate(original_method, version, tracer):
|
|
|
127
128
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
128
129
|
|
|
129
130
|
with tracer.start_as_current_span(
|
|
130
|
-
APIS["IMAGES_GENERATION"]["METHOD"],
|
|
131
|
+
name=get_span_name(APIS["IMAGES_GENERATION"]["METHOD"]),
|
|
131
132
|
kind=SpanKind.CLIENT,
|
|
132
133
|
context=set_span_in_context(trace.get_current_span()),
|
|
133
134
|
) as span:
|
|
@@ -192,7 +193,7 @@ def images_edit(original_method, version, tracer):
|
|
|
192
193
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
193
194
|
|
|
194
195
|
with tracer.start_as_current_span(
|
|
195
|
-
APIS["IMAGES_EDIT"]["METHOD"],
|
|
196
|
+
name=APIS["IMAGES_EDIT"]["METHOD"],
|
|
196
197
|
kind=SpanKind.CLIENT,
|
|
197
198
|
context=set_span_in_context(trace.get_current_span()),
|
|
198
199
|
) as span:
|
|
@@ -282,7 +283,7 @@ def chat_completions_create(original_method, version, tracer):
|
|
|
282
283
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
283
284
|
|
|
284
285
|
span = tracer.start_span(
|
|
285
|
-
APIS["CHAT_COMPLETION"]["METHOD"],
|
|
286
|
+
name=get_span_name(APIS["CHAT_COMPLETION"]["METHOD"]),
|
|
286
287
|
kind=SpanKind.CLIENT,
|
|
287
288
|
context=set_span_in_context(trace.get_current_span()),
|
|
288
289
|
)
|
|
@@ -376,7 +377,7 @@ def async_chat_completions_create(original_method, version, tracer):
|
|
|
376
377
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
377
378
|
|
|
378
379
|
span = tracer.start_span(
|
|
379
|
-
APIS["CHAT_COMPLETION"]["METHOD"],
|
|
380
|
+
name=get_span_name(APIS["CHAT_COMPLETION"]["METHOD"]),
|
|
380
381
|
kind=SpanKind.CLIENT,
|
|
381
382
|
context=set_span_in_context(trace.get_current_span()),
|
|
382
383
|
)
|
|
@@ -455,7 +456,7 @@ def embeddings_create(original_method, version, tracer):
|
|
|
455
456
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
456
457
|
|
|
457
458
|
with tracer.start_as_current_span(
|
|
458
|
-
APIS["EMBEDDINGS_CREATE"]["METHOD"],
|
|
459
|
+
name=get_span_name(APIS["EMBEDDINGS_CREATE"]["METHOD"]),
|
|
459
460
|
kind=SpanKind.CLIENT,
|
|
460
461
|
context=set_span_in_context(trace.get_current_span()),
|
|
461
462
|
) as span:
|
|
@@ -512,7 +513,7 @@ def async_embeddings_create(original_method, version, tracer):
|
|
|
512
513
|
)
|
|
513
514
|
|
|
514
515
|
with tracer.start_as_current_span(
|
|
515
|
-
APIS["EMBEDDINGS_CREATE"]["METHOD"],
|
|
516
|
+
name=get_span_name(APIS["EMBEDDINGS_CREATE"]["METHOD"]),
|
|
516
517
|
kind=SpanKind.CLIENT,
|
|
517
518
|
context=set_span_in_context(trace.get_current_span()),
|
|
518
519
|
) as span:
|
|
@@ -17,6 +17,7 @@ limitations under the License.
|
|
|
17
17
|
import json
|
|
18
18
|
|
|
19
19
|
from langtrace.trace_attributes import DatabaseSpanAttributes
|
|
20
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
20
21
|
from opentelemetry import baggage, trace
|
|
21
22
|
from opentelemetry.trace import SpanKind
|
|
22
23
|
from opentelemetry.trace.status import Status, StatusCode
|
|
@@ -57,7 +58,7 @@ def generic_patch(operation_name, version, tracer):
|
|
|
57
58
|
attributes = DatabaseSpanAttributes(**span_attributes)
|
|
58
59
|
|
|
59
60
|
with tracer.start_as_current_span(
|
|
60
|
-
api["METHOD"],
|
|
61
|
+
name=get_span_name(api["METHOD"]),
|
|
61
62
|
kind=SpanKind.CLIENT,
|
|
62
63
|
context=set_span_in_context(trace.get_current_span()),
|
|
63
64
|
) as span:
|
|
@@ -16,6 +16,7 @@ limitations under the License.
|
|
|
16
16
|
|
|
17
17
|
import json
|
|
18
18
|
from langtrace.trace_attributes import DatabaseSpanAttributes
|
|
19
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
19
20
|
from langtrace_python_sdk.utils.silently_fail import silently_fail
|
|
20
21
|
from langtrace_python_sdk.utils import set_span_attribute
|
|
21
22
|
from opentelemetry import baggage, trace
|
|
@@ -58,7 +59,7 @@ def collection_patch(method, version, tracer):
|
|
|
58
59
|
attributes = DatabaseSpanAttributes(**span_attributes)
|
|
59
60
|
|
|
60
61
|
with tracer.start_as_current_span(
|
|
61
|
-
api["METHOD"],
|
|
62
|
+
name=get_span_name(api["METHOD"]),
|
|
62
63
|
kind=SpanKind.CLIENT,
|
|
63
64
|
context=set_span_in_context(trace.get_current_span()),
|
|
64
65
|
) as span:
|
|
@@ -8,6 +8,7 @@ from langtrace_python_sdk.utils.llm import (
|
|
|
8
8
|
get_langtrace_attributes,
|
|
9
9
|
get_llm_request_attributes,
|
|
10
10
|
get_llm_url,
|
|
11
|
+
get_span_name,
|
|
11
12
|
set_event_completion,
|
|
12
13
|
set_span_attributes,
|
|
13
14
|
set_usage_attributes,
|
|
@@ -39,7 +40,7 @@ def patch_vertexai(name, version, tracer: Tracer):
|
|
|
39
40
|
}
|
|
40
41
|
attributes = LLMSpanAttributes(**span_attributes)
|
|
41
42
|
span = tracer.start_span(
|
|
42
|
-
name=name,
|
|
43
|
+
name=get_span_name(name),
|
|
43
44
|
kind=SpanKind.CLIENT,
|
|
44
45
|
context=set_span_in_context(trace.get_current_span()),
|
|
45
46
|
)
|
|
@@ -17,6 +17,7 @@ limitations under the License.
|
|
|
17
17
|
import json
|
|
18
18
|
|
|
19
19
|
from langtrace.trace_attributes import DatabaseSpanAttributes
|
|
20
|
+
from langtrace_python_sdk.utils.llm import get_span_name
|
|
20
21
|
from opentelemetry import baggage, trace
|
|
21
22
|
from opentelemetry.trace import SpanKind
|
|
22
23
|
from opentelemetry.trace.status import Status, StatusCode
|
|
@@ -132,7 +133,7 @@ def create_traced_method(method_name, version, tracer, get_collection_name=None)
|
|
|
132
133
|
attributes = DatabaseSpanAttributes(**span_attributes)
|
|
133
134
|
|
|
134
135
|
with tracer.start_as_current_span(
|
|
135
|
-
method_name,
|
|
136
|
+
name=get_span_name(method_name),
|
|
136
137
|
kind=SpanKind.CLIENT,
|
|
137
138
|
context=set_span_in_context(trace.get_current_span()),
|
|
138
139
|
) as span:
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/utils/llm.py
RENAMED
|
@@ -33,6 +33,13 @@ from opentelemetry.trace.status import StatusCode
|
|
|
33
33
|
import os
|
|
34
34
|
|
|
35
35
|
|
|
36
|
+
def get_span_name(operation_name):
|
|
37
|
+
extra_attributes = get_extra_attributes()
|
|
38
|
+
if extra_attributes is not None and "langtrace.span.name" in extra_attributes:
|
|
39
|
+
return f'{operation_name}-{extra_attributes["langtrace.span.name"]}'
|
|
40
|
+
return operation_name
|
|
41
|
+
|
|
42
|
+
|
|
36
43
|
def estimate_tokens(prompt):
|
|
37
44
|
"""
|
|
38
45
|
Estimate the number of tokens in a prompt."""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "2.2.18"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "2.2.17"
|
|
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.2.17 → langtrace_python_sdk-2.2.18}/src/examples/chroma_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/chroma_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/chat.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/embed.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/rerank.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/cohere_example/tools.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/crewai_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/quiz_gen.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/dspy_example/react.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/fastapi_example/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/gemini_example/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/gemini_example/main.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/hiveagent_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/langchain_example/tool.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/agent.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/llamaindex_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/ollama_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/ollama_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/otlp_example/otlp_basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/perplexity_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/pinecone_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/qdrant_example/__init__.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/qdrant_example/basic.py
RENAMED
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/routellm_example/basic.py
RENAMED
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/examples/vertexai_example/main.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{langtrace_python_sdk-2.2.17 → langtrace_python_sdk-2.2.18}/src/langtrace_python_sdk/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|