@phren/cli 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +590 -0
- package/mcp/dist/capabilities/cli.js +61 -0
- package/mcp/dist/capabilities/index.js +15 -0
- package/mcp/dist/capabilities/mcp.js +61 -0
- package/mcp/dist/capabilities/types.js +57 -0
- package/mcp/dist/capabilities/vscode.js +61 -0
- package/mcp/dist/capabilities/web-ui.js +61 -0
- package/mcp/dist/cli-actions.js +302 -0
- package/mcp/dist/cli-config.js +580 -0
- package/mcp/dist/cli-extract.js +305 -0
- package/mcp/dist/cli-govern.js +371 -0
- package/mcp/dist/cli-graph.js +169 -0
- package/mcp/dist/cli-hooks-citations.js +44 -0
- package/mcp/dist/cli-hooks-context.js +56 -0
- package/mcp/dist/cli-hooks-globs.js +83 -0
- package/mcp/dist/cli-hooks-output.js +130 -0
- package/mcp/dist/cli-hooks-retrieval.js +2 -0
- package/mcp/dist/cli-hooks-session.js +1402 -0
- package/mcp/dist/cli-hooks.js +350 -0
- package/mcp/dist/cli-namespaces.js +989 -0
- package/mcp/dist/cli-ops.js +253 -0
- package/mcp/dist/cli-search.js +407 -0
- package/mcp/dist/cli.js +108 -0
- package/mcp/dist/content-archive.js +278 -0
- package/mcp/dist/content-citation.js +391 -0
- package/mcp/dist/content-dedup.js +622 -0
- package/mcp/dist/content-learning.js +472 -0
- package/mcp/dist/content-metadata.js +186 -0
- package/mcp/dist/content-validate.js +462 -0
- package/mcp/dist/core-finding.js +54 -0
- package/mcp/dist/core-project.js +36 -0
- package/mcp/dist/core-search.js +50 -0
- package/mcp/dist/data-access.js +400 -0
- package/mcp/dist/data-tasks.js +821 -0
- package/mcp/dist/embedding.js +344 -0
- package/mcp/dist/entrypoint.js +387 -0
- package/mcp/dist/finding-context.js +172 -0
- package/mcp/dist/finding-impact.js +181 -0
- package/mcp/dist/finding-journal.js +122 -0
- package/mcp/dist/finding-lifecycle.js +259 -0
- package/mcp/dist/governance-audit.js +22 -0
- package/mcp/dist/governance-locks.js +96 -0
- package/mcp/dist/governance-policy.js +648 -0
- package/mcp/dist/governance-scores.js +355 -0
- package/mcp/dist/hooks.js +449 -0
- package/mcp/dist/impact-scoring.js +22 -0
- package/mcp/dist/index-query.js +168 -0
- package/mcp/dist/index.js +205 -0
- package/mcp/dist/init-config.js +336 -0
- package/mcp/dist/init-preferences.js +62 -0
- package/mcp/dist/init-setup.js +1305 -0
- package/mcp/dist/init-shared.js +29 -0
- package/mcp/dist/init.js +1730 -0
- package/mcp/dist/link-checksums.js +62 -0
- package/mcp/dist/link-context.js +257 -0
- package/mcp/dist/link-doctor.js +591 -0
- package/mcp/dist/link-skills.js +212 -0
- package/mcp/dist/link.js +596 -0
- package/mcp/dist/logger.js +15 -0
- package/mcp/dist/machine-identity.js +38 -0
- package/mcp/dist/mcp-config.js +254 -0
- package/mcp/dist/mcp-data.js +315 -0
- package/mcp/dist/mcp-extract-facts.js +78 -0
- package/mcp/dist/mcp-extract.js +133 -0
- package/mcp/dist/mcp-finding.js +557 -0
- package/mcp/dist/mcp-graph.js +339 -0
- package/mcp/dist/mcp-hooks.js +256 -0
- package/mcp/dist/mcp-memory.js +58 -0
- package/mcp/dist/mcp-ops.js +328 -0
- package/mcp/dist/mcp-search.js +628 -0
- package/mcp/dist/mcp-session.js +651 -0
- package/mcp/dist/mcp-skills.js +189 -0
- package/mcp/dist/mcp-tasks.js +551 -0
- package/mcp/dist/mcp-types.js +7 -0
- package/mcp/dist/memory-ui-assets.js +6 -0
- package/mcp/dist/memory-ui-data.js +513 -0
- package/mcp/dist/memory-ui-graph.js +1910 -0
- package/mcp/dist/memory-ui-page.js +353 -0
- package/mcp/dist/memory-ui-scripts.js +1387 -0
- package/mcp/dist/memory-ui-server.js +1218 -0
- package/mcp/dist/memory-ui-styles.js +555 -0
- package/mcp/dist/memory-ui.js +9 -0
- package/mcp/dist/package-metadata.js +13 -0
- package/mcp/dist/phren-art.js +52 -0
- package/mcp/dist/phren-core.js +108 -0
- package/mcp/dist/phren-dotenv.js +67 -0
- package/mcp/dist/phren-paths.js +476 -0
- package/mcp/dist/proactivity.js +172 -0
- package/mcp/dist/profile-store.js +228 -0
- package/mcp/dist/project-config.js +85 -0
- package/mcp/dist/project-locator.js +25 -0
- package/mcp/dist/project-topics.js +1134 -0
- package/mcp/dist/provider-adapters.js +176 -0
- package/mcp/dist/runtime-profile.js +18 -0
- package/mcp/dist/session-checkpoints.js +131 -0
- package/mcp/dist/session-utils.js +68 -0
- package/mcp/dist/shared-content.js +8 -0
- package/mcp/dist/shared-embedding-cache.js +143 -0
- package/mcp/dist/shared-fragment-graph.js +456 -0
- package/mcp/dist/shared-governance.js +4 -0
- package/mcp/dist/shared-index.js +1334 -0
- package/mcp/dist/shared-ollama.js +192 -0
- package/mcp/dist/shared-paths.js +1 -0
- package/mcp/dist/shared-retrieval.js +796 -0
- package/mcp/dist/shared-search-fallback.js +375 -0
- package/mcp/dist/shared-sqljs.js +42 -0
- package/mcp/dist/shared-stemmer.js +171 -0
- package/mcp/dist/shared-vector-index.js +199 -0
- package/mcp/dist/shared.js +114 -0
- package/mcp/dist/shell-entry.js +209 -0
- package/mcp/dist/shell-input.js +943 -0
- package/mcp/dist/shell-palette.js +119 -0
- package/mcp/dist/shell-render.js +252 -0
- package/mcp/dist/shell-state-store.js +81 -0
- package/mcp/dist/shell-types.js +13 -0
- package/mcp/dist/shell-view-list.js +14 -0
- package/mcp/dist/shell-view.js +707 -0
- package/mcp/dist/shell.js +352 -0
- package/mcp/dist/skill-files.js +117 -0
- package/mcp/dist/skill-registry.js +279 -0
- package/mcp/dist/skill-state.js +28 -0
- package/mcp/dist/startup-embedding.js +57 -0
- package/mcp/dist/status.js +323 -0
- package/mcp/dist/synonyms.json +670 -0
- package/mcp/dist/task-hygiene.js +251 -0
- package/mcp/dist/task-lifecycle.js +347 -0
- package/mcp/dist/tasks-github.js +76 -0
- package/mcp/dist/telemetry.js +165 -0
- package/mcp/dist/test-global-setup.js +37 -0
- package/mcp/dist/tool-registry.js +104 -0
- package/mcp/dist/update.js +97 -0
- package/mcp/dist/utils.js +543 -0
- package/package.json +67 -0
- package/skills/README.md +7 -0
- package/skills/consolidate/SKILL.md +152 -0
- package/skills/discover/SKILL.md +175 -0
- package/skills/init/SKILL.md +216 -0
- package/skills/profiles/SKILL.md +121 -0
- package/skills/sync/SKILL.md +261 -0
- package/starter/README.md +74 -0
- package/starter/global/CLAUDE.md +89 -0
- package/starter/global/skills/humanize.md +30 -0
- package/starter/global/skills/pipeline.md +35 -0
- package/starter/global/skills/release.md +35 -0
- package/starter/machines.yaml +8 -0
- package/starter/my-api/.claude/skills/README.md +7 -0
- package/starter/my-api/CLAUDE.md +33 -0
- package/starter/my-api/FINDINGS.md +9 -0
- package/starter/my-api/summary.md +7 -0
- package/starter/my-api/tasks.md +7 -0
- package/starter/my-first-project/.claude/skills/README.md +7 -0
- package/starter/my-first-project/CLAUDE.md +49 -0
- package/starter/my-first-project/FINDINGS.md +24 -0
- package/starter/my-first-project/summary.md +11 -0
- package/starter/my-first-project/tasks.md +25 -0
- package/starter/my-frontend/.claude/skills/README.md +7 -0
- package/starter/my-frontend/CLAUDE.md +33 -0
- package/starter/my-frontend/FINDINGS.md +9 -0
- package/starter/my-frontend/summary.md +7 -0
- package/starter/my-frontend/tasks.md +7 -0
- package/starter/profiles/default.yaml +4 -0
- package/starter/profiles/personal.yaml +4 -0
- package/starter/profiles/work.yaml +4 -0
- package/starter/templates/README.md +7 -0
- package/starter/templates/frontend/CLAUDE.md +23 -0
- package/starter/templates/frontend/FINDINGS.md +7 -0
- package/starter/templates/frontend/reference/README.md +4 -0
- package/starter/templates/frontend/summary.md +7 -0
- package/starter/templates/frontend/tasks.md +11 -0
- package/starter/templates/library/CLAUDE.md +22 -0
- package/starter/templates/library/FINDINGS.md +7 -0
- package/starter/templates/library/reference/README.md +4 -0
- package/starter/templates/library/summary.md +7 -0
- package/starter/templates/library/tasks.md +11 -0
- package/starter/templates/monorepo/CLAUDE.md +21 -0
- package/starter/templates/monorepo/FINDINGS.md +7 -0
- package/starter/templates/monorepo/reference/README.md +4 -0
- package/starter/templates/monorepo/summary.md +7 -0
- package/starter/templates/monorepo/tasks.md +11 -0
- package/starter/templates/python-project/CLAUDE.md +21 -0
- package/starter/templates/python-project/FINDINGS.md +7 -0
- package/starter/templates/python-project/reference/README.md +4 -0
- package/starter/templates/python-project/summary.md +7 -0
- package/starter/templates/python-project/tasks.md +10 -0
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# my-first-project findings
|
|
2
|
+
|
|
3
|
+
Fragments accumulated over time. Captured automatically during sessions and committed on exit.
|
|
4
|
+
|
|
5
|
+
<!-- How findings work:
|
|
6
|
+
|
|
7
|
+
Phren captures insights as you code. When Claude discovers something non-obvious
|
|
8
|
+
(a pitfall, a pattern, a decision with context), it calls add_finding() and the
|
|
9
|
+
insight lands here. The Stop hook auto-commits after every response.
|
|
10
|
+
|
|
11
|
+
Entries are grouped by date. Old entries get confidence-decayed over time, so stale
|
|
12
|
+
findings fade from retrieval naturally. You can remove wrong entries with
|
|
13
|
+
remove_finding() or clean up bulk with `phren shell` > :find remove.
|
|
14
|
+
|
|
15
|
+
Example entries (delete these once you have real ones):
|
|
16
|
+
|
|
17
|
+
## 2026-03-06
|
|
18
|
+
|
|
19
|
+
- The auth middleware runs before rate limiting, order matters in the middleware stack
|
|
20
|
+
<!-- phren:cite {"created_at":"2026-03-06T00:00:00.000Z"} -->
|
|
21
|
+
- `npm run dev` needs PORT set or it defaults to 3001, not 3000
|
|
22
|
+
<!-- phren:cite {"created_at":"2026-03-06T00:00:00.000Z"} -->
|
|
23
|
+
|
|
24
|
+
-->
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# my-first-project
|
|
2
|
+
|
|
3
|
+
**What:** Replace this with one sentence about what the project does
|
|
4
|
+
**Stack:** The key tech: language, framework, main deps
|
|
5
|
+
**Status:** active
|
|
6
|
+
**Run:** the command you use most (e.g. npm run dev)
|
|
7
|
+
**Watch out:** the one thing that will bite you if you forget it
|
|
8
|
+
|
|
9
|
+
<!-- This summary is the first thing phren shows Claude about your project.
|
|
10
|
+
Keep it short: 5 lines max. Think of it as the elevator pitch that helps
|
|
11
|
+
Claude understand what it's working on before reading any code. -->
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# my-first-project tasks
|
|
2
|
+
|
|
3
|
+
## Active
|
|
4
|
+
|
|
5
|
+
### P0: Getting started
|
|
6
|
+
|
|
7
|
+
- [ ] Fill in CLAUDE.md with your project's commands, architecture, and conventions
|
|
8
|
+
- [ ] Update summary.md with a real description of your project
|
|
9
|
+
|
|
10
|
+
## Queue
|
|
11
|
+
|
|
12
|
+
### P1: Phren setup
|
|
13
|
+
|
|
14
|
+
- [ ] Push this phren repo to a private GitHub repo for backup
|
|
15
|
+
- [ ] Run `phren doctor` to verify everything is wired up
|
|
16
|
+
- [ ] Add a second project with `phren-init <name>` or `phren shell`
|
|
17
|
+
|
|
18
|
+
### P2: Nice to have
|
|
19
|
+
|
|
20
|
+
- [ ] Set up profiles for work vs personal machines in profiles/
|
|
21
|
+
- [ ] Add project-specific skills to the project `skills/` directory
|
|
22
|
+
|
|
23
|
+
## Done
|
|
24
|
+
|
|
25
|
+
- [x] Run `npx phren init` to set up phren
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# CLAUDE.md
|
|
2
|
+
|
|
3
|
+
## Project overview
|
|
4
|
+
|
|
5
|
+
**Purpose**: Frontend app. Replace this with a real description of what it does.
|
|
6
|
+
**Stack**: React, TypeScript, Vite (or whatever you're using)
|
|
7
|
+
**Status**: active
|
|
8
|
+
**Version**: 0.0.0
|
|
9
|
+
|
|
10
|
+
## Commands
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
# Install: npm install
|
|
14
|
+
# Run: npm run dev
|
|
15
|
+
# Test: npm test
|
|
16
|
+
# Build: npm run build
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Project skills
|
|
20
|
+
|
|
21
|
+
Source skills live in the phren project `skills/` directory. Phren resolves global + project-local skills and mirrors the effective set into repo-local `.claude/skills/`.
|
|
22
|
+
|
|
23
|
+
## Architecture
|
|
24
|
+
|
|
25
|
+
<!-- Component structure, routing, state management approach -->
|
|
26
|
+
|
|
27
|
+
## Key patterns
|
|
28
|
+
|
|
29
|
+
<!-- Naming rules, component patterns, things to never do -->
|
|
30
|
+
|
|
31
|
+
<!-- Tip: If this file grows past ~100 lines, split it using @import directives.
|
|
32
|
+
Example: @CLAUDE-architecture.md, @CLAUDE-commands.md, @CLAUDE-conventions.md
|
|
33
|
+
See phren README for details. -->
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# my-frontend findings
|
|
2
|
+
|
|
3
|
+
Findings accumulated over time. Captured automatically during sessions and committed on exit.
|
|
4
|
+
|
|
5
|
+
<!-- Example entry:
|
|
6
|
+
## 2026-03-04
|
|
7
|
+
- HMR breaks if you rename a component file without restarting the dev server
|
|
8
|
+
- The API base URL in .env.local must not have a trailing slash
|
|
9
|
+
-->
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# my-frontend
|
|
2
|
+
|
|
3
|
+
**What:** Frontend app: replace with what yours actually does
|
|
4
|
+
**Stack:** React, TypeScript, Vite (or whatever you're using)
|
|
5
|
+
**Status:** active
|
|
6
|
+
**Run:** npm run dev
|
|
7
|
+
**Watch out:** API base URL set in .env.local: needs to match whatever port my-api runs on
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# starter/templates/
|
|
2
|
+
|
|
3
|
+
Project templates bundled in the npm package, used by `npx phren init --template <name>`.
|
|
4
|
+
|
|
5
|
+
Each subdirectory (frontend, library, monorepo, python-project) contains pre-filled project files with sensible defaults for that project type. When a user runs init with `--template`, these files are copied into their `~/.phren/<project>/` directory. For other project types, adaptive init infers topics and structure from repo content.
|
|
6
|
+
|
|
7
|
+
Users interact with this directory indirectly through the `--template` flag during init. To add a new template type, create a subdirectory here with the standard project files.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# {{project}}
|
|
2
|
+
|
|
3
|
+
Frontend application.
|
|
4
|
+
|
|
5
|
+
## Commands
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install
|
|
9
|
+
npm run dev
|
|
10
|
+
npm run build
|
|
11
|
+
npm test
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Architecture
|
|
15
|
+
|
|
16
|
+
<!-- Fill in: routing, state management, component structure -->
|
|
17
|
+
|
|
18
|
+
## Conventions
|
|
19
|
+
|
|
20
|
+
- Components in src/components/
|
|
21
|
+
- Pages/routes in src/pages/ or src/routes/
|
|
22
|
+
- Shared utilities in src/lib/
|
|
23
|
+
- CSS modules or Tailwind for styling
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# {{project}}
|
|
2
|
+
|
|
3
|
+
Reusable library published to a package registry.
|
|
4
|
+
|
|
5
|
+
## Commands
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install
|
|
9
|
+
npm run build
|
|
10
|
+
npm test
|
|
11
|
+
npm publish
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Architecture
|
|
15
|
+
|
|
16
|
+
<!-- Fill in: entry point, exports, module format -->
|
|
17
|
+
|
|
18
|
+
## Conventions
|
|
19
|
+
|
|
20
|
+
- Source in src/, tests in src/ alongside modules
|
|
21
|
+
- Exports defined in package.json exports field
|
|
22
|
+
- Semantic versioning, changelog on every release
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# {{project}}
|
|
2
|
+
|
|
3
|
+
Monorepo with multiple packages.
|
|
4
|
+
|
|
5
|
+
## Commands
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install
|
|
9
|
+
npm run build --workspaces
|
|
10
|
+
npm test --workspaces
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Architecture
|
|
14
|
+
|
|
15
|
+
<!-- Fill in package layout and dependencies -->
|
|
16
|
+
|
|
17
|
+
## Conventions
|
|
18
|
+
|
|
19
|
+
- Each package in packages/ is independently versioned
|
|
20
|
+
- Shared types in packages/shared
|
|
21
|
+
- Use workspace references for inter-package deps
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# {{project}}
|
|
2
|
+
|
|
3
|
+
Python project.
|
|
4
|
+
|
|
5
|
+
## Commands
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
python -m venv .venv && source .venv/bin/activate
|
|
9
|
+
pip install -e ".[dev]"
|
|
10
|
+
pytest
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Architecture
|
|
14
|
+
|
|
15
|
+
<!-- Fill in as the project grows -->
|
|
16
|
+
|
|
17
|
+
## Conventions
|
|
18
|
+
|
|
19
|
+
- Use pyproject.toml for packaging
|
|
20
|
+
- Type hints on public APIs
|
|
21
|
+
- Tests in tests/ directory
|