Import

Suggest mapper correspondences for a sample

Propose a source -> destination correspondence for each destination an AI model recognizes in the submitted sample profile, to pre-fill the mapper builder for review. Destinations it does not recognize are simply omitted.

The sample file is not sent: the caller parses it locally and submits only a profile of its source fields (identifier, one example value, and for CSV the aggregates measured over the scanned rows). The destination fields are derived server-side from the passport-creation schema, so they cannot drift from what the import accepts.

The answer is filtered against the submitted sources and the generated destinations, so it can only ever reference fields that exist. It stays a suggestion: nothing is persisted, and the import itself remains deterministic.

Never fails on the model's account: if it is unreachable or answers unusably, correspondences come from a deterministic lexical matcher instead and degraded is set.

Read confidence before applying a correspondence. The list reports every destination that was recognized, including the ones judged unfit to pre-fill: high and review are meant to be applied (review asks for a second look), while low must be offered rather than filled in — its values would fail passport validation on every row. evidence says why, and origin says who proposed it; anything other than llm was produced without a model call.

post/v1/import/mappers/suggest-mapping

Request

  • Base URL: https://api.prod.keyban.io
  • URL: https://api.prod.keyban.io/v1/import/mappers/suggest-mapping
  • Auth: API key in header X-Api-Key

Request body

string required

Response

Suggested correspondences

degradedboolean required

True when the language model could not be reached or answered unusably, and the correspondences come from the deterministic matcher alone. The suggestion is then narrower — it favours leaving a destination empty over guessing — so it deserves a closer review. Never an error: a degraded suggestion is still returned with a 200.

Example response

{
  "mappings": [
    {
      "destination": "product.modelNumber",
      "source": "$.product.mpn",
      "origin": "alias",
      "evidence": "confirmed",
      "confidence": "high"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.