lurqrun 0.0.4 → 0.0.6
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 +70 -13
- package/dist/bin/lurq.js +1268 -989
- package/dist/bin/lurq.js.map +1 -1
- package/dist/index.d.ts +85 -4
- package/dist/index.js +1273 -987
- package/dist/index.js.map +1 -1
- package/drizzle/0011_compat_provenance_closures.sql +11 -0
- package/drizzle/0012_api_surfaces.sql +9 -0
- package/drizzle/0013_nice_thanos.sql +1 -0
- package/drizzle/0014_luxuriant_malcolm_colcord.sql +10 -0
- package/drizzle/0015_past_fat_cobra.sql +11 -0
- package/drizzle/0016_futuristic_junta.sql +50 -0
- package/drizzle/meta/0011_snapshot.json +1049 -0
- package/drizzle/meta/0012_snapshot.json +1115 -0
- package/drizzle/meta/0013_snapshot.json +1121 -0
- package/drizzle/meta/0014_snapshot.json +1190 -0
- package/drizzle/meta/0015_snapshot.json +1280 -0
- package/drizzle/meta/0016_snapshot.json +1683 -0
- package/drizzle/meta/_journal.json +42 -0
- package/package.json +8 -3
- package/templates/skill-instructions.md +38 -16
package/dist/index.d.ts
CHANGED
|
@@ -35,6 +35,16 @@ type Confidence = 'proven' | 'emerging' | 'promising' | 'unproven';
|
|
|
35
35
|
type Runtime = 'browser' | 'node' | 'both';
|
|
36
36
|
/** Result of co-installing two package versions in the sandbox (compat matrix). */
|
|
37
37
|
type CompatStatus = 'compatible' | 'conflict';
|
|
38
|
+
/**
|
|
39
|
+
* Evidence class behind a compat edge (§3, §4B). Ordered weakest→strongest for
|
|
40
|
+
* upsert precedence: a mined `observed` must never overwrite a sandbox `verified`
|
|
41
|
+
* or `conflict`. `declared` = Tier-0 peer/engine semver; `observed` = co-resolved
|
|
42
|
+
* in N real dependency graphs; `verified` = sandbox co-install passed; `conflict`
|
|
43
|
+
* = declared conflict or a sandbox co-install failed.
|
|
44
|
+
*/
|
|
45
|
+
type CompatProvenance = 'declared' | 'observed' | 'verified' | 'conflict';
|
|
46
|
+
/** Upsert precedence: higher wins, so mining can't erase a proven verdict. */
|
|
47
|
+
declare const PROVENANCE_RANK: Record<CompatProvenance, number>;
|
|
38
48
|
/** Coarse post-install result an agent reports back via `report_outcome` — never
|
|
39
49
|
* source code, just whether the recommended package installed / compiled /
|
|
40
50
|
* passed tests, or failed. Feeds the recommendation→outcome flywheel (§3.1). */
|
|
@@ -62,13 +72,28 @@ interface CompatConflict {
|
|
|
62
72
|
packages: string[];
|
|
63
73
|
detail: string;
|
|
64
74
|
}
|
|
75
|
+
/** One stored compat edge surfaced to agents, with its evidence class (§4B). */
|
|
76
|
+
interface CompatEvidence {
|
|
77
|
+
packages: [string, string];
|
|
78
|
+
versions: [string, string];
|
|
79
|
+
status: CompatStatus;
|
|
80
|
+
provenance: CompatProvenance;
|
|
81
|
+
/** Distinct resolved graphs an `observed` edge was witnessed in (0 otherwise). */
|
|
82
|
+
witnessCount: number;
|
|
83
|
+
}
|
|
65
84
|
/**
|
|
66
85
|
* `compat` output: whole-architecture compatibility for a set of packages.
|
|
67
86
|
* Tier-1 peer-dependency/engine analysis + any Tier-2 sandbox conflicts.
|
|
68
87
|
*/
|
|
69
88
|
interface CompatOutput {
|
|
70
89
|
packages: string[];
|
|
71
|
-
|
|
90
|
+
/** Evidence-graded verdict:
|
|
91
|
+
* - `conflict` — a proven incompatibility (peer-range violation or conflict edge).
|
|
92
|
+
* - `compatible` — every pair is *positively evidenced* (verified/observed edge).
|
|
93
|
+
* - `likely` — no conflict found, but not proven; absence of a declared
|
|
94
|
+
* conflict is not proof, so an unverified set is never `compatible`.
|
|
95
|
+
* - `unknown` — a member has no metadata yet (not ingested). */
|
|
96
|
+
overall: 'compatible' | 'likely' | 'conflict' | 'unknown';
|
|
72
97
|
conflicts: CompatConflict[];
|
|
73
98
|
/** Packages lurq has no compatibility metadata for (counted toward `unknown`). */
|
|
74
99
|
unverified: string[];
|
|
@@ -78,6 +103,51 @@ interface CompatOutput {
|
|
|
78
103
|
name: string;
|
|
79
104
|
version: string | null;
|
|
80
105
|
}[];
|
|
106
|
+
/** Stored edges among these packages with their evidence strength (§4B) — lets
|
|
107
|
+
* agents (and metrics) see *why* a pair is called compatible, not just that. */
|
|
108
|
+
evidence: CompatEvidence[];
|
|
109
|
+
}
|
|
110
|
+
/** Kind of an exported symbol, from its `.d.ts` declaration. */
|
|
111
|
+
type ExportKind = 'function' | 'class' | 'interface' | 'type' | 'enum' | 'variable' | 'namespace' | 'unknown';
|
|
112
|
+
/** One normalized exported symbol of a package version's public API surface. */
|
|
113
|
+
interface ExportSymbol {
|
|
114
|
+
name: string;
|
|
115
|
+
kind: ExportKind;
|
|
116
|
+
/** Single-line normalized signature (params/return for functions, etc.), or
|
|
117
|
+
* null when the declaration carries no useful signature. */
|
|
118
|
+
signature: string | null;
|
|
119
|
+
}
|
|
120
|
+
/** What changed between two API surfaces (§4D). Deltas are computed, not guessed. */
|
|
121
|
+
interface SurfaceDelta {
|
|
122
|
+
added: ExportSymbol[];
|
|
123
|
+
removed: ExportSymbol[];
|
|
124
|
+
/** A symbol that disappeared and a near-identical one that appeared — inferred
|
|
125
|
+
* by signature similarity, so an agent sees a rename, not remove+add. */
|
|
126
|
+
renamed: {
|
|
127
|
+
from: ExportSymbol;
|
|
128
|
+
to: ExportSymbol;
|
|
129
|
+
}[];
|
|
130
|
+
/** Same name, changed signature. */
|
|
131
|
+
changed: {
|
|
132
|
+
name: string;
|
|
133
|
+
before: string | null;
|
|
134
|
+
after: string | null;
|
|
135
|
+
}[];
|
|
136
|
+
}
|
|
137
|
+
/** `usage` tool output: version-exact API surface + optional delta from a known
|
|
138
|
+
* version the agent was trained/working on (§4D). */
|
|
139
|
+
interface UsageOutput {
|
|
140
|
+
package: string;
|
|
141
|
+
version: string | null;
|
|
142
|
+
/** Extracted export list, or null when types are unavailable (falls back to
|
|
143
|
+
* the README, which is already fetched). */
|
|
144
|
+
surface: ExportSymbol[] | null;
|
|
145
|
+
available: boolean;
|
|
146
|
+
/** Present when a `knownVersion` was supplied and both surfaces resolved. */
|
|
147
|
+
delta?: SurfaceDelta & {
|
|
148
|
+
fromVersion: string;
|
|
149
|
+
};
|
|
150
|
+
note?: string;
|
|
81
151
|
}
|
|
82
152
|
type AdvisorySeverity = 'critical' | 'high' | 'moderate' | 'low' | 'info';
|
|
83
153
|
interface Advisory {
|
|
@@ -178,7 +248,7 @@ declare const SERVER_NAME = "lurq";
|
|
|
178
248
|
* Keep in sync with package.json "name". */
|
|
179
249
|
declare const PACKAGE_NAME = "lurqrun";
|
|
180
250
|
/** Keep in sync with package.json "version". */
|
|
181
|
-
declare const VERSION = "0.0.
|
|
251
|
+
declare const VERSION = "0.0.6";
|
|
182
252
|
/** Default hosted endpoint the install wizard writes into agent configs. The
|
|
183
253
|
* marketing site is `lurq.run`; the MCP service lives on the `api.` subdomain.
|
|
184
254
|
* Overridable per-invocation with `lurq install --url …` or `LURQ_ENDPOINT`. */
|
|
@@ -201,7 +271,15 @@ declare const CACHE_TTL: {
|
|
|
201
271
|
readonly bundlephobia: number;
|
|
202
272
|
};
|
|
203
273
|
|
|
204
|
-
/**
|
|
274
|
+
/**
|
|
275
|
+
* Load env into process.env exactly once. Safe to call repeatedly.
|
|
276
|
+
*
|
|
277
|
+
* Layering: if `LURQ_ENV_FILE` is set (e.g. `.env.production`), that file loads
|
|
278
|
+
* *first* so its values win, then `.env` fills in the rest (dotenv never
|
|
279
|
+
* overrides an already-set key). This is how the explicit prod path works —
|
|
280
|
+
* `LURQ_ENV_FILE=.env.production` supplies the prod DATABASE_URL while `.env`
|
|
281
|
+
* still provides shared secrets — without prod ever being the ambient default.
|
|
282
|
+
*/
|
|
205
283
|
declare function loadEnv(): void;
|
|
206
284
|
declare const EnvSchema: z.ZodObject<{
|
|
207
285
|
DATABASE_URL: z.ZodOptional<z.ZodString>;
|
|
@@ -233,6 +311,7 @@ declare const EnvSchema: z.ZodObject<{
|
|
|
233
311
|
LURQ_API_KEY: z.ZodOptional<z.ZodString>;
|
|
234
312
|
E2B_API_KEY: z.ZodOptional<z.ZodString>;
|
|
235
313
|
E2B_TEMPLATE: z.ZodOptional<z.ZodString>;
|
|
314
|
+
USE_LIVE_API: z.ZodOptional<z.ZodString>;
|
|
236
315
|
}, "strip", z.ZodTypeAny, {
|
|
237
316
|
EMBEDDING_PROVIDER: "openai" | "local";
|
|
238
317
|
EMBEDDING_MODEL: string;
|
|
@@ -256,6 +335,7 @@ declare const EnvSchema: z.ZodObject<{
|
|
|
256
335
|
LURQ_API_KEY?: string | undefined;
|
|
257
336
|
E2B_API_KEY?: string | undefined;
|
|
258
337
|
E2B_TEMPLATE?: string | undefined;
|
|
338
|
+
USE_LIVE_API?: string | undefined;
|
|
259
339
|
}, {
|
|
260
340
|
DATABASE_URL?: string | undefined;
|
|
261
341
|
GITHUB_TOKEN?: string | undefined;
|
|
@@ -279,6 +359,7 @@ declare const EnvSchema: z.ZodObject<{
|
|
|
279
359
|
LURQ_API_KEY?: string | undefined;
|
|
280
360
|
E2B_API_KEY?: string | undefined;
|
|
281
361
|
E2B_TEMPLATE?: string | undefined;
|
|
362
|
+
USE_LIVE_API?: string | undefined;
|
|
282
363
|
}>;
|
|
283
364
|
type Config = z.infer<typeof EnvSchema>;
|
|
284
365
|
declare class ConfigError extends Error {
|
|
@@ -309,4 +390,4 @@ declare const logger: {
|
|
|
309
390
|
|
|
310
391
|
declare function buildProgram(): Command;
|
|
311
392
|
|
|
312
|
-
export { API_KEY_PREFIX, type Advisory, type AdvisorySeverity, type BuildSignal, type BuildVerified, CACHE_TTL, CATEGORIES, type Candidate, type Category, type CategorySource, type CompatConflict, type CompatOutput, type CompatStatus, type Confidence, type Config, ConfigError, DEFAULT_ENDPOINT, type DependencyRanges, type DiscoverySource, type DiscoveryStatus, EMBEDDING_DIM, type EvaluateOutput, FRONTEND_CATEGORIES, PACKAGE_NAME, type PeerMeta, type RiskLevel, type Runtime, SERVER_NAME, STALENESS_DAYS, type ScoreBreakdown, type UsageGuide, VERSION, type VerifyOutput, buildProgram, getConfig, isCategory, isFrontendCategory, loadEnv, logger, requireConfig };
|
|
393
|
+
export { API_KEY_PREFIX, type Advisory, type AdvisorySeverity, type BuildSignal, type BuildVerified, CACHE_TTL, CATEGORIES, type Candidate, type Category, type CategorySource, type CompatConflict, type CompatEvidence, type CompatOutput, type CompatProvenance, type CompatStatus, type Confidence, type Config, ConfigError, DEFAULT_ENDPOINT, type DependencyRanges, type DiscoverySource, type DiscoveryStatus, EMBEDDING_DIM, type EvaluateOutput, type ExportKind, type ExportSymbol, FRONTEND_CATEGORIES, PACKAGE_NAME, PROVENANCE_RANK, type PeerMeta, type RiskLevel, type Runtime, SERVER_NAME, STALENESS_DAYS, type ScoreBreakdown, type SurfaceDelta, type UsageGuide, type UsageOutput, VERSION, type VerifyOutput, buildProgram, getConfig, isCategory, isFrontendCategory, loadEnv, logger, requireConfig };
|