Skip to content

Commit ab1d7de

Browse files
authored
[feat] Add support for dashscope sdk (#66)
2 parents efc992c + 713e2b3 commit ab1d7de

File tree

56 files changed

+16259
-12
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+16259
-12
lines changed

.github/workflows/loongsuite_lint_0.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,25 @@ env:
3232

3333
jobs:
3434

35+
lint-loongsuite-instrumentation-dashscope:
36+
name: LoongSuite loongsuite-instrumentation-dashscope
37+
runs-on: ubuntu-latest
38+
timeout-minutes: 30
39+
steps:
40+
- name: Checkout repo @ SHA - ${{ github.sha }}
41+
uses: actions/checkout@v4
42+
43+
- name: Set up Python 3.13
44+
uses: actions/setup-python@v5
45+
with:
46+
python-version: "3.13"
47+
48+
- name: Install tox
49+
run: pip install tox-uv
50+
51+
- name: Run tests
52+
run: tox -c tox-loongsuite.ini -e lint-loongsuite-instrumentation-dashscope
53+
3554
lint-loongsuite-instrumentation-mem0:
3655
name: LoongSuite loongsuite-instrumentation-mem0
3756
runs-on: ubuntu-latest

.github/workflows/loongsuite_test_0.yml

Lines changed: 190 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,196 @@ env:
3232

3333
jobs:
3434

35+
py39-test-loongsuite-instrumentation-dashscope-oldest_ubuntu-latest:
36+
name: LoongSuite loongsuite-instrumentation-dashscope-oldest 3.9 Ubuntu
37+
runs-on: ubuntu-latest
38+
timeout-minutes: 30
39+
steps:
40+
- name: Checkout repo @ SHA - ${{ github.sha }}
41+
uses: actions/checkout@v4
42+
43+
- name: Set up Python 3.9
44+
uses: actions/setup-python@v5
45+
with:
46+
python-version: "3.9"
47+
48+
- name: Install tox
49+
run: pip install tox-uv
50+
51+
- name: Run tests
52+
run: tox -c tox-loongsuite.ini -e py39-test-loongsuite-instrumentation-dashscope-oldest -- -ra
53+
54+
py39-test-loongsuite-instrumentation-dashscope-latest_ubuntu-latest:
55+
name: LoongSuite loongsuite-instrumentation-dashscope-latest 3.9 Ubuntu
56+
runs-on: ubuntu-latest
57+
timeout-minutes: 30
58+
steps:
59+
- name: Checkout repo @ SHA - ${{ github.sha }}
60+
uses: actions/checkout@v4
61+
62+
- name: Set up Python 3.9
63+
uses: actions/setup-python@v5
64+
with:
65+
python-version: "3.9"
66+
67+
- name: Install tox
68+
run: pip install tox-uv
69+
70+
- name: Run tests
71+
run: tox -c tox-loongsuite.ini -e py39-test-loongsuite-instrumentation-dashscope-latest -- -ra
72+
73+
py310-test-loongsuite-instrumentation-dashscope-oldest_ubuntu-latest:
74+
name: LoongSuite loongsuite-instrumentation-dashscope-oldest 3.10 Ubuntu
75+
runs-on: ubuntu-latest
76+
timeout-minutes: 30
77+
steps:
78+
- name: Checkout repo @ SHA - ${{ github.sha }}
79+
uses: actions/checkout@v4
80+
81+
- name: Set up Python 3.10
82+
uses: actions/setup-python@v5
83+
with:
84+
python-version: "3.10"
85+
86+
- name: Install tox
87+
run: pip install tox-uv
88+
89+
- name: Run tests
90+
run: tox -c tox-loongsuite.ini -e py310-test-loongsuite-instrumentation-dashscope-oldest -- -ra
91+
92+
py310-test-loongsuite-instrumentation-dashscope-latest_ubuntu-latest:
93+
name: LoongSuite loongsuite-instrumentation-dashscope-latest 3.10 Ubuntu
94+
runs-on: ubuntu-latest
95+
timeout-minutes: 30
96+
steps:
97+
- name: Checkout repo @ SHA - ${{ github.sha }}
98+
uses: actions/checkout@v4
99+
100+
- name: Set up Python 3.10
101+
uses: actions/setup-python@v5
102+
with:
103+
python-version: "3.10"
104+
105+
- name: Install tox
106+
run: pip install tox-uv
107+
108+
- name: Run tests
109+
run: tox -c tox-loongsuite.ini -e py310-test-loongsuite-instrumentation-dashscope-latest -- -ra
110+
111+
py311-test-loongsuite-instrumentation-dashscope-oldest_ubuntu-latest:
112+
name: LoongSuite loongsuite-instrumentation-dashscope-oldest 3.11 Ubuntu
113+
runs-on: ubuntu-latest
114+
timeout-minutes: 30
115+
steps:
116+
- name: Checkout repo @ SHA - ${{ github.sha }}
117+
uses: actions/checkout@v4
118+
119+
- name: Set up Python 3.11
120+
uses: actions/setup-python@v5
121+
with:
122+
python-version: "3.11"
123+
124+
- name: Install tox
125+
run: pip install tox-uv
126+
127+
- name: Run tests
128+
run: tox -c tox-loongsuite.ini -e py311-test-loongsuite-instrumentation-dashscope-oldest -- -ra
129+
130+
py311-test-loongsuite-instrumentation-dashscope-latest_ubuntu-latest:
131+
name: LoongSuite loongsuite-instrumentation-dashscope-latest 3.11 Ubuntu
132+
runs-on: ubuntu-latest
133+
timeout-minutes: 30
134+
steps:
135+
- name: Checkout repo @ SHA - ${{ github.sha }}
136+
uses: actions/checkout@v4
137+
138+
- name: Set up Python 3.11
139+
uses: actions/setup-python@v5
140+
with:
141+
python-version: "3.11"
142+
143+
- name: Install tox
144+
run: pip install tox-uv
145+
146+
- name: Run tests
147+
run: tox -c tox-loongsuite.ini -e py311-test-loongsuite-instrumentation-dashscope-latest -- -ra
148+
149+
py312-test-loongsuite-instrumentation-dashscope-oldest_ubuntu-latest:
150+
name: LoongSuite loongsuite-instrumentation-dashscope-oldest 3.12 Ubuntu
151+
runs-on: ubuntu-latest
152+
timeout-minutes: 30
153+
steps:
154+
- name: Checkout repo @ SHA - ${{ github.sha }}
155+
uses: actions/checkout@v4
156+
157+
- name: Set up Python 3.12
158+
uses: actions/setup-python@v5
159+
with:
160+
python-version: "3.12"
161+
162+
- name: Install tox
163+
run: pip install tox-uv
164+
165+
- name: Run tests
166+
run: tox -c tox-loongsuite.ini -e py312-test-loongsuite-instrumentation-dashscope-oldest -- -ra
167+
168+
py312-test-loongsuite-instrumentation-dashscope-latest_ubuntu-latest:
169+
name: LoongSuite loongsuite-instrumentation-dashscope-latest 3.12 Ubuntu
170+
runs-on: ubuntu-latest
171+
timeout-minutes: 30
172+
steps:
173+
- name: Checkout repo @ SHA - ${{ github.sha }}
174+
uses: actions/checkout@v4
175+
176+
- name: Set up Python 3.12
177+
uses: actions/setup-python@v5
178+
with:
179+
python-version: "3.12"
180+
181+
- name: Install tox
182+
run: pip install tox-uv
183+
184+
- name: Run tests
185+
run: tox -c tox-loongsuite.ini -e py312-test-loongsuite-instrumentation-dashscope-latest -- -ra
186+
187+
py313-test-loongsuite-instrumentation-dashscope-oldest_ubuntu-latest:
188+
name: LoongSuite loongsuite-instrumentation-dashscope-oldest 3.13 Ubuntu
189+
runs-on: ubuntu-latest
190+
timeout-minutes: 30
191+
steps:
192+
- name: Checkout repo @ SHA - ${{ github.sha }}
193+
uses: actions/checkout@v4
194+
195+
- name: Set up Python 3.13
196+
uses: actions/setup-python@v5
197+
with:
198+
python-version: "3.13"
199+
200+
- name: Install tox
201+
run: pip install tox-uv
202+
203+
- name: Run tests
204+
run: tox -c tox-loongsuite.ini -e py313-test-loongsuite-instrumentation-dashscope-oldest -- -ra
205+
206+
py313-test-loongsuite-instrumentation-dashscope-latest_ubuntu-latest:
207+
name: LoongSuite loongsuite-instrumentation-dashscope-latest 3.13 Ubuntu
208+
runs-on: ubuntu-latest
209+
timeout-minutes: 30
210+
steps:
211+
- name: Checkout repo @ SHA - ${{ github.sha }}
212+
uses: actions/checkout@v4
213+
214+
- name: Set up Python 3.13
215+
uses: actions/setup-python@v5
216+
with:
217+
python-version: "3.13"
218+
219+
- name: Install tox
220+
run: pip install tox-uv
221+
222+
- name: Run tests
223+
run: tox -c tox-loongsuite.ini -e py313-test-loongsuite-instrumentation-dashscope-latest -- -ra
224+
35225
py39-test-loongsuite-instrumentation-mem0-oldest_ubuntu-latest:
36226
name: LoongSuite loongsuite-instrumentation-mem0-oldest 3.9 Ubuntu
37227
runs-on: ubuntu-latest
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
6+
7+
## [Unreleased]
8+
9+
### Added
10+
11+
- Initial implementation of DashScope instrumentation
12+
- Support for Generation.call (sync)
13+
- Support for AioGeneration.call (async)
14+
- Support for TextEmbedding.call
15+
- Support for TextReRank.call
16+
- Support for ImageSynthesis.call (sync)
17+
- Support for ImageSynthesis.async_call (async task submission)
18+
- Support for ImageSynthesis.wait (async task waiting)
19+
- Support for streaming responses (sync and async)
20+
- Data extraction and telemetry collection using `opentelemetry-util-genai`
21+
- Span attributes following OpenTelemetry GenAI Semantic Conventions:
22+
- Operation name, provider name, model names
23+
- Token usage (input/output tokens)
24+
- Finish reasons
25+
- Request parameters (temperature, top_p, max_tokens)
26+
- Response ID
27+

0 commit comments

Comments
 (0)