မေးလေ့ရှိသော မေးခွန်းများ
PRECC ကို သုံးရန် လုံခြုံပါသလား?
ဟုတ်ကဲ့။ PRECC သည် Claude Code ၏ တရားဝင် PreToolUse hook ယန္တရားကို အသုံးပြုသည်။ Hook သည်:
- အင်တာနက်မလိုဘဲ အပြည့်အဝ လုပ်ဆောင်သည်
- 5 မီလီစက္ကန့်အတွင်း ပြီးစီးသည်
- Fail-open ဖြစ်သည်: ပြဿနာတစ်ခုခု ဖြစ်ပေါ်ပါက မူလ ကွန်မန်းသည် မပြောင်းလဲဘဲ လုပ်ဆောင်သည်
- ကွန်မန်းများကိုသာ ပြင်ဆင်ပြီး ကိုယ်တိုင် မလုပ်ဆောင်ပါ
- ဒေတာကို SQLite တွင် ဒေသတွင်း သိမ်းဆည်းသည်
PRECC သည် အခြား AI ကုဒ်ရေးသည့် ကိရိယာများနှင့် အလုပ်လုပ်ပါသလား?
PRECC ကို Claude Code အတွက် အထူးသဖြင့် ဒီဇိုင်းထုတ်ထားသည်။ Cursor၊ Copilot၊ Windsurf သို့မဟုတ် အခြား AI ကုဒ်ရေးသည့် ကိရိယာများနှင့် အလုပ်မလုပ်ပါ။
အဝေးမှတိုင်းတာခြင်းက ဘာဒေတာ ပေးပို့သလဲ?
အဝေးမှတိုင်းတာခြင်းသည် ရွေးချယ်မှသာ ဖြစ်သည်။ ဖွင့်ထားသောအခါ ပေးပို့သည်:
- PRECC ဗားရှင်း၊ OS နှင့် ဗိသုကာ
- စုစုပေါင်း အရေအတွက်များ
- ပျမ်းမျှ hook ကြန့်ကြာချိန်
ကွန်မန်းစာသား၊ ဖိုင်လမ်းကြောင်းများ သို့မဟုတ် ကိုယ်ရေးကိုယ်တာ သတင်းအချက်အလက် ပေးပို့ခြင်း မရှိပါ။
PRECC ကို ဘယ်လို ဖယ်ရှားမလဲ?
PRECC is fully reversible — remove it in three steps:
-
Hook မှတ်ပုံတင်ခြင်း ဖယ်ရှားရန်:
# Delete the hook entry from Claude Code's settings # (precc init added it; removing it disables PRECC) -
Binary ဖိုင် ဖယ်ရှားရန်:
rm ~/.local/bin/precc ~/.local/bin/precc-hook ~/.local/bin/precc-learner -
ဒေတာ ဖယ်ရှားရန် (ရွေးချယ်နိုင်):
rm -rf ~/.local/share/precc/ rm -rf ~/.config/precc/
ကျွန်ုပ်၏ လိုင်စင် သက်တမ်းကုန်သွားပါပြီ။ ဘာဖြစ်မလဲ?
PRECC သည် Community အဆင့်သို့ ပြန်သွားသည်။ အဓိက လုပ်ဆောင်ချက်များ ဆက်လုပ်ဆောင်သည်:
- Built-in ကျွမ်းကျင်မှုများ အသက်ဝင်နေဆဲ
- Hook pipeline ပုံမှန် လုပ်ဆောင်သည်
Pro လုပ်ဆောင်ချက်များ သက်တမ်းတိုးသည်အထိ မရရှိနိုင်ပါ။
Hook အလုပ်မလုပ်သလို ဖြစ်နေသည်။ ဘယ်လို debug လုပ်မလဲ?
Run precc doctor first — it automates every check below. To diagnose by hand:
-
Hook မှတ်ပုံတင်ထားသလား စစ်ဆေးပါ:
precc init -
Hook ကို ကိုယ်တိုင် စမ်းသပ်ပါ:
echo '{"tool_input":{"command":"cargo build"}}' | precc-hook -
Binary ဖိုင် PATH ထဲတွင် ရှိမရှိ စစ်ဆေးပါ:
which precc-hook -
~/.claude/settings.jsonရှိ Claude Code hook ဖွဲ့စည်းပုံကို စစ်ဆေးပါ။
PRECC က Claude Code ကို နှေးစေပါသလား?
မဟုတ်ပါ။ Hook သည် 5 မီလီစက္ကန့်အတွင်း ပြီးစီးသည်။
CI/CD တွင် PRECC ကို သုံးနိုင်ပါသလား?
PRECC ကို interactive Claude Code session များအတွက် ဒီဇိုင်းထုတ်ထားသည်။ CI/CD တွင် precc gha သည် GitHub Actions ကို ခွဲခြမ်းစိတ်ဖြာနိုင်သည်။
ရှာဖွေတွေ့ရှိသော ကျွမ်းကျင်မှုများသည် built-in ကျွမ်းကျင်မှုများနှင့် ဘယ်လို ကွာခြားသလဲ?
Built-in ကျွမ်းကျင်မှုများသည် PRECC နှင့်အတူ ပါဝင်ပြီး ဘုံ wrong-directory ပုံစံများကို ကာမိသည်။ Mined ကျွမ်းကျင်မှုများသည် သင့် session log များမှ သင်ယူသည်။
အဖွဲ့နှင့် ကျွမ်းကျင်မှုများ မျှဝေနိုင်ပါသလား?
ဟုတ်ကဲ့။ precc skills export NAME ဖြင့် TOML သို့ export လုပ်ပြီး ဖိုင်ကို မျှဝေနိုင်သည်။
Why do I see zero tokens saved?
If precc savings reports 0 tokens despite an active Claude Code session burning input/output tokens, the hook is not firing. Three causes account for almost every reported instance:
-
You are on v0.3.42 or v0.3.43. These releases shipped a data-path regression where the hook wrote metrics to a directory that the CLI then read from a different directory — both ran, but the savings number stayed at 0. Fixed in v0.3.44 (data paths routed through
db::data_dir()). Upgrade with:precc update -
Your
settings.jsonis missing the hook entry. Runprecc doctor(available in v0.3.53+). It checks each precondition of the hot path — settings file, hook entry, binary on$PATH, heuristics DB, recent invocations — and reports the first one that fails:precc doctorIf doctor is not available because you are on an older release, run
precc initto (re)register the hook. -
Your session has not yet hit a skill trigger. PRECC only intercepts Bash commands matching one of the active skills. If your session has been pure file editing or pure web fetching against domains not covered by
webfetch-opencli, you have not yet given the hook anything to compress or rewrite. This is normal. Runprecc skills listto see what triggers exist.
If after upgrading and running precc doctor you still see zero savings, file an issue at https://github.com/peri-a-i/precc-cc/issues with the output of precc doctor.
My MCP server (e.g. lean-ctx) is pegging CPU. How do I kill it safely without taking Claude Code down with it?
PRECC does not ship or supervise MCP servers — but this is a recurring trap because some MCP binaries (notably lean-ctx) are also invoked as per-Bash-tool-call wrappers by the Claude Code harness, not just as long-running servers. A naive pkill <name> then matches many short-lived wrappers in addition to the server.
Identify the runaway PID, do not kill by name:
pgrep -f "^lean-ctx$" \
| xargs -I{} ps -o pid,%cpu,etime,args -p {} \
| sort -k2 -nr | head -3
The top row is the long-running server (large etime, high %cpu). Send SIGTERM to only that PID:
kill -TERM <pid>
Avoid these forms, all of which can also kill Claude Code or break in-flight tool calls:
pkill lean-ctx— matches transientlean-ctx -c <cmd>wrappers spawned per Bash tool call.pkill -9 -f lean-ctx— same broad match, plus ungraceful exit leaves the MCP stdio half-open.pkill -g <pgid>/kill -- -<pgid>— kills the whole process group, which includesclaudeitself when the MCP server shares a session with it.
If after a clean SIGTERM the server does not exit within a few seconds, escalate with kill -KILL <pid> on the same single PID (still not by name). Claude Code will lose those MCP tools until you restart it; it should not exit on its own.
This advice is independent of PRECC — but PRECC users frequently run lean-ctx, so it is worth documenting here.
What is OpenCLI and do I need it?
OpenCLI is a third-party Node.js tool that turns ~148 websites into structured-output CLI commands (opencli hackernews top, opencli reddit search <q>, opencli arxiv search <q>, …). PRECC ships two built-in skills that work with it:
webfetch-opencli-hint— fires oncurl/wget/http/fetchagainst any of 11 OpenCLI-supported domains andsuggest_fix-es the equivalentopencli <site> …command. Suggestion only; never modifies the command.webfetch-opencli-hackernews— auto-rewritescurl|wget news.ycombinator.comtoopencli hackernews topwith an inlinecommand -v openclifallback to the original command if OpenCLI isn’t installed.
You don’t need OpenCLI for PRECC to work. The hint skill costs nothing; the auto-rewrite skill is safe to ship default-on because of the fallback.
If you want OpenCLI’s WebFetch token savings, install it with:
precc init --opencli
That runs npm install -g @jackwener/opencli (Node.js 20+ required). For cookie-reuse on logged-in pages, also install OpenCLI’s Chrome extension separately — see the project README. The extension requests broad permissions (debugger, <all_urls>, cookies); review them before installing.
precc doctor reports OpenCLI’s presence on $PATH as an informational line:
i opencli: installed (webfetch-opencli skills will auto-rewrite)
or
i opencli: not installed (run `precc init --opencli` if you want WebFetch token savings)
Never marks doctor as failing — the integration is fully opt-in.