Skip to content

Platform Limits

Every script surface in KnowledgeLake runs under a time limit that the code enforces. When a script hits its limit, the engine stops it, and the step fails or the change is not applied. This page lists those limits so you can design code that finishes well inside them.

At a glance

  • Browser scripts 5 seconds for a Custom Behavior, 1.5 seconds for a search filter behavior.
  • Workflow scripts 120 seconds for a Custom Step, 10 seconds for a Custom Event, 10 seconds for all routes of a step together.
  • Intuitive AI scripts 5 to 15 minutes.
  • Scope Only limits enforced in the code. Size limits for uploads and requests depend on the network in front of your tenant, so this page does not list them.

Scripts in the browser

Where the script runs Time limit
Custom Behavior in the index panel 5 seconds
Search filter behavior in the search query panel 1.5 seconds

When an index panel behavior hits the limit or throws an error, none of its changes are applied. The browser console shows the error, and the field shows "Behavior Custom Behavior could not be fired."

Scripts in the workflow

Where the script runs Time limit
Custom Step 120 seconds by default. A tenant setting can change it.
Custom Event step 10 seconds
All routes out of one step, together 10 seconds
A JavaScript or Liquid value in a step setting 5 minutes
Custom Behavior on the server (Index Your Documents, Run Indexing Behaviors, Start QC Task, Search bulk edit) 5 seconds per behavior
  • A Custom Step that hits its limit fails with Javascript timeout limit was exceeded. Its queued changes are not applied.
  • A Custom Event step that hits its limit fails the same way, and no event is written.
  • The 10 seconds for routes is shared. All of a step's JavaScript routes run in one engine, one after the other.
  • A Liquid template stops after 10,000 loop iterations. Liquid errors do not stop the step. A bad expression renders as empty text.
  • On the server, a behavior that hits its limit fails with Script execution interrupted by host.

Call External API

Setting Behavior
Timeout In seconds. 0 or empty means 15 minutes.
REST Verb Only GET and POST run. Other verbs in the list fail the step.
External API URL Local and private addresses are refused before any request is sent (Api domain is not valid.).

Set the step timeout below the limit of the platform that hosts your endpoint. If the step times out first, the step fails even when your code finishes later. If the host stops your code first, the step fails with no result.

Intuitive AI scripts and patterns

Where it runs Time limit
Custom Condition (page) 15 minutes
Custom Document Condition 15 minutes
Custom Action (page) 5 minutes
Custom Document Action 15 minutes
Regex Anchor match 5 seconds
Regular expression refiner on an OCR action 5 seconds
Other limit Value
services.OcrService.GetDocumentOcr pages 20 by default. A higher maxPagesToOcr is capped at 100.
Zero-Shot Classifier (AI Refiner) hint text for one class The hints are joined and cut to 1,000 characters.

A regular expression that runs longer than 5 seconds stops with a timeout. Avoid nested quantifiers such as (a+)+ on long OCR text.

REST API

Limit Value
V1_KWorkItemAPI/GetWorkState polling Poll no more often than every 1.5 seconds. Faster polling can return a cached state instead of a fresh one.
Page size (PageSize or Take) on the query actions of V1_JobsAPI and V1_RPAAPI, and on V1_ProcessingAPI QueryForWorkItems and QueryForWorkItemHistories 20 by default, 1,000 at most.

There is no general rate limit in the API code. Still, send bulk updates one at a time or in small groups, and check Success on each response.

Custom Gizmos

Limit Value
Signed links to the gizmo's own files Expire 5 minutes after the task loads the gizmo (tenant default).

Load the files your gizmo needs when it starts. Do not fetch the gizmo's own files later from a timer or after a long user action.

Custom Insight widgets

Limit Value
Web Request source timeout Set on the connection, in seconds. 30 by default. It must be greater than 0.

Your endpoint must answer inside this time on every dashboard load, and on GET {base}/validate when an administrator tests the connection.

Events

Limit Value
Event size at an Azure Cosmos DB Secondary Event Provider Over 1.5 MB, every string property is cut to 5,000 characters and eventWasTrimmed is set to "true".
Custom Event property values Strings. Pass String(x) for a number and JSON.stringify(x) for an object. An object or array value fails the step.

Delivery to a Secondary Event Provider is best effort. A failed write to Cosmos DB is tried once more after 5 seconds, then dropped. Design reports that tolerate a missing event.