Skip to content

修复接口调用模型未打印埋点信息 #101

@guojunke

Description

@guojunke

Describe your environment

python为flask框架,flask框架版本为3.1.1,opentelemetry版本为1.39.1。,agentscope版本为1.0.11,安装流程为:

安装OpenTelemetry相关包

pip install opentelemetry-distro opentelemetry-exporter-otlp
opentelemetry-bootstrap -a install

安装AgentScope

pip install agentscope

安装AgentScope可观测插件

git clone https://github.com/alibaba/loongsuite-python-agent.git
cd loongsuite-python-agent
pip install ./instrumentation-loongsuite/loongsuite-instrumentation-agentscope
pip install ./util/opentelemetry-util-genai

项目启动命令为:opentelemetry-instrument --traces_exporter console --metrics_exporter console python src/manage.py

What happened?

现象:opentelemtry只打印了框架的埋点日志,未打印业务调用相关日志

Steps to Reproduce

flask框架版本为3.1.1,opentelemetry版本为1.39.1。,agentscope版本为1.0.11,安装流程为:

安装OpenTelemetry相关包

pip install opentelemetry-distro opentelemetry-exporter-otlp
opentelemetry-bootstrap -a install

安装AgentScope

pip install agentscope

安装AgentScope可观测插件

git clone https://github.com/alibaba/loongsuite-python-agent.git
cd loongsuite-python-agent
pip install ./instrumentation-loongsuite/loongsuite-instrumentation-agentscope
pip install ./util/opentelemetry-util-genai

项目启动命令为:opentelemetry-instrument --traces_exporter console --metrics_exporter console python src/manage.py

Expected Result

能够显示业务调用每个方法的埋点信息(输入、输出参数、方法名、耗时、开始时间、结束时间)

Actual Result

只有框架相关埋点信息

Additional context

No response

Would you like to implement a fix?

None

Tip

React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions