TEngine is a Unity framework for building games, providing modules for asynchronous work, hot updates, asset management, configuration tables, and user interfaces. It is for Unity developers and teams making commercial projects across desktop, mobile, web, and WeChat Mini Game targets, with catalogue skills supporting its AI-assisted development workflow.
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 Alex-Rachel/TEngine --skill improve-codebase-architecturegit clone --depth 1 https://github.com/Alex-Rachel/TEngineWrote 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/alex-rachel/tengine/improve-codebase-architecture)<a href="https://agentmods.dev/skills/alex-rachel/tengine/improve-codebase-architecture"><img src="https://agentmods.dev/badge/skills/alex-rachel/tengine/improve-codebase-architecture/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/alex-rachel/tengine/improve-codebase-architecture"><img src="https://agentmods.dev/badge/skills/alex-rachel/tengine/improve-codebase-architecture.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.00069 | $0.01682 |
| Opus 5 | $0.00034 | $0.00841 |
| Sonnet 5 | $0.00014 | $0.00336 |
| Haiku 4.5 | $0.00007 | $0.00168 |
Grade A, and why
improve-codebase-architecture 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 9d 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 — 82 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Improve Codebase Architecture
暴露架构摩擦并提出加深机会——将浅模块变为深模块的重构。目标是可测试性和 AI 可导航性。
术语表
在每个建议中精确使用这些术语。一致的语言是关键——不要滑向"component"、"service"、"API"或"boundary"。完整定义见 LANGUAGE.md。
- Module(模块) — 任何具有接口和实现的东西(函数、类、包、切片)。
- Interface(接口) — 调用者使用模块所需知道的一切:类型、不变量、错误模式、顺序、配置。不仅仅是类型签名。
- Implementation(实现) — 内部的代码。
- Depth(深度) — 接口处的杠杆:少量接口背后的大量行为。Deep(深) = 高杠杆。Shallow(浅) = 接口几乎与实现一样复杂。
- Seam(接缝) — 接口所在的位置;一个可以在不原地编辑的情况下改变行为的地方。(使用这个词,不是"boundary"。)
- Adapter(适配器) — 在接缝处满足接口的具体实现。
- Leverage(杠杆) — 调用者从深度中获得的收益。
- Locality(局部性) — 维护者从深度中获得的收益:变更、bug、知识集中在一个地方。
关键原则(完整列表见 LANGUAGE.md):
- 删除测试:想象删除该模块。如果复杂性消失了,那它就是传递模块。如果复杂性重新出现在 N 个调用者身上,那它就在发挥价值。
- 接口就是测试面。
- 一个适配器 = 假设的接缝。两个适配器 = 真正的接缝。
本技能依据项目的领域模型。领域语言为好的接缝命名;ADR 记录本技能不应重新争论的决策。
流程
1. 探索
首先阅读项目的领域术语表和你将涉及区域中的任何 ADR。
然后使用 Agent 工具配合 subagent_type=Explore 来遍历代码库。不要遵循死板的经验法则——有机地探索,并记录你感受到摩擦的地方:
- 哪里理解一个概念需要在许多小模块之间来回跳转?
- 哪里模块是浅的——接口几乎与实现一样复杂?
- 哪里提取了纯函数仅仅为了可测试性,但真正的 bug 隐藏在调用方式中(没有局部性)?
- 哪里紧耦合的模块跨接缝泄漏?
- 代码库的哪些部分未被测试,或难以通过当前接口进行测试?
对你怀疑是浅模块的任何东西应用删除测试:删除它会让复杂性集中,还是仅仅移动它?"是的,集中了"就是你要的信号。
2. 以 HTML 报告呈现候选
将一个自包含的 HTML 文件写入操作系统临时目录,这样不会在仓库中留下任何东西。从 $TMPDIR 解析临时目录,回退到 /tmp(Windows 上是 %TEMP%),写入 <tmpdir>/architecture-review-<timestamp>.html,这样每次运行都会得到一个新文件。为用户打开它——Linux 上用 xdg-open <path>,macOS 上用 open <path>,Windows 上用 start <path>——并告诉他们绝对路径。
报告使用 Tailwind via CDN 进行布局和样式,使用 Mermaid via CDN 绘制图表,当图/流程/时序能可靠传达结构时使用。将 Mermaid 与手工 CSS/SVG 视觉混合使用——当关系呈图状(调用图、依赖、序列)时使用 Mermaid,当你想要更偏编辑性质的视觉(质量图、剖面图、折叠动画)时使用手工 div/SVG。每个候选都有一个 before/after 可视化。要视觉化。
对于每个候选,使用与之前相同的模板,但渲染为卡片:
- 文件 — 涉及哪些文件/模块
- 问题 — 当前架构为什么造成摩擦
- 方案 — 什么会改变的通俗描述
- 收益 — 用局部性和杠杆解释,以及测试将如何改善
- Before / After 图 — 并排,自定义绘制,展示浅性和加深
- 建议强度 —
Strong、Worth exploring、Speculative之一,渲染为徽章
报告末尾以 顶部建议 章节结束:你建议先处理哪个候选以及原因。
领域使用 CONTEXT.md 词汇,架构使用 LANGUAGE.md 词汇。 如果 CONTEXT.md 定义了"Order",就说"the Order intake module"——不是"the FooBarHandler",也不是"the Order service"。
What ships with it
4 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.
- 9d ago First seen · 82 lines · 69 tokens per session scan A ed420256b574
improve-codebase-architecture is a skill published in the GitHub repository Alex-Rachel/TEngine (2,330 stars, last pushed 29d ago), licensed MIT. It adds 69 tokens to every session and 1,682 once invoked, about $0.0003 per session on Opus 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-08-30.
Other skills, from other repositories
red-team-review
Unified adversarial review: v4.3 Strategic Matrix (MTA-004). 7-phase framework: Priors → Rubric → Adversarial Lenses → SWOT/TOWS → MCDA Decision Engine → Blind Spot/Kill Switch → Executive Summary. Absorbs: bias-detector.
decision-journal
Unified decision lifecycle: Pre-decision logging, post-decision review, failure classification, and calibration tracking. Absorbs: post-mortem-engine.
Smart Code Review
Review a PR diff: triage its severity, then produce a depth-appropriate review with structured findings, fix suggestions, and a merge decision. Use for code review, review PR, and severity triage requests.
godot-code-review
Use when reviewing GDScript or C# Godot code — checklist of best practices, common anti-patterns, and Godot-specific pitfalls.
et-excel
ET Excel MCP workflow for reading, writing, styling, transforming, and inspecting xlsx data. Use when operating Excel cells, ranges, sheets, formulas, charts, merges, batch data import/export, or editing Luban source spreadsheets before export.
et-test-run
ET test execution and failure debugging workflow for WOW. Use when building before tests, cleaning Logs, running server or Hotfix tests through ET.App Test commands, running Unity Editor tests through UnityBridge UnityTestRunRequest, reading Logs/All.log, judging results, and diagnosing failed or unmatched tests.