engram-harness 0.1.0
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 +112 -0
- package/dist/cli.js +34336 -0
- package/hooks/EventCapture.hook.ts +114 -0
- package/hooks/GreetingHook.hook.ts +35 -0
- package/hooks/LoadContext.hook.ts +245 -0
- package/hooks/SecurityValidator.hook.ts +626 -0
- package/hooks/SessionSummary.hook.ts +114 -0
- package/hooks/lib/identity.ts +143 -0
- package/hooks/lib/paths.ts +76 -0
- package/hooks/lib/time.ts +138 -0
- package/hooks/patterns.example.yaml +200 -0
- package/package.json +53 -0
- package/skills/DoWork/SKILL.md +41 -0
- package/skills/DoWork/Workflows/Capture.md +39 -0
- package/skills/DoWork/Workflows/Status.md +40 -0
- package/skills/DoWork/Workflows/WorkLoop.md +26 -0
- package/skills/HelloWorld/SKILL.md +33 -0
- package/skills/HelloWorld/Workflows/Greet.md +14 -0
- package/skills/Reflect/SKILL.md +30 -0
- package/skills/Reflect/Workflows/ExtractLearnings.md +69 -0
- package/skills/Research/SKILL.md +40 -0
- package/skills/Research/Workflows/Compare.md +41 -0
- package/skills/Research/Workflows/DeepDive.md +41 -0
- package/skills/Research/Workflows/QuickLookup.md +28 -0
- package/templates/CLAUDE.md.template +34 -0
- package/templates/constitution.md.template +38 -0
- package/templates/context.md.template +25 -0
- package/templates/skill/SKILL.md.template +31 -0
- package/templates/skill/Workflows/Example.md.template +14 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Percival Labs
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
# Engram
|
|
2
|
+
|
|
3
|
+
**The AI Harness for Everyone** -- open-source personal AI infrastructure that turns any model into *your* AI.
|
|
4
|
+
|
|
5
|
+
Engram is the stable layer between a raw AI model and a useful AI system. It provides the structure -- skills, hooks, memory, security, personality -- so you can swap models without losing your setup. When a new model releases, your skills still work. Your memory persists. Your identity carries over.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install -g engram-harness
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Requires Node.js 20+.
|
|
14
|
+
|
|
15
|
+
## Commands
|
|
16
|
+
|
|
17
|
+
### `engram init`
|
|
18
|
+
|
|
19
|
+
Scaffolds your personal AI infrastructure at `~/.claude/`. Creates identity files, starter skills, lifecycle hooks, memory directories, and a security validator -- everything needed to turn Claude Code into a personalized AI system.
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
engram init
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
### `engram bundle`
|
|
26
|
+
|
|
27
|
+
Generates a portable setup package for platforms that don't support CLI (Claude.ai, Claude Desktop, ChatGPT). Downloads as a zip with instructions, personality config, skills, and memory templates.
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
engram bundle --for "YourName"
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### `engram serve`
|
|
34
|
+
|
|
35
|
+
Starts an MCP (Model Context Protocol) server that exposes your skills and memory as tools any MCP-compatible client can use.
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
engram serve
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### `engram skill`
|
|
42
|
+
|
|
43
|
+
Manages your skill library -- create new skills from templates, rebuild the skill index, or list what's installed.
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
engram skill create MyNewSkill
|
|
47
|
+
engram skill index
|
|
48
|
+
engram skill list
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Architecture
|
|
52
|
+
|
|
53
|
+
Engram organizes AI infrastructure into five composable layers:
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
Layer 5: Agent Personalities -- Who your AI is
|
|
57
|
+
Layer 4: Skills & Workflows -- What your AI can do
|
|
58
|
+
Layer 3: Hooks & Events -- When things happen
|
|
59
|
+
Layer 2: Memory & History -- What your AI remembers
|
|
60
|
+
Layer 1: Security & Validation -- What your AI guards against
|
|
61
|
+
|
|
|
62
|
+
MODEL (pluggable -- Claude, GPT, Gemini, local)
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Each layer is independent. Use all five or start with just one.
|
|
66
|
+
|
|
67
|
+
## What You Get
|
|
68
|
+
|
|
69
|
+
After `engram init`, your `~/.claude/` directory contains:
|
|
70
|
+
|
|
71
|
+
| File / Directory | Purpose |
|
|
72
|
+
|------------------|---------|
|
|
73
|
+
| `CLAUDE.md` | AI identity, skill registry, global config |
|
|
74
|
+
| `context.md` | Your personal context (who you are, what you work on) |
|
|
75
|
+
| `constitution.md` | Personality calibration (tunable YAML dials) |
|
|
76
|
+
| `settings.json` | Runtime config with hook wiring |
|
|
77
|
+
| `skills/` | 4 starter skills (Research, DoWork, Reflect, HelloWorld) |
|
|
78
|
+
| `hooks/` | 3 lifecycle hooks (security, context loading, session summary) |
|
|
79
|
+
| `MEMORY/` | Structured memory directories |
|
|
80
|
+
|
|
81
|
+
Everything is plain files. Markdown, YAML, JSON. No database. No cloud service. Human-readable, git-friendly, portable.
|
|
82
|
+
|
|
83
|
+
## Web Bundle Generator
|
|
84
|
+
|
|
85
|
+
Don't use CLI? Visit the [Engram website](site/index.html) to generate a setup package through your browser. Fill in your name, tune personality sliders, and download a zip you can upload to Claude Projects or paste into ChatGPT custom instructions.
|
|
86
|
+
|
|
87
|
+
## Documentation
|
|
88
|
+
|
|
89
|
+
| Document | Description |
|
|
90
|
+
|----------|-------------|
|
|
91
|
+
| [Getting Started](docs/GETTING-STARTED.md) | Installation, setup, first session |
|
|
92
|
+
| [Creating Skills](docs/CREATING-SKILLS.md) | Build and register custom skills |
|
|
93
|
+
| [Writing Hooks](docs/WRITING-HOOKS.md) | Event-driven lifecycle hooks |
|
|
94
|
+
| [Architecture Guide](docs/ARCHITECTURE-GUIDE.md) | The five-layer system in detail |
|
|
95
|
+
| [Examples](docs/EXAMPLES.md) | Skills, hooks, and configuration examples |
|
|
96
|
+
| [FAQ](docs/FAQ.md) | Common questions |
|
|
97
|
+
|
|
98
|
+
## Contributing
|
|
99
|
+
|
|
100
|
+
Contributions welcome.
|
|
101
|
+
|
|
102
|
+
1. Fork the repository
|
|
103
|
+
2. Create a feature branch (`git checkout -b feature/my-feature`)
|
|
104
|
+
3. Read the relevant spec in `specs/` before making changes
|
|
105
|
+
4. Follow existing conventions (TitleCase for skills, TypeScript for hooks)
|
|
106
|
+
5. Submit a pull request with a clear description
|
|
107
|
+
|
|
108
|
+
For bugs and feature requests, open an issue on GitHub.
|
|
109
|
+
|
|
110
|
+
## License
|
|
111
|
+
|
|
112
|
+
MIT -- see [LICENSE](LICENSE) for details.
|