Skip to content

feat(skill): add /pramana skill with subcommands over MCP primitives #243

Description

@sarath-soman

Motivation

Pramana's primary interaction surface is MCP (from Claude Code) + CLI. MCP tools are already exposed (`list-tenants`, `get`, `search`, `traverse`, `list`), but invoking them mechanically one-at-a-time through the MCP layer misses useful orchestrations: a search that auto-opens the top hit, a "show me everything about X" that runs get + traverse + formatted summary, tenant mounts/reloads, doctor output, etc.

A single `/pramana` skill with dispatch-style subcommands gives one clear entry point, reduces skill sprawl, and keeps the surface discoverable.

Structure

One skill file at `.claude/skills/pramana/SKILL.md` (lives in pramana-ops repo; surfaces in pramana/.claude/skills/pramana/ via the existing symlink). Dispatches on first argument:

```
/pramana [args...]
```

Subcommand Wraps Purpose
`tenants` MCP `list-tenants` List available KBs with artifact counts
`get [section]` MCP `get` Fetch one artifact
`search ` MCP `search` Rank-ordered search
`list [--tags a,b]` MCP `list` List artifacts, optionally filtered
`traverse [--type T] [--depth N]` MCP `traverse` Walk relationships
`explore ` get + traverse, formatted Single-turn deep dive on one artifact
`doctor [--tenant T]` CLI `pramana doctor` Integrity diagnostics
`reload ` CLI `pramana reload` Reload a tenant from disk
`lint [--tenant T]` CLI `pramana lint` Lint knowledge sources
`daemon status` / `daemon start` / `daemon stop` CLI `pramana serve` + HTTP health Daemon lifecycle
`config` CLI `pramana config` passthrough Tenant mounts/edits
`version` CLI `pramana version` Version info

Default subcommand (no args or unrecognized) → print a menu of available subcommands and 1-line descriptions.

Skill file layout

```
.claude/skills/pramana/
├── SKILL.md # entry; dispatcher; describes subcommands
├── references/
│ ├── tenants.md # how to read the list-tenants output
│ ├── search.md # ranking semantics, query syntax
│ ├── traverse.md # relationship types, depth safety
│ ├── explore.md # orchestration recipe for the composite subcommand
│ ├── doctor.md # interpreting doctor JSON
│ ├── daemon.md # start/stop, health endpoints
│ └── config.md # mounting tenants
└── commands/ # optional: per-subcommand prompts if they grow
```

Behaviour rules

  • Every subcommand that reads from a tenant takes `` as its first positional after the verb, mirroring CLI shape.
  • When MCP is available in the session, prefer it over shelling out. Fall back to `pramana ` via Bash only for surfaces MCP doesn't expose (doctor, reload, lint, daemon, config).
  • `/pramana` with no args: print the subcommand menu; don't guess intent.
  • Don't silently mutate state. `config`, `reload`, `daemon start/stop` should confirm before acting.
  • Output formatting: render MCP JSON as human-readable markdown tables/sections in the conversation. Raw JSON only on explicit `--json` or `--raw`.

Out of scope (separate skills / tickets)

Acceptance

  • `/pramana` dispatch works for every subcommand listed above
  • Each subcommand has a one-page reference under `references/`
  • Invoking `/pramana tenants` in a fresh Claude conversation returns the live tenant list via MCP (no shell)
  • `/pramana explore ` returns a single formatted summary that includes the artifact body, its outbound relationships, and its inverse-relationships, without requiring the user to chain calls manually
  • SKILL.md is short (< 200 lines); deep content lives in `references/`

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions