Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add agentsope/SkillAlchemy --skill agentsop-trajectory-to-semantic-opsgit clone --depth 1 https://github.com/agentsope/SkillAlchemyWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/agentsope/skillalchemy/agentsop-trajectory-to-semantic-ops)<a href="https://agentmods.dev/skills/agentsope/skillalchemy/agentsop-trajectory-to-semantic-ops"><img src="https://agentmods.dev/badge/skills/agentsope/skillalchemy/agentsop-trajectory-to-semantic-ops/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/agentsope/skillalchemy/agentsop-trajectory-to-semantic-ops"><img src="https://agentmods.dev/badge/skills/agentsope/skillalchemy/agentsop-trajectory-to-semantic-ops.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00126 | $0.03380 |
| Opus 5.5 | $0.00050 | $0.01352 |
| Sonnet 5.5 | $0.00025 | $0.00676 |
| Haiku 4.5 | $0.00013 | $0.00338 |
Grade A, and why
agentsop-trajectory-to-semantic-ops scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 205 lines — stays where its author put it; the contents beside it link to each section on GitHub.
执行轨迹 → 语义算子 提炼 SOP
一句话:把 agent 的一次运行轨迹(动作 + 观察 + 退出码 + 分数)压成「失败证据」,再把它翻译成带数据语义约束的可复用算子——不是把轨迹原样塞回提示词,而是提炼出「为什么这一步会错」的跨任务决策规则。
1. 何时激活本技能
下列任一情形成立时,按本 SOP 进入「轨迹提炼」工作模式:
- 你手里有一批 agent 运行产物:
trajectory.json(结构化动作流)、agent_trace.txt(可读的「动作 → 观察」)、results.jsonl(逐题分数/失败原因)。 - 你要从失败里长出新技能,或让一个现有数据科学技能在某类操作上不再重复犯错。
- 你在跑 SkillOpt(或类似轨迹优化器),需要把历史轨迹喂进去,但不希望污染技能正文。
- 你关心的是跨任务可复用的操作知识,而不是某一题的具体答案。
不应激活的反面信号:见 §6 反模式与边界。
2. 核心心智模型
2.1 先分清三个「技能/算子」概念
| 概念 | 作用 | 你该提取的是哪一层 |
|---|---|---|
| LOTUS 式语义算子 | 用自然语言描述数据变换,交由执行计划实现 | 不能因名字叫 sem_join 就继承其语义模型 |
| 任务能力分类(AgenticDataBench skills) | 用操作模式标注/组织任务 | 是能力标签,不等于可直接加载的运行时技能 |
| SKILL.md 运行时技能 | 执行时提供流程、知识、代码与资源 | 这是承载形式;贡献来自其中的机制 |
一句话:语义算子的价值,是保存「跨任务可复用的决策约束」,并让相邻操作能检查它们——不是把某条管线的实现代码当知识。
2.2 执行轨迹的真实结构
一条轨迹是 agent 动作的时间序列表(AgenticDataBench 实测格式):
{"kind":"message","content":"..."}
{"kind":"command","command":"bash -lc 'python3 - ...'","exit_code":0,"output":"..."}
{"kind":"command","command":"bash -lc '...'","exit_code":1,"output":"SyntaxError: ..."}
三个铁律:
exit_code是失败信号,不是全部。exit≠0的步是「哪里断了」;但exit=0的步也可能错在语义(算对但口径错)。message是 agent 的自我叙述,不是事实。它说「已完成」不等于产物正确;要拿命令/观察/分数交叉核对。output是观察:WROTE output.csv ROWS 10这种回读自检,比一句「完成」可信得多。
2.3 语义算子的五字段模板
每个算子至少记录这五样(缺一不可):
| 组成 | 具体内容 |
|---|---|
| 适用条件 | 什么输入/状态下该用这个算子 |
| 输入语义 | 每行代表什么、连接键、键是否唯一、时间粒度、缺失键策略 |
| 操作决策 | 是否确需模糊匹配、阈值从哪来、一对多是否允许、未匹配如何处理 |
| 输出约束 | 输出粒度、键关系、连接覆盖率、行数变化、新增缺失值 |
| 验证与修复 | 键碰撞、多对多扩增、错误匹配;按失败类别读取对应修复说明 |
2.4 八类「容易出错」的操作族
先只挑 6–10 个高频且确实易错的操作族做原型:entity alignment(实体对齐)、join cardinality(连接基数)、grouped/window statistics(分组/窗口统计)、time alignment(时间对齐)、missingness(缺失)、unit handling(量纲)、train/test transformation(训练/测试转换)、artifact validation(产物校验)。
反例:join 后行数变化本身不能判错——一对多可能正是任务要求。检查器必须对照事先绑定的期望关系;没证据时给出「未验证」,不套统一规则。
3. SOP 工作流(轨迹 → 算子)
Phase 1 — 收料(collect)
收集最近 N 轮的 results.jsonl(分数/失败原因)+ 每条轨迹。只收,不改。缺了分数只剩轨迹,等于只有症状没有诊断。
Phase 2 — 压迹(trajectory → text)
What ships with it
7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 205 lines · 126 tokens per session scan A 1201b4ba3499
agentsop-trajectory-to-semantic-ops is a skill published in the GitHub repository agentsope/SkillAlchemy (513 stars, last pushed 22d ago), licensed MIT. It adds 126 tokens to every session and 3,380 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-25.
agentsop-trajectory-to-semantic-ops compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| agentsop-trajectory-to-semantic-opsagentsope/SkillAlchemy | Skill | 513 | 22d ago | MIT | A | 126 | Claude Code, Codex |
| kaggleshepsci/kaggle-skill | Skill | 116 | today | MIT | A | 100 | Claude Code |
| karpathy-llm-wikiAstro-Han/karpathy-llm-wiki | Skill | 2.8k | 4mo ago | MIT | A | 67 | Claude Code, Codex |
| shellgamesMemTensor/skills-vote | Skill | 309 | 2mo ago | MIT | A | 103 | Claude Code, Codex |
| local-ai-modelsmintuz/skills | Skill | 38 | 5d ago | MIT | A | 97 | Claude Code |
| curl-searchMemTensor/skills-vote | Skill | 309 | 2mo ago | MIT | A | 55 | Claude Code, Codex |
| skills-vote-localMemTensor/skills-vote | Skill | 309 | 2mo ago | MIT | A | 28 | Claude Code, Codex |