microsoft-agents-a365-observability-hosting 0.2.1.dev33__tar.gz → 0.2.1.dev36__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.
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/PKG-INFO +1 -1
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/middleware/output_logging_middleware.py +4 -11
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/scope_helpers/utils.py +4 -6
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365_observability_hosting.egg-info/PKG-INFO +1 -1
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/README.md +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/__init__.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/middleware/__init__.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/middleware/baggage_middleware.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/middleware/observability_hosting_manager.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/scope_helpers/__init__.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/scope_helpers/populate_baggage.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/scope_helpers/populate_invoke_agent_scope.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/token_cache_helpers/__init__.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365/observability/hosting/token_cache_helpers/agent_token_cache.py +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365_observability_hosting.egg-info/SOURCES.txt +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365_observability_hosting.egg-info/dependency_links.txt +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365_observability_hosting.egg-info/requires.txt +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/microsoft_agents_a365_observability_hosting.egg-info/top_level.txt +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/pyproject.toml +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/setup.cfg +0 -0
- {microsoft_agents_a365_observability_hosting-0.2.1.dev33 → microsoft_agents_a365_observability_hosting-0.2.1.dev36}/setup.py +0 -0
|
@@ -12,13 +12,12 @@ from microsoft_agents.activity import Activity
|
|
|
12
12
|
from microsoft_agents.hosting.core.turn_context import TurnContext
|
|
13
13
|
from microsoft_agents_a365.observability.core.agent_details import AgentDetails
|
|
14
14
|
from microsoft_agents_a365.observability.core.constants import (
|
|
15
|
+
CHANNEL_LINK_KEY,
|
|
16
|
+
CHANNEL_NAME_KEY,
|
|
15
17
|
GEN_AI_CALLER_ID_KEY,
|
|
16
18
|
GEN_AI_CALLER_NAME_KEY,
|
|
17
|
-
GEN_AI_CALLER_TENANT_ID_KEY,
|
|
18
19
|
GEN_AI_CALLER_UPN_KEY,
|
|
19
20
|
GEN_AI_CONVERSATION_ID_KEY,
|
|
20
|
-
GEN_AI_EXECUTION_SOURCE_DESCRIPTION_KEY,
|
|
21
|
-
GEN_AI_EXECUTION_SOURCE_NAME_KEY,
|
|
22
21
|
GEN_AI_EXECUTION_TYPE_KEY,
|
|
23
22
|
)
|
|
24
23
|
from microsoft_agents_a365.observability.core.models.caller_details import CallerDetails
|
|
@@ -74,7 +73,6 @@ def _derive_caller_details(context: TurnContext) -> CallerDetails | None:
|
|
|
74
73
|
caller_id=getattr(frm, "aad_object_id", None),
|
|
75
74
|
caller_upn=getattr(frm, "agentic_user_id", None),
|
|
76
75
|
caller_name=getattr(frm, "name", None),
|
|
77
|
-
tenant_id=getattr(frm, "tenant_id", None),
|
|
78
76
|
)
|
|
79
77
|
|
|
80
78
|
|
|
@@ -195,18 +193,13 @@ class OutputLoggingMiddleware:
|
|
|
195
193
|
# Set additional attributes on the scope
|
|
196
194
|
output_scope.set_tag_maybe(GEN_AI_CONVERSATION_ID_KEY, conversation_id)
|
|
197
195
|
output_scope.set_tag_maybe(GEN_AI_EXECUTION_TYPE_KEY, execution_type)
|
|
198
|
-
output_scope.set_tag_maybe(
|
|
199
|
-
|
|
200
|
-
)
|
|
201
|
-
output_scope.set_tag_maybe(
|
|
202
|
-
GEN_AI_EXECUTION_SOURCE_DESCRIPTION_KEY, source_metadata.get("description")
|
|
203
|
-
)
|
|
196
|
+
output_scope.set_tag_maybe(CHANNEL_NAME_KEY, source_metadata.get("name"))
|
|
197
|
+
output_scope.set_tag_maybe(CHANNEL_LINK_KEY, source_metadata.get("description"))
|
|
204
198
|
|
|
205
199
|
if caller_details:
|
|
206
200
|
output_scope.set_tag_maybe(GEN_AI_CALLER_ID_KEY, caller_details.caller_id)
|
|
207
201
|
output_scope.set_tag_maybe(GEN_AI_CALLER_UPN_KEY, caller_details.caller_upn)
|
|
208
202
|
output_scope.set_tag_maybe(GEN_AI_CALLER_NAME_KEY, caller_details.caller_name)
|
|
209
|
-
output_scope.set_tag_maybe(GEN_AI_CALLER_TENANT_ID_KEY, caller_details.tenant_id)
|
|
210
203
|
|
|
211
204
|
try:
|
|
212
205
|
await send_next()
|
|
@@ -5,6 +5,8 @@ from typing import Any
|
|
|
5
5
|
|
|
6
6
|
from microsoft_agents.activity import Activity
|
|
7
7
|
from microsoft_agents_a365.observability.core.constants import (
|
|
8
|
+
CHANNEL_LINK_KEY,
|
|
9
|
+
CHANNEL_NAME_KEY,
|
|
8
10
|
GEN_AI_AGENT_AUID_KEY,
|
|
9
11
|
GEN_AI_AGENT_DESCRIPTION_KEY,
|
|
10
12
|
GEN_AI_AGENT_ID_KEY,
|
|
@@ -12,12 +14,9 @@ from microsoft_agents_a365.observability.core.constants import (
|
|
|
12
14
|
GEN_AI_AGENT_UPN_KEY,
|
|
13
15
|
GEN_AI_CALLER_ID_KEY,
|
|
14
16
|
GEN_AI_CALLER_NAME_KEY,
|
|
15
|
-
GEN_AI_CALLER_TENANT_ID_KEY,
|
|
16
17
|
GEN_AI_CALLER_UPN_KEY,
|
|
17
18
|
GEN_AI_CONVERSATION_ID_KEY,
|
|
18
19
|
GEN_AI_CONVERSATION_ITEM_LINK_KEY,
|
|
19
|
-
GEN_AI_EXECUTION_SOURCE_DESCRIPTION_KEY,
|
|
20
|
-
GEN_AI_EXECUTION_SOURCE_NAME_KEY,
|
|
21
20
|
GEN_AI_EXECUTION_TYPE_KEY,
|
|
22
21
|
TENANT_ID_KEY,
|
|
23
22
|
)
|
|
@@ -42,7 +41,6 @@ def get_caller_pairs(activity: Activity) -> Iterator[tuple[str, Any]]:
|
|
|
42
41
|
yield GEN_AI_CALLER_ID_KEY, frm.aad_object_id
|
|
43
42
|
yield GEN_AI_CALLER_NAME_KEY, frm.name
|
|
44
43
|
yield GEN_AI_CALLER_UPN_KEY, frm.agentic_user_id
|
|
45
|
-
yield GEN_AI_CALLER_TENANT_ID_KEY, frm.tenant_id
|
|
46
44
|
|
|
47
45
|
|
|
48
46
|
def get_execution_type_pair(activity: Activity) -> Iterator[tuple[str, Any]]:
|
|
@@ -100,8 +98,8 @@ def get_source_metadata_pairs(activity: Activity) -> Iterator[tuple[str, Any]]:
|
|
|
100
98
|
sub_channel = channel_id.sub_channel
|
|
101
99
|
|
|
102
100
|
# Yield channel name as source name
|
|
103
|
-
yield
|
|
104
|
-
yield
|
|
101
|
+
yield CHANNEL_NAME_KEY, channel_name
|
|
102
|
+
yield CHANNEL_LINK_KEY, sub_channel
|
|
105
103
|
|
|
106
104
|
|
|
107
105
|
def get_conversation_pairs(activity: Activity) -> Iterator[tuple[str, Any]]:
|
|
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
|