{
  "spec_version": "1.4.0-otel",
  "timestamp": "2026-04-24T00:13:03.355457Z",
  "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
  "span_id": "00f067aa0ba902b7",
  "severity_text": "WARN",
  "severity_number": 13,
  "event_name": "swarm.agent.lifecycle.deprecated",
  "resource": {
    "service.name": "swarm-orchestrator",
    "service.version": "4.2.0",
    "deployment.environment": "production",
    "node.id": "worker-node-aws-us-east-1a-04"
  },
  "attributes": {
    "agent.id": "VolatilityRiskAgent",
    "agent.previous_version": "v29.x",
    "agent.target_version": "v30",
    "deprecation.reason": "Transitioning to v30 architecture.",
    "deprecation.action_required": true
  },
  "metrics": {
    "agent.core_logic.function_count": 3,
    "agent.capabilities.count": 0
  },
  "artifacts": {
    "provenance": {
      "repository": "git+ssh://repo/core/agents/volatility_risk_agent.py",
      "commit_sha": "a1b2c3d4e5f6g7h8i9j0",
      "docstring_hash": "sha256:d8c4b12389a..."
    },
    "extracted_capabilities": [],
    "core_logic_signatures": [
      {
        "name": "__init__",
        "ast_hash": "sha256:7bf97a7dad0a32ab",
        "loc": 2,
        "source": "def __init__(self, config: Dict[str, Any], **kwargs):\n        super().__init__(config, **kwargs)"
      },
      {
        "name": "execute",
        "ast_hash": "sha256:313f3174de0ab9de",
        "loc": 114,
        "source_omitted_for_brevity": true,
        "note": "In a real telemetry pipeline, large functions can be truncated or omitted entirely in favor of the 'ast_hash' to save network bandwidth and storage costs."
      },
      {
        "name": "_analyze_volatility_cone",
        "ast_hash": "sha256:0589b5bbfedc1aba",
        "loc": 29,
        "source": "def _analyze_volatility_cone(self, current_vol: float, historical_vols: list[float]) -> Dict[str, Any]:\n        \"\"\"Analyzes where current volatility sits relative to historical distribution.\"\"\"\n        if not historical_vols or len(historical_vols) < 5:\n            return {\"percentile\": 50, \"status\": \"Insufficient Data\"}\n\n        # Sort historical data\n        sorted_vols = sorted(historical_vols)\n        n = len(sorted_vols)\n\n        # Calculate Percentile\n        # Number of items less than current_vol\n        below_count = sum(1 for v in sorted_vols if v < current_vol)\n        percentile = (below_count / n) * 100.0\n\n        # Determine status\n        if percentile < 10: status = \"Extremely Low (Reversion Risk)\"\n        elif percentile < 25: status = \"Low\"\n        elif percentile < 75: status = \"Normal\"\n        elif percentile < 90: status = \"High\"\n        else: status = \"Extremely High\"\n\n        return {\n            \"current_vol\": float(current_vol),\n            \"percentile\": float(percentile),\n            \"min_historical\": float(sorted_vols[0]),\n            \"max_historical\": float(sorted_vols[-1]),\n            \"median_historical\": float(np.median(sorted_vols)),\n            \"status\": status\n        }"
      }
    ]
  }
}