@vxil/sdk 0.11.0 → 0.12.0
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/dist/index.d.ts +21 -3
- package/dist/index.js +8 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -741,7 +741,14 @@ export interface SearchHit {
|
|
|
741
741
|
chunk_id: string;
|
|
742
742
|
doc_id: string;
|
|
743
743
|
text: string;
|
|
744
|
+
/** the fused RANK value (reciprocal-rank fusion: ≈ 1/61 for the first hit at
|
|
745
|
+
* the default rrf_k) — it orders the hits; it is NOT a similarity, so never
|
|
746
|
+
* threshold on it. */
|
|
744
747
|
score: number;
|
|
748
|
+
/** cosine similarity of the hit to the query (−1…1, higher = closer) — the
|
|
749
|
+
* value to threshold on. null when the query used no vector (mode
|
|
750
|
+
* 'keyword', or a bring-your-own-vectors collection queried by text only). */
|
|
751
|
+
similarity: number | null;
|
|
745
752
|
/** provider relevance score — present only when the hit went through the
|
|
746
753
|
* configured BYO reranker (`reranked: true` on the result set). */
|
|
747
754
|
rerank_score?: number;
|
|
@@ -1499,6 +1506,9 @@ export interface RagSearchHit {
|
|
|
1499
1506
|
text: string;
|
|
1500
1507
|
/** the raw retrieval score (RRF, or rerank relevance when reranked). */
|
|
1501
1508
|
score: number;
|
|
1509
|
+
/** cosine similarity of the hit to the query, passed through from
|
|
1510
|
+
* vector-search (−1…1; null when retrieval used no query vector). */
|
|
1511
|
+
similarity?: number | null;
|
|
1502
1512
|
/** the effective post-boost score results are RANKED by — present only when
|
|
1503
1513
|
* metadata boosts applied (rag.md §2f). */
|
|
1504
1514
|
boosted_score?: number;
|
|
@@ -3998,9 +4008,12 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
|
|
|
3998
4008
|
/** The deployed functions (name, endpoint, bindings, scopes, limits, the
|
|
3999
4009
|
* runtime each script runs under), `runtime`, the settings a deploy uses
|
|
4000
4010
|
* now, and `cpuMsCeiling`, the per-invocation CPU limit (ms) the plan
|
|
4001
|
-
* gives a function now (its own `limits.cpuMs` can only lower it)
|
|
4002
|
-
*
|
|
4011
|
+
* gives a function now (its own `limits.cpuMs` can only lower it), and
|
|
4012
|
+
* `enabled`: false while the project's functions are paused as a whole
|
|
4013
|
+
* (a Free project on the production workload, a downgrade) — invokes then
|
|
4014
|
+
* answer 404. Any authenticated key may read it. (GET /v1/functions) */
|
|
4003
4015
|
list: () => Promise<{
|
|
4016
|
+
enabled?: boolean;
|
|
4004
4017
|
functions: DeployedFunction[];
|
|
4005
4018
|
runtime?: {
|
|
4006
4019
|
compatibilityDate: string;
|
|
@@ -4028,11 +4041,13 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
|
|
|
4028
4041
|
hook_reconcile?: {
|
|
4029
4042
|
created: number;
|
|
4030
4043
|
updated: number;
|
|
4044
|
+
unchanged?: number;
|
|
4031
4045
|
deleted: number;
|
|
4032
4046
|
failed: number;
|
|
4033
4047
|
};
|
|
4034
4048
|
cron_schedules?: {
|
|
4035
4049
|
created: number;
|
|
4050
|
+
unchanged?: number;
|
|
4036
4051
|
deleted: number;
|
|
4037
4052
|
failed: number;
|
|
4038
4053
|
};
|
|
@@ -5146,7 +5161,10 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
|
|
|
5146
5161
|
}) => Promise<RagStreamHandle>;
|
|
5147
5162
|
/** Retrieval-only grounding preview (rag.md §1c): the exact chunks `answer`
|
|
5148
5163
|
* would ground on, with rerank + metadata boosts applied — no generation,
|
|
5149
|
-
* no token spend. `boosts`/`rerank`/`min_score` override the rag config.
|
|
5164
|
+
* no token spend. `boosts`/`rerank`/`min_score` override the rag config.
|
|
5165
|
+
* `min_score` floors the EFFECTIVE `score`, which is a RANK value (about
|
|
5166
|
+
* 0.016–0.033 at the top): a floor above ~0.033 drops every hit. Judge
|
|
5167
|
+
* relevance by each hit's `similarity` (cosine, -1..1) instead. */
|
|
5150
5168
|
search: (input: {
|
|
5151
5169
|
query: string;
|
|
5152
5170
|
collection?: string;
|
package/dist/index.js
CHANGED
|
@@ -1388,8 +1388,10 @@ export class Vxil {
|
|
|
1388
1388
|
/** The deployed functions (name, endpoint, bindings, scopes, limits, the
|
|
1389
1389
|
* runtime each script runs under), `runtime`, the settings a deploy uses
|
|
1390
1390
|
* now, and `cpuMsCeiling`, the per-invocation CPU limit (ms) the plan
|
|
1391
|
-
* gives a function now (its own `limits.cpuMs` can only lower it)
|
|
1392
|
-
*
|
|
1391
|
+
* gives a function now (its own `limits.cpuMs` can only lower it), and
|
|
1392
|
+
* `enabled`: false while the project's functions are paused as a whole
|
|
1393
|
+
* (a Free project on the production workload, a downgrade) — invokes then
|
|
1394
|
+
* answer 404. Any authenticated key may read it. (GET /v1/functions) */
|
|
1393
1395
|
list: async () => (await this.call('GET', '/v1/functions')).data,
|
|
1394
1396
|
/**
|
|
1395
1397
|
* Remove ONE function from the deployed set — a new functions config
|
|
@@ -1903,7 +1905,10 @@ export class Vxil {
|
|
|
1903
1905
|
stream: async (input) => (await this.call('POST', '/v1/rag/answer', { ...input, stream: true })).data,
|
|
1904
1906
|
/** Retrieval-only grounding preview (rag.md §1c): the exact chunks `answer`
|
|
1905
1907
|
* would ground on, with rerank + metadata boosts applied — no generation,
|
|
1906
|
-
* no token spend. `boosts`/`rerank`/`min_score` override the rag config.
|
|
1908
|
+
* no token spend. `boosts`/`rerank`/`min_score` override the rag config.
|
|
1909
|
+
* `min_score` floors the EFFECTIVE `score`, which is a RANK value (about
|
|
1910
|
+
* 0.016–0.033 at the top): a floor above ~0.033 drops every hit. Judge
|
|
1911
|
+
* relevance by each hit's `similarity` (cosine, -1..1) instead. */
|
|
1907
1912
|
search: async (input) => (await this.call('POST', '/v1/rag/search', input)).data,
|
|
1908
1913
|
/** Ingest into the backing vector-search collection (chunk → embed → index). */
|
|
1909
1914
|
ingest: async (collection, input) => (await this.call('POST', `/v1/rag/ingest/${encodeURIComponent(collection)}`, input)).data,
|
package/package.json
CHANGED