songjongdevsecops/dsh-regras ↗★ 0

dsh-regras

DeepSeek Harness plugin: semantic search over the AGENTS.md and README.md rules of your workspace tree, with a tool for the agent and a command for you. 适合需要在工作区中快速检索和应用AGENTS.md等规则文件的用户。

패키지
dsh-regras
호환성
미검증
버전
0.1.1
라이선스
MIT
최근 업데이트
2026. 10. 18.

설치

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:songjongdevsecops/dsh-regras

Configuration

Every path is configurable and the defaults derive from your home directory, so nothing is tied to a specific machine. Override by environment variable, or by the config of the regras line in your profile patch. A patch replaces the whole config of the line, so restate every key you want to keep.

Config keyEnvironment variableDefaultMeaning
raizDSH_REGRAS_RAIZ~/workspacesroot of the rules tree
colecaoDSH_REGRAS_COLECAOregras-bgem3-v1memsearch collection
memsearchDSH_REGRAS_MEMSEARCH~/.local/bin/memsearchmemsearch binary
espelhoDSH_REGRAS_ESPELHO`
/.espelho, else raiz`corpus scanned by the hygiene report

The report also uses DSH_REGRAS_PY (a Python interpreter with pymilvus and numpy); by default it uses the memsearch tool environment, then python3.

Profile patch example (~/.dsh/profiles/web/cordis.patch.yml):

- id: regras
  config:
    raiz: '/home/you/rules'
    colecao: 'regras-bgem3-v1'
    memsearch: '/home/you/.local/bin/memsearch'
    espelho: '/home/you/rules'

Usage

Ask the agent a question about where something belongs, how to name it, what is forbidden, or who owns it. It calls qual_regra and gets the matching segments with their source paths.

In the chat:

/regras buscar naming          # five best rule segments
/regras higiene                # duplicate candidates, orphan paths, doc/code drift
/regras pares                  # the candidate pairs, with both texts, for review

higiene writes relatorios/-higiene/ next to the package, with relatorio.md and pares-candidatos.jsonl. The duplicate line is candidates only: embeddings measure topical proximity, not contradiction, and two opposite rules look alike in the vector space. The reader decides with both texts in hand. Nothing is rewritten: the report only reads files.