Skip to content

Conversation

@michaelneale
Copy link
Collaborator

fixes ##7121

seems to bring the content back, if we still want langfuse that is cc @blackgirlbytes @DOsinga

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes missing Langfuse trace content by propagating user/assistant text into Langfuse trace-level input/output and improving Langfuse base URL env var compatibility.

Changes:

  • Add trace-level update support in ObservationLayer and filter trace_input/trace_output out of span updates.
  • Record tool-call input and trace input/output from the agent via tracing fields/events.
  • Expand Langfuse base URL env var lookup to include LANGFUSE_BASE_URL and LANGFUSE_HOST.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
crates/goose/src/tracing/observation_layer.rs Adds trace update path for input/output and tests covering trace-only and mixed metadata behavior.
crates/goose/src/tracing/langfuse_layer.rs Accepts additional env vars for Langfuse base URL configuration.
crates/goose/src/agents/agent.rs Instruments tool dispatch and reply flow to emit trace input/output content.

Comment on lines +471 to +472
"tool": tool_call.name,
"arguments": tool_call.arguments,
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

json!({"tool": tool_call.name, "arguments": tool_call.arguments}) moves fields out of tool_call, so subsequent uses of tool_call.name / tool_call.arguments in this function will not compile; serialize references (e.g., &tool_call.name / &tool_call.arguments) or clone the fields before building input_summary.

Suggested change
"tool": tool_call.name,
"arguments": tool_call.arguments,
"tool": &tool_call.name,
"arguments": &tool_call.arguments,

Copilot uses AI. Check for mistakes.
Comment on lines +189 to +190
for (k, v) in updates {
body[k] = v;
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

body[k] = v is indexing a serde_json::Value with a String, which doesn’t type-check; use body[&k] = v or mutate the underlying object via as_object_mut() and insert.

Suggested change
for (k, v) in updates {
body[k] = v;
if let Some(map) = body.as_object_mut() {
for (k, v) in updates {
map.insert(k, v);
}

Copilot uses AI. Check for mistakes.
@codefromthecrypt codefromthecrypt added this pull request to the merge queue Feb 11, 2026
Copy link
Collaborator

@codefromthecrypt codefromthecrypt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, shortly I'll do another pass on otel cleanups since have a conference soon to show off goose at!

Merged via the queue into main with commit d138c88 Feb 11, 2026
24 checks passed
@codefromthecrypt codefromthecrypt deleted the micn/fix-langfuse-trace branch February 11, 2026 02:45
tlongwell-block added a commit that referenced this pull request Feb 11, 2026
* origin/main: (107 commits)
  feat: Allow overriding default bat themes using environment variables (#7140)
  Make the system prompt smaller (#6991)
  Pre release script (#7145)
  Spelling (#7137)
  feat(mcp): upgrade rmcp to 0.15.0 and advertise MCP Apps UI extension capability (#6927)
  fix: ensure assistant messages with tool_calls include content field (#7076)
  fix(canonical): handle gcp_vertex_ai model mapping correctly (#6836)
  Group dependencies in root Cargo.toml (#6948)
  refactor: updated elevenLabs API module and `remove button` UX (#6781)
  fix: we were missing content from langfuse traces (#7135)
  docs: update username in authors.yml (#7132)
  fix extension selector syncing issues (#7133)
  fix(acp): per-session Agent for model isolation and load_session restore (#7115)
  fix(claude-code): defensive coding improvements for model switching (#7131)
  feat(claude-code): dynamic model listing and mid-session model switching (#7120)
  Inline worklet source (#7128)
  [docs] One shot prompting is dead - Blog Post (#7113)
  fix: correct spelling of Debbie O'Brien's name in authors.yml (#7127)
  docs: GCP Vertex AI org policy filtering & update OnboardingProviderSetup component (#7125)
  feat: replace subagent and skills with unified summon extension (#6964)
  ...

# Conflicts:
#	Cargo.lock
#	Cargo.toml
zanesq added a commit to Abhijay007/goose that referenced this pull request Feb 11, 2026
* upstream/main: (109 commits)
  [docs] Skills Marketplace UI Improvements (block#7158)
  More no-window flags (block#7122)
  feat: Allow overriding default bat themes using environment variables (block#7140)
  Make the system prompt smaller (block#6991)
  Pre release script (block#7145)
  Spelling (block#7137)
  feat(mcp): upgrade rmcp to 0.15.0 and advertise MCP Apps UI extension capability (block#6927)
  fix: ensure assistant messages with tool_calls include content field (block#7076)
  fix(canonical): handle gcp_vertex_ai model mapping correctly (block#6836)
  Group dependencies in root Cargo.toml (block#6948)
  refactor: updated elevenLabs API module and `remove button` UX (block#6781)
  fix: we were missing content from langfuse traces (block#7135)
  docs: update username in authors.yml (block#7132)
  fix extension selector syncing issues (block#7133)
  fix(acp): per-session Agent for model isolation and load_session restore (block#7115)
  fix(claude-code): defensive coding improvements for model switching (block#7131)
  feat(claude-code): dynamic model listing and mid-session model switching (block#7120)
  Inline worklet source (block#7128)
  [docs] One shot prompting is dead - Blog Post (block#7113)
  fix: correct spelling of Debbie O'Brien's name in authors.yml (block#7127)
  ...
Tyler-Hardin pushed a commit to Tyler-Hardin/goose that referenced this pull request Feb 11, 2026
Tyler-Hardin pushed a commit to Tyler-Hardin/goose that referenced this pull request Feb 11, 2026
Tyler-Hardin pushed a commit to Tyler-Hardin/goose that referenced this pull request Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants