deeprefine

deeprefine is a skill for Claude Code from HKUST-KnowComp/DeepRefine-Skill. It costs 73 tokens per session (1,526 once invoked), scanned A, a copy of deeprefine, MIT.

An adapter for DeepRefine, a workflow for reviewing and improving Graphify or LLM-Wiki knowledge graphs. It connects that workflow to the DeepSeek Harness command-line tool.

In plain words
What is it for?
Use it to inspect, refine, repair, or review a knowledge graph, or apply a previously reviewed refinement.
Why use it?
It provides a defined process for diagnosing graph issues and pauses for review before changing graph data.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Good fit Use it to inspect, refine, repair, or review a knowledge graph, or apply a previously reviewed refinement.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hkust-knowcomp/deeprefine-skill/dsh_skill
Install

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.

Any agent
npx skills add HKUST-KnowComp/DeepRefine-Skill --skill dsh_skill
Clone the repo
git clone --depth 1 https://github.com/HKUST-KnowComp/DeepRefine-Skill

Made for: Claude Code.

Wrote 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.

agentmods badge for deeprefine

README.md
[![agentmods](https://agentmods.dev/badge/skills/hkust-knowcomp/deeprefine-skill/dsh_skill/github.svg)](https://agentmods.dev/skills/hkust-knowcomp/deeprefine-skill/dsh_skill)
Your own site
<a href="https://agentmods.dev/skills/hkust-knowcomp/deeprefine-skill/dsh_skill"><img src="https://agentmods.dev/badge/skills/hkust-knowcomp/deeprefine-skill/dsh_skill/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.

agentmods 80×15 button for deeprefine

Your own site · 80×15
<a href="https://agentmods.dev/skills/hkust-knowcomp/deeprefine-skill/dsh_skill"><img src="https://agentmods.dev/badge/skills/hkust-knowcomp/deeprefine-skill/dsh_skill.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 73 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,526 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 89% copy Near-identical to another mod in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00073 $0.01526
Opus 5.5 $0.00029 $0.00610
Sonnet 5.5 $0.00015 $0.00305
Haiku 4.5 $0.00007 $0.00153

Measured 3mo ago against content hash 905738d00195, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

deeprefine 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 3mo 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.

Origin

This is a copy

89% identical to deeprefine — 47 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

deeprefine_skill/dsh_skill/SKILL.md · 188 lines

How it starts

The opening of the file, as written. The whole thing — 188 lines — stays where its author put it; the contents beside it link to each section on GitHub.

DeepRefine - DeepSeek Harness (dsh) Adapter

This file is the dsh-specific entrypoint. It keeps the platform rules small and loads longer DeepRefine procedure details only when needed:

Do not reimplement or shorten the algorithm from memory. Load the relevant reference file before executing that part of the workflow.

dsh Invocation

Trigger this skill when the user:

  • explicitly invokes /deeprefine;
  • asks to refine, improve, diagnose, repair, inspect, or review a Graphify knowledge graph;
  • asks to apply a previously reviewed DeepRefine refinement.

Run from the knowledge-base project root, where graphify-out/graph.json exists. If the user is planning or asking how DeepRefine works, explain the workflow and do not mutate files.

If deeprefine is unavailable, tell the user to install it:

pip install deeprefine-cli

For source development:

pip install -e /path/to/DeepRefine-Skill

Hard Safety Policy

A normal /deeprefine invocation is dry-run only and MUST NEVER call deeprefine apply.

The default workflow must stop after:

  1. deeprefine loop validate
  2. deeprefine review
  3. showing the proposed actions and HIGH/MEDIUM/LOW review report to the user

Then ask for explicit approval.

Only if the user's next message explicitly says to approve/apply/write the graph may you run:

deeprefine apply --trace-file ... --refinement-file ...
deeprefine loop finish --trace-file ... --refinement-file ...

Do not treat any of these as approval:

  • generation of a <refinement> block;
  • a valid loop_trace_<query_id>.json;
  • a prior user message;
  • a successful deeprefine review.

Read the full file on GitHub · 188 lines

Files

What ships with it

3 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.

Changes

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.

  1. 3mo ago First seen · 188 lines · 73 tokens per session scan A 905738d00195

Subscribe to this mod's changes

deeprefine is a skill published in the GitHub repository HKUST-KnowComp/DeepRefine-Skill (90 stars, last pushed 3mo ago), licensed MIT. It adds 73 tokens to every session and 1,526 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 89% identical to deeprefine, differing in 47 lines, and is treated as a copy.

Related

deeprefine compared with skills from other repositories

deeprefine next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
deeprefineHKUST-KnowComp/DeepRefine-SkillSkill903mo agoMITA73Claude Code
llm-wikizosmaai/pi-llm-wikiSkill6345d agoMITA52Claude Code
binder-importmpazik/BinderSkill411mo agoMITA62Claude Code
customer_support_agentLeeroo-AI/leeroopedia-mcpSkill141mo agoMITA0Claude Code, Codex
ml_inference_optimizationLeeroo-AI/leeroopedia-mcpSkill141mo agoMITA0Claude Code, Codex
knowledge-base-interopalrcatraz/astra-knowledge-base-mcpSkill226d agoMITA56Claude Code, Codex
leeroopedia-mcpLeeroo-AI/leeroopedia-mcpSkill141mo agoMITA42Claude Code, Codex