def _get_response_token_counts(raw_response: Dict[str, Any]) -> Dict[str, int]:
    """
    Extract token usage information from the response.

    Args:
        raw_response: The raw response containing token usage information.

    Returns:
        A dictionary containing token counts, or an empty dictionary if usage info is not found.

    """
    if not raw_response.get("usage"):
        return {}

    return {
        "prompt_tokens": raw_response["usage"].get("prompt_tokens", 0),
        "completion_tokens": raw_response["usage"].get("completion_tokens", 0),
        "total_tokens": raw_response["usage"].get("total_tokens", 0),
    }

    Extract token usage information from the response.

    Args:
        raw_response: The raw response containing token usage information.

    Returns:
        A dictionary containing token counts, or an empty dictionary if usage info is not found.

    
llama-index-integrations/llms/llama-index-llms-oci-data-science/llama_index/llms/oci_data_science/utils.py