Atlas / Skills / val1813 / Refactor

RefactorSAFE

skills/val1813/refactor

一个能持续增强本地开源模型的cli,专门为本地部署模型优化的coding窗口。目前仍然处于mvp未能大规模测试和端到端跑通,欢迎指正🙏🏻🙏🏻🙏🏻

Verdict
SAFE
Grade
B
Trust score
89 /100
Version
1.0.0
Hosts
—
License
—
Stars
685
01

Overview

一个能持续增强本地开源模型的cli,专门为本地部署模型优化的coding窗口。目前仍然处于mvp未能大规模测试和端到端跑通,欢迎指正🙏🏻🙏🏻🙏🏻

Read from source at commit 55367f81de56OBSERVED · 2026-10-13
Advertisement
02

What it tells the agent

The instruction file, verbatim from the audited commit — this is the text the model reads, and the surface the audit's instruction layer examines. Quoted here so you can judge it without cloning anything.

---
name: RefactorExpert
version: 1.0.0
trigger_keywords: [重构, refactor, 去重, deduplicate, 代码重构]
trigger_min_confidence: 0.7
pipeline: [locator, generator, verifier]
lifecycle: mature
---

## 领域知识

- 每次只做一种重构,不混合多种变更,便于验证行为一致
- 代码坏味道识别:重复代码→提取函数、过长函数→拆分、深层嵌套→提前返回/卫语句
- SOLID原则:单一职责(类只做一件事)、开闭(扩展开放修改关闭)、依赖倒置(依赖抽象不依赖具体)
- 提取函数:3行以上重复代码或逻辑独立片段,命名体现意图而非实现
- 简化条件:复杂if/else链改为策略模式或查表法
- 消除魔法数字:提取为命名常量,放在文件顶部或配置中
- 参数过多(>4个):封装为数据类/字典/配置对象
- 重构前确保有测试覆盖,重构后运行测试验证行为不变
- 不改变公开API签名,除非调用方也在重构范围内
- 大范围重构分步提交:先提取→再替换调用→最后删除旧代码

## 经验规则(自动生成)
03

Trust audit

SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeNA
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
none-observed
Network
none-observed
Shell
none-observed
Dependencies
pinned
Secrets in source
none-found

Findings (1)

LOWInventory / provenance · inv.no_license · CWE-1104
Why it matters. no LICENSE file and no repo licence
Fix. add a licence

Gates applied: no_behavioural_pass, no_license.

Audited 2026-10-13 · audit v0.4.1 · source sha 55367f81de56full audit observations/trust-audit/skill/val1813__refactor.json · Report an issue / request a re-scan
04

Audit history

Every audit this skill has had.

DateSourceVerdictGradeScoreChange
2026-10-1355367f81de56SAFEB89first audit
05

Questions

What does the Refactor skill do?

一个能持续增强本地开源模型的cli,专门为本地部署模型优化的coding窗口。目前仍然处于mvp未能大规模测试和端到端跑通,欢迎指正🙏🏻🙏🏻🙏🏻

Is Refactor safe to install?

The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean skill reads B.

What can Refactor access on my machine?

The audit observed no filesystem, network or shell use at all in its source.

How current is this page?

The grade is for one exact copy of the source (55367f81de56), read on 2026-10-13. The repository is watched, and a new audit runs when it changes — this is the first audit.

Advertisement