@runcontext/cli 0.3.5 → 0.4.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/README.md +38 -65
- package/dist/index.js +1689 -238
- package/dist/index.js.map +1 -1
- package/dist/server-DEKWPP3H.js +192 -0
- package/dist/server-DEKWPP3H.js.map +1 -0
- package/package.json +39 -9
package/README.md
CHANGED
|
@@ -1,93 +1,66 @@
|
|
|
1
1
|
# @runcontext/cli
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**ContextKit — tell your AI agent to build your semantic layer.**
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Tell your AI agent: *"Install @runcontext/cli and build a semantic layer for my database."*
|
|
6
|
+
|
|
7
|
+
The agent introspects your database, scaffolds metadata, and goes back and forth with you — asking about metrics, ownership, and business rules — while it builds the semantic layer using CLI commands. When it reaches Gold tier, it exports an **AI Blueprint** and serves the metadata to other AI agents via MCP.
|
|
6
8
|
|
|
7
9
|
## Installation
|
|
8
10
|
|
|
9
11
|
```bash
|
|
10
|
-
|
|
11
|
-
npm install -g @runcontext/cli
|
|
12
|
-
|
|
13
|
-
# Or per-project
|
|
14
|
-
npm install -D @runcontext/cli
|
|
12
|
+
npm install @runcontext/cli
|
|
15
13
|
```
|
|
16
14
|
|
|
17
15
|
## Quick Start
|
|
18
16
|
|
|
19
|
-
|
|
20
|
-
# Point at any database — interactive wizard does the rest
|
|
21
|
-
context setup
|
|
22
|
-
|
|
23
|
-
# Or step by step
|
|
24
|
-
context introspect --db duckdb://warehouse.duckdb
|
|
25
|
-
context enrich --target silver --apply
|
|
26
|
-
context tier
|
|
27
|
-
```
|
|
17
|
+
In Claude Code, Cursor, Windsurf, or any agentic coding platform:
|
|
28
18
|
|
|
29
|
-
|
|
19
|
+
> *"Install @runcontext/cli and build a semantic layer for my database."*
|
|
30
20
|
|
|
31
|
-
|
|
21
|
+
Or run it yourself:
|
|
32
22
|
|
|
33
23
|
```bash
|
|
34
|
-
context setup
|
|
35
|
-
context
|
|
36
|
-
context
|
|
37
|
-
context
|
|
38
|
-
context fix --write # Auto-fix lint issues where possible
|
|
39
|
-
context build # Compile context files → emit manifest JSON
|
|
40
|
-
context tier [model] # Show Bronze/Silver/Gold scorecard
|
|
24
|
+
context setup # Interactive wizard — database to metadata in one flow
|
|
25
|
+
context tier # Check Bronze/Silver/Gold score
|
|
26
|
+
context blueprint # Export AI Blueprint (portable Gold-tier spec)
|
|
27
|
+
context serve --stdio # Serve to AI agents via MCP
|
|
41
28
|
```
|
|
42
29
|
|
|
43
|
-
|
|
30
|
+
## Commands
|
|
44
31
|
|
|
45
32
|
```bash
|
|
46
|
-
|
|
47
|
-
context
|
|
48
|
-
context
|
|
49
|
-
context
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
33
|
+
# Build the semantic layer
|
|
34
|
+
context setup # Interactive wizard — full pipeline in one flow
|
|
35
|
+
context new <name> # Scaffold a new data product
|
|
36
|
+
context introspect # Scan a database -> scaffold Bronze metadata
|
|
37
|
+
context enrich --target silver # Auto-enrich toward a target tier
|
|
38
|
+
context lint # Run 40 lint rules
|
|
39
|
+
context fix --write # Auto-fix lint issues
|
|
40
|
+
context build # Compile -> emit manifest JSON
|
|
41
|
+
context tier [model] # Show Bronze/Silver/Gold scorecard
|
|
53
42
|
|
|
54
|
-
|
|
55
|
-
context
|
|
56
|
-
context
|
|
57
|
-
context
|
|
58
|
-
context
|
|
59
|
-
|
|
43
|
+
# Explore and verify
|
|
44
|
+
context explain <name> # Look up any model, term, or owner
|
|
45
|
+
context rules # List all lint rules
|
|
46
|
+
context validate-osi <file> # Validate against OSI spec
|
|
47
|
+
context verify # Check accuracy against a live database
|
|
48
|
+
|
|
49
|
+
# Export and serve
|
|
50
|
+
context blueprint [model] # Export AI Blueprints (portable OSI YAML)
|
|
51
|
+
context serve --stdio # MCP server over stdio
|
|
52
|
+
context serve --http --port 3000 # MCP server over HTTP
|
|
53
|
+
context site # Static documentation site
|
|
54
|
+
context dev --studio # Visual editor in the browser
|
|
55
|
+
context init # Scaffold a new project
|
|
60
56
|
```
|
|
61
57
|
|
|
62
|
-
## The Tier System
|
|
63
|
-
|
|
64
|
-
| Tier | What it means | How to get there |
|
|
65
|
-
|---|---|---|
|
|
66
|
-
| **Bronze** | Discoverable — described, owned, classified | `context introspect` |
|
|
67
|
-
| **Silver** | Trusted — lineage, glossary, sample values, trust status | `context enrich --target silver` |
|
|
68
|
-
| **Gold** | AI-Ready — semantic roles, golden queries, guardrails, business rules | Human curation + `context enrich --target gold` |
|
|
69
|
-
|
|
70
58
|
## Database Support
|
|
71
59
|
|
|
72
|
-
|
|
73
|
-
|---|---|
|
|
74
|
-
| DuckDB | `--db duckdb://path/to/file.duckdb` |
|
|
75
|
-
| PostgreSQL | `--db postgres://user:pass@host:5432/db` |
|
|
60
|
+
DuckDB, PostgreSQL, MySQL, SQL Server, SQLite, Snowflake, BigQuery, ClickHouse, Databricks.
|
|
76
61
|
|
|
77
62
|
## MCP Server
|
|
78
63
|
|
|
79
|
-
Expose your metadata to AI agents:
|
|
80
|
-
|
|
81
|
-
```bash
|
|
82
|
-
# For Claude Code / Cursor
|
|
83
|
-
context serve --stdio
|
|
84
|
-
|
|
85
|
-
# For multi-agent setups
|
|
86
|
-
context serve --http --port 3000
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
Add to `.claude/mcp.json`:
|
|
90
|
-
|
|
91
64
|
```json
|
|
92
65
|
{
|
|
93
66
|
"mcpServers": {
|
|
@@ -99,9 +72,9 @@ Add to `.claude/mcp.json`:
|
|
|
99
72
|
}
|
|
100
73
|
```
|
|
101
74
|
|
|
102
|
-
##
|
|
75
|
+
## Documentation
|
|
103
76
|
|
|
104
|
-
|
|
77
|
+
[contextkit.dev](https://contextkit.dev) | [GitHub](https://github.com/erickittelson/ContextKit)
|
|
105
78
|
|
|
106
79
|
## License
|
|
107
80
|
|