TODO: Should make a parameters struct.
(
&self,
database: &Database,
conversation_id: String,
result: TelemetryResult,
data: ChatAddedMessageParams,
)
| 311 | |
| 312 | #[allow(clippy::too_many_arguments)] // TODO: Should make a parameters struct. |
| 313 | pub async fn send_chat_added_message( |
| 314 | &self, |
| 315 | database: &Database, |
| 316 | conversation_id: String, |
| 317 | result: TelemetryResult, |
| 318 | data: ChatAddedMessageParams, |
| 319 | ) -> Result<(), TelemetryError> { |
| 320 | let mut telemetry_event = Event::new(EventType::ChatAddedMessage { |
| 321 | conversation_id, |
| 322 | result, |
| 323 | data, |
| 324 | }); |
| 325 | set_event_metadata(database, &mut telemetry_event).await; |
| 326 | |
| 327 | Ok(self.tx.send(telemetry_event)?) |
| 328 | } |
| 329 | |
| 330 | pub async fn send_record_user_turn_completion( |
| 331 | &self, |