@infino-ai/infino 0.11.16 → 0.11.18

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/infino/index.d.ts CHANGED
@@ -325,6 +325,11 @@ export declare class Table {
325
325
  /** Count rows matching a BM25 keyword `query` over `column`, without
326
326
  * fetching them. `mode` is `"or"` (default) or `"and"`. */
327
327
  count(column: string, query: string, opts?: CountOptions): number;
328
+ /** The rows each SQL predicate (e.g. `"price > 500"`) holds, one count per
329
+ * predicate in order; `"true"` counts every row. Counted from the range
330
+ * index without running a query when each predicate is one range on one
331
+ * range-indexed column; one aggregate runs otherwise. */
332
+ countWhere(predicates: string[]): number[];
328
333
  /** `column`'s rows counted per value, as `SELECT column, COUNT(*) ...
329
334
  * GROUP BY column` gives them: one record per value with its `count(*)`, a
330
335
  * null value for the rows that hold none (or an Arrow `Table`). Read from
package/infino/index.js CHANGED
@@ -333,6 +333,13 @@ class Table {
333
333
  count(column, query, opts = {}) {
334
334
  return guard(this.remote, () => this.inner.count(column, query, opts.mode));
335
335
  }
336
+ /** The rows each SQL predicate (e.g. `"price > 500"`) holds, one count per
337
+ * predicate in order; `"true"` counts every row. Counted from the range
338
+ * index without running a query when each predicate is one range on one
339
+ * range-indexed column; one aggregate runs otherwise. */
340
+ countWhere(predicates) {
341
+ return guard(this.remote, () => this.inner.countWhere(predicates));
342
+ }
336
343
  valueCounts(column, opts = {}) {
337
344
  return decode(guard(this.remote, () => this.inner.valueCounts(column)), opts.arrow);
338
345
  }
@@ -396,6 +396,13 @@ export declare class Table {
396
396
  * fetching them. `mode` is `"or"` (default) or `"and"`.
397
397
  */
398
398
  count(column: string, query: string, mode?: string | undefined | null): number
399
+ /**
400
+ * The rows each SQL `predicate` (e.g. `"price > 500"`) holds, one count
401
+ * per predicate in order; `"true"` counts every row. Counted from the
402
+ * range index without running a query when each predicate is one range
403
+ * on one range-indexed column; one aggregate runs otherwise.
404
+ */
405
+ countWhere(predicates: Array<string>): Array<number>
399
406
  /**
400
407
  * `column`'s rows counted per value, as `SELECT column, COUNT(*) ...
401
408
  * GROUP BY column` gives them: Arrow rows of each value and its
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infino-ai/infino",
3
- "version": "0.11.16",
3
+ "version": "0.11.18",
4
4
  "description": "Fast search on object storage — SQL, full-text, and vector search.",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -82,12 +82,12 @@
82
82
  "apache-arrow": "^17"
83
83
  },
84
84
  "optionalDependencies": {
85
- "infx-darwin-x64": "0.11.16",
86
- "infx-darwin-arm64": "0.11.16",
87
- "infx-linux-x64-gnu": "0.11.16",
88
- "infx-linux-arm64-gnu": "0.11.16",
89
- "infx-linux-x64-musl": "0.11.16",
90
- "infx-linux-arm64-musl": "0.11.16"
85
+ "infx-darwin-x64": "0.11.18",
86
+ "infx-darwin-arm64": "0.11.18",
87
+ "infx-linux-x64-gnu": "0.11.18",
88
+ "infx-linux-arm64-gnu": "0.11.18",
89
+ "infx-linux-x64-musl": "0.11.18",
90
+ "infx-linux-arm64-musl": "0.11.18"
91
91
  },
92
92
  "devDependencies": {
93
93
  "@napi-rs/cli": "^2.18.0",