Developer Guide

The full reference. Getting Started gets you from API key to first query in ten minutes -- this is the addendum for everything after that: every connector, full tier/rate-limit behaviour, every error code, and the REST reference for non-Python clients.

Ingestion connectors -- full reference

connect() infers the connector from the URL scheme where it can, or accepts connector= explicitly. Every connector hands each record to the same local pipeline. The scout looks at the record first and works out what each field is; numbers carry on through the profiler > classifier > accumulator > detector described in Getting Started, and everything else is kept with its value -- only the resulting episodes leave your device.

ConnectorScheme / triggerKey arguments
HTTPConnectorhttp://, https://interval_s=1.0, headers=None, timeout_s=10.0
WebSocketConnectorws://, wss://url only
MQTTConnectormqtt://host, topic, port=1883, username=None, password=None
FileConnector.jsonl/.csv/.json path, or file://format="auto", replay_rate_hz=0.0 (0 = as fast as possible)
GeneratorConnectorconnector="generator"source (iterable or callable), interval_s=0.0
DataFrameConnectorconnector="dataframe"df (pandas DataFrame), timestamp_column=None, replay_rate_hz=0.0
PipeConnectorconnector="pipe"stream=None (defaults to stdin)

Calling connect() again on an already-connected client stops the previous connector first -- you can re-point a running client at a new source without creating a second one.

What the connectors read -- the scout (vaas-x 0.1.15 and later)

A source can hold more than numbers. The scout sorts every field of every record before anything else sees it, and nothing it does changes how a purely numeric stream behaves.

What the field isWhat happens to it
Number (and a number sent as text, such as "42.5")Becomes a sensor channel: profiled, classified and watched by the detector, exactly as before.
true / falseStays a channel (as 1 and 0) and is kept as a real true or false in the episode.
Identifier (id, user_id, userId, uuid)Kept, but never a channel: an id is a name, not a signal.
Text, a title, a descriptionKept with its value in the episode text, so an agent that recalls it can read it. Long text is split into parts of about 1,500 characters, each its own linked episode.
TimestampKept as text. It is ignored when deciding whether a record is a repeat.
A nested objectOpened up to three levels, with dotted names such as owner.login. Lists are kept as short JSON text.

An episode built from a record with more than numbers has text such as Readings: name="vaas-x", private=false, description="Persistent memory for agents", stargazers_count=44, ..., most useful fields first and web addresses last, cut with a note of what was left out if it is long. The real values are kept in the episode and returned in the data object of query() and get_episode().

A web address can return JSON (an object or a list of objects), an RSS or Atom feed (one record per entry), or a plain text or HTML page (one text record). Repeats: a record with text or other non-numeric content that is exactly what was stored a moment ago -- a feed polled again with no new stories -- is stored once. A purely numeric reading is never skipped, because the same value twice in a row is a real reading. Pass dedupe=False to connect() to store everything, or dedupe=True to skip any exact repeat.

Say what the fields mean -- the data dictionary (vaas-x 0.1.16 and later)

A feed gives names, not meanings. GitHub's watchers_count is the number of stars (an old name); the real watchers are subscribers_count. An agent that reads watchers_count=44 cannot know that, and guessing from the name gives the wrong answer. Write the meanings down once and every agent that recalls the device reads them next to the values.

brain = Bootstrap(api_key="...", device_id="github_feed")
brain.describe_fields({
    "watchers_count": "the star count (an old GitHub name); real watchers are subscribers_count",
    "size": "repository size in kilobytes",
})
brain.connect("https://api.github.com/repos/VAAS-X/vaas-x", interval_s=60)

# or, in one step as the source is connected
brain.connect(url, field_notes={"size": "repository size in kilobytes"})

describe_fields(fields, device_id=None, replace=False) adds to what is already there (a note for a field that has one replaces it); replace=True makes fields the whole dictionary; a blank meaning removes that note. field_notes() reads the dictionary and clear_field_notes() removes it. Up to 200 notes per device, a name up to 120 characters, a meaning up to 300. You can also edit it in the app: open a device in the fleet view and press Fields.

When an agent calls recall or get_memory, each result that has a data object also gets a meanings object (only the fields that episode has) and one line at the end of its text: Field meanings: watchers_count = the star count (an old GitHub name); .... Only you can write the dictionary, with your API key or in the app. An agent connected through the MCP connector cannot, so a poisoned note cannot change what every other agent reads. Notes are removed when the device or the account is deleted.

Say which machine, run or session each reading belongs to -- units (vaas-x 0.1.18 and later)

