code: def _send_request(
      self, model_name: str, raw_request: Dict[str, Any]
  ) -> Dict[str, Any]:
      response = requests.request(
          method="POST",
          url=f"https://enterprise-api.writer.com/llm/organization/3002/model/{model_name}/completions",
          headers={
              "Content-Type": "application/json",
              "Accept": "application/json",
              "Authorization": f"Bearer {self.api_key}",
          },
          data=json.dumps(raw_request),
      )
      result = json.loads(response.text)
      if "error" in result:
          raise ValueError(
              f"Request failed with error: {result['error']}"
          )
      return result
  
file_path: H2O/h2o_hf/helm/src/helm/proxy/clients/palmyra_client.py
imports: import json
  import requests
  from typing import Any, Dict, List
  from helm.common.cache import Cache, CacheConfig
  from helm.common.hierarchical_logger import hlog
  from helm.common.request import Request, RequestResult, Sequence, Token, ErrorFlags
  from helm.common.tokenization_request import DecodeRequest, DecodeRequestResult, TokenizationRequest, TokenizationRequestResult
  from .client import Client, wrap_request_time, truncate_sequence
label_desc: Use image node_id 2 for calling the PalmyraClient obj's underlying member method code with example usage: obj._send_request(model_name, raw_request) and returns: result