Skip to content

Commit 1b38395

Browse files
Pylint Issue
1 parent 414ae47 commit 1b38395

File tree

4 files changed

+17
-21
lines changed

4 files changed

+17
-21
lines changed

src/backend/app_kernel.py

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# app_kernel.py
22
import asyncio
33
import logging
4-
import os
54
import uuid
65
from typing import Dict, List, Optional
76

@@ -10,7 +9,7 @@
109
from auth.auth_utils import get_authenticated_user_details
1110

1211
# Azure monitoring
13-
from azure.monitor.opentelemetry import configure_azure_monitor
12+
# from azure.monitor.opentelemetry import configure_azure_monitor
1413
from config_kernel import Config
1514
from event_utils import track_event_if_configured
1615

@@ -35,22 +34,23 @@
3534
from utils_kernel import initialize_runtime_and_context, rai_success
3635

3736
# Check if the Application Insights Instrumentation Key is set in the environment variables
38-
#connection_string = os.getenv("APPLICATIONINSIGHTS_CONNECTION_STRING")
39-
#if connection_string:
40-
# Configure Application Insights if the Instrumentation Key is found
41-
#configure_azure_monitor(connection_string=connection_string)
42-
# logging.info(
43-
# "Application Insights configured with the provided Instrumentation Key"
44-
# )
45-
#else:
46-
# # Log a warning if the Instrumentation Key is not found
47-
# logging.warning(
48-
# "No Application Insights Instrumentation Key found. Skipping configuration"
49-
# )
37+
# connection_string = os.getenv("APPLICATIONINSIGHTS_CONNECTION_STRING")
38+
# if connection_string:
39+
# # Configure Application Insights if the Instrumentation Key is found
40+
# configure_azure_monitor(connection_string=connection_string)
41+
# logging.info(
42+
# "Application Insights configured with the provided Instrumentation Key"
43+
# )
44+
# else:
45+
# # Log a warning if the Instrumentation Key is not found
46+
# logging.warning(
47+
# "No Application Insights Instrumentation Key found. Skipping configuration"
48+
# )
5049

5150
# Configure logging
5251
logging.basicConfig(level=logging.INFO)
5352

53+
5454
# Suppress INFO logs from 'azure.core.pipeline.policies.http_logging_policy'
5555
logging.getLogger("azure.core.pipeline.policies.http_logging_policy").setLevel(
5656
logging.WARNING

src/backend/kernel_agents/agent_base.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@
88
from event_utils import track_event_if_configured
99
from models.messages_kernel import (ActionRequest, ActionResponse,
1010
AgentMessage, Step, StepStatus)
11-
from semantic_kernel.agents.azure_ai.azure_ai_agent import AzureAIAgent, AzureAIAgentThread
12-
from semantic_kernel.agents.azure_ai.azure_ai_agent_settings import AzureAIAgentSettings
11+
from semantic_kernel.agents.azure_ai.azure_ai_agent import AzureAIAgent
1312
from semantic_kernel.functions import KernelFunction
1413

1514
# Default formatting instructions used across agents

src/backend/kernel_agents/agent_factory.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
from models.messages_kernel import AgentType, PlannerResponsePlan
2424
# pylint:disable=E0611
2525
from semantic_kernel.agents.azure_ai.azure_ai_agent import AzureAIAgent, AzureAIAgentThread
26-
from semantic_kernel.agents.azure_ai.azure_ai_agent_settings import AzureAIAgentSettings
26+
2727
logger = logging.getLogger(__name__)
2828

2929

@@ -265,7 +265,7 @@ async def create_all_agents(
265265
temperature=temperature,
266266
agent_instances=agent_instances, # Pass agent instances to the planner
267267
client=client,
268-
response_format = {
268+
response_format= {
269269
"type": "json_schema",
270270
"json_schema": {
271271
"name": PlannerResponsePlan.__name__,

src/backend/kernel_agents/planner_agent.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
import uuid
44
from typing import Any, Dict, List, Optional, Tuple
55

6-
from azure.ai.agents.models import (ResponseFormatJsonSchema,
7-
ResponseFormatJsonSchemaType)
86
from context.cosmos_memory_kernel import CosmosMemoryContext
97
from event_utils import track_event_if_configured
108
from kernel_agents.agent_base import BaseAgent
@@ -21,7 +19,6 @@
2119
from semantic_kernel.functions import KernelFunction
2220
from semantic_kernel.functions.kernel_arguments import KernelArguments
2321

24-
2522
class PlannerAgent(BaseAgent):
2623
"""Planner agent implementation using Semantic Kernel.
2724

0 commit comments

Comments
 (0)