harshalmore31 commited on
Commit
f0bd8c6
·
verified ·
1 Parent(s): 905f063

Synced repo using 'sync_with_huggingface' Github Action

Browse files
Files changed (1) hide show
  1. swarms/structs/ui/ui.py +0 -5
swarms/structs/ui/ui.py CHANGED
@@ -161,11 +161,6 @@ def initialize_agents(
161
  print(f"Agent created: {agent.agent_name}")
162
  agents.append(agent)
163
 
164
- # Optionally, remove the API key from os.environ (for security)
165
- if provider == "openai":
166
- del os.environ["OPENAI_API_KEY"]
167
- # Similarly, remove for other providers if desired
168
-
169
  logger.info(f"Agents initialized successfully: {[agent.agent_name for agent in agents]}")
170
  return agents
171
  except Exception as e:
 
161
  print(f"Agent created: {agent.agent_name}")
162
  agents.append(agent)
163
 
 
 
 
 
 
164
  logger.info(f"Agents initialized successfully: {[agent.agent_name for agent in agents]}")
165
  return agents
166
  except Exception as e: