lurqrun 0.0.8 → 0.0.9
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 +189 -75
- package/dist/bin/lurq.js +562 -126
- package/dist/bin/lurq.js.map +1 -1
- package/dist/index.d.ts +12 -0
- package/dist/index.js +562 -126
- package/dist/index.js.map +1 -1
- package/drizzle/0026_awesome_mordo.sql +1 -0
- package/drizzle/0027_charming_ulik.sql +2 -0
- package/drizzle/meta/0026_snapshot.json +2413 -0
- package/drizzle/meta/0027_snapshot.json +2425 -0
- package/drizzle/meta/_journal.json +14 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,124 +1,238 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
1
3
|
# lurq
|
|
2
4
|
|
|
3
|
-
|
|
5
|
+
**Execution-verified dependency intelligence for AI coding agents.**
|
|
4
6
|
|
|
5
|
-
|
|
7
|
+
A live index of npm scored from public signals, plus a sandbox that settles the
|
|
8
|
+
questions metadata can't — exposed as an MCP server, a CLI, an HTTP API, and an
|
|
9
|
+
installable agent skill.
|
|
6
10
|
|
|
7
|
-
|
|
11
|
+
[](https://www.npmjs.com/package/lurqrun)
|
|
12
|
+
[](https://www.npmjs.com/package/lurqrun)
|
|
13
|
+
[](LICENSE)
|
|
14
|
+
[](https://nodejs.org)
|
|
15
|
+
[](https://modelcontextprotocol.io)
|
|
8
16
|
|
|
9
|
-
|
|
17
|
+
[Quick start](#quick-start) · [MCP tools](#mcp-tools) · [CLI](#cli) · [Autopilot](#autopilot) · [How ranking works](#how-ranking-works) · [Docs](https://lurq.run/docs)
|
|
10
18
|
|
|
11
|
-
|
|
19
|
+
</div>
|
|
12
20
|
|
|
13
21
|
---
|
|
14
22
|
|
|
15
|
-
##
|
|
23
|
+
## Why
|
|
24
|
+
|
|
25
|
+
Your agent picks the dependencies now, and it picks them from training data frozen
|
|
26
|
+
at its cutoff, ranked by how often a name appeared in text — not by whether the
|
|
27
|
+
package is healthy today. So agents install libraries that are abandoned, carry
|
|
28
|
+
open advisories, or don't exist at all.
|
|
29
|
+
|
|
30
|
+
lurq is what the agent checks first.
|
|
31
|
+
|
|
32
|
+
Most of what matters is readable — release cadence, advisories, deprecations,
|
|
33
|
+
types/tests/docs, bundle cost — and lurq ingests all of it daily. The rest isn't
|
|
34
|
+
readable at all. Whether a package installs cleanly, whether it imports without
|
|
35
|
+
throwing, whether two versions can coexist in one tree: those are only knowable by
|
|
36
|
+
running them, so lurq runs them in an isolated sandbox and keeps the result.
|
|
37
|
+
|
|
38
|
+
lurq recommends and explains packages; your agent writes the code. Responses are
|
|
39
|
+
compact and token-budgeted, built for a context window rather than a screen.
|
|
40
|
+
|
|
41
|
+
> **Scope:** the JavaScript/TypeScript web stack (npm) only.
|
|
16
42
|
|
|
17
|
-
|
|
18
|
-
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Quick start
|
|
19
46
|
|
|
20
|
-
lurq is a **hosted service
|
|
21
|
-
|
|
47
|
+
lurq is a **hosted service** — you don't run a database or a sync.
|
|
48
|
+
[Create a free account](https://lurq.run/sign-up) to generate an API key, then run
|
|
49
|
+
the guided installer:
|
|
22
50
|
|
|
23
51
|
```bash
|
|
24
|
-
npx lurqrun
|
|
52
|
+
npx lurqrun install
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
It prompts for your key, validates it, detects your installed assistants, and
|
|
56
|
+
writes a keyed remote MCP entry:
|
|
57
|
+
|
|
58
|
+
```json
|
|
59
|
+
{
|
|
60
|
+
"type": "http",
|
|
61
|
+
"url": "https://api.lurq.run/mcp",
|
|
62
|
+
"headers": { "Authorization": "Bearer ..." }
|
|
63
|
+
}
|
|
25
64
|
```
|
|
26
65
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
66
|
+
**No database credentials ever touch your machine.** Restart your agent afterward.
|
|
67
|
+
|
|
68
|
+
<details>
|
|
69
|
+
<summary><b>Supported assistants</b></summary>
|
|
30
70
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
`LURQ_API_KEY` to export
|
|
34
|
-
- **registers the mcp server** in every assistant it finds (claude code, cursor,
|
|
35
|
-
windsurf, vscode/copilot, codex, gemini cli, antigravity, kiro), as a keyed
|
|
36
|
-
remote entry:
|
|
37
|
-
`{ "type": "http", "url": "https://api.lurq.run/mcp", "headers": { "Authorization": "Bearer …" } }`
|
|
38
|
-
- **installs the agent skill**, so the model reaches for lurq on its own instead of
|
|
39
|
-
answering about a package from memory: a real skill at
|
|
40
|
-
`~/.claude/skills/lurq/SKILL.md` for claude code, and the equivalent rules or
|
|
41
|
-
steering file for the others
|
|
71
|
+
Claude Code · Cursor · Windsurf · VS Code / Copilot · Codex · Gemini CLI ·
|
|
72
|
+
Antigravity · Kiro
|
|
42
73
|
|
|
43
|
-
|
|
44
|
-
|
|
74
|
+
Target one explicitly with `npx lurqrun install-skill --agent <name>`, or
|
|
75
|
+
self-host against your own database with `--local`.
|
|
45
76
|
|
|
46
|
-
|
|
47
|
-
swap in a different key. `lurq install` and `lurq login` are aliases for it.
|
|
77
|
+
</details>
|
|
48
78
|
|
|
49
|
-
|
|
50
|
-
serve-http`? point setup at it with `lurq setup --url https://your.host/mcp`, and
|
|
51
|
-
issue the key on that machine with `lurq keys create`. the endpoint is stored
|
|
52
|
-
alongside the key, so later re-runs stay on your server.
|
|
79
|
+
---
|
|
53
80
|
|
|
54
|
-
##
|
|
81
|
+
## MCP tools
|
|
55
82
|
|
|
56
|
-
|
|
83
|
+
Once installed, your agent can call these over MCP. Every response is compact and
|
|
57
84
|
carries a `dataAsOf` timestamp.
|
|
58
85
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
86
|
+
| Tool | What it answers |
|
|
87
|
+
|---|---|
|
|
88
|
+
| `recommend` | Best current packages for a described need (≤5, scored, with confidence) |
|
|
89
|
+
| `evaluate` | Full evidence read for one package — scores, advisories, usage guide |
|
|
90
|
+
| `compare` | 2–5 packages ranked head-to-head |
|
|
91
|
+
| `verify` | Is this package real, healthy, and not risky? *(anti-hallucination guard)* |
|
|
92
|
+
| `compat` | Will these packages actually install together? (peer/engine constraints) |
|
|
93
|
+
| `plan` | Source every slot in a stack at once, checked for cross-slot coherence |
|
|
94
|
+
| `diagram` | A reference-architecture Mermaid diagram for a stack |
|
|
95
|
+
| `usage` | A version's *real* public API — symbols and signatures from its shipped `.d.ts` |
|
|
96
|
+
| `resolve_surface` | The exact export surface of one package version |
|
|
97
|
+
| `diff_surface` | What a version bump adds, removes, renames, or changes arity on |
|
|
98
|
+
| `report_outcome` | What happened after a pick shipped — installed clean, broke the build, resolved the task |
|
|
99
|
+
|
|
100
|
+
`usage` is the one worth calling out: pass the version your model *thinks* it knows
|
|
101
|
+
and get the precise delta to the version you're actually installing. That fact
|
|
102
|
+
exists in no changelog and no model's training data.
|
|
103
|
+
|
|
104
|
+
---
|
|
68
105
|
|
|
69
|
-
##
|
|
106
|
+
## CLI
|
|
70
107
|
|
|
71
|
-
|
|
72
|
-
stored it. every capability is a subcommand:
|
|
108
|
+
The same index, scriptable. Every capability is a subcommand.
|
|
73
109
|
|
|
74
110
|
```bash
|
|
111
|
+
# Discovery
|
|
75
112
|
lurq recommend "a form library for react"
|
|
76
|
-
lurq
|
|
113
|
+
lurq evaluate zod
|
|
77
114
|
lurq compare date-fns dayjs moment
|
|
78
|
-
lurq
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
lurq
|
|
82
|
-
lurq
|
|
115
|
+
lurq verify jsonwebtoken
|
|
116
|
+
|
|
117
|
+
# API surfaces
|
|
118
|
+
lurq usage zod --known 3.22.4 # what changed since the version you know
|
|
119
|
+
lurq versions react # stored version timeline
|
|
120
|
+
|
|
121
|
+
# Stacks
|
|
122
|
+
lurq compat next react react-dom # do these install together?
|
|
123
|
+
lurq plan ./project.md # a description in, a scored stack out
|
|
124
|
+
|
|
125
|
+
# Upgrades
|
|
126
|
+
lurq upgrade-plan . # what's behind, and what each upgrade removes
|
|
127
|
+
lurq check-upgrade . --plan lurq-plan.json --exit-code
|
|
128
|
+
|
|
129
|
+
# Configuration & serving
|
|
130
|
+
lurq weights # the exact ranking weights, printed
|
|
131
|
+
lurq edit-weights --set composite.lambda=0.5
|
|
132
|
+
lurq serve-http # run it as a rate-limited service of your own
|
|
83
133
|
```
|
|
84
134
|
|
|
85
|
-
|
|
135
|
+
Every read command takes `--json`.
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
## Autopilot
|
|
86
140
|
|
|
87
|
-
|
|
141
|
+
lurq also keeps a repository's dependencies current **and rewrites the code an
|
|
142
|
+
upgrade breaks.**
|
|
88
143
|
|
|
89
|
-
|
|
90
|
-
|
|
144
|
+
Renovate and Dependabot open a PR that says *"bumped react-router 6→8"* and gate it
|
|
145
|
+
on your test suite. If coverage misses the affected path, the PR merges green and
|
|
146
|
+
breaks in production.
|
|
147
|
+
|
|
148
|
+
lurq opens a PR that says *"bumped react-router 6→8, and rewrote the 14 call sites
|
|
149
|
+
that used `useHistory`, which no longer exists"* — because it holds the
|
|
150
|
+
symbol-level surface diff and intersects it with what your code references.
|
|
151
|
+
|
|
152
|
+
**The gate needs no tests at all.**
|
|
153
|
+
|
|
154
|
+
```
|
|
155
|
+
blocking a referenced symbol disappears → the code will throw
|
|
156
|
+
warning a referenced symbol changed arity → it may silently misbehave
|
|
157
|
+
ok nothing referenced is affected
|
|
158
|
+
unverified could not be established → never counted as safe
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
### The loop
|
|
162
|
+
|
|
163
|
+
| Step | Runs on | Needs |
|
|
164
|
+
|---|---|---|
|
|
165
|
+
| 1. `lurq upgrade-plan` — drift + what each upgrade removes | your runner | lurq key |
|
|
166
|
+
| 2. `lurq check-upgrade` — intersect with your source, `file:line` | your runner | nothing |
|
|
167
|
+
| 3. `claude-code-action` — rewrite the named call sites, run your tests | your runner | Anthropic credential |
|
|
168
|
+
| 4. `create-pull-request` — one branch, one PR | your runner | `GITHUB_TOKEN` |
|
|
169
|
+
| 5. Outcomes post back — names and counts, never source | lurq | — |
|
|
170
|
+
|
|
171
|
+
Steps 1–2 are the default. The generated workflow starts in `comment` mode: it
|
|
172
|
+
plans, checks, and writes the brief to the run summary, changing nothing. Editing
|
|
173
|
+
is opt-in per repository.
|
|
174
|
+
|
|
175
|
+
### Trust model
|
|
176
|
+
|
|
177
|
+
- **lurq's GitHub App is `Contents: read-only` and stays that way.** It cannot
|
|
178
|
+
write to any repository, ever.
|
|
179
|
+
- **Every write uses your own `GITHUB_TOKEN`** — ephemeral, scoped to one repo,
|
|
180
|
+
limited to what the `permissions:` block in a file *you* committed declares.
|
|
181
|
+
- **The agent cannot touch version control.** Its allowlist is
|
|
182
|
+
`Read,Edit,Write,Bash(<pkg-manager>:*)` — no `git`, no network. The model edits
|
|
183
|
+
files; the *workflow* commits. A prompt injection in a dependency's changelog
|
|
184
|
+
cannot push a branch.
|
|
185
|
+
- **Revoking it is `git rm .github/workflows/lurq-upgrade.yml`.**
|
|
186
|
+
|
|
187
|
+
Architecture and limits: [`docs/lurq-autopilot.md`](docs/lurq-autopilot.md).
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## Where the evidence comes from
|
|
192
|
+
|
|
193
|
+
Two sources, and the distinction is the whole point.
|
|
194
|
+
|
|
195
|
+
**Readable** — npm, GitHub, deps.dev, and OSV, re-synced daily. Downloads, release
|
|
196
|
+
cadence, maintenance, advisories, deprecations, license, bundle cost. This is what
|
|
91
197
|
scoring runs on.
|
|
92
198
|
|
|
93
|
-
**
|
|
94
|
-
installs a package version, imports it, and records what happened.
|
|
199
|
+
**Executed** — an isolated sandbox (E2B, with a local driver for trusted work) that
|
|
200
|
+
installs a package version, imports it, and records what happened. Co-installing a
|
|
95
201
|
set is how compatibility is established: a successful co-install is positive proof
|
|
96
202
|
two versions coexist, a failure is proof they conflict, and the error is kept as
|
|
97
203
|
evidence. `compat` and `plan` read those edges, which is why lurq can tell you a
|
|
98
204
|
*stack* holds together rather than only that each package looks fine alone.
|
|
99
205
|
|
|
100
|
-
|
|
206
|
+
Facts of the second kind appear in no changelog and no model's training data, and
|
|
101
207
|
they go stale unless someone keeps re-running the experiment.
|
|
102
208
|
|
|
103
|
-
|
|
209
|
+
---
|
|
104
210
|
|
|
105
|
-
|
|
106
|
-
vector + full-text search over precomputed scores, which is why it's fast, cheap, and
|
|
107
|
-
reproducible.
|
|
211
|
+
## How ranking works
|
|
108
212
|
|
|
109
|
-
|
|
110
|
-
-
|
|
111
|
-
|
|
112
|
-
old popular one
|
|
113
|
-
- the two blend at a single tunable λ for the default sort
|
|
213
|
+
Deterministic, and public. **No model sits in the ranking path** — `recommend` is
|
|
214
|
+
hybrid vector + full-text search over precomputed scores, which is why it's fast,
|
|
215
|
+
cheap, and reproducible.
|
|
114
216
|
|
|
115
|
-
|
|
116
|
-
|
|
217
|
+
```
|
|
218
|
+
health = maintenance 0.35 · adoption 0.30 · reliability 0.25 · efficiency 0.10
|
|
219
|
+
quality = types · tests · docs · changelog · dep count · license · provenance
|
|
220
|
+
composite = blend at a single tunable λ (default 0.35)
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
`quality` is a separate, **adoption-independent** axis, so a well-built new package
|
|
224
|
+
isn't buried by an old popular one.
|
|
225
|
+
|
|
226
|
+
Every weight lives in [`src/scoring/weights.ts`](src/scoring/weights.ts) and is
|
|
227
|
+
printable with `lurq weights`. An answer an agent acts on is worth nothing if it
|
|
228
|
+
can't be audited.
|
|
229
|
+
|
|
230
|
+
---
|
|
117
231
|
|
|
118
|
-
##
|
|
232
|
+
## Contact
|
|
119
233
|
|
|
120
|
-
|
|
234
|
+
Inquiries, partnerships, or proposals: **jadenryu@gmail.com**
|
|
121
235
|
|
|
122
|
-
##
|
|
236
|
+
## License
|
|
123
237
|
|
|
124
|
-
Apache
|
|
238
|
+
[Apache-2.0](LICENSE)
|