Skip to content

Add LLM observability with Langfuse #4

Description

@burner-agent

Summary

Integrate langfuse/langfuse (25k+ stars) for LLM observability — tracking token usage, latency, cost, and prompt/response quality across all Claude invocations.

Motivation

Burner has no visibility into which RALPH loops burn the most tokens, which prompts are inefficient, or how response quality varies over time. Langfuse provides a lightweight tracing layer that records every LLM call with metadata, enabling cost optimization and self-improvement feedback.

Proposal

  • Add Langfuse JS SDK as a dependency
  • Wrap Claude CLI invocations in src/agent.ts with Langfuse trace spans
  • Track: token counts, latency, model used, loop/thread context, success/failure
  • Optional: score outputs for self-improvement feedback loops
  • Self-hostable or cloud — operator's choice

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions