Skip to content

feat: enhance observability with plugin (#3)#37

Merged
sjy3 merged 4 commits intovolcengine:mainfrom
shunjiazhu:feat/observability_plugin
Feb 3, 2026
Merged

feat: enhance observability with plugin (#3)#37
sjy3 merged 4 commits intovolcengine:mainfrom
shunjiazhu:feat/observability_plugin

Conversation

@shunjiazhu
Copy link
Contributor

@shunjiazhu shunjiazhu commented Feb 2, 2026

增加add veadk observability plugin
用法:

在配置文件中添加observability配置

observability:
  opentelemetry:
    apmplus:
      endpoint: "https://apmplus-cn-beijing.volces.com:4318"
      api_key: "YOUR_APMPLUS_API_KEY"
      service_name: "YOUR_SERVICE_NAME"

在代码中引入plugin:

  config := &launcher.Config{
      AgentLoader:    agent.NewSingleLoader(a),
      PluginConfig: runner.PluginConfig{
          Plugins: []*plugin.Plugin{observability.NewPlugin()},
      },
  }
image image image

shunjiazhu and others added 3 commits February 2, 2026 21:27
* add span processor and meter implementation

* add an example of observability

* add unit tests for observability

* update config according to python implementation

* rename function and const variable names

* add unit test files

* add config.yaml in observability example

* update metrics implementation like veadk-python

* move internal functions to private

* update metrics implementation: adding apmplus metrics

* fix parse tool name

* add configs for enable local providers

* only enable metrics exporter for apmplus

* update example config

* fix missing attrs

* fix gen_ai.client.token.usage

* fix gen_ai.client.token.usage

* fix gen_ai.client.token.usage

* update to use plugin

* update to polish logs

* delete span processors

* go mod tidy

* add launcher example

* remove duplicate spans

* remove duplicate spans

* merge with main

* save work

* add processor

* resolve conflicts with main

* extract span metadata in state

* remove useless function and constants

* clean map to avoid leak

* remove complicated functions

* change key from traceid  to spanid

* fix execute tool span missing

* clean map to avoid resource leak

* update metrics attributes according to python implementation

* split long functions

* polish logs

* restore ../../model/openai.go
@shunjiazhu shunjiazhu force-pushed the feat/observability_plugin branch from 7ba6d3e to 2668daf Compare February 2, 2026 15:36
@shunjiazhu shunjiazhu force-pushed the feat/observability_plugin branch from 2668daf to b40d4a5 Compare February 2, 2026 16:22
@sjy3 sjy3 merged commit d69ee52 into volcengine:main Feb 3, 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.

2 participants