@openweave/weave-cli 1.0.2
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 +116 -0
- package/package.json +45 -0
- package/src/cli.test.ts +722 -0
- package/src/cli.ts +155 -0
- package/src/commands/errors.ts +211 -0
- package/src/commands/init.ts +133 -0
- package/src/commands/migrate.ts +239 -0
- package/src/commands/milestones.ts +249 -0
- package/src/commands/orphans.ts +210 -0
- package/src/commands/query.ts +170 -0
- package/src/commands/save-node.ts +161 -0
- package/src/commands/skills.ts +230 -0
- package/src/commands/status.ts +122 -0
- package/src/commands/tools.ts +346 -0
- package/src/index.ts +12 -0
- package/src/types.ts +53 -0
- package/src/utils.ts +19 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 lemur bookstores
|
|
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,116 @@
|
|
|
1
|
+
# β¨οΈ Weave CLI
|
|
2
|
+
|
|
3
|
+
> Command-line interface for OpenWeave intelligent agent framework
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
**Weave CLI** is the command-line tool for interacting with OpenWeave locally. It provides commands to scaffold projects, track progress, and manage the agent's knowledge graph.
|
|
8
|
+
|
|
9
|
+
## Installation
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm install -g @openweave/weave-cli
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Or use directly with npx:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npx @openweave/weave-cli --help
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Commands
|
|
22
|
+
|
|
23
|
+
### `weave init <project>`
|
|
24
|
+
|
|
25
|
+
Initialize a new OpenWeave project session.
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
weave init my-project
|
|
29
|
+
# Creates:
|
|
30
|
+
# - my-project/.weave/context.json (knowledge graph state)
|
|
31
|
+
# - my-project/ROADMAP.md (milestone tracker)
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### `weave status`
|
|
35
|
+
|
|
36
|
+
Show current project status and milestones.
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
weave status
|
|
40
|
+
# Output:
|
|
41
|
+
# πΊοΈ OpenWeave Project Status
|
|
42
|
+
# M1 Β· WeaveGraph Core [β
100%]
|
|
43
|
+
# M2 Β· WeaveLint Core [π 50%]
|
|
44
|
+
# M3 Β· WeavePath Core [π 0%]
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### `weave milestones`
|
|
48
|
+
|
|
49
|
+
List all milestones and sub-tasks.
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
weave milestones
|
|
53
|
+
# Shows detailed breakdown of all milestones
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### `weave errors`
|
|
57
|
+
|
|
58
|
+
List error registry and correction patterns.
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
weave errors
|
|
62
|
+
# Shows common errors encountered and corrections applied
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### `weave query <term>`
|
|
66
|
+
|
|
67
|
+
Search the knowledge graph.
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
weave query "authentication system"
|
|
71
|
+
# Returns nodes matching the query with relevance scores
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### `weave save-node`
|
|
75
|
+
|
|
76
|
+
Manually add a node to the knowledge graph.
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
weave save-node --label "API Design Decision" --type DECISION
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### `weave orphans`
|
|
83
|
+
|
|
84
|
+
Run code orphan detection on current project.
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
weave orphans --path ./src
|
|
88
|
+
# Shows unused functions, classes, and modules
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Configuration
|
|
92
|
+
|
|
93
|
+
Weave CLI uses `.weave/config.json` for project settings:
|
|
94
|
+
|
|
95
|
+
```json
|
|
96
|
+
{
|
|
97
|
+
"project_name": "my-project",
|
|
98
|
+
"knowledge_graph_path": ".weave/context.json",
|
|
99
|
+
"roadmap_file": "ROADMAP.md",
|
|
100
|
+
"include_tests": false,
|
|
101
|
+
"max_context_depth": 2
|
|
102
|
+
}
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## Environment Variables
|
|
106
|
+
|
|
107
|
+
- `WEAVE_PROJECT_ROOT` β Override project root directory
|
|
108
|
+
- `WEAVE_VERBOSE` β Enable verbose logging
|
|
109
|
+
- `WEAVE_DEBUG` β Enable debug mode
|
|
110
|
+
|
|
111
|
+
## Related Packages
|
|
112
|
+
|
|
113
|
+
- **@openweave/weave-graph** β Knowledge graph storage and retrieval
|
|
114
|
+
- **@openweave/weave-lint** β Code orphan detection
|
|
115
|
+
- **@openweave/weave-path** β Milestone planning
|
|
116
|
+
- **@openweave/weave-link** β MCP server for integrations
|
package/package.json
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@openweave/weave-cli",
|
|
3
|
+
"version": "1.0.2",
|
|
4
|
+
"description": "Weave CLI - Command-line interface for OpenWeave agent framework",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.js",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"bin": {
|
|
9
|
+
"weave": "./dist/cli.js"
|
|
10
|
+
},
|
|
11
|
+
"files": [
|
|
12
|
+
"dist",
|
|
13
|
+
"src"
|
|
14
|
+
],
|
|
15
|
+
"keywords": [
|
|
16
|
+
"openweave",
|
|
17
|
+
"cli",
|
|
18
|
+
"agent",
|
|
19
|
+
"planning"
|
|
20
|
+
],
|
|
21
|
+
"author": "OpenWeave Team",
|
|
22
|
+
"license": "MIT",
|
|
23
|
+
"private": false,
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@openweave/weave-provider": "0.8.0",
|
|
26
|
+
"@openweave/weave-graph": "0.2.0",
|
|
27
|
+
"@openweave/weave-tools": "1.0.0",
|
|
28
|
+
"@openweave/weave-path": "0.2.0",
|
|
29
|
+
"@openweave/weave-skills": "1.0.0",
|
|
30
|
+
"@openweave/weave-lint": "0.2.0",
|
|
31
|
+
"@openweave/weave-link": "0.2.0"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@types/node": "22.10.1",
|
|
35
|
+
"typescript": "5.7.2",
|
|
36
|
+
"vitest": "3.0.0",
|
|
37
|
+
"tsx": "4.7.0"
|
|
38
|
+
},
|
|
39
|
+
"scripts": {
|
|
40
|
+
"build": "tsc",
|
|
41
|
+
"dev": "tsx src/cli.ts",
|
|
42
|
+
"test": "vitest --no-coverage",
|
|
43
|
+
"cli": "node dist/cli.js"
|
|
44
|
+
}
|
|
45
|
+
}
|