When one device receives readings from many machines, runs, lots or sessions, tag each reading with its unit: a name or number of at most 40 characters, with no control characters. It is sent as the tag unit:<id>. The service keeps a unit's readings together when it checks how well an estimate holds up on units it has not seen, and a device needs ten or more distinct units before it is given a probability. Readings sent without a unit count as one unit per calendar day (UTC).

brain.connect("press_4.csv", unit="press_4_run_17")      # every reading of this stream belongs to one run
brain.connect("all_machines.csv", unit_field="machine")   # or read each reading's unit from a column of the file

unit_field names a column (or key) whose value is that reading's unit; the column is used only to name the unit and is not stored as a measurement. A unit the service would not keep (longer than 40 characters, or with control characters) is refused when you call connect(), with a message that says why; a value like that inside the column leaves that reading without a unit and says so once. A unit tag a connector already set is kept. Whole numbers read from a file as 17.0 are the unit 17.

With an earlier version of the package, or when you send readings yourself with ingest(), give each reading a "unit" field next to its payload, or the tag unit:<id> in the episode's metadata.tags. See the product guide for what the service does with units.

Look at what is stored -- episodes() and devices() (vaas-x 0.1.20 and later)

query() searches; these two list. Both only read: they change nothing and are not counted as searches against a plan's daily limit.

page = brain.episodes(outcome="failed", limit=10)          # what a memory holds, newest first
print(page["total"], page["matching"], page["counts"])      # everything stored; how many fit the filter; {'worked': .., 'failed': .., 'pending': ..}
for ep in page["items"]:
    print(ep["id"], ep["state"], ep["text"])

print(brain.devices()["devices"])                          # the memories on this account, with how many episodes each holds

hits = brain.query("pump seal leaking", prefer_success=False)   # a search that does not favour what worked, so things that failed surface too

episodes(device_id=None, offset=0, limit=25, outcome="all", q="") returns total (everything stored), matching (how many fit your filter), counts (worked, failed, pending), offset, limit and items. Each item has id, text, text_truncated, timestamp, outcome, state and tags. outcome is "all", "worked", "failed" or "pending" (anything else is refused in the script before anything is sent, as is an offset below 0 or a limit below 1). q keeps only episodes whose text, id or tags contain that word or phrase: a plain text match, not a similarity search. At most 100 episodes come back per call; step through with offset. Long text is shortened (text_truncated says so): fetch the whole episode with get_episode(). If nothing has been stored under that memory name yet, the service answers 404 memory_not_found and error.hint points you at devices().

devices(include_empty=False) returns {"status": "ok", "devices": [...]}, one row per memory with device_id, episodes and vectors. A memory with nothing stored in it is left out unless you pass include_empty=True (every account starts with an empty default one). A Free account has one memory; the limit for each plan is on the pricing page. The REST equivalents are GET /episodes and GET /me/devices below.

HiveMind -- how the merge actually works

HiveMind calls the standard query endpoint once per registered device and merges the results client-side: de-duplicated by episode ID (keeping the higher-scoring copy if the same episode surfaces from more than one device), sorted by score, then truncated to k. If a specific device errors -- unreachable, revoked key, etc. -- that device is skipped rather than failing the whole query. Check fleet.devices to confirm what's currently registered. Calling query() before adding any devices falls back to your account's default device.

ArtificialCognition -- per-modality status

Getting Started covers the basic encode/ingest/retrieve flow. Here's the honest state of each modality, so you know what to validate before depending on it operationally:

  • Text -- production-ready. No missing-weights caveat.
  • IMU -- no trained weights ship with the package. The encoder runs on random initialisation until you supply a real checkpoint via checkpoints={"imu": "path/to/imu_weights.pt"}. Check ac.encoders["imu"].weights_loaded -- it's False until a real checkpoint is loaded, and embeddings aren't meaningful for retrieval before that.
  • Vision / audio / depth / thermal -- wrap pretrained third-party models. Structurally correct, but treat as early access until validated against your own data.
  • Cross-modal retrieval (ac.retrieve()) needs the resolver's /ac/query endpoint, backed by a flat cosine-similarity index, v1 scope: no cross-device search yet. That endpoint exists in the current server source but its rollout to any given resolver deployment can lag the client SDK. Don't assume it's live -- call retrieve() and check: a clean result means it's available on your resolver; a vaasx.ac.RetrievalNotAvailable exception (rather than a silent failure) means it isn't there yet. encode(), ingest(), and outcome() don't have this caveat -- they route through the same production episode pipeline Bootstrap itself uses.

