@tobilu/qmd 2.1.0 → 2.5.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/CHANGELOG.md +88 -0
- package/README.md +3 -0
- package/bin/qmd +111 -32
- package/dist/ast.d.ts +1 -0
- package/dist/ast.js +18 -8
- package/dist/bench/bench.d.ts +2 -0
- package/dist/bench/bench.js +108 -13
- package/dist/bench/score.d.ts +11 -4
- package/dist/bench/score.js +34 -13
- package/dist/bench/types.d.ts +13 -0
- package/dist/cli/qmd.d.ts +26 -0
- package/dist/cli/qmd.js +1172 -121
- package/dist/collections.d.ts +9 -0
- package/dist/collections.js +32 -7
- package/dist/db.d.ts +6 -3
- package/dist/db.js +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.js +5 -2
- package/dist/llm.d.ts +65 -3
- package/dist/llm.js +376 -63
- package/dist/mcp/server.d.ts +6 -3
- package/dist/mcp/server.js +41 -26
- package/dist/paths.d.ts +1 -0
- package/dist/paths.js +4 -0
- package/dist/store.d.ts +92 -17
- package/dist/store.js +676 -176
- package/package.json +23 -12
- package/scripts/build.mjs +29 -0
- package/scripts/check-package-grammars.mjs +29 -0
- package/scripts/package-smoke.mjs +65 -0
- package/scripts/test-all.mjs +27 -0
- package/skills/qmd/SKILL.md +203 -0
- package/skills/qmd/references/mcp-setup.md +102 -0
- package/skills/release/SKILL.md +139 -0
- package/skills/release/scripts/install-hooks.sh +38 -0
- package/dist/embedded-skills.d.ts +0 -6
- package/dist/embedded-skills.js +0 -14
package/dist/bench/types.d.ts
CHANGED
|
@@ -34,6 +34,12 @@ export interface BackendResult {
|
|
|
34
34
|
precision_at_k: number;
|
|
35
35
|
/** Fraction of expected files found anywhere in results */
|
|
36
36
|
recall: number;
|
|
37
|
+
/** Fraction of expected files found in the first result */
|
|
38
|
+
recall_at_1: number;
|
|
39
|
+
/** Fraction of expected files found in the top 3 results */
|
|
40
|
+
recall_at_3: number;
|
|
41
|
+
/** Fraction of expected files found in the top 5 results */
|
|
42
|
+
recall_at_5: number;
|
|
37
43
|
/** Reciprocal rank of first relevant result (1/rank, 0 if not found) */
|
|
38
44
|
mrr: number;
|
|
39
45
|
/** Harmonic mean of precision_at_k and recall */
|
|
@@ -46,6 +52,10 @@ export interface BackendResult {
|
|
|
46
52
|
latency_ms: number;
|
|
47
53
|
/** Top result file paths (for inspection) */
|
|
48
54
|
top_files: string[];
|
|
55
|
+
/** Expected files that were found anywhere in the returned result set */
|
|
56
|
+
matched_files: string[];
|
|
57
|
+
/** Expected files missing from the returned result set */
|
|
58
|
+
unmatched_expected_files: string[];
|
|
49
59
|
}
|
|
50
60
|
export interface QueryResult {
|
|
51
61
|
id: string;
|
|
@@ -60,6 +70,9 @@ export interface BenchmarkResult {
|
|
|
60
70
|
summary: Record<string, {
|
|
61
71
|
avg_precision: number;
|
|
62
72
|
avg_recall: number;
|
|
73
|
+
avg_recall_at_1: number;
|
|
74
|
+
avg_recall_at_3: number;
|
|
75
|
+
avg_recall_at_5: number;
|
|
63
76
|
avg_mrr: number;
|
|
64
77
|
avg_f1: number;
|
|
65
78
|
avg_latency_ms: number;
|
package/dist/cli/qmd.d.ts
CHANGED
|
@@ -1,2 +1,28 @@
|
|
|
1
|
+
import { type OutputFormat } from "./formatter.js";
|
|
2
|
+
type CliLifecycleWritable = {
|
|
3
|
+
write(chunk: string | Uint8Array, callback?: (error?: Error | null) => void): boolean;
|
|
4
|
+
};
|
|
5
|
+
type FinishSuccessfulCliCommandOptions = {
|
|
6
|
+
command: string;
|
|
7
|
+
format?: OutputFormat;
|
|
8
|
+
cleanup?: () => Promise<void>;
|
|
9
|
+
exit?: (code: number) => void;
|
|
10
|
+
immediateExit?: (code: number) => void;
|
|
11
|
+
stdout?: CliLifecycleWritable;
|
|
12
|
+
stderr?: CliLifecycleWritable;
|
|
13
|
+
platform?: NodeJS.Platform;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Finish a successful CLI command after output has been flushed. On macOS JSON
|
|
17
|
+
* query runs, skip normal native teardown and use Node/Bun's immediate exit path:
|
|
18
|
+
* ggml Metal can abort from C++ finalizers after valid JSON has already been
|
|
19
|
+
* produced (#368). This wrapper is only reached after the command completed, so
|
|
20
|
+
* real query failures still exit through the normal error path before this runs.
|
|
21
|
+
*/
|
|
22
|
+
export declare function finishSuccessfulCliCommand(options: FinishSuccessfulCliCommandOptions): Promise<void>;
|
|
23
|
+
export declare function resolveEmbedModelForCli(): string;
|
|
24
|
+
export declare function resolveGenerateModelForCli(): string;
|
|
25
|
+
export declare function resolveRerankModelForCli(): string;
|
|
1
26
|
export declare function buildEditorUri(template: string, absolutePath: string, line: number, col: number): string;
|
|
2
27
|
export declare function termLink(text: string, url: string, isTTY?: boolean): string;
|
|
28
|
+
export {};
|