From 8547938d1dd66ff557942e4fb1796ec920654d62 Mon Sep 17 00:00:00 2001 From: Douwe Osinga Date: Mon, 6 Oct 2025 20:39:06 -0400 Subject: [PATCH] Put it back --- crates/goose-cli/src/cli.rs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/crates/goose-cli/src/cli.rs b/crates/goose-cli/src/cli.rs index 37819d631a..27a04dd38d 100644 --- a/crates/goose-cli/src/cli.rs +++ b/crates/goose-cli/src/cli.rs @@ -843,6 +843,13 @@ pub async fn cli() -> Result<()> { let session_start = std::time::Instant::now(); let session_type = if resume { "resumed" } else { "new" }; + tracing::info!( + counter.goose.session_starts = 1, + session_type, + interactive = true, + "Session started" + ); + let session_id = if let Some(id) = identifier { Some(get_session_id(id).await?) } else { @@ -901,6 +908,20 @@ pub async fn cli() -> Result<()> { "Session completed" ); + tracing::info!( + counter.goose.session_duration_ms = session_duration.as_millis() as u64, + session_type, + "Session duration" + ); + + if total_tokens > 0 { + tracing::info!( + counter.goose.session_tokens = total_tokens, + session_type, + "Session tokens" + ); + } + Ok(()) } };