Bto Optimize Mac logo

Bto Optimize Mac

Community
sonpiaz
bto-optimize-mac

Đo trước rồi mới dọn RAM và ổ đĩa trên macOS một cách an toàn. Cache sinh lại được thì tự dọn; dữ liệu cá nhân thì liệt kê ra để bạn duyệt; không bao giờ kill process bừa. Dùng khi ổ đĩa đầy, RAM cao (memory pressure), máy chậm, hoặc trước khi chạy build nặng. Gọi bằng "dọn máy", "ổ đĩa đầy", "tối ưu RAM", "optimize mac".

Overview

Publishersonpiaz
Repositorybto-skills
Skill namebto-optimize-mac
Stars
29
Forks
22
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by sonpiaz on GitHub. Read the source before you install it.

Installation

Install the Bto Optimize Mac AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/sonpiaz/bto-skills/tree/main/bto-optimize-mac
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/sonpiaz/bto-skills.git /tmp/bto-skills
mkdir -p .claude/skills
cp -r /tmp/bto-skills/bto-optimize-mac .claude/skills/bto-optimize-mac
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Bto Optimize Mac in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Bto Optimize Mac on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Bto Optimize Mac is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

/bto-optimize-mac

Playbook for developers running multiple agents, local servers, and large node_modules trees.

Hard rules

  • No pkill -f, killall, or kill-by-port. Only stop PIDs you started.
  • Check "in use" before deleting any directory: pgrep -fl -- "<path>" and lsof -a -d cwd -Fn | grep -F "n<path>". If something is using it → skip and log why.
  • Do not delete personal data until the owner picks each item from a table.
  • Do not run unknown scripts with guessed flags — read the script first.
  • No git config. Do not remove worktrees with uncommitted or unpushed work.
  • Re-measure at delete time — do not reuse stale numbers from earlier in the session.

1. Measure

bash
df -k /System/Volumes/Data | awk 'NR==2{printf "%.1f GB free\n", $4/1048576}'
du -xsh ~/* ~/.[!.]* 2>/dev/null | sort -h | tail -30
du -xsh ~/Library/Caches ~/Library/Developer 2>/dev/null | sort -h | tail -20
du -sh /private/tmp/claude-*/*/* 2>/dev/null | sort -h | tail -12   # if using Claude Code

For each large node_modules: print git -C <repo> log -1 --format=%cr to see if the repo is still active.

RAM: memory_pressure, top -o mem -stats pid,command,mem. Prefer footprint over RSS on Apple Silicon when available.


2. Safe auto-clean (regenerable)

TargetCommand
npm cacherm -rf ~/.npm/_cacache ~/.npm/_npx
bun cacherm -rf ~/.bun/install/cache
Yarn / uv / piprm -rf ~/Library/Caches/Yarn ~/.cache/uv ~/Library/Caches/pip
Xcoderm -rf ~/Library/Developer/Xcode/DerivedData; xcrun simctl delete unavailable
SwiftPMrm -rf ~/Library/Caches/org.swift.swiftpm
Stale agent temp dirsOnly dirs whose session transcript has not changed in >24h; never touch active sessions
Merged worktree depsRemove node_modules / .next in worktrees whose branch is merged; keep worktree + branch

Keep: browser automation caches (ms-playwright, puppeteer) if you use them.


3. List for human approval (one table, one pass)

  • node_modules in repos touched in the last 30 days.
  • Docker/Colima VM (deleting loses images/volumes).
  • Large app bundles that re-download on demand (e.g. IDE VM bundles) — skip if VM is running.
  • iOS simulators — prefer xcrun simctl erase <udid> for powered-off devices.
  • Test browser profiles (deleting loses login).
  • Downloads: installers (.dmg), exports — only mark duplicates after cmp -s proves byte-identical.
  • Another agent's worktree — ask that session to remove it.

4. Never touch without explicit approval

Project transcripts (~/.claude/projects), photos, main browser profiles, password keychain, primary production checkout, board/source trees you depend on, latest app backups.


5. RAM

  • Do not kill other people's terminal sessions or IDE windows.
  • Orphan processes: only suggest reclaim after confirming the parent exited.
  • One process >8 GB is suspicious (often a runaway search). Find the parent before suggesting kill.
  • App memory leaks: human restarts the app when panes have saved state.

6. Report

  • Free GB before → after.
  • Deleted list with sizes.
  • Skipped list with reasons.
  • Approval table for personal data.

If an incident occurred, add one rule to the project's lessons.md.

Frequently asked questions

What does the Bto Optimize Mac AI skill do?

Đo trước rồi mới dọn RAM và ổ đĩa trên macOS một cách an toàn. Cache sinh lại được thì tự dọn; dữ liệu cá nhân thì liệt kê ra để bạn duyệt; không bao giờ kill process bừa. Dùng khi ổ đĩa đầy, RAM cao (memory pressure), máy chậm, hoặc trước khi chạy build nặng. Gọi bằng "dọn máy", "ổ đĩa đầy", "tối ưu RAM", "optimize mac".

Why use Bto Optimize Mac on TypingMind?

Because you install it once and use it with any model. Bto Optimize Mac is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Bto Optimize Mac in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/sonpiaz/bto-skills/tree/main/bto-optimize-mac. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Bto Optimize Mac?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Bto Optimize Mac?

As many as you like. As long as a model supports skills, you can use Bto Optimize Mac with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Bto Optimize Mac AI skill free?

Yes. It is published on GitHub by sonpiaz under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