langfuse / langfuse/opencode-observability-plugin
Feature: expose skill and subagent names for Langfuse analytics
@bezbac is already working on this.
Since Sep 15, 2026.
- Dominant language
- TypeScript
- Stars
- 29
- Forks
- 18
- Avg merge
- 5h 26m
- Merged PRs (30d)
- 8
Description
Problem
OpenCode skill and task tool calls are exported as Langfuse TOOL observations named only skill and task.
The semantic values are preserved only inside the observation input:
- Skill name:
input.name - Subagent type:
input.subagent_type
Langfuse dashboards can group tool observations by observation name, but cannot group or filter metrics by fields nested inside observation input. As a result, dashboards can show only total skill invocations and total subagent spawns. They cannot break those calls down by skill name or subagent type.
Current behavior
A skill invocation such as:
{
"name": "resolve-dependencies"
}
is exported as an observation named skill.
A subagent spawn such as:
{
"subagent_type": "developer"
}
is exported as an observation named task.
On current main, traceToolStart creates the span with startSpan(input.tool, ...), so these semantic names are not exposed through the observation name. I reproduced the behavior with plugin 0.3.0, and the same naming behavior remains in the current 0.4.0 source.
Expected behavior
Expose the semantic skill or subagent name through a field that Langfuse metrics can group and filter by.
Possible approaches:
- Name observations
skill:<name>andtask:<subagent_type>. - Add stable Langfuse attributes or metadata fields that are supported as dashboard dimensions.
The original tool input should remain available unchanged.
Why this matters
This would allow native Langfuse dashboards to report:
- Skill invocation counts by skill name
- Subagent spawn counts by subagent type
- Per-trace skill and subagent usage
Without this, users must build a separate pipeline that parses observation inputs and writes the extracted values back into Langfuse.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.