idun-agent-engine 0.4.1__py3-none-any.whl → 0.4.2__py3-none-any.whl

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.
Files changed (43) hide show
  1. idun_agent_engine/_version.py +1 -1
  2. idun_agent_engine/agent/adk/adk.py +2 -2
  3. idun_agent_engine/agent/haystack/__init__.py +0 -2
  4. idun_agent_engine/agent/haystack/haystack.py +9 -5
  5. idun_agent_engine/agent/langgraph/langgraph.py +10 -13
  6. idun_agent_engine/core/config_builder.py +26 -13
  7. idun_agent_engine/guardrails/guardrails_hub/guardrails_hub.py +52 -9
  8. idun_agent_engine/mcp/__init__.py +2 -2
  9. idun_agent_engine/mcp/helpers.py +11 -15
  10. idun_agent_engine/mcp/registry.py +5 -5
  11. idun_agent_engine/observability/base.py +11 -2
  12. idun_agent_engine/observability/gcp_trace/gcp_trace_handler.py +3 -1
  13. idun_agent_engine/observability/langfuse/langfuse_handler.py +1 -3
  14. idun_agent_engine/server/dependencies.py +7 -2
  15. idun_agent_engine/server/lifespan.py +2 -7
  16. idun_agent_engine/server/routers/agent.py +2 -1
  17. idun_agent_engine/server/routers/base.py +7 -5
  18. idun_agent_engine/telemetry/__init__.py +0 -1
  19. idun_agent_engine/telemetry/config.py +0 -1
  20. idun_agent_engine/telemetry/telemetry.py +3 -4
  21. idun_agent_engine/templates/correction.py +4 -7
  22. idun_agent_engine/templates/deep_research.py +1 -0
  23. idun_agent_engine/templates/translation.py +4 -4
  24. {idun_agent_engine-0.4.1.dist-info → idun_agent_engine-0.4.2.dist-info}/METADATA +1 -1
  25. {idun_agent_engine-0.4.1.dist-info → idun_agent_engine-0.4.2.dist-info}/RECORD +40 -43
  26. idun_platform_cli/groups/agent/package.py +1 -1
  27. idun_platform_cli/telemetry.py +2 -1
  28. idun_platform_cli/tui/schemas/create_agent.py +8 -4
  29. idun_platform_cli/tui/screens/create_agent.py +38 -12
  30. idun_platform_cli/tui/utils/config.py +1 -1
  31. idun_platform_cli/tui/validators/guardrails.py +8 -6
  32. idun_platform_cli/tui/validators/mcps.py +9 -6
  33. idun_platform_cli/tui/widgets/chat_widget.py +3 -1
  34. idun_platform_cli/tui/widgets/guardrails_widget.py +4 -4
  35. idun_platform_cli/tui/widgets/mcps_widget.py +112 -24
  36. idun_platform_cli/tui/widgets/memory_widget.py +0 -1
  37. idun_platform_cli/tui/widgets/observability_widget.py +2 -2
  38. idun_platform_cli/tui/widgets/serve_widget.py +2 -3
  39. idun_agent_engine/agent/haystack/haystack_model.py +0 -13
  40. idun_agent_engine/guardrails/guardrails_hub/utils.py +0 -1
  41. idun_agent_engine/server/routers/agui.py +0 -47
  42. {idun_agent_engine-0.4.1.dist-info → idun_agent_engine-0.4.2.dist-info}/WHEEL +0 -0
  43. {idun_agent_engine-0.4.1.dist-info → idun_agent_engine-0.4.2.dist-info}/entry_points.txt +0 -0
@@ -113,7 +113,6 @@ def _get_or_create_distinct_id() -> str | None:
113
113
  - `IDUN_TELEMETRY_DISTINCT_ID` (if set)
114
114
  - A UUID persisted to `<cache_dir>/idun/telemetry_user_id`
115
115
  """
116
-
117
116
  raw = os.environ.get(_DISTINCT_ID_ENV)
118
117
  if raw and raw.strip():
119
118
  return raw.strip()
@@ -183,9 +182,10 @@ class IdunTelemetry:
183
182
  self._distinct_id = _get_or_create_distinct_id()
184
183
  return self._client
185
184
 
186
- def capture(self, event: str, properties: dict[str, Any] | None = None) -> Future[None] | None:
185
+ def capture(
186
+ self, event: str, properties: dict[str, Any] | None = None
187
+ ) -> Future[None] | None:
187
188
  """Capture an event asynchronously (best-effort)."""
188
-
189
189
  if not self.enabled:
190
190
  return None
191
191
 
@@ -220,7 +220,6 @@ class IdunTelemetry:
220
220
 
221
221
  def shutdown(self, timeout_seconds: float = 1.0) -> None:
222
222
  """Best-effort flush/shutdown without blocking application shutdown."""
223
-
224
223
  executor = self._executor
225
224
  client = self._client
226
225
 
@@ -1,7 +1,7 @@
1
1
  """Correction Agent Template."""
2
2
 
3
3
  import os
4
- from typing import TypedDict, Annotated, List, Any
4
+ from typing import Annotated, Any, TypedDict
5
5
 
6
6
  try:
7
7
  from langchain.chat_models import init_chat_model
@@ -11,13 +11,13 @@ except ImportError:
11
11
  except ImportError:
12
12
  init_chat_model = None
13
13
 
14
- from langchain_core.messages import SystemMessage, BaseMessage
15
- from langgraph.graph import StateGraph, START, END
14
+ from langchain_core.messages import BaseMessage, SystemMessage
15
+ from langgraph.graph import END, START, StateGraph
16
16
  from langgraph.graph.message import add_messages
17
17
 
18
18
 
19
19
  class State(TypedDict):
20
- messages: Annotated[List[BaseMessage], add_messages]
20
+ messages: Annotated[list[BaseMessage], add_messages]
21
21
 
22
22
 
23
23
  MODEL_NAME = os.getenv("CORRECTION_MODEL", "gemini-2.5-flash")
@@ -33,18 +33,15 @@ else:
33
33
  print("Warning: init_chat_model not found in langchain.")
34
34
 
35
35
 
36
-
37
36
  async def correct_text(state: State):
38
37
  """Correct the spelling, syntax, and grammar of the text."""
39
38
  if not llm:
40
-
41
39
  return {
42
40
  "messages": [
43
41
  SystemMessage(content="Error: Model not initialized. Check logs.")
44
42
  ]
45
43
  }
46
44
 
47
-
48
45
  prompt = (
49
46
  f"You are a professional text corrector for {LANGUAGE}. "
50
47
  f"Correct the spelling, syntax, grammar, and conjugation of the following text. "
@@ -1,6 +1,7 @@
1
1
  """Deep Research Agent Template."""
2
2
 
3
3
  import os
4
+
4
5
  from deepagents import create_deep_agent
5
6
  from tavily import TavilyClient
6
7
 
@@ -1,7 +1,7 @@
1
1
  """Translation Agent Template."""
2
2
 
3
3
  import os
4
- from typing import TypedDict, Annotated, List
4
+ from typing import Annotated, TypedDict
5
5
 
6
6
  # Try importing init_chat_model, fallback if necessary
7
7
  try:
@@ -12,14 +12,14 @@ except ImportError:
12
12
  except ImportError:
13
13
  init_chat_model = None
14
14
 
15
- from langchain_core.messages import SystemMessage, BaseMessage
16
- from langgraph.graph import StateGraph, START, END
15
+ from langchain_core.messages import BaseMessage, SystemMessage
16
+ from langgraph.graph import END, START, StateGraph
17
17
  from langgraph.graph.message import add_messages
18
18
 
19
19
 
20
20
  # Define the state
21
21
  class State(TypedDict):
22
- messages: Annotated[List[BaseMessage], add_messages]
22
+ messages: Annotated[list[BaseMessage], add_messages]
23
23
 
24
24
 
25
25
  # Read configuration from environment variables
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: idun-agent-engine
3
- Version: 0.4.1
3
+ Version: 0.4.2
4
4
  Summary: Python SDK and runtime to serve AI agents with FastAPI, LangGraph, and observability.
5
5
  Project-URL: Homepage, https://github.com/geoffreyharrazi/idun-agent-platform
6
6
  Project-URL: Repository, https://github.com/geoffreyharrazi/idun-agent-platform
@@ -1,64 +1,61 @@
1
1
  idun_agent_engine/__init__.py,sha256=PhOL6foq5V0eXaoXw7xKUeCWXIWrOHrAFB8OuJnBqyM,550
2
- idun_agent_engine/_version.py,sha256=46Sg_0NATQ79huYXlK2uZI6BAN4q9gzxYyxZAuU0Bh0,72
2
+ idun_agent_engine/_version.py,sha256=rHg5d6fgwIvzBZWjYtyruzXJK6jO7QljvyRBzdBlBBU,72
3
3
  idun_agent_engine/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
4
  idun_agent_engine/agent/__init__.py,sha256=foyOoRdI_04q1b6f2A5EXEpWSCKjZxpgWMWrKcsHNl8,220
5
5
  idun_agent_engine/agent/base.py,sha256=c-3gljSHQpm6aY0JNDmXkaPtcW55rXdsI8Cgv9l4bCs,3294
6
6
  idun_agent_engine/agent/adk/__init__.py,sha256=jLV2Z9qQGZtBpF_0pQI1FRCPJ_J1G3Z6cEAzHnQyuu4,83
7
- idun_agent_engine/agent/adk/adk.py,sha256=0lfubR5ylfmfuSTOryULxnlJS3gAxpP3xtRaDypGqvE,11415
8
- idun_agent_engine/agent/haystack/__init__.py,sha256=y5ADrD8gWBeYIvV7tmu6OpPdJ8POHt-tyraIL7RkkWI,179
9
- idun_agent_engine/agent/haystack/haystack.py,sha256=k4NAx_zTBO9uiExM9NtuDAN94H1lrCWtHf1GEWEN16g,10966
10
- idun_agent_engine/agent/haystack/haystack_model.py,sha256=EtOYnsWRufcrQufTRMeB3V-rZVQqfnmwKwPsYGfZdCs,362
7
+ idun_agent_engine/agent/adk/adk.py,sha256=hljK87MJ5pfQWudbPhN4OpZxHXOXbZGLQA3mKaJ6dx4,11415
8
+ idun_agent_engine/agent/haystack/__init__.py,sha256=mfYFciVPKRXBxPhnpIy5qPJ8mUSyywUAxiFXFPTzEV4,104
9
+ idun_agent_engine/agent/haystack/haystack.py,sha256=nh86oGy7Q2mBbNdbvMfSYrtKLnNdXCI53S3SnzYp-J4,11039
11
10
  idun_agent_engine/agent/haystack/utils.py,sha256=sKRoPhzZWFw1NPsYwCockafzMBCCq3lGOrndbNE_C3M,609
12
11
  idun_agent_engine/agent/langgraph/__init__.py,sha256=CoBdkp9P4livdy5B0bvj9o7ftoqKmXEr9cZv4TZLncs,107
13
- idun_agent_engine/agent/langgraph/langgraph.py,sha256=cbVrUs74a0p6omypMHWO3-1uqGLtJdiyAMrCheQHF5w,22966
12
+ idun_agent_engine/agent/langgraph/langgraph.py,sha256=s8mSm6exo69KBPIhCinRotS8v4DyMGQLG1nFL65rUbA,22871
14
13
  idun_agent_engine/core/__init__.py,sha256=F0DMDlWcSWS_1dvh3xMbrdcVvZRHVnoAFFgREuSJfBI,408
15
14
  idun_agent_engine/core/app_factory.py,sha256=2w4o7wV8FQCZdBTk3W7cS0vnmpUM_TdAmphFKHbL31w,2597
16
- idun_agent_engine/core/config_builder.py,sha256=MosVcPjn7qXUAlmaYvnPquJ0jZ55pDOLfLv0i-D-A28,26049
15
+ idun_agent_engine/core/config_builder.py,sha256=5wbFNKLomw7aWEnfZ6iyljTwpFO_rdgw4c3CUzwLsW4,26221
17
16
  idun_agent_engine/core/engine_config.py,sha256=IR8WhbenDstNSL7ORrUW8AnzgS3exFQxtwip66pFhcM,545
18
17
  idun_agent_engine/core/server_runner.py,sha256=DwN5kHiKVvUJLw5iSkaxs2rKRaMgOwSUZmeUPSuDbf8,4899
19
18
  idun_agent_engine/guardrails/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
20
19
  idun_agent_engine/guardrails/base.py,sha256=rvi7gcuKK8-3GtGicWzMWYsKKv0g3LjGBI-FycxgKVU,814
21
20
  idun_agent_engine/guardrails/guardrails_hub/__init__.py,sha256=MwWdgrM1dNzKwuS9ZEFw5Cin91JXh2PYlMma8yZFO7o,123
22
- idun_agent_engine/guardrails/guardrails_hub/guardrails_hub.py,sha256=DgcUIDy9_bcVcpYVvDJowFe_QVlCpEkr8hntPRgRmS0,3456
23
- idun_agent_engine/guardrails/guardrails_hub/utils.py,sha256=bC6-MsCVF7xKTr48z7OzJJUeWvqAB7BiHeNTiKsme70,20
24
- idun_agent_engine/mcp/__init__.py,sha256=ygChpEQ4MzMpEifW3szi5kNiLIMhOhJEtqxy0nmewDU,501
25
- idun_agent_engine/mcp/helpers.py,sha256=b345RHXgeZ15a4gfg8sUJ3Ke7Iwke6FR1RqDRfRUB0c,6589
26
- idun_agent_engine/mcp/registry.py,sha256=8zt9o8MZmYKx55xb0E7n-qOCR_3m2-XGf7ToQEwHkTU,4229
21
+ idun_agent_engine/guardrails/guardrails_hub/guardrails_hub.py,sha256=3H3_1XLXfOB_hrv9cti6aX5CPUNBrV9eQPLwjGx8YN4,4918
22
+ idun_agent_engine/mcp/__init__.py,sha256=PsBUpfFvvgzJhCFeIH8215VrHiHLnBCrP4jfHGw1gmQ,501
23
+ idun_agent_engine/mcp/helpers.py,sha256=NMieZ6FSOaEpxeBLwUWvr-NYje1_AM3_h9LK7Sym6dk,6561
24
+ idun_agent_engine/mcp/registry.py,sha256=ncur1Zp_2bSZBdJRTI8wIq2Lt-fP0oyPHPJH4RnEaKs,4241
27
25
  idun_agent_engine/observability/__init__.py,sha256=DCtK6b3xiX4dh0_8GBDOcSXQdcIJz2wTqqPa_ZFAES4,430
28
- idun_agent_engine/observability/base.py,sha256=C6mY_ZafDEHkMz8_ZeaEh--pyYuzJYEUqhoJ0sVP2wY,5570
26
+ idun_agent_engine/observability/base.py,sha256=Hst5dAxoJwPpiKw9p3MH79-AVZSNTciZ0hlq8K0rSFg,5686
29
27
  idun_agent_engine/observability/gcp_logging/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
30
28
  idun_agent_engine/observability/gcp_logging/gcp_logging_handler.py,sha256=cMUKfukmSZhIdO2v5oWkqI2_c6umtYqlhzflnOeoq6A,1685
31
29
  idun_agent_engine/observability/gcp_trace/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
32
- idun_agent_engine/observability/gcp_trace/gcp_trace_handler.py,sha256=YBlUqUwPuOPi0yDNEy9x_g52nJBlSe9a0EEHDIHIr68,3898
30
+ idun_agent_engine/observability/gcp_trace/gcp_trace_handler.py,sha256=WMg8u161P-rIS1k8jZiNcRyxvxNE7MwEkktKqcOFWHQ,3920
33
31
  idun_agent_engine/observability/langfuse/__init__.py,sha256=J8XcHV4aT1pF97k5EZiqrnYYPs9VjwfV5rUMihc5Pgk,128
34
- idun_agent_engine/observability/langfuse/langfuse_handler.py,sha256=RP9MXiYDRe7zWTmZmzQBn6AjRn0y8jrBnWOaUUaMxNA,2795
32
+ idun_agent_engine/observability/langfuse/langfuse_handler.py,sha256=c9Rzu7SCiyWOPVDimqwMY1Swvp57rKf-RePtHs-zhkw,2765
35
33
  idun_agent_engine/observability/phoenix/__init__.py,sha256=tEwJYijcvSGNhFW4QJmvBcTu1D0YVJkZRTmkNCGTteM,130
36
34
  idun_agent_engine/observability/phoenix/phoenix_handler.py,sha256=lGqSq-L1vmoEhAr9rbWO3KlNX5HSgBhCKESHMdZ-AfY,2539
37
35
  idun_agent_engine/observability/phoenix_local/__init__.py,sha256=m9dIw1GWGKAW4wP08jxA7j4yrOg0Nxq_08bwVh8YogE,146
38
36
  idun_agent_engine/observability/phoenix_local/phoenix_local_handler.py,sha256=wjOZuMpAxdD5D33rzxycNEzFMunETpPnYjiHjbjz5GA,4252
39
37
  idun_agent_engine/server/__init__.py,sha256=WaFektUsy37bNg2niAUy_TykzStukgWPnxC-t49CEwo,177
40
- idun_agent_engine/server/dependencies.py,sha256=MVH8STOQ8wu-iYE_28y5dvw5FGT5PX0uQl0ldkpxw6Y,2080
41
- idun_agent_engine/server/lifespan.py,sha256=pTPZ36R4jlx1jq249kpj4DEe-opIGYiRNUHncKlnuGs,4670
38
+ idun_agent_engine/server/dependencies.py,sha256=hRviN2YEf8tvTek2F7IUIp-JH7_V-ru-HKbCqLAox2o,2117
39
+ idun_agent_engine/server/lifespan.py,sha256=oXPDmCjNxCIQdrcZ_Q7bDx6mtndpLRI7VNeKEDIuQNw,4619
42
40
  idun_agent_engine/server/server_config.py,sha256=RYA7Y0c5aRw_WXaX8svFUIEtTPqzn3o-WQRm2p52C6g,213
43
41
  idun_agent_engine/server/routers/__init__.py,sha256=BgNzSVvHtGPGn5zhXhomwpKlDYBkeFi7xCbdcWVOgc8,102
44
- idun_agent_engine/server/routers/agent.py,sha256=qLaVRKgMIu-YfOi-tPEzLNRZKZ4DaZEQ8KQ-4HrWbbY,9194
45
- idun_agent_engine/server/routers/agui.py,sha256=Z1G4fuo57MazQWfp7ao8QZ1or2H9BXLS_JB1nFPXAkE,1891
46
- idun_agent_engine/server/routers/base.py,sha256=wICOXCokCIRjmHuDPDTWqeXqOVPes1CtDtiR_HvtsF0,3756
47
- idun_agent_engine/telemetry/__init__.py,sha256=oYmmgUYvuwM-eV1qBeTgy6HoG6H3LC_S4fMH04QiMWY,519
48
- idun_agent_engine/telemetry/config.py,sha256=APSmZWocwSqB1xSxoZkJrSTZnWlBiQdif4whdXi8uBE,845
49
- idun_agent_engine/telemetry/telemetry.py,sha256=g14ouZnSIV85A58HeAH5IlJ_IDKO_uYo7kFbWRo5PpI,7319
42
+ idun_agent_engine/server/routers/agent.py,sha256=QDqlR8P19ghLQrIFSd2w-c7iODXAv_P6bQ2AIYCWd7A,9182
43
+ idun_agent_engine/server/routers/base.py,sha256=5kZtPE0QAUZGlvsry2ygzz95IqdjvE2cFqGepD9TA6I,3763
44
+ idun_agent_engine/telemetry/__init__.py,sha256=jeKw2GMqqwoSh1sOxljVmVgP2BHObFYnZeNIF2NPwD8,518
45
+ idun_agent_engine/telemetry/config.py,sha256=JJhw3hysT_0HdbdyuOevD9WeEo4Eu4x0Y3sH5NWZvEY,844
46
+ idun_agent_engine/telemetry/telemetry.py,sha256=yOEExjFwhxvj5J6QW9cMeqFk6J6S0b1XlEb2Kni195o,7330
50
47
  idun_agent_engine/templates/__init__.py,sha256=xxbJZXaX6VEm_UrqzAOQcuujpEji5yqYzwQfwiqig8o,31
51
- idun_agent_engine/templates/correction.py,sha256=qApH4W99K31maxNrGf0hPVe_Wd4xjYjJrEKlu7PbRpw,1823
52
- idun_agent_engine/templates/deep_research.py,sha256=j4WypBkBz7V3EG-U8vawfNXDNhcCf2QiEK0veI4M68s,1077
53
- idun_agent_engine/templates/translation.py,sha256=vjp1yEyhDMFO4nEbq5WG7LAA7nLrhVAjznOkV7ob_Ss,2149
48
+ idun_agent_engine/templates/correction.py,sha256=_NdgXLENpUhjT81CQI-gzH_yhGwbxSmBAo_VRFmBgQ0,1814
49
+ idun_agent_engine/templates/deep_research.py,sha256=x9BJucpkHzocxmCQ3--HrxjU8A1-StwL-2SVPcslTTI,1078
50
+ idun_agent_engine/templates/translation.py,sha256=bUEhhJuCpoON7PPi0yGE6f3SlZgXhN9WNwj1F9IyN9o,2143
54
51
  idun_platform_cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
55
52
  idun_platform_cli/main.py,sha256=B7b1x0kgfuiAWGmSCFJeu_zkWiodJjOGu0nWuNAWM-k,299
56
- idun_platform_cli/telemetry.py,sha256=mLTO8717ckmglm_oSl1xFxomk-eqwqrCU9Nl1uq27Dg,1711
53
+ idun_platform_cli/telemetry.py,sha256=pSjnOXMbT2LuvNVPNCvBdYXRQG4EJbfrfiiC20NSIqk,1738
57
54
  idun_platform_cli/groups/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
58
55
  idun_platform_cli/groups/init.py,sha256=gBWU7tQ0v9aaPNSQXorKWrOkUc5YgJU06pzDC-qG97U,769
59
56
  idun_platform_cli/groups/agent/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
60
57
  idun_platform_cli/groups/agent/main.py,sha256=QMGQi3JZ76SeFI3miIjVWpMt0L-hGz5FwxtTPQX4-Uw,301
61
- idun_platform_cli/groups/agent/package.py,sha256=JeoQBZ_egkeKhQhB-FuGGrY1T1VG4f4ixuhjt0mDygE,2615
58
+ idun_platform_cli/groups/agent/package.py,sha256=DjCUSEbPLnHbYkxpkumLb7jZytMWr5WuPDxgLCTcy-8,2614
62
59
  idun_platform_cli/groups/agent/serve.py,sha256=ujCmJ3JsrjHkXvNwyB7V4poAaTxMQAPcIbRPDVybRQo,3947
63
60
  idun_platform_cli/tui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
64
61
  idun_platform_cli/tui/main.py,sha256=1gFEdbynBfiBLrZrKvNJN16Uc_3DOJl1spexRz38Q-E,3080
@@ -66,24 +63,24 @@ idun_platform_cli/tui/css/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJW
66
63
  idun_platform_cli/tui/css/create_agent.py,sha256=ZyFNv6-EUTUaJ_817wh0KUvdu8rtuuPj9jTbigLfOR8,14050
67
64
  idun_platform_cli/tui/css/main.py,sha256=gJ_kNb2lC2l99lq8NqtYU2imXAjUpxfiOaf1mNJr-Po,1134
68
65
  idun_platform_cli/tui/schemas/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
69
- idun_platform_cli/tui/schemas/create_agent.py,sha256=2jsZ5v1sZLKmypgimdVoeVjd-wOylTE3IUYPw63eb8Y,1512
66
+ idun_platform_cli/tui/schemas/create_agent.py,sha256=7aXTyf8boBr5xyLAf1O8rXsPca5LUqHz1GqKhOYwPsY,1714
70
67
  idun_platform_cli/tui/screens/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
71
- idun_platform_cli/tui/screens/create_agent.py,sha256=3Yav2gvJhh0el4BTLuYzYELrHWuKDBnNnNHlRIBUEJE,23881
68
+ idun_platform_cli/tui/screens/create_agent.py,sha256=0j-euLfosun7syXAjZYuoexoXmIzmlnZjNiKcoMWKvc,24473
72
69
  idun_platform_cli/tui/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
73
- idun_platform_cli/tui/utils/config.py,sha256=AEgjgnNkCtQwuGxI8lclteunKZXvn_TMx0eBx7uJWto,7286
70
+ idun_platform_cli/tui/utils/config.py,sha256=SIDJUfE7vzI3xGXnVPeD7CeTA1Bi6xtQStLvjDMwn50,7281
74
71
  idun_platform_cli/tui/validators/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
75
- idun_platform_cli/tui/validators/guardrails.py,sha256=l6TJKxjpr8Nktwndh6C7Juz4oY-bqpg295jtYTKHuQ8,3537
76
- idun_platform_cli/tui/validators/mcps.py,sha256=oDxbxt7qOzsW8yjd_fwBnlDPOSxPqCXqbF5q8eEYRVQ,2852
72
+ idun_platform_cli/tui/validators/guardrails.py,sha256=E4KEVD0KV4gG9ZdlA591HA0seYY2xEDB3HeVPAxbH5E,3585
73
+ idun_platform_cli/tui/validators/mcps.py,sha256=r_YOxIWLPXVDXN9lwO1UvhvbTns7WrwmunO1zydttu4,2883
77
74
  idun_platform_cli/tui/validators/observability.py,sha256=IWNuJg42eZUxjV-7v12kms7DpJsAs3FSSD5zLU5eKUc,2436
78
75
  idun_platform_cli/tui/widgets/__init__.py,sha256=w8rQsUxqTtxuhpOPxCgl1pmv2vjCJseKNc1lhfMMkBM,521
79
- idun_platform_cli/tui/widgets/chat_widget.py,sha256=8RCAY97asVxyy7VV7IJ4kEAX9edK46UGO90BJ0X4BL0,5731
80
- idun_platform_cli/tui/widgets/guardrails_widget.py,sha256=3EDrfTKXyN7N8qMuWVy-BjK6ia3CZIE0EVm1sh6FhMw,14552
76
+ idun_platform_cli/tui/widgets/chat_widget.py,sha256=hPWZSX2kwSGwFxWWW1TQ-HOvOa5Y3BjCJnj5WgOrVqY,5753
77
+ idun_platform_cli/tui/widgets/guardrails_widget.py,sha256=EzrZEaAyx7ViW7Vk-QLyu235b1jqauCoyvM9i3qsuGY,14553
81
78
  idun_platform_cli/tui/widgets/identity_widget.py,sha256=LjpX-mgIinxJ5FzKBFz1HYbImwX7khpbetl86LsPnfw,9508
82
- idun_platform_cli/tui/widgets/mcps_widget.py,sha256=5AToZHU5PAUJEuq0HhL4Mi_VmWlFLyTeY5pohWY3rKw,10974
83
- idun_platform_cli/tui/widgets/memory_widget.py,sha256=QHCH0et_lJa9pheTpcZdbzTDUzw95Do2koi6hEdmrOc,6996
84
- idun_platform_cli/tui/widgets/observability_widget.py,sha256=9AO7-nqMEIx_9FCmqbtprxoBejq4w8bR9wOhxl2BbmA,14915
85
- idun_platform_cli/tui/widgets/serve_widget.py,sha256=0FinYhkyA0LJnX1g4JDrkcD5df-l-qgMxjRjgF0CleQ,2749
86
- idun_agent_engine-0.4.1.dist-info/METADATA,sha256=xGS6C3n58AGB9WezKja-6Oy2EigEcuO3v8M6JKnZFu0,10870
87
- idun_agent_engine-0.4.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
88
- idun_agent_engine-0.4.1.dist-info/entry_points.txt,sha256=XG3oxlSOaCrYKT1oyhKa0Ag1iJPMZ-WF6gaV_mzIJW4,52
89
- idun_agent_engine-0.4.1.dist-info/RECORD,,
79
+ idun_platform_cli/tui/widgets/mcps_widget.py,sha256=fXZzGbK7I4_yDFolvI3UbsR5yeKmW-sNz8STGKYk0E8,12125
80
+ idun_platform_cli/tui/widgets/memory_widget.py,sha256=QCJF6bd21s-QWdQY-UqqPtWZSIl-9xil6ul-a2r6vL0,6966
81
+ idun_platform_cli/tui/widgets/observability_widget.py,sha256=9ioS_BwOkW6NPtzJJa-S-mNUDOqP3QYYgTePcAun18s,14915
82
+ idun_platform_cli/tui/widgets/serve_widget.py,sha256=fSr75DuOxiXr0KbbEDAl0t5iOlDqMQLRiHdMCrENZdI,2728
83
+ idun_agent_engine-0.4.2.dist-info/METADATA,sha256=HrghAw_locsILEAp1BDj6D5SIq8xfFslUv6NndiLzx8,10870
84
+ idun_agent_engine-0.4.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
85
+ idun_agent_engine-0.4.2.dist-info/entry_points.txt,sha256=XG3oxlSOaCrYKT1oyhKa0Ag1iJPMZ-WF6gaV_mzIJW4,52
86
+ idun_agent_engine-0.4.2.dist-info/RECORD,,
@@ -38,7 +38,7 @@ def generate_dockerfile(dependency: Dependency) -> str:
38
38
  return "" # Unreachable, but satisfies type checker
39
39
  if dependency == Dependency.REQUIREMENT:
40
40
  # TODO: use from file
41
- requirements_dockerfile = f"""FROM python:3.12-slim
41
+ requirements_dockerfile = """FROM python:3.12-slim
42
42
  RUN apt-get update && pip install uv
43
43
 
44
44
  RUN uv pip install idun-agent-schema==0.3.1 --system
@@ -4,7 +4,8 @@ from __future__ import annotations
4
4
 
5
5
  import functools
6
6
  import time
7
- from typing import Any, Callable, TypeVar
7
+ from collections.abc import Callable
8
+ from typing import Any, TypeVar
8
9
 
9
10
  from idun_agent_engine.telemetry import get_telemetry, sanitize_telemetry_config
10
11
 
@@ -21,7 +21,7 @@ agent:
21
21
  # we need to map the graph_definition, pipeline_definition, agent_definition fields based on framework
22
22
  AGENT_SOURCE_KEY_MAPPING: dict[str, str] = dict(
23
23
  {
24
- "HAYSTACK": "pipeline_definition",
24
+ "HAYSTACK": "component_definition",
25
25
  "LANGGRAPH": "graph_definition",
26
26
  "ADK": "agent",
27
27
  }
@@ -35,21 +35,25 @@ class TUIAgentConfig(BaseModel):
35
35
  graph_definition: str
36
36
 
37
37
  @field_validator("*", mode="after")
38
- def validate_not_null(cls, value: str | Any | None) -> str:
38
+ def validate_not_null(cls, value: str | Any | None) -> str: # noqa: N805
39
39
  if value is None or value == "":
40
40
  raise ValueError("Cannot have empty fields!")
41
41
  return value
42
42
 
43
43
  def to_engine_config(self) -> dict[str, Any]:
44
+ sanitized_name = self.name.replace("-", "_").replace(" ", "_")
45
+
44
46
  agent_config = {
45
- "name": self.name,
47
+ "name": sanitized_name if self.framework == "ADK" else self.name,
46
48
  AGENT_SOURCE_KEY_MAPPING[self.framework]: self.graph_definition,
47
49
  }
48
50
 
49
51
  if self.framework == "ADK":
50
- agent_config["app_name"] = self.name.replace("-", "_").replace(" ", "_")
52
+ agent_config["app_name"] = sanitized_name
51
53
  agent_config["session_service"] = {"type": "in_memory"}
52
54
  agent_config["memory_service"] = {"type": "in_memory"}
55
+ elif self.framework == "HAYSTACK":
56
+ agent_config["component_type"] = "pipeline"
53
57
 
54
58
  return {
55
59
  "server": {"api": {"port": self.port}},
@@ -7,7 +7,7 @@ from textual.app import ComposeResult
7
7
  from textual.containers import Container, Horizontal, Vertical
8
8
  from textual.reactive import reactive
9
9
  from textual.screen import Screen
10
- from textual.widgets import Button, Footer, Label, RichLog, Static
10
+ from textual.widgets import Button, Label, RichLog, Static
11
11
 
12
12
  from idun_platform_cli.tui.css.create_agent import CREATE_AGENT_CSS
13
13
  from idun_platform_cli.tui.schemas.create_agent import TUIAgentConfig
@@ -71,7 +71,11 @@ class CreateAgentScreen(Screen):
71
71
  config = self.config_manager.load_config()
72
72
  if config:
73
73
  port = config.get("server", {}).get("api", {}).get("port", 8008)
74
- pids = subprocess.check_output(["lsof", "-ti", f":{port}"], text=True).strip().split("\n")
74
+ pids = (
75
+ subprocess.check_output(["lsof", "-ti", f":{port}"], text=True)
76
+ .strip()
77
+ .split("\n")
78
+ )
75
79
  for pid in pids:
76
80
  if pid:
77
81
  try:
@@ -254,7 +258,10 @@ class CreateAgentScreen(Screen):
254
258
  yield serve
255
259
  yield chat
256
260
 
257
- footer = Static("💡 Press Next to save section | Press Ctrl+Q to exit", classes="custom-footer")
261
+ footer = Static(
262
+ "💡 Press Next to save section | Press Ctrl+Q to exit",
263
+ classes="custom-footer",
264
+ )
258
265
  yield footer
259
266
 
260
267
  def on_mount(self) -> None:
@@ -395,9 +402,7 @@ class CreateAgentScreen(Screen):
395
402
  if data is not None:
396
403
  success, msg = self.config_manager.save_partial("memory", data)
397
404
  if not success:
398
- self.notify(
399
- "Memory configuration is invalid", severity="error"
400
- )
405
+ self.notify("Memory configuration is invalid", severity="error")
401
406
  return
402
407
  self.validated_sections.add("memory")
403
408
  self._update_nav_checkmark("memory")
@@ -447,14 +452,20 @@ class CreateAgentScreen(Screen):
447
452
 
448
453
  validated_servers, msg = validate_mcp_servers(data)
449
454
  if validated_servers is None:
450
- self.notify("Error validating MCPs: make sure all fields are correct.", severity="error")
455
+ self.notify(
456
+ "Error validating MCPs: make sure all fields are correct.",
457
+ severity="error",
458
+ )
451
459
  return
452
460
 
453
461
  success, save_msg = self.config_manager.save_partial(
454
462
  "mcp_servers", validated_servers
455
463
  )
456
464
  if not success:
457
- self.notify("Error saving MCPs: make sure all fields are correct.", severity="error")
465
+ self.notify(
466
+ "Error saving MCPs: make sure all fields are correct.",
467
+ severity="error",
468
+ )
458
469
  return
459
470
 
460
471
  self.validated_sections.add("mcps")
@@ -510,9 +521,15 @@ class CreateAgentScreen(Screen):
510
521
  ["lsof", "-ti", f":{port}"],
511
522
  capture_output=True,
512
523
  text=True,
513
- check=True
524
+ check=True,
525
+ )
526
+ pids = (
527
+ subprocess.check_output(
528
+ ["lsof", "-ti", f":{port}"], text=True
529
+ )
530
+ .strip()
531
+ .split("\n")
514
532
  )
515
- pids = subprocess.check_output(["lsof", "-ti", f":{port}"], text=True).strip().split("\n")
516
533
  for pid in pids:
517
534
  if pid:
518
535
  try:
@@ -563,7 +580,13 @@ class CreateAgentScreen(Screen):
563
580
 
564
581
  try:
565
582
  process = subprocess.Popen(
566
- ["idun", "agent", "serve", "--source=file", f"--path={config_path}"],
583
+ [
584
+ "idun",
585
+ "agent",
586
+ "serve",
587
+ "--source=file",
588
+ f"--path={config_path}",
589
+ ],
567
590
  stdout=subprocess.PIPE,
568
591
  stderr=subprocess.STDOUT,
569
592
  text=True,
@@ -585,7 +608,10 @@ class CreateAgentScreen(Screen):
585
608
  self.run_worker(self._stream_logs(process), exclusive=True)
586
609
 
587
610
  except Exception:
588
- self.notify("Failed to start server. Check your configuration.", severity="error")
611
+ self.notify(
612
+ "Failed to start server. Check your configuration.",
613
+ severity="error",
614
+ )
589
615
 
590
616
  async def _stream_logs(self, process) -> None:
591
617
  import asyncio
@@ -178,5 +178,5 @@ class ConfigManager:
178
178
  with self.agent_path.open("r") as f:
179
179
  return yaml.safe_load(f) or {}
180
180
 
181
- except Exception as e:
181
+ except Exception:
182
182
  return {}
@@ -1,12 +1,12 @@
1
1
  """Guardrails validation logic."""
2
2
 
3
3
  from idun_agent_schema.engine.guardrails_v2 import (
4
- GuardrailConfigId,
4
+ BanListConfig,
5
5
  BiasCheckConfig,
6
- ToxicLanguageConfig,
7
6
  CompetitionCheckConfig,
8
- BanListConfig,
9
7
  DetectPIIConfig,
8
+ GuardrailConfigId,
9
+ ToxicLanguageConfig,
10
10
  )
11
11
 
12
12
 
@@ -19,7 +19,7 @@ def validate_guardrail(guardrail_id: str, config: dict) -> tuple[any, str]:
19
19
  config_id=GuardrailConfigId.BIAS_CHECK,
20
20
  api_key=config.get("api_key", ""),
21
21
  reject_message=config.get("reject_message", "Bias detected"),
22
- threshold=threshold
22
+ threshold=threshold,
23
23
  )
24
24
  return validated, "ok"
25
25
 
@@ -28,8 +28,10 @@ def validate_guardrail(guardrail_id: str, config: dict) -> tuple[any, str]:
28
28
  validated = ToxicLanguageConfig(
29
29
  config_id=GuardrailConfigId.TOXIC_LANGUAGE,
30
30
  api_key=config.get("api_key", ""),
31
- reject_message=config.get("reject_message", "Toxic language detected"),
32
- threshold=threshold
31
+ reject_message=config.get(
32
+ "reject_message", "Toxic language detected"
33
+ ),
34
+ threshold=threshold,
33
35
  )
34
36
  return validated, "ok"
35
37
 
@@ -30,12 +30,15 @@ def validate_mcp_servers(
30
30
  None,
31
31
  f"Server '{name}': command is required for stdio transport",
32
32
  )
33
- elif transport in ["sse", "streamable_http", "websocket"]:
34
- if not server_data.get("url"):
35
- return (
36
- None,
37
- f"Server '{name}': url is required for {transport} transport",
38
- )
33
+ elif transport in [
34
+ "sse",
35
+ "streamable_http",
36
+ "websocket",
37
+ ] and not server_data.get("url"):
38
+ return (
39
+ None,
40
+ f"Server '{name}': url is required for {transport} transport",
41
+ )
39
42
 
40
43
  args = server_data.get("args", [])
41
44
  if isinstance(args, str):
@@ -22,7 +22,9 @@ class ChatWidget(Widget):
22
22
  with chat_container:
23
23
  yield RichLog(id="chat_history", highlight=True, markup=True, wrap=True)
24
24
 
25
- thinking_container = Horizontal(classes="chat-thinking-container", id="chat_thinking")
25
+ thinking_container = Horizontal(
26
+ classes="chat-thinking-container", id="chat_thinking"
27
+ )
26
28
  thinking_container.display = False
27
29
  with thinking_container:
28
30
  yield LoadingIndicator(id="chat_spinner")
@@ -1,11 +1,11 @@
1
1
  """Guardrails configuration widget."""
2
2
 
3
+ from idun_agent_schema.engine.guardrails_v2 import GuardrailsV2
3
4
  from textual.app import ComposeResult
4
- from textual.containers import Horizontal, Vertical, Grid
5
- from textual.widgets import Static, Input, Switch, RadioSet, RadioButton, TextArea
5
+ from textual.containers import Grid, Horizontal, Vertical
6
6
  from textual.widget import Widget
7
+ from textual.widgets import Input, RadioButton, RadioSet, Static, Switch, TextArea
7
8
 
8
- from idun_agent_schema.engine.guardrails_v2 import GuardrailsV2
9
9
  from idun_platform_cli.tui.validators.guardrails import validate_guardrail
10
10
 
11
11
 
@@ -310,7 +310,7 @@ class GuardrailsWidget(Widget):
310
310
  self.app.notify(
311
311
  "Error validating Guardrails: make sure all fields are correct.",
312
312
  severity="error",
313
- timeout=10
313
+ timeout=10,
314
314
  )
315
315
  return None
316
316