Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
e28b0086
Commit
e28b0086
authored
Nov 17, 2025
by
guanyu1
Browse files
benchmark_hunyuan.py
parent
0746a2bb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
benchmarks/benchmark_hunyuan.py
benchmarks/benchmark_hunyuan.py
+11
-2
No files found.
benchmarks/benchmark_hunyuan.py
View file @
e28b0086
...
@@ -64,10 +64,19 @@ DEFAULT_PROMPT_TOKEN_IDS = [
...
@@ -64,10 +64,19 @@ DEFAULT_PROMPT_TOKEN_IDS = [
20
,
23
,
36827
,
696
,
2929
,
5232
,
82
,
8910
,
20
,
23
,
36827
,
696
,
2929
,
5232
,
82
,
8910
,
6704
,
25451
,
43032
,
127962
,
127960
,
127967
,
6704
,
25451
,
43032
,
127962
,
127960
,
127967
,
]
]
PROMPTS
=
"你是一个搜索排序专家,请你仔细阅读以下Doc和Query,给出文章满意度评分及具体原因。请注意,本次搜索时间是2024年12月22日。
\n\n
Query:sdl 概述
\n
- Query领域:游戏
\n
- 时效需求:无时效
\n
- 权威需求:中权威
\n\n
Doc内容:
\n
- 标题:【SDL实践指南】SDL基本介绍
\n
- 正文:文章前言传统的软件开发生命周期关注核心点在于需求分析、需求设计和需求编码实现,但是事实证明只注重软件业务功能设计实现而缺乏对产品安全考量的产品终将会为此而付出惨痛的代价,例如:因为缺乏对安全相关法律法规的了解,在产品业务功能实现中过度采集用户个人数据信息并将其进行滥用和不安全的存储而带来的法律追责问题和应用产品强制下架整改;因为产品发版后被攻击者恶意攻击造成系统无法正常使用而被迫强制下线进行漏洞修复等,为了规避产品上线后由于潜在的安全问题而带来的经济损失以及时间成本等问题SDL应运而生。SDL简介SDL(Security Development Lifecycle,安全开发生命周期)是由微软提出的一种从安全角度指导软件开发的管理模式,它主要通过在传统的软件开发生命周期的各个阶段穿插一系列的安全活动来保障和提升产品自身的安全能力SDL侧重于软件开发过程中的安全保证过程,旨在开发出安全的软件应
\n\n
Doc作者:
\n
- 作者名称:七芒星实验室
\n
- 作者领域:科技_信息技术
\n
- 作者认证:个人
\n\n
Doc来源:腾讯网
\n
- 平台领域:综合站点
\n
- 备案类型:企业
\n
- 平台等级:10
\n
- 权威等级:1
\n\n
Doc时间:2023年03月05日 (距今:658天)
\n\n
Query:sdl 概述"
if
__name__
==
"__main__"
:
if
__name__
==
"__main__"
:
llm
=
LLM
(
model
=
"/tools/gy_model/hunyuan_model"
,
task
=
"classify"
,
trust_remote_code
=
True
,
runner
=
"pooling"
)
llm
=
LLM
(
model
=
"/tools/gy_model/hunyuan_model"
,
task
=
"classify"
,
trust_remote_code
=
True
)
(
output
,)
=
llm
.
classify
(
token_inputs
(
DEFAULT_PROMPT_TOKEN_IDS
))
# 以列表形式传入,避免某些路径把字符串当作序列逐字符处理
(
output
,)
=
llm
.
classify
(
PROMPTS
)
probs
=
output
.
outputs
.
probs
probs
=
output
.
outputs
.
probs
print
(
f
"Class Probabilities:
{
probs
!
r
}
(size=
{
len
(
probs
)
}
)"
)
print
(
f
"Class Probabilities:
{
probs
!
r
}
(size=
{
len
(
probs
)
}
)"
)
# llm = LLM(model="/tools/gy_model/hunyuan_model", task="classify",trust_remote_code=True,runner="pooling")
# (output,) = llm.classify(token_inputs(DEFAULT_PROMPT_TOKEN_IDS))
# probs = output.outputs.probs
# print(f"Class Probabilities: {probs!r} (size={len(probs)})")
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment