@functional-systems/srcx 0.1.0-dev.1 → 0.1.0-dev.11

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/VALIDATION.md CHANGED
@@ -4,12 +4,336 @@ Date: 2026-09-25 (Asia/Seoul).
4
4
 
5
5
  ## Evidence boundary
6
6
 
7
- This implementation has passed local fixtures/fault injection/SDK transport checks
8
- and a live synthetic A/B acceptance run against the user-supplied LambdaDB
9
- connection. Only generated test source was uploaded. No production repository
10
- source or paid embeddings were used, and no Git repository/npm package was
11
- published. Live evidence below is limited to this small fixture; it is not a
12
- throughput, general concurrency, or retrieval-quality benchmark.
7
+ The initial implementation passed local fixtures/fault injection/SDK transport checks,
8
+ a live synthetic A/B acceptance run, and an exact-package self-index of the public
9
+ srcx repository against the user-supplied LambdaDB connection. No private source
10
+ or paid embeddings were used. These checks are not a throughput, general
11
+ concurrency, or retrieval-quality benchmark. npm publication evidence is recorded
12
+ separately below. The persistent Git branch changes have a separate synthetic
13
+ live run recorded next; the earlier live runs do not validate this new path.
14
+
15
+ ## Click/Cobra development diagnostic
16
+
17
+ At frozen harness `4f7c865055749c82641015a2302983b034877e23`, 48 actual CLI searches
18
+ completed sequentially on pinned public Click/Python and Cobra/Go sources with
19
+ managed small and existing text fallback. All **455 handles and 231 reads** passed
20
+ source/version checks. Complete first-five evidence was lexical **7/16**, semantic
21
+ **5/16**, hybrid **8/16**; natural-language tasks scored **2/6, 2/6, 4/6**. Top-ten
22
+ candidate availability was **8/16, 11/16, 10/16**. These are fixed assistant-authored
23
+ implementation labels without independent review or agent answer grading.
24
+
25
+ Both imports published validated immutable versions; no command failures or
26
+ resumes occurred. Usage reservations were 388,771 document input tokens, 32 query
27
+ embeddings, 350 query input tokens and 48 searches. Completed replays preserved
28
+ report bytes/timestamps without service calls. Local Node 24.15.0 passed **78 tests**,
29
+ typecheck, formatting and version checks; frozen-harness Node 22/24 CI and installed
30
+ package checks passed. [Results and limitations](eval/TRANSFER-RESULTS.md) include
31
+ report hashes, inspected cases and coverage/output costs; [protocol](eval/TRANSFER-RUN.md)
32
+ records fixed budgets. Earlier draft-preparation evidence below remains historical.
33
+
34
+ ## Evaluation diagnostics and transfer draft
35
+
36
+ Evaluation subprocess failures now append safe command diagnostics with process
37
+ or JSON-decode stage, exit/signal metadata and allowlisted stderr. Fixture checks
38
+ cover no automatic retry, preservation across multiple failures, secret/source
39
+ omission, private file permissions, malformed output, output overflow and log-write
40
+ failure. This cannot recover stderr from old live failures. Node 24.15.0 passed
41
+ **75 tests**, typecheck, formatting and version checks for this follow-up.
42
+ The read-side regression invokes the actual `readHandle` for seven failure paths
43
+ and verifies both safe-message retention and omission of contaminated stderr.
44
+
45
+ A separate offline preparation imported pinned Click 8.1.8 and Cobra v1.9.1 Git
46
+ sources into local managed-small build artifacts, without service calls or
47
+ embedding generation. All 16 draft questions' byte hashes, source line ranges and
48
+ inclusion were verified. The 207 files contain 544 eligible chunks with 388,771
49
+ estimated embedding input tokens. Python/Go use the current text fallback; no new
50
+ parser or search behavior was added. These labels are assistant-authored and not
51
+ independently reviewed. See [draft protocol and reproduction](eval/TRANSFER-EVAL.md)
52
+ and [diagnostic retention rules](eval/COMMAND-DIAGNOSTICS.md). No retrieval quality,
53
+ provider cost or live operational reliability is measured by this preparation.
54
+
55
+ ## Retrieval mode comparison
56
+
57
+ At application/harness commit `de5a23bbc2f0712d134066354b4313420d21fccd`, the
58
+ actual CLI completed 48 searches across the same two managed corpora and fixed
59
+ 16-question suite. All **456 results/handles** and **236 reads** matched pinned
60
+ source and version facts. Revised-label complete evidence was lexical **16/16**,
61
+ semantic **8/16**, and hybrid **13/16**; unchanged original labels scored 14/16,
62
+ 8/16, and 11/16. These are diagnostic coverage measurements, not human answer grades.
63
+
64
+ All three hybrid regressions contained the required evidence in search's top ten,
65
+ but outside the first five reads. Keep lexical as the default pending fresh-task
66
+ ranking evaluation. The run also exposed a query response omitting one managed
67
+ vector; same-Tag fetch hydration now preserves non-vector payload equality and
68
+ hit order/scores. The failed attempt remains separate from the complete fresh run.
69
+
70
+ Node 22/24 passed **67 tests**, typechecking and installed-package CLI checks after
71
+ the fix. The completed live report was revalidated without new service calls, and
72
+ its bytes/timestamp were unchanged. See [full results](eval/RETRIEVAL-MODE-RESULTS.md)
73
+ for per-mode metrics, inspected misses, input/usage accounting, source revisions,
74
+ report hashes and evidence limits; [protocol](eval/RETRIEVAL-MODES.md) documents
75
+ reproduction and effects.
76
+
77
+ ## Query-style supplement
78
+
79
+ At harness commit `65c8e7060366f4df846c9b2bc08270e7337f0df1`, 72 searches tested
80
+ eight new tasks with identifier, natural-language and mixed formulations using
81
+ the same managed small model and the same two immutable publications. All
82
+ **696 result handles and 356 reads** matched source/version facts. Complete
83
+ first-five evidence by lexical/semantic/hybrid was **7/8, 7/8, 7/8** for identifiers,
84
+ **0/8, 3/8, 1/8** for natural descriptions and **5/8, 7/8, 6/8** for mixed queries.
85
+ These are eight paired tasks, not 24 independent judgments. Semantic helped on
86
+ this diagnostic; the original keyword-heavy result must not be generalized.
87
+
88
+ The frozen protocol adds verified candidate coverage at ranks 1/3/5/10, the first
89
+ complete prefix, stdout tokens and offline token-budget prefixes. No model,
90
+ ranking, read-selection or product default changed. The original suite/results
91
+ and incomplete run remain intact. A completed rerun preserved report bytes and
92
+ timestamp without service calls. Node 22.14.0 and 24.15.0 passed **69 tests**;
93
+ typecheck, formatting and frozen-harness CI passed. See [results and cases](eval/QUERY-STYLE-RESULTS.md),
94
+ [protocol](eval/QUERY-STYLES.md), and [embedding model research](eval/EMBEDDING-MODELS.md).
95
+
96
+ ## Managed small versus large comparison
97
+
98
+ At frozen harness `6fa65b541dc50debdfa4f9a6297301b2cb3c2b53`, small (1536 dimensions)
99
+ and large (3072 dimensions) completed 240 searches over identical pinned source/chunk inputs.
100
+ All **2,304 result handles and 1,184 reads** passed source/version validation.
101
+ Style-suite complete top-five evidence was semantic **17/24 → 16/24** and hybrid
102
+ **14/24 → 16/24**; natural semantic improved **3/8 → 4/8**. The separate regression
103
+ set scored semantic **8/16 → 8/16** and hybrid **13/16 → 12/16**. All 40 lexical
104
+ candidate lists matched across models. Small coverage repeated the earlier runs.
105
+
106
+ An initial large attempt stopped twice with an unknown CLI search error; its
107
+ 19 partial rows and two successful diagnostic queries remain excluded. A fresh
108
+ isolated run reused the same publications and completed without changing the
109
+ frozen protocol. All four completed reports revalidated without service calls
110
+ and retained their bytes/timestamps. Keep small as the initial managed choice
111
+ and large opt-in; these familiar diagnostic tasks do not establish a model winner.
112
+
113
+ Node 22.14.0 and 24.15.0 passed **72 tests**, typecheck and installed-package CLI
114
+ checks covering lexical/small/large. Formatting/version checks and frozen-code
115
+ CI passed. [Full results](eval/MODEL-COMPARISON-RESULTS.md) record per-query changes,
116
+ report hashes, original-label scores, all five roots' reserved usage, and limits;
117
+ [protocol](eval/MODEL-COMPARISON.md) records the predeclared comparison.
118
+
119
+ Review follow-up: resume and completed replay now reject saved rows whose category
120
+ is missing or differs from the frozen question, even when the stored summary was
121
+ recomputed to match the corruption. The subprocess regression first reproduced
122
+ the acceptance bug, then passed with the guard; valid replay and rejected reports
123
+ both preserve their bytes. Node 24.15.0 passed **73 tests** after this change.
124
+ The four completed model reports have no category mismatches and remain unchanged.
125
+ Their frozen harness remains the revision recorded above; the new harness requires
126
+ fresh run roots rather than rewriting historical runtime fingerprints.
127
+
128
+ ## Managed OpenAI embedding acceptance
129
+
130
+ The opt-in managed preset passed a separate synthetic live run at application and
131
+ harness commit `177731386f76a13723a83aa8470d4e0715e29424` using Node 24.15.0 and
132
+ the user-supplied development connection. It completed at
133
+ `2026-09-24T20:46:46.305Z` in 111.706 seconds. Only synthetic source was uploaded.
134
+
135
+ - Both commits published validated immutable Tags, with six generated 1536-number
136
+ vectors in each corpus. Mixed file/manifest records correctly omitted vectors.
137
+ - Six filtered searches (lexical, semantic and hybrid for each version) returned
138
+ 14 result handles; every full-file read matched the pinned Git blob byte for byte.
139
+ - The second import skipped unchanged records, removed deleted content, and kept
140
+ the original version's handle readable. Fresh repository discovery preserved the
141
+ managed preset and schema.
142
+ - Ordinary upserts submitted ten eligible chunk inputs across both imports. The
143
+ preflight upper bound was 167 estimated document input tokens; four searches
144
+ requested query embeddings. These counts are not provider-reported billed usage.
145
+
146
+ The first run at `fb5b6d8` correctly remained unpublished: this deployment omitted
147
+ vectors from list responses despite `includeVectors=true`, while fetch/query on
148
+ that same Tag returned them. The transport now fetches those listed IDs from the
149
+ same immutable Tag and requires exact non-vector payload equality before vector
150
+ validation. Regression checks reject missing fetch records and changed payloads.
151
+ The failed run and retry journal remain under `.srcx/live-managed/`; they were not
152
+ relabelled as successful evidence. The successful run has a separate Collection
153
+ and evidence directory, `.srcx/live-managed-verified/`, in the validation worktree.
154
+ Both synthetic Collections are retained for inspection.
155
+
156
+ The successful report SHA-256 is
157
+ `6c96ac8af9b79c85e98c84f1f01851906f0b1b3e4d96b51d9417cb59380ac532`;
158
+ its runtime fingerprint is
159
+ `7d8a8006820ee523a88e80d6614327000ce305cffafe377d18fda5b50ba9c947`.
160
+ A same-runtime rerun made no service calls and preserved the original report bytes.
161
+ The harness rejects changed runtime/destination/Node inputs and incomplete runs
162
+ before new requests; recovery after uncertain writes remains explicit.
163
+
164
+ Node 22.14.0 and 24.15.0 each passed **61 tests**, typechecking, and installed-tarball
165
+ CLI checks for both presets. Formatting, version validation and diff checks passed.
166
+ Local tests cover generated-vector failures, exact payload validation, unchanged
167
+ record reuse, uncertain-write recovery, preset/schema drift, query serialization,
168
+ and credential-free managed previews. Live checks used the built application APIs;
169
+ installed-package CLI checks used the loopback fault-injection store.
170
+ These checks establish integration/source correctness, not semantic relevance gains
171
+ or performance on real repositories. The earlier lexical evaluations remain separate.
172
+
173
+ ## Default CLI search/read evaluation
174
+
175
+ The follow-up uses actual built CLI subprocesses with the unchanged default
176
+ syntax/path-scope-symbol preset across pinned public `srcx` and `lambdadb-cli`
177
+ commits. At harness commit `57b63e1cdbf7ec722b95bb0f40ac0ef5039af3e8`, both
178
+ publications validated and all **136 search results/handles** and **76 read
179
+ responses** matched their pinned source, version and citation. No embeddings
180
+ were used. The run completed at `2026-09-24T20:01:58.865Z`.
181
+
182
+ The frozen 16-question suite recovered complete labeled evidence for **14/16**.
183
+ The two remaining cases reflect a one-byte blank-line boundary and an omitted
184
+ alternative document/code answer, not demonstrated source-integrity failures.
185
+ Mean full CLI stdout was **7,383 tokens** per query. This fixed-five-read protocol
186
+ is distinct from the earlier full-chunk/token-budget comparison; neither measures
187
+ general task success. Labels remain assistant-authored without independent human
188
+ review. See [eval/CLI-RESULTS.md](https://github.com/lambdadb/srcx/blob/develop/eval/CLI-RESULTS.md)
189
+ for per-repository scores, inspected misses and evidence boundaries, and
190
+ [eval/CLI-WORKFLOW.md](https://github.com/lambdadb/srcx/blob/develop/eval/CLI-WORKFLOW.md)
191
+ for reproduction and normal Collection effects.
192
+
193
+ Local Node 24.15.0 passed **54 tests**, typechecking, formatting/version checks and
194
+ the installed-package CLI contract. Node 22/24 CI passed at the harness commit.
195
+ Live execution used built CLI subprocesses; package validation used a loopback
196
+ fixture. A completed rerun preserved the original report bytes and timestamp.
197
+ Raw evidence and recovery journals remain under `.srcx/cli-eval/` in the validation
198
+ worktree; the older pilot's original report remains unchanged.
199
+
200
+ ## Retrieval evaluation harness
201
+
202
+ The internal pilot adds five checks for unique source-range scoring, token-budget
203
+ prefix selection, source/hit integrity, equal path-only enrichment, and rejecting
204
+ stale runtime checkpoints before any connection. With these checks, Node.js
205
+ 24.15.0 passed **50 tests**, typechecking, version validation, and clean installed
206
+ package checks. The default CLI preset and config hash remain unchanged.
207
+
208
+ The suite fixes 16 queries, expected source byte ranges, and two full Git commits
209
+ before retrieval. Both chunkers materialize the same included files, use separate
210
+ config identities, and run through the existing immutable publication validation.
211
+ Live retrieval observations and limitations are in [eval/RESULTS.md](https://github.com/lambdadb/srcx/blob/develop/eval/RESULTS.md),
212
+ with reproduction instructions in [eval/README.md](https://github.com/lambdadb/srcx/blob/develop/eval/README.md). These diagnostic
213
+ labels were authored from source before querying and are not independently
214
+ human-reviewed judgments or a general retrieval-quality benchmark.
215
+
216
+ Post-review, `splitEvidence` now requires complete coverage of all required ranges
217
+ before classifying a result as split across chunks. The multi-range regression
218
+ brings the local suite to **51 passing tests**. Offline rescoring of all 32 retained
219
+ query/method pairs preserved every metric and category summary. The original live
220
+ report, runtime fingerprint, and completion timestamp were not changed.
221
+
222
+ ## Persistent Git branch tracking
223
+
224
+ Local regression coverage exercises one writer across consecutive commits,
225
+ branch-local deletion/diff baselines, separate branches sharing canonical Tags,
226
+ rewinds to already published commits, and imports from fresh local state. Fault
227
+ injection verifies last-published branch resolution during partial writes, pending
228
+ ownership protection when the local journal is missing, stale/corrupt candidate
229
+ rejection, and retries after uncertain control writes. Branch/tag ambiguity and
230
+ explicit full refs are covered.
231
+
232
+ The CLI fixture also imports and updates a tracked branch through the real SDK
233
+ transport and selects it for search, resolve, and read. The same fixture runs
234
+ against the installed tarball. These checks use a loopback fault-injection model,
235
+ not a live LambdaDB deployment.
236
+
237
+ A separate **live LambdaDB run passed all 12 checkpoints** on September 25 using
238
+ Node **24.15.0**, application source commit
239
+ `f42a9141cef3bfc0b604e1b14a00c79607c7dd98`, and the original checkout's `.env.local`
240
+ loaded explicitly through Node. The run took **414.195 seconds** and uploaded only
241
+ synthetic Git source with no paid embeddings. It verified:
242
+
243
+ - First-import timeout remains unpublished, followed by same-journal recovery.
244
+ - A -> B uses one fixed Collection Branch; pending B still resolves/searches A,
245
+ and a fresh local state cannot overwrite that pending branch.
246
+ - Added/modified/deleted code searches correctly after B; old A evidence still
247
+ reads the exact original source bytes.
248
+ - A second Git branch shares canonical A/B Tags while maintaining its own writer
249
+ baseline, including B -> A -> B movement and an unchanged repeated import.
250
+ - A SHA-only new commit uses a manual `work-*` writer.
251
+
252
+ A separate invocation of the actual CLI against that live Collection passed
253
+ branch `resolve`, branch-selected `search`, and a full-file `read` compared byte
254
+ for byte with the pinned Git blob. It used the built CLI, not a registry-installed
255
+ package. Local installed-package evidence remains separate above.
256
+
257
+ The reproducible harness is `scripts/live-branches.mjs` (`npm run
258
+ test:live:branches`). Its ignored evidence is `.srcx/live-branches/report.json`
259
+ and `.srcx/live-branches/cli-report.json` in the validation worktree. The report
260
+ records the exact source commit, harness SHA-256, per-check results, and resource
261
+ URL. One synthetic Collection is retained with two tracked writers, one manual
262
+ writer, the two control/checkpoint Branches, three canonical commit Tags, and seven
263
+ candidate Tags. No application fix was needed during this live run.
264
+
265
+ On Node **22.14.0** and **24.15.0**, typechecking, all **43 tests**, and installed
266
+ package checks passed. Formatting, release-version validation, and `git diff
267
+ --check` also passed locally. These results are not GitHub CI evidence.
268
+
269
+ ## Final branch review validation
270
+
271
+ The final pre-PR review reproduced a read-order race: a concurrent publication
272
+ could advance branch control beyond the version list already captured by the
273
+ reader. Resolution now pins the control record first. The review also found that
274
+ live reruns could skip saved checkpoints while replacing the reported source
275
+ revision; checkpoints now require matching runtime, harness, fixture, lockfile,
276
+ and Node fingerprints and preserve their original revision/completion time.
277
+ Regression tests cover both cases, including rejecting stale evidence before any
278
+ connection or report mutation.
279
+
280
+ After these fixes, Node **22.14.0** and **24.15.0** each passed typechecking,
281
+ all **45 tests**, and installed-package checks. Formatting, release-version
282
+ validation, and diff checks passed locally.
283
+
284
+ A fresh synthetic live run at application/harness commit
285
+ `2988c7e1826a44cfed48381681d0125b28ae9086` passed all **12 checkpoints** in
286
+ **432.836 seconds**. The built CLI also passed live branch resolution,
287
+ search, and exact source reads. Final reports are retained separately under
288
+ `.srcx/live-branches-review/report.json` and
289
+ `.srcx/live-branches-review/cli-report.json`; the previous run remains intact.
290
+ This final run retained one synthetic Collection with two tracked writers, one
291
+ manual writer, two control/checkpoint Branches, three canonical commit Tags,
292
+ and seven candidate Tags. CI evidence, once available on the PR, is separate
293
+ from these local and live results.
294
+
295
+ ## Initial npm package and live self-index
296
+
297
+ The exact `0.1.0-dev.1` tarball from merged commit
298
+ `f94f947bf593b2f8498c07e130933b0ab444f868` passed clean installation, CLI execution,
299
+ WASM parsing, and the loopback import/search/read contract. Its installed CLI then
300
+ imported that same Git commit into LambdaDB: **37 files, 260 chunks**, with
301
+ inventory, content, and query validation passing. A `validateBuild` query returned
302
+ three results from `src/build.ts`; the full-file read matched the pinned Git blob
303
+ byte for byte. This was a lexical-only import (`embedding=none`).
304
+
305
+ The first npm publication used this tested tarball with the `dev` dist-tag. The
306
+ registry tarball's SHA-512 matched the candidate, and a clean installation of the
307
+ downloaded registry tarball passed the same CLI contract. Registry signatures are
308
+ present. The local bootstrap has no GitHub Actions provenance. npm also created
309
+ `latest=0.1.0-dev.1`; that tag does not represent a stable release.
310
+
311
+ Local evidence is retained under `.srcx/releases/0.1.0-dev.1-f94f947/` (ignored),
312
+ including `candidate.json`, `live-publication.json`, `live-verification.json`,
313
+ `registry-version.json`, and the exact candidate and downloaded tarballs.
314
+ The source commit's [Node 22/24 CI](https://github.com/lambdadb/srcx/actions/runs/36035063463)
315
+ also passed. Current distribution and automation status is in
316
+ [RELEASING.md](RELEASING.md).
317
+
318
+ ## First automatic development publication
319
+
320
+ [CI attempt 3](https://github.com/lambdadb/srcx/actions/runs/36035063463/attempts/3)
321
+ published `0.1.0-dev.3` using npm Trusted Publishing from the same reviewed commit.
322
+ The version suffix is the first-parent commit count. The registry's `gitHead`
323
+ and SLSA provenance both identify `f94f947bf593b2f8498c07e130933b0ab444f868`;
324
+ provenance also identifies `lambdadb/srcx`, `.github/workflows/publish.yaml`, and
325
+ the GitHub-hosted workflow run. The downloaded tarball's SHA-512 matches registry
326
+ metadata. A clean install by package name/version passed CLI execution and the
327
+ loopback import/search/read contract. `npm audit signatures` verified all eight
328
+ installed registry signatures and three attestations, including srcx provenance.
329
+ `dev=0.1.0-dev.3`; `latest=0.1.0-dev.1` remains the bootstrap prerelease.
330
+
331
+ The initial automatic attempt stopped during the pre-write metadata lookup while
332
+ npm's full package listing still returned 404. After the listing became visible,
333
+ only the failed publishing job was rerun. No publication write was retried to
334
+ work around propagation. Local evidence is retained in `registry-dev3.json`,
335
+ `attestations-dev3.json`, and `provenance-dev3.json` under the release directory
336
+ above. No stable release, GitHub Release, or Homebrew formula was created.
13
337
 
14
338
  ## Local checks
15
339
 
@@ -76,11 +400,9 @@ The test suite covers:
76
400
  reruns. Simulated registry delays/failures verify bounded post-write reads and
77
401
  no automatic publication retry; no test writes to npm.
78
402
 
79
- Release infrastructure is prepared in `.github/workflows/publish.yaml` for Node
80
- 22/24. Local validation does not establish GitHub Actions or npm publication
81
- success. Initial npm registration, package-specific Trusted Publisher setup, and
82
- enabling `NPM_DEV_PUBLISH_ENABLED` remain separate release steps. See
83
- [RELEASING.md](RELEASING.md); no npm or Homebrew release was performed in this setup.
403
+ Release infrastructure is in `.github/workflows/publish.yaml` for Node 22/24.
404
+ The local checks above are distinct from the CI, npm, and live-service evidence
405
+ recorded separately. No stable/rc or Homebrew release has been performed.
84
406
 
85
407
  The demo writes [.srcx/demo-report.json](.srcx/demo-report.json). That generated
86
408
  report identifies the retained synthetic repository, A/B build artifacts, counts,
@@ -94,19 +416,22 @@ interface verifies eligibility/cache behavior only; production provider selectio
94
416
  semantic/hybrid querying, pricing, and evaluation remain open. Public imports
95
417
  reject a vector-enabled build to prevent fixture vectors from reaching LambdaDB.
96
418
 
97
- Each import gets a fresh `work-*` Branch, with incremental reuse only from an exact
98
- validated previous writer snapshot. Existing writers are not mutated after
99
- publication. Persistent `git-*` tracking, automatic failed-workspace recovery,
100
- Alias pruning, and garbage collection are not yet implemented. Failed/candidate
419
+ Git branch imports reuse a fixed `git-*` Branch with its last validated immutable
420
+ baseline; SHA/tag-only imports retain frozen `work-*` writers. Automatic Git
421
+ observation, failed-workspace recovery, branch rename/deletion handling, Alias
422
+ pruning, and garbage collection are not yet implemented. Failed/candidate
101
423
  resources and build artifacts are retained. A single importing host is required;
102
- the local lock is not a distributed lease.
424
+ the local lock is not a distributed lease. Remote pending ownership prevents
425
+ accidental adoption from fresh local state but is not a distributed compare-and-set
426
+ or lease protocol.
103
427
 
104
428
  Parsing uses the pinned packaged grammars. Unsupported/new syntax can fall back
105
429
  and is recorded; no claim of complete language-version coverage is made. There is
106
430
  no optimal-chunking claim. The fixed-window baseline is implemented internally;
107
- the planned 10–20-query retrieval comparison has not been run. The in-memory test
108
- model does not approximate Lucene ranking, distributed indexing, retention, or
109
- compaction timing.
431
+ the first 16-query live lexical comparison is recorded in [eval/RESULTS.md](https://github.com/lambdadb/srcx/blob/develop/eval/RESULTS.md).
432
+ It is a single-repository diagnostic, not a general optimal-chunking result. The
433
+ in-memory test model does not approximate Lucene ranking, distributed indexing,
434
+ retention, or compaction timing.
110
435
 
111
436
  Canonical publication records exist on main; listings require both the remote
112
437
  summary and the matching immutable Tag manifest. A candidate or a lone `ver-*`
package/dist/build.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { type Identity } from "./git.js";
1
+ import { resolveCommit, type Identity } from "./git.js";
2
2
  import { CHUNKER } from "./chunk.js";
3
3
  import { type Doc } from "./common.js";
4
4
  export declare const INDEX_CONFIGS: {
@@ -26,13 +26,82 @@ export type Preset = {
26
26
  schemaVersion: 1;
27
27
  chunker: typeof CHUNKER;
28
28
  mode: "syntax" | "window";
29
+ /** Internal evaluation override; the CLI keeps its original enrichment. */
30
+ enrichment?: "path-only-v1";
29
31
  maxFileBytes: number;
30
32
  embedding: {
31
33
  model: string;
32
34
  dimensions: number;
35
+ managed?: true;
36
+ provider?: "openai";
37
+ similarity?: "cosine";
38
+ sourceField?: "embeddingText";
33
39
  } | null;
34
40
  };
35
41
  export declare const PRESET: Preset;
42
+ /** Opt-in managed preset; PRESET stays byte-for-byte compatible with lexical corpora. */
43
+ export declare const MANAGED_PRESET: Preset;
44
+ export declare const MANAGED_LARGE_PRESET: Preset;
45
+ export declare function presetFor(embedding?: string): Preset;
46
+ export declare function supportedPreset(preset: unknown): preset is Preset;
47
+ export declare function indexConfigs(preset?: Preset): {
48
+ readonly kind: {
49
+ readonly type: "keyword";
50
+ };
51
+ readonly path: {
52
+ readonly type: "keyword";
53
+ };
54
+ readonly language: {
55
+ readonly type: "keyword";
56
+ };
57
+ readonly fileId: {
58
+ readonly type: "keyword";
59
+ };
60
+ readonly symbol: {
61
+ readonly type: "keyword";
62
+ };
63
+ readonly searchText: {
64
+ readonly type: "text";
65
+ readonly analyzers: readonly ["standard"];
66
+ };
67
+ } | {
68
+ embeddingText: {
69
+ type: string;
70
+ analyzers: string[];
71
+ };
72
+ embedding: {
73
+ type: string;
74
+ managedEmbedding: boolean;
75
+ embedding: {
76
+ model: string;
77
+ dimensions: number;
78
+ provider?: "openai";
79
+ similarity?: "cosine";
80
+ sourceField?: "embeddingText";
81
+ };
82
+ };
83
+ kind: {
84
+ readonly type: "keyword";
85
+ };
86
+ path: {
87
+ readonly type: "keyword";
88
+ };
89
+ language: {
90
+ readonly type: "keyword";
91
+ };
92
+ fileId: {
93
+ readonly type: "keyword";
94
+ };
95
+ symbol: {
96
+ readonly type: "keyword";
97
+ };
98
+ searchText: {
99
+ readonly type: "text";
100
+ readonly analyzers: readonly ["standard"];
101
+ };
102
+ };
103
+ /** Validate server enrichment separately; all other payload fields remain exact. */
104
+ export declare function recordHash(doc: Doc, preset: Preset): string;
36
105
  export type InventoryItem = {
37
106
  path: string;
38
107
  pathBase64: string;
@@ -48,6 +117,8 @@ export type InventoryItem = {
48
117
  parseStatus?: string;
49
118
  tokens?: number;
50
119
  embedded?: number;
120
+ managed?: number;
121
+ managedTokens?: number;
51
122
  skipped?: number;
52
123
  };
53
124
  export type Build = {
@@ -84,6 +155,7 @@ export declare function loadBuild(directory: string): Promise<Build>;
84
155
  export declare function materialize(args: {
85
156
  identity: Identity;
86
157
  ref: string;
158
+ resolvedCommit?: Awaited<ReturnType<typeof resolveCommit>>;
87
159
  output: string;
88
160
  previous?: Build;
89
161
  preset?: Preset;