UNPKG

newrelic

Version:
22 lines (16 loc) 567 B
/* * Copyright 2025 New Relic Corporation. All rights reserved. * SPDX-License-Identifier: Apache-2.0 */ 'use strict' const LlmEvent = require('./event') class LlmEmbedding extends LlmEvent { constructor({ agent, segment, request = {}, response = {}, withError = false, transaction }) { super({ agent, segment, request, response, responseAttrs: true, transaction }) this.error = withError if (agent.config.ai_monitoring.record_content.enabled === true) { this.input = request.contents?.toString() } } } module.exports = LlmEmbedding