solace-agent-mesh 1.0.1__py3-none-any.whl → 1.0.3__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.

Potentially problematic release.


This version of solace-agent-mesh might be problematic. Click here for more details.

Files changed (117) hide show
  1. solace_agent_mesh/__init__.py +5 -0
  2. solace_agent_mesh/agent/adk/callbacks.py +23 -1
  3. solace_agent_mesh/agent/adk/filesystem_artifact_service.py +34 -41
  4. solace_agent_mesh/agent/adk/runner.py +10 -6
  5. solace_agent_mesh/agent/adk/services.py +141 -60
  6. solace_agent_mesh/agent/protocol/event_handlers.py +84 -155
  7. solace_agent_mesh/agent/sac/app.py +12 -2
  8. solace_agent_mesh/agent/sac/component.py +182 -38
  9. solace_agent_mesh/agent/sac/task_execution_context.py +15 -6
  10. solace_agent_mesh/agent/tools/builtin_artifact_tools.py +8 -1
  11. solace_agent_mesh/agent/tools/general_agent_tools.py +4 -2
  12. solace_agent_mesh/agent/tools/peer_agent_tool.py +97 -88
  13. solace_agent_mesh/agent/utils/artifact_helpers.py +148 -14
  14. solace_agent_mesh/assets/docs/404.html +3 -3
  15. solace_agent_mesh/assets/docs/assets/js/{04989206.674a8007.js → 04989206.da8246cd.js} +1 -1
  16. solace_agent_mesh/assets/docs/assets/js/1023fc19.8e6d174c.js +1 -0
  17. solace_agent_mesh/assets/docs/assets/js/1c6e87d2.a8c5ce5a.js +1 -0
  18. solace_agent_mesh/assets/docs/assets/js/{3d406171.f722eaf5.js → 3d406171.9b081d5f.js} +1 -1
  19. solace_agent_mesh/assets/docs/assets/js/75384d09.c3991823.js +1 -0
  20. solace_agent_mesh/assets/docs/assets/js/9eff14a2.036c35ea.js +1 -0
  21. solace_agent_mesh/assets/docs/assets/js/{aba87c2f.d3e2dcc3.js → aba87c2f.a6b84da6.js} +1 -1
  22. solace_agent_mesh/assets/docs/assets/js/{ae4415af.8e279b5d.js → ae4415af.96189a93.js} +1 -1
  23. solace_agent_mesh/assets/docs/assets/js/b7006a3a.38c0cf3d.js +1 -0
  24. solace_agent_mesh/assets/docs/assets/js/bb2ef573.56931473.js +1 -0
  25. solace_agent_mesh/assets/docs/assets/js/{cc969b05.954186d4.js → cc969b05.bd3e0d6c.js} +1 -1
  26. solace_agent_mesh/assets/docs/assets/js/f284c35a.5aff74ab.js +1 -0
  27. solace_agent_mesh/assets/docs/assets/js/f897a61a.862b0514.js +1 -0
  28. solace_agent_mesh/assets/docs/assets/js/main.dc7db184.js +2 -0
  29. solace_agent_mesh/assets/docs/assets/js/runtime~main.aa687c82.js +1 -0
  30. solace_agent_mesh/assets/docs/docs/documentation/concepts/agents/index.html +3 -3
  31. solace_agent_mesh/assets/docs/docs/documentation/concepts/architecture/index.html +3 -3
  32. solace_agent_mesh/assets/docs/docs/documentation/concepts/cli/index.html +8 -6
  33. solace_agent_mesh/assets/docs/docs/documentation/concepts/gateways/index.html +4 -4
  34. solace_agent_mesh/assets/docs/docs/documentation/concepts/orchestrator/index.html +3 -3
  35. solace_agent_mesh/assets/docs/docs/documentation/concepts/plugins/index.html +3 -3
  36. solace_agent_mesh/assets/docs/docs/documentation/deployment/debugging/index.html +21 -4
  37. solace_agent_mesh/assets/docs/docs/documentation/deployment/deploy/index.html +3 -3
  38. solace_agent_mesh/assets/docs/docs/documentation/deployment/observability/index.html +3 -3
  39. solace_agent_mesh/assets/docs/docs/documentation/enterprise/index.html +3 -3
  40. solace_agent_mesh/assets/docs/docs/documentation/getting-started/component-overview/index.html +3 -3
  41. solace_agent_mesh/assets/docs/docs/documentation/getting-started/installation/index.html +3 -3
  42. solace_agent_mesh/assets/docs/docs/documentation/getting-started/introduction/index.html +3 -3
  43. solace_agent_mesh/assets/docs/docs/documentation/getting-started/quick-start/index.html +10 -10
  44. solace_agent_mesh/assets/docs/docs/documentation/tutorials/bedrock-agents/index.html +4 -4
  45. solace_agent_mesh/assets/docs/docs/documentation/tutorials/custom-agent/index.html +5 -5
  46. solace_agent_mesh/assets/docs/docs/documentation/tutorials/event-mesh-gateway/index.html +4 -4
  47. solace_agent_mesh/assets/docs/docs/documentation/tutorials/mcp-integration/index.html +4 -4
  48. solace_agent_mesh/assets/docs/docs/documentation/tutorials/mongodb-integration/index.html +5 -5
  49. solace_agent_mesh/assets/docs/docs/documentation/tutorials/rag-integration/index.html +140 -0
  50. solace_agent_mesh/assets/docs/docs/documentation/tutorials/rest-gateway/index.html +4 -4
  51. solace_agent_mesh/assets/docs/docs/documentation/tutorials/slack-integration/index.html +4 -4
  52. solace_agent_mesh/assets/docs/docs/documentation/tutorials/sql-database/index.html +4 -4
  53. solace_agent_mesh/assets/docs/docs/documentation/user-guide/builtin-tools/artifact-management/index.html +4 -4
  54. solace_agent_mesh/assets/docs/docs/documentation/user-guide/builtin-tools/audio-tools/index.html +3 -3
  55. solace_agent_mesh/assets/docs/docs/documentation/user-guide/builtin-tools/data-analysis-tools/index.html +5 -5
  56. solace_agent_mesh/assets/docs/docs/documentation/user-guide/builtin-tools/embeds/index.html +3 -3
  57. solace_agent_mesh/assets/docs/docs/documentation/user-guide/builtin-tools/index.html +3 -3
  58. solace_agent_mesh/assets/docs/docs/documentation/user-guide/create-agents/index.html +3 -3
  59. solace_agent_mesh/assets/docs/docs/documentation/user-guide/create-gateways/index.html +3 -3
  60. solace_agent_mesh/assets/docs/docs/documentation/user-guide/creating-service-providers/index.html +3 -3
  61. solace_agent_mesh/assets/docs/docs/documentation/user-guide/solace-ai-connector/index.html +3 -3
  62. solace_agent_mesh/assets/docs/docs/documentation/user-guide/structure/index.html +3 -3
  63. solace_agent_mesh/assets/docs/img/solace-logo-text.svg +18 -0
  64. solace_agent_mesh/assets/docs/lunr-index-1755120326601.json +1 -0
  65. solace_agent_mesh/assets/docs/lunr-index.json +1 -1
  66. solace_agent_mesh/assets/docs/search-doc-1755120326601.json +1 -0
  67. solace_agent_mesh/assets/docs/search-doc.json +1 -1
  68. solace_agent_mesh/assets/docs/sitemap.xml +1 -1
  69. solace_agent_mesh/cli/__init__.py +1 -1
  70. solace_agent_mesh/cli/commands/init_cmd/env_step.py +8 -0
  71. solace_agent_mesh/cli/commands/init_cmd/orchestrator_step.py +21 -1
  72. solace_agent_mesh/cli/commands/plugin_cmd/catalog_cmd.py +1 -0
  73. solace_agent_mesh/cli/commands/plugin_cmd/official_registry.py +2 -1
  74. solace_agent_mesh/cli/commands/run_cmd.py +42 -3
  75. solace_agent_mesh/cli/main.py +1 -3
  76. solace_agent_mesh/client/webui/frontend/static/assets/main-BCpII1-0.css +1 -0
  77. solace_agent_mesh/client/webui/frontend/static/assets/main-DzKPMTRs.js +673 -0
  78. solace_agent_mesh/client/webui/frontend/static/index.html +2 -2
  79. solace_agent_mesh/common/exceptions.py +25 -0
  80. solace_agent_mesh/common/utils/initializer.py +51 -0
  81. solace_agent_mesh/common/utils/message_utils.py +79 -0
  82. solace_agent_mesh/config_portal/backend/common.py +1 -1
  83. solace_agent_mesh/config_portal/backend/plugin_catalog/constants.py +2 -1
  84. solace_agent_mesh/config_portal/backend/plugin_catalog/registry_manager.py +6 -2
  85. solace_agent_mesh/config_portal/backend/plugin_catalog/scraper.py +1 -5
  86. solace_agent_mesh/config_portal/backend/plugin_catalog_server.py +1 -0
  87. solace_agent_mesh/config_portal/backend/server.py +1 -0
  88. solace_agent_mesh/config_portal/frontend/static/client/assets/_index-xSu2leR8.js +48 -0
  89. solace_agent_mesh/config_portal/frontend/static/client/assets/{manifest-d2b54a97.js → manifest-950eb3be.js} +1 -1
  90. solace_agent_mesh/config_portal/frontend/static/client/index.html +1 -1
  91. solace_agent_mesh/gateway/base/component.py +15 -2
  92. solace_agent_mesh/gateway/http_sse/routers/artifacts.py +9 -3
  93. solace_agent_mesh/gateway/http_sse/sse_manager.py +23 -1
  94. solace_agent_mesh/templates/gateway_component_template.py +75 -44
  95. solace_agent_mesh/templates/logging_config_template.ini +64 -0
  96. solace_agent_mesh/templates/plugin_agent_config_template.yaml +1 -1
  97. {solace_agent_mesh-1.0.1.dist-info → solace_agent_mesh-1.0.3.dist-info}/METADATA +56 -46
  98. {solace_agent_mesh-1.0.1.dist-info → solace_agent_mesh-1.0.3.dist-info}/RECORD +102 -96
  99. solace_agent_mesh/assets/docs/assets/js/1023fc19.015679ca.js +0 -1
  100. solace_agent_mesh/assets/docs/assets/js/1c6e87d2.23bccffb.js +0 -1
  101. solace_agent_mesh/assets/docs/assets/js/9eff14a2.1bf8f61c.js +0 -1
  102. solace_agent_mesh/assets/docs/assets/js/b7006a3a.40b10c9d.js +0 -1
  103. solace_agent_mesh/assets/docs/assets/js/bb2ef573.207e6990.js +0 -1
  104. solace_agent_mesh/assets/docs/assets/js/f284c35a.ecc3d195.js +0 -1
  105. solace_agent_mesh/assets/docs/assets/js/f897a61a.2c2e152c.js +0 -1
  106. solace_agent_mesh/assets/docs/assets/js/main.7ed3319f.js +0 -2
  107. solace_agent_mesh/assets/docs/assets/js/runtime~main.d9520ae2.js +0 -1
  108. solace_agent_mesh/assets/docs/img/Solace_AI_Framework_README.png +0 -0
  109. solace_agent_mesh/assets/docs/lunr-index-1753813536522.json +0 -1
  110. solace_agent_mesh/assets/docs/search-doc-1753813536522.json +0 -1
  111. solace_agent_mesh/client/webui/frontend/static/assets/main-An0a5j5k.js +0 -663
  112. solace_agent_mesh/client/webui/frontend/static/assets/main-Bu5-4Bac.css +0 -1
  113. solace_agent_mesh/config_portal/frontend/static/client/assets/_index-DNxCwAGB.js +0 -48
  114. /solace_agent_mesh/assets/docs/assets/js/{main.7ed3319f.js.LICENSE.txt → main.dc7db184.js.LICENSE.txt} +0 -0
  115. {solace_agent_mesh-1.0.1.dist-info → solace_agent_mesh-1.0.3.dist-info}/WHEEL +0 -0
  116. {solace_agent_mesh-1.0.1.dist-info → solace_agent_mesh-1.0.3.dist-info}/entry_points.txt +0 -0
  117. {solace_agent_mesh-1.0.1.dist-info → solace_agent_mesh-1.0.3.dist-info}/licenses/LICENSE +0 -0