Only the encoders you actually call encode(...) with are loaded -- passing just text= never touches torch/torchvision at all.

Rate limiting -- full behaviour

TierBurst limitDaily query cap
Free60/min100/day, resets midnight UTC
Personal240/minUnlimited
Developer300/minUnlimited
Professional600/minUnlimited
EnterpriseNo practical limit (agreed per contract)Unlimited

Burst limit is a per-key requests-per-minute cap checked on every ingest/query/ac/* call -- exceeding it returns 429 burst_rate_limited. Hitting the Free-tier daily query cap returns a structured 429 that includes the limit, reset time, and an upgrade link, rather than a bare error. There's also a global rate limit across the whole service (independent of tier) -- if you ever see 503 global_rate_limited with capacity left on your own key, that's whole-platform load, not something specific to your account.

What the SDK does about it (vaas-x 0.1.14 and later). A 429 burst_rate_limited means the request was refused before anything was stored, so asking again later is safe. The SDK waits and retries it, by default up to 6 times with waits of about 1, 2, 4, 8, 16 and 30 seconds (a minute in all, which is how long the limit takes to clear), honouring a Retry-After header if the service sends one, and only then raises the error. Pass max_retries=0 to Bootstrap() to fail at once, or set VAASX_MAX_RETRIES. Nothing else is retried: a plan's note limit (..._episode_limit_reached), too many key resets, and every other error are raised straight away.

Error codes -- full table

StatusdetailMeaning
400query_requiredEmpty query string passed to query()
400no_valid_itemsingest() called with an empty/invalid items list
401missing_api_key / invalid_api_keyNo key, or key not recognised
403key_inactive_subscription_lapsed_or_cancelledKey exists but the subscription behind it isn't active
403multi_device_not_enabled / device_limit_reachedA Free account has one memory (leave device_id out to use it); other plans have a limit on devices
404memory_not_foundepisodes() for a memory name that has nothing stored yet
400outcome_filter_not_understoodREST only: GET /episodes with an outcome other than all, worked, failed or pending (the SDK refuses it before sending)
429burst_rate_limitedPer-key requests/minute exceeded
429<tier>_tier_daily_query_limit_reachedFree-tier daily query cap hit
429<tier>_tier_episode_limit_reachedThe plan's limit on stored episodes is reached; new ones are refused (nothing already stored is deleted)
502shard_query_failed / shard_ingest_failed / shard_outcome_failedReached your device's shard but the call itself failed -- usually transient, safe to retry with backoff
503global_rate_limitedWhole-service rate limit, not specific to your key

A VaasxAPIError with status_code=0 means the request never reached the server at all -- network error, DNS failure, or timeout. Check e.detail for the underlying message.

What the SDK adds (vaas-x 0.1.20 and later). The answers people meet most come with a plain sentence about what to do next, so you do not have to look the code up:

try:
    brain.query("...")
except VaasxAPIError as e:
    print(e.hint or e)        # e.g. "This plan's searches for today are used up (every query counts as one). They reset at midnight UTC. Personal and above have no daily search limit: https://vaasx.com/pricing"
    print(e.status_code, e.code)   # 429 free_tier_daily_query_limit_reached

e.hint is set for: a plan's daily search limit, its limit on stored episodes or on devices, a Free account asking for more than its one memory, a missing or invalid key, a lapsed or cancelled subscription, the per-minute limit, a busy service, a memory that is still starting, a memory name with nothing stored, and no network (status 0). For any other answer it is None: the SDK does not guess. e.code is the service's own short name for the problem (empty if it gave none). Nothing else changed: str(e) is still vaasx_api_error:<status>:<detail>, e.status_code and e.detail are as before, and only burst_rate_limited is retried (a daily limit or a full account is raised at once, because waiting does not clear it).

REST API reference (non-Python clients)

Base URL https://api.vaasx.com. All authenticated endpoints expect Authorization: Bearer <api_key>.

MethodPathAuthPurpose
GET/healthnoneLiveness check
POST/free-signupnone{"email": "..."} -- issues a Free-tier key
POST/ingestkey{"device_id": ..., "items": [...]}
GET/querykey?q=...&k=10&device_id=...&include_episode=true&prefer_success=true
POST/outcomekey{"id": ..., "device_id": ..., "success": bool, "delta": 0.0, "error_type": null}
GET/episodeskey?device_id=...&offset=0&limit=25&outcome=all&q=... -- lists what a memory holds, newest first (at most 100 a call), with total, matching and counts; outcome is all, worked, failed or pending; not a search and not counted as one
GET/me/deviceskey?include_empty=false -- the memories on this account, one row each with device_id, episodes and vectors
GET/neighbourskey?like=<episode id> or ?latest=true, with k, device_id, resolved_only -- the nearest past situations to a reading, as ordinary hits with their units, plus a model block when the device has one
POST/devices/{device_id}/reindexkeyEncodes the device's whole history so earlier readings can be searched by value; changes no episode; can be repeated; "default" is the unnamed device
POST/devices/{device_id}/fitkeyFits the device's estimator now (one per device per hour); answers with its card
GET/devices/{device_id}/modelkeyThe model card: what it was trained on, how it did on units it had not seen, and whether it may give a probability
POST/ac/ingestkey, Professional+{"device_id": ..., "embedding": [...], "metadata": {...}}
POST/ac/querykey, Professional+{"device_id": ..., "embedding": [...], "k": 10}
GET/devices/{device_id}/fieldskeyWhat you have said this device's fields mean: {"fields": {name: meaning}}
PUT/devices/{device_id}/fieldskey{"fields": {"watchers_count": "the star count"}} -- replaces the whole dictionary; a blank meaning removes that note; "default" is the unnamed device
DELETE/devices/{device_id}/fieldskeyRemoves every note for this device

/ingest and /query are the only two endpoints most non-Python integrations need -- the SDK is a thin wrapper around exactly these calls plus the local edge pipeline, which has no server-side equivalent since it runs client-side by design. Subscription management (upgrading, downgrading, billing details) isn't part of this table -- handle that via the pricing page's own Stripe checkout and billing portal, not by calling the resolver directly.

/query and /episode/{id} return each hit as {"id", "score", "timestamp", "tags", "text", "outcome"}. For an episode built from a record with fields, there is also data (the stored field values, up to 60 fields, text values up to 300 characters, most useful first) and, if you have written a dictionary, meanings for the fields present. For a Bootstrap episode the text also shows the readings (Readings: name=value, ...) and the meanings line.

/ingest responds with {"status": "ok", "ingested": <count>, "episode_ids": [...]} -- episode_ids is index-aligned with the items you sent (null for any item that was skipped), so you can zip them back together to know exactly which item got which id. If an item omits episode_id, one is generated server-side and returned; you only need to supply your own if you want a specific, predictable id.

FAQ / troubleshooting

Why is the package a compiled wheel instead of readable source?

The retrieval, indexing, and encryption internals are proprietary and stay server-side or ship compiled -- a deliberate IP-protection choice, not an attempt to hide anything from you. Everything you actually interact with -- client methods, request/response shapes, connectors, error handling -- is documented on this page and is exactly what you get.

pip install vaas-x fails on my platform

Wheel coverage is broadest on Linux x86_64 (Python 3.10-3.14). If your platform/Python combination isn't covered yet, email hello@vaasx.com rather than assuming it's a local problem -- it may just not be built yet.

My query() calls return nothing

Most common cause is querying before you've ingested anything for that device_id -- episodes are scoped per device unless you're using HiveMind. Check device_id matches between your ingest() and query() calls.

My agent reads the values but guesses what they mean

Say what the fields mean with describe_fields() (vaas-x 0.1.16) or the Fields button in the app. Recall then returns the meaning next to each value it shows. Without a dictionary an agent only has the field names to go on.

My feed's text does not show up when an agent recalls it

Check you are on vaas-x 0.1.15 or later (pip install --upgrade vaas-x): earlier versions read only the numbers in a record. A feed or page that has not changed since the last poll is stored once, not every time, unless you pass dedupe=False.

Should I call outcome() for every episode?

No -- it's optional. Episodes without a recorded outcome are still retrievable by similarity; they just don't benefit from prefer_success=True ranking. If you already know the outcome at ingest time (typical for an agent that acts and immediately observes the result), skip the separate call entirely and ingest a complete state/action/outcome item instead -- see Getting Started, section 5b.

What happens if I exceed my tier's episode limit?

The service refuses new episodes with 429 <tier>_tier_episode_limit_reached, which carries the limit and an upgrade link. Nothing already stored is deleted. The SDK raises it at once (waiting does not clear it), and from vaas-x 0.1.20 error.hint says what to do: delete old episodes in the app or move to a plan with room, on the pricing page. devices() shows how many episodes each memory holds.

Where do I go for anything not covered here?

hello@vaasx.com for general questions, support@vaasx.com for existing-customer support, sales@vaasx.com for Enterprise/contract questions.

Quick start: Getting Started. Architecture and benchmarks: Core Platform Guide.