Invoke Capture

Production traffic is the best source of new training data — it is exactly the distribution of inputs your function needs to get right. Invoke capture is how Nyckel taps into it: every invoke is evaluated, and the most informative ones are automatically captured to your function’s Review queue for annotation.

Capture is selective by design. Annotating thousands of near-identical, high-confidence predictions costs review time without teaching the model anything new. So instead of saving everything, Nyckel captures the invokes most likely to improve the model when annotated.

What gets captured

Each invoke is checked against several capture strategies:

A few additional rules keep the queue worth your time:

The lifecycle

  1. 1Application invokes the function
  2. 2Informative invokes are captured
  3. 3You annotate them in the Review queue
  4. 4Annotated samples join the training data
  5. 5The model retrains and improves
  1. Your application invokes the function and gets back a prediction and confidence score.
  2. Nyckel evaluates the invoke against the capture strategies above. Informative invokes are captured; the rest are counted and answered, but not queued.
  3. Captured invokes appear in the Review tab of your function in the console, together with their predicted label and confidence.
  4. You confirm or correct each one. That annotation converts the captured invoke into a labeled sample in your training data.
  5. Nyckel retrains in the background, benchmarks the new model, and promotes it if it is better. No deploy step.

The result is a data flywheel: the function improves precisely on the traffic it actually serves, at a small fraction of the annotation effort of labeling everything.

The Review tab is the built-in way to work the queue, but it isn’t the only one — you can pull captured invokes via the API and route them through your own annotation tools. See Build a feedback loop.

Invokes vs. annotations

Invoke counts and annotation counts measure different things, and they are not expected to match:

Because only informative invokes are captured, and only annotated captures become samples, a healthy production function will always show far fewer annotations than invokes. A function with thousands of invokes and a few hundred annotations is working exactly as intended — it is not dropping data.

NoteIf you need a record of every invoke, keep it on your side of the API: log each request with its prediction, keyed by the externalId you send. Invoke capture is a training-data mechanism, not an audit log.

Opting traffic out

Capture is on by default for every function. To keep specific traffic out of the queue — load tests, synthetic traffic, inputs you never want stored — pass capture=false on the invoke:

POST https://www.nyckel.com/v1/functions/{functionId}/invoke?capture=false