@@ -5,9 +5,9 @@
5
5
  <link rel="icon" type="image/svg+xml" href="/assets/favicon-BLgzUch9.ico" />
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <title>Solace Agent Mesh</title>
8
- <script type="module" crossorigin src="/assets/main-An0a5j5k.js"></script>
8
+ <script type="module" crossorigin src="/assets/main-DzKPMTRs.js"></script>
9
9
  <link rel="modulepreload" crossorigin href="/assets/client-bp6u3qVZ.js">
10
- <link rel="stylesheet" crossorigin href="/assets/main-Bu5-4Bac.css">
10
+ <link rel="stylesheet" crossorigin href="/assets/main-BCpII1-0.css">
11
11
  </head>
12
12
  <body>
13
13
  <div id="root"></div>
@@ -0,0 +1,25 @@
1
+ """Custom exceptions for Solace Agent Mesh."""
2
+
3
+
4
+ class MessageSizeExceededError(Exception):
5
+ """Raised when a message exceeds the maximum allowed size."""
6
+
7
+ def __init__(self, actual_size: int, max_size: int, message: str = None):
8
+ """Initialize the MessageSizeExceededError.
9
+
10
+ Args:
11
+ actual_size: The actual size of the message in bytes.
12
+ max_size: The maximum allowed size in bytes.
13
+ message: Optional custom error message. If None, a default message
14
+ will be generated.
15
+ """
16
+ self.actual_size = actual_size
17
+ self.max_size = max_size
18
+
19
+ if message is None:
20
+ message = (
21
+ f"Message size {actual_size} bytes exceeds maximum limit of "
22
+ f"{max_size} bytes"
23
+ )
24
+
25
+ super().__init__(message)
@@ -0,0 +1,51 @@
1
+ import os
2
+ import json
3
+ import yaml
4
+ from solace_ai_connector.common.log import log
5
+ from solace_ai_connector.main import load_config
6
+
7
+ _has_initialized_system = False
8
+
9
+ def initialize():
10
+ global _has_initialized_system
11
+ if not _has_initialized_system:
12
+ _has_initialized_system = True
13
+ else:
14
+ return
15
+
16
+ try:
17
+ from solace_agent_mesh_enterprise.init_enterprise import initialize_enterprise_features
18
+ except ImportError:
19
+ # Community edition
20
+ # Contact Solace support for enterprise features
21
+ return
22
+
23
+ enterprise_config = os.getenv("SAM_ENTERPRISE_CONFIG")
24
+ if enterprise_config and isinstance(enterprise_config, str):
25
+ if enterprise_config.endswith('.yaml') or enterprise_config.endswith('.yml'):
26
+ try:
27
+ enterprise_config = load_config(enterprise_config)
28
+ except Exception as e:
29
+ log.error("Failed to load YAML config from SAM_ENTERPRISE_CONFIG: %s", e, exc_info=True)
30
+ raise
31
+ elif enterprise_config.endswith('.json'):
32
+ try:
33
+ with open(enterprise_config, 'r', encoding='utf-8') as file:
34
+ enterprise_config = json.load(file)
35
+ except Exception as e:
36
+ log.error("Failed to load JSON config from SAM_ENTERPRISE_CONFIG: %s", e, exc_info=True)
37
+ raise
38
+ else:
39
+ try:
40
+ enterprise_config = json.loads(enterprise_config)
41
+ except json.JSONDecodeError as e:
42
+ log.error("Invalid JSON in SAM_ENTERPRISE_CONFIG: %s", e, exc_info=True)
43
+ raise
44
+ else:
45
+ enterprise_config = {}
46
+
47
+ try:
48
+ initialize_enterprise_features(enterprise_config)
49
+ except Exception as e:
50
+ log.error("Failed to initialize enterprise features: %s", e, exc_info=True)
51
+ raise
@@ -0,0 +1,79 @@
1
+ """Message utility functions for size calculation and validation.
2
+
3
+ This module provides utilities for calculating and validating message sizes
4
+ to ensure they don't exceed configured limits. The size calculation matches
5
+ the exact serialization format used by the Solace AI Connector (JSON + UTF-8).
6
+ """
7
+
8
+ import json
9
+ from typing import Any, Dict, Tuple
10
+
11
+ from solace_ai_connector.common.log import log
12
+
13
+ # Maximum bytes per character in UTF-8 encoding (4 bytes for full Unicode range)
14
+ MAX_UTF8_BYTES_PER_CHARACTER = 4
15
+
16
+
17
+ def calculate_message_size(payload: Dict[str, Any]) -> int:
18
+ """Calculate the exact size of a message payload in bytes.
19
+
20
+ Uses JSON serialization followed by UTF-8 encoding to match the exact
21
+ format used by the Solace AI Connector.
22
+
23
+ Args:
24
+ payload: The message payload dictionary to calculate size for.
25
+
26
+ Returns:
27
+ The size of the payload in bytes.
28
+
29
+ Note:
30
+ If JSON serialization fails, falls back to string representation
31
+ for size estimation.
32
+ """
33
+ try:
34
+ # Use JSON serialization + UTF-8 encoding to match Solace AI Connector
35
+ json_str = json.dumps(payload, separators=(",", ":"), ensure_ascii=False)
36
+ return len(json_str.encode("utf-8"))
37
+ except (TypeError, ValueError) as e:
38
+ # Graceful fallback if JSON serialization fails
39
+ log.warning(
40
+ f"Failed to serialize payload to JSON for size calculation: {e}. "
41
+ f"Using string representation fallback."
42
+ )
43
+ try:
44
+ return len(str(payload).encode("utf-8"))
45
+ except Exception as fallback_error:
46
+ log.error(
47
+ f"Fallback size calculation also failed: {fallback_error}. "
48
+ f"Returning conservative estimate."
49
+ )
50
+ # Conservative estimate using maximum UTF-8 bytes per character
51
+ return len(str(payload)) * MAX_UTF8_BYTES_PER_CHARACTER
52
+
53
+
54
+ def validate_message_size(
55
+ payload: Dict[str, Any], max_size_bytes: int, component_identifier: str = "Unknown"
56
+ ) -> Tuple[bool, int]:
57
+ """Validate that a message payload doesn't exceed the maximum size limit.
58
+
59
+ Args:
60
+ payload: The message payload dictionary to validate.
61
+ max_size_bytes: The maximum allowed size in bytes.
62
+ component_identifier: Identifier for the component performing validation
63
+ (used in log messages).
64
+
65
+ Returns:
66
+ A tuple containing:
67
+ - bool: True if the payload is within size limits, False otherwise
68
+ - int: The actual size of the payload in bytes
69
+
70
+ Note:
71
+ Logs an error if size exceeds the limit.
72
+ """
73
+ actual_size = calculate_message_size(payload)
74
+
75
+ # Check if size exceeds the limit
76
+ if actual_size > max_size_bytes:
77
+ return False, actual_size
78
+
79
+ return True, actual_size
@@ -30,7 +30,7 @@ AGENT_DEFAULTS = {
30
30
  "supports_streaming": True,
31
31
  "model_type": "general",
32
32
  "instruction": "You are a helpful AI assistant named __AGENT_NAME__.",
33
- "artifact_handling_mode": "embed",
33
+ "artifact_handling_mode": "reference",
34
34
  "enable_embed_resolution": True,
35
35
  "enable_artifact_content_instruction": True,
36
36
  "tools": "[]",
@@ -3,6 +3,7 @@ from pathlib import Path
3
3
 
4
4
  try:
5
5
  from cli.utils import get_sam_cli_home_dir
6
+
6
7
  SAM_HOME = get_sam_cli_home_dir()
7
8
  except ImportError:
8
9
  print(
@@ -14,7 +15,7 @@ except ImportError:
14
15
  SAM_HOME.mkdir(parents=True, exist_ok=True)
15
16
 
16
17
  DEFAULT_OFFICIAL_REGISTRY_URL = (
17
- "https://github.com/SolaceLabs/solace-agent-mesh-core-plugins"
18
+ "https://github.com/SolaceLabs/solace-agent-mesh-core-plugins"
18
19
  )
19
20
  OFFICIAL_REGISTRY_GIT_BRANCH = "main"
20
21
  IGNORE_OFFICIAL_FLAG_REPOS = []
@@ -6,7 +6,11 @@ from typing import List, Optional, Dict, Any
6
6
  from pydantic import ValidationError
7
7
 
8
8
  from .models import Registry
9
- from .constants import DEFAULT_OFFICIAL_REGISTRY_URL, USER_REGISTRIES_PATH, OFFICIAL_REGISTRY_GIT_BRANCH
9
+ from .constants import (
10
+ DEFAULT_OFFICIAL_REGISTRY_URL,
11
+ USER_REGISTRIES_PATH,
12
+ OFFICIAL_REGISTRY_GIT_BRANCH,
13
+ )
10
14
 
11
15
 
12
16
  class RegistryManager:
@@ -33,7 +37,7 @@ class RegistryManager:
33
37
  ),
34
38
  is_default=True,
35
39
  is_official_source=True,
36
- git_branch=OFFICIAL_REGISTRY_GIT_BRANCH
40
+ git_branch=OFFICIAL_REGISTRY_GIT_BRANCH,
37
41
  )
38
42
 
39
43
  registries_map: Dict[str, Registry] = {
@@ -250,11 +250,7 @@ class PluginScraper:
250
250
  kwargs = {}
251
251
  if registry.git_branch:
252
252
  kwargs["branch"] = registry.git_branch
253
- git.Repo.clone_from(
254
- registry.path_or_url,
255
- repo_local_path,
256
- **kwargs
257
- )
253
+ git.Repo.clone_from(registry.path_or_url, repo_local_path, **kwargs)
258
254
 
259
255
  for item in repo_local_path.iterdir():
260
256
  if item.is_dir() and not item.name.startswith("."):
@@ -18,6 +18,7 @@ if not logger.hasHandlers():
18
18
  registry_manager = RegistryManager()
19
19
  plugin_scraper = PluginScraper()
20
20
 
21
+
21
22
  def create_plugin_catalog_app(shared_config=None):
22
23
  current_dir = Path(__file__).parent
23
24
  static_folder_path = (
@@ -38,6 +38,7 @@ except ImportError as err:
38
38
  )
39
39
  raise err from exc
40
40
 
41
+
41
42
  def get_agent_field_definitions():
42
43
  fields = []
43
44
  fields.append(