# pi-skill-recommender

`pi-skill-recommender` is a standalone Pi package that watches for repeated workflows across sessions and turns strong candidates into draft Pi skills.

The extension records lightweight observations from repeated Pi work, clusters recurring workflows, and lets you generate or promote draft skills from strong candidates.

## Command surface

The extension registers these slash commands:

- `/skill-recommender-status` — show configured paths, observation totals, and current recommender state.
- `/skill-recommender-candidates` — list recurring-workflow candidates waiting for review.
- `/skill-recommender-generate <candidate-id>` — generate a draft skill from a workflow-worthy candidate.
- `/skill-recommender-ignore <candidate-id>` — permanently suppress a candidate you do not want suggested again.
- `/skill-recommender-snooze <candidate-id>` — hide a candidate temporarily so it can resurface later.
- `/skill-recommender-promote <candidate-id>` — copy a generated draft into the maintained global skill root.

## Install

Install the published package with:

```bash
pi install npm:pi-skill-recommender
```

For local development from a checkout, install from a local clone path:

```bash
pi install /path/to/pi-skill-recommender
```

Because the package includes the `pi-package` keyword and a `pi` manifest, it is intended to be discoverable on pi.dev once published.

## Runtime paths

Generated skills will be written to:

```text
~/.pi/agent/skills/generated-by-skill-recommender/
```

Runtime state will live under:

```text
~/.pi/agent/data/pi-skill-recommender/
```

The extension manages discovery-time setup through `resources_discover`, but because generated skills already live under Pi's default global skill root you should run `/reload` after generating or promoting a skill if you want the current session to pick it up immediately.

## Package layout

This package is configured to expose extension entry points from:

```text
extensions/*.ts
```

The runtime implementation file is:

```text
extensions/skill-recommender.ts
```

## Development notes

Current package metadata follows the Pi package conventions documented in the Pi packages and extensions docs on pi.dev.

The package intentionally keeps V1 deterministic and local-first: heuristic clustering, file-backed state, template-based `SKILL.md` generation, and manual `/reload` after generate or promote.
