SuperAPI AI Directory

matter-workspace

General & other

View repository

Updated 10-15 20:29

About this skill

/matter-workspace

Multi-client practitioners work across multiple clients and matters. A matter workspace isolates one client's or engagement's context from other clients or engagements. This command manages those workspaces.

Subcommands

  • /commercial-legal:matter-workspace new <slug> — Create a new matter workspace, run a brief intake interview, write matter.md
  • /commercial-legal:matter-workspace list — List matters and their statuses
  • /commercial-legal:matter-workspace switch <slug> — Set the current matter
  • /commercial-legal:matter-workspace close <slug> — Archive a matter (move to _archived/, never delete)
  • /commercial-legal:matter-workspace none — Detach from any current matter, pure practice-area-level work

Instructions

  1. Read the review guidelines — confirm that the ## 事项工作区 section is populated. If Enabled is ✗, inform the user that matter workspaces are closed — suitable for corporate legal users serving only one company. Do not error — the closed state is the expected state for corporate legal users.
  2. Use the following subcommand logic.
  3. Dispatch based on the subcommand.
  4. Show the user the changes and confirm before writing.

Notes

  • Unless 跨事项上下文 in the practice-area-level CLAUDE.md is on, skills never read files across matters.
  • Archiving is not deletion — closed matters remain readable for retention/conflicts purposes.
  • Short names use lowercase plus hyphens. If a short name is reused across archived and current matters, the archived one is retained under _archived/<slug>/ .

Multi-client practitioners (private practice — solo practice, small firm, large firm) work across multiple matters. The context of one matter must not leak to another matter.

The default state is closed. Corporate legal users will never see — they operate only at the practice-area level. The matter workspace is turned on for private-practice users at cold start, or by editing ## 事项工作区 in the review guidelines.

Storage layout

All matter data is located at:

~/.claude/plugins/config/claude-for-legal-zh/commercial-legal/
├── CLAUDE.md                       # 业务领域级审查指引
└── matters/
    ├── <slug>/
    │   ├── matter.md               # 客户、对方当事人、事项类型、关键事实、覆盖规则
    │   ├── history.md              # 日期化的事件日志
    │   ├── notes.md                # 自由形式的工作笔记
    │   └── outputs/                # 事项的技能输出(可选子文件夹)
    └── _archived/
        └── <slug>/                 # 已关闭的事项——可读但非当前

Subcommand logic

new <slug>

  1. Confirm the short name is not already taken. If taken, ask the user to choose another short name.
  2. Run the intake interview: client, opposing party, matter type, confidentiality level, key facts, matter-specific overriding rules, related matters.
  3. Write matters/<slug>/matter.md。
  4. per the template, seeding history.md。
  5. Create empty notes.md。
  6. Do not switch automatically. Ask whether to switch.

list

Enumerate matters/*/matter.md. Print a table. Mark the current matter as *。

switch <slug>

  1. Confirm matters/<slug>/matter.md exists.
  2. Edit the Active matter: line in the review guidelines.
  3. Show the user the matter.md summary.

close <slug>

  1. Confirm the folder exists.
  2. Append a "closed" entry to history.md。
  3. Move the folder to _archived/。
  4. If it is the current matter, set Active matter: to none。

none

Set Active matter: to none. Confirm with the user.

Cross-matter context

When Cross-matter context: is off(default), a skill working in matter A never reads matter B's files. When it is on , the skill reads across matters only when the user explicitly requests it.

What this skill does not do

  • Does not run conflict-of-interest checks. Conflict of interest is the practitioner's/firm's job.
  • Does not enforce retention policies. Closes the archive but does not delete.
  • Does not automatically route output. The substantive skill decides where to write; this skill tells which folder is current.