Developers
ENPT

Manager Learning

Review the learnings Tolky extracts from conversations handled by your team, and approve, reject or add them to the knowledge base.

When an operator takes over a conversation and answers something the avatar could not, that answer is valuable. Manager Learning analyzes these conversations and proposes learnings: new content the knowledge base is missing, or corrections where the base says something different from what your team said.

Each learning waits for a decision in Learning › Triage. With the API you can run the same review from your own tools.

Lifecycle of a learning

StatusMeaning
pendingWaiting for review. The AI does not use it yet.
approvedYou accepted the content.
rejectedYou rejected it. It stays in the history.
promotedAdded to the knowledge base as content. The AI uses it in answers.
supersededA newer learning about the same subject replaced it.
archivedRemoved from the queue automatically. You can restore it.

A learning is either new_content (the base did not cover the subject) or correction (the base diverges from what the manager said).

ReferenceTechnical details

All endpoints are POST and require a host token in the header (Authorization: Bearer $TOLKY_TOKEN). The account always comes from the token.

PurposePath
List learnings/api/externalAPIs/public/contentaware/learningsget
Count pending learnings/api/externalAPIs/public/contentaware/learningscount
Get one learning/api/externalAPIs/public/contentaware/learningget
Approve/api/externalAPIs/public/contentaware/learningapprove
Reject/api/externalAPIs/public/contentaware/learningreject
Restore an archived learning/api/externalAPIs/public/contentaware/learningrestore
Promote to the knowledge base/api/externalAPIs/public/contentaware/learningpromote
List datasets for promotion/api/externalAPIs/public/contentaware/datasetsget

List learnings

NameTypeRequiredDescription
statusesstring[]NoStatuses to include. Default ["pending"].
learningKindstringNonew_content or correction.
severitystringNohigh, medium or low.
sensitivitystringNolow, medium or high. Overrides your account's filter. high shows everything.
topicIdstringNoOnly learnings of this topic.
searchstringNoText search.
limitintegerNoDefault 50, maximum 500.
offsetintegerNoDefault 0.
curl -X POST "https://api.tolky.to/api/externalAPIs/public/contentaware/learningsget" \
  -H "Authorization: Bearer $TOLKY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ "statuses": ["pending"], "limit": 20 }'

The response has learnings, topics, total, limit, offset, sensitivity and quota. Each learning has id, title, content, learningKind, severity, relevance, status, occurrences, topicId, topicLabel, conversationId, lastSeenAt and createdAt.

The pending queue is released in small batches: at most quota.perKind items of each kind (10 by default). total is the real size of the queue, quota.offered is what was released. History and search have no quota.

learningscount takes an optional sensitivity and returns count (released now), total (all pending), quota and sensitivity.

Get, approve, reject, restore

EndpointBodyEffect
learninggetlearningIdReturns learning and originInsight (the analysis that produced it, with the related messages).
learningapprovelearningIdpending to approved.
learningrejectlearningId, reviewNote (optional, up to 2000 characters)pending to rejected.
learningrestorelearningIdarchived to pending.

Approve, reject and restore return the updated learning.

Promote to the knowledge base

Creates a knowledge base entry with the learning's content. Promoting a pending learning also approves it.

NameTypeRequiredDescription
learningIdstringYesLearning to promote. Must be pending or approved.
datasetIdstringNoDestination dataset from datasetsget. When omitted, a dataset for manager learnings is created on first use.
replaceChunkIdstringNoExisting knowledge base entry the learning corrects. It is removed in the same operation and the new entry goes to the same dataset.
curl -X POST "https://api.tolky.to/api/externalAPIs/public/contentaware/learningpromote" \
  -H "Authorization: Bearer $TOLKY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ "learningId": "3f0c2a8e-..." }'

The response has learningId, chunkId, replacedChunkId, datasetId, datasetName, datasetProvisioned, status and learning. Promoting again does not create a duplicate: a learning already promoted answers 409.

datasetsget takes no body and returns datasets: [{ id, datasetName, datasetType }].

Errors

CodeWhen
400Invalid input, for example a datasetId different from the dataset of replaceChunkId, or a token that is not a host token.
401Invalid token.
403No token sent, or the dataset belongs to another account.
404Learning, dataset or entry to replace not found in your account.
409The learning is not in the status the action needs. Also TARGET_NOT_PROMOTABLE (the learning targets the avatar identity, not the knowledge base) and REPLACE_TARGET_NOT_CULPRIT, REPLACE_TARGET_DRIFTED or REPLACE_TARGET_ALREADY_DELETED for an invalid replaceChunkId.
503Manager Learning is not enabled for your account.

Previous

Doc Analyzer

Next

Flow webhooks