Vector Search & Analytics

Find the match. Understand the data.

Vector search finds similar content, even when the words differ. SQL answers structured questions about your data. Minds gives your agents both, from finding a related support issue to analyzing when those issues occur.

Vector analytics

Different words. The right context.

A question does not have to quote the answer. Explore related records, narrow the set, and read the source.

Why is checkout taking so long?Support collection
2 related recordsCheckout only
SUP-208Source passage

Payment confirmation delay

Customers wait for the confirmation screen after the payment provider accepts the transaction.

Support conversation · September 8

Original context included

Open the source behind the match.

A result is useful when you can read it. Choose a record to inspect its original passage and provenance.

Choose a chapter to explore

Interactive example collection with illustrative similarity scores.

Meaning meets structure

Search the meaning. Query the details.

A question about slow checkout can lead to a report about payment delays. Use a product-specific index to focus the search, then query structured records in SQL to count issues and compare when they occurred.

01

Similarity

Find related content

An embedding represents the meaning of content as numbers. Minds indexes those vectors so you can search for nearby matches in your own data.

02

Metrics

Choose how to compare

Match the comparison method to your embedding model. Choose cosine similarity, Euclidean distance, or dot product when you create an index.

03

Search

Choose the right index

Choose the relevant index and request the number of neighbors your agent needs. Use returned identifiers to connect matches to records in your application.

04

SQL

Ask questions in SQL

Count records, group results, and compare trends using SQL. The DataFusion query engine handles the execution behind those familiar queries.

05

Data exchange

Work with columnar data

The analytics engine uses Apache Arrow to represent data in columns, with Arrow Flight support for transferring tabular results.

06

Sources

Bring your data

Register CSV files, Parquet files, or core storage as query sources. Analyze the records relevant to your application.

Build with your data

Start with a match. Follow with a question.

Create an index with the dimensions your embedding model produces, add identified vectors, then search it. Use the analytics interface for SQL over registered tables.

Create an index and search a sample vectortypescript
// Run server-side with credentials scoped to this Mind.
const endpoint = process.env.AKASHA_URL;
const capability = process.env.AKASHA_CAPABILITY;
if (!endpoint || !capability) throw new Error("Configure your Mind connection");

async function request(method: string, path: string, body?: unknown) {
  const headers: Record<string, string> = {
    "Content-Type": "application/json",
    "x-akasha-capability": capability!,
  };
  if (process.env.AKASHA_TOKEN) {
    headers.Authorization = "Bearer " + process.env.AKASHA_TOKEN;
  }
  const response = await fetch(new URL(path, endpoint), {
    method, headers,
    body: body === undefined ? undefined : JSON.stringify(body),
  });
  if (!response.ok) throw new Error("Mind request failed: " + response.status);
  return response.json();
}

// Three dimensions keep this example readable.
// Use the dimensions and vectors produced by your embedding model.
await request("POST", "/v1/ml/vector/create", {
  name: "filings", dims: 3, metric: "cosine",
});
await request("POST", "/v1/ml/vector/add", {
  name: "filings", id: crypto.randomUUID(), vector: [0.2, 0.5, 0.8],
});
const { matches } = await request("POST", "/v1/ml/vector/search", {
  name: "filings", vector: [0.2, 0.4, 0.9], k: 5,
});
// Query your registered analytics sources through /v1/analytics/sql.
Technical details

Tune retrieval to your application.

HNSW indexes embeddings for approximate similarity search, with settings for balancing recall and search cost. DataFusion runs SQL over your registered data sources.

HNSW
Input
Embeddings from your chosen model
Index type
HNSW
Metrics
cosine · euclidean · dot
HTTP operations
create · add · search · save
Search request
name · vector · k
DataFusion
Queries
Read-only SQL SELECT
SQL engine
DataFusion + Arrow
Streaming
Arrow Flight gRPC
Sources
csv · parquet · core
SQL route
POST /v1/analytics/sql

Make your data useful to your agents.

Find related information and ask structured questions about it, with search and analytics on your dedicated Mind.