fix(skill): 回退 description 截断缩短,保留优先级顺序+目录60
This commit is contained in:
parent
3ecb4f755c
commit
9f8534bc4e
@ -1022,7 +1022,7 @@ async def _build_role_skills_block(sor, project_id, role, org_id=""):
|
|||||||
lines = ["## 可用技能(目录,优先级 角色>项目>产线>组织>通用)"]
|
lines = ["## 可用技能(目录,优先级 角色>项目>产线>组织>通用)"]
|
||||||
for s in others[:60]:
|
for s in others[:60]:
|
||||||
tag = SCOPE_TAG.get(getattr(s, 'scope', ''), getattr(s, 'scope', ''))
|
tag = SCOPE_TAG.get(getattr(s, 'scope', ''), getattr(s, 'scope', ''))
|
||||||
lines.append(f"- [{tag}] {s.name}: {(s.description or '')[:60]}")
|
lines.append(f"- [{tag}] {s.name}: {(s.description or '')[:100]}")
|
||||||
blocks.append("\n".join(lines))
|
blocks.append("\n".join(lines))
|
||||||
return "\n\n".join(blocks)
|
return "\n\n".join(blocks)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user