Initializing help system before first use

Model Annotations

The following section describes the additional annotations available for use when declaring model entities and in the decorator of execution modes.

Annotation of Progress Entities

Model Input and Result entities can be marked to emit progress information during model execution by setting the update_progress flag on the type annotation:
  TotalReturn: xi.types.Scalar(dtype=xi.real, manage=xi.Manage.RESULT, update_progress=True)
The behavior of non-progress entities does not change and will not be affected.
LogEntryIndex: xi.types.Index(dtype=xi.integer, manage=xi.Manage.RESULT,
     update_progress=True)
LogEntry: xi.types.Series(index=['LogEntryIndex'], dtype=xi.string, 
     manage=xi.Manage.RESULT, update_progress=True)
If the following requirements are not fulfilled, an error is returned :
  • All index sets of a progress entity must also be progress entities and vice-versa.
  • Input progress entities must be annotated update_after_execution=True.

Decoration of Execution Modes

Execution modes get annotated to send progress information by setting the parameter send_progress in the decorator:
@xi.ExecMode(name="CUSTOM_RUN", send_progress=True)
The following works for any built-in and custom RUN or LOAD mode.
@xi.ExecModeLoad(send_progress=True)
def loaddata(self):
With this annotation, the following two instructions can be used in this execution mode:
self.insight.send_progress_update This command will emit progress events from the model to all views observing this execution mode.
self.insight.get_messages Call this subroutine to retrieve messages from the message queue on the worker.

Treatment of Entity Values

All scenario entities are locked in the Insight data repository while a model is running. During execution, progress entities are held as temporary values updated directly on the client; the client displays these updated values, not those held in the repository. The server stores the last submitted values for progress entities until the model execution is complete, at which point the progress values are discarded.

Prior to the start of model execution:
  • All result entities values (both unmarked and marked for progress) are always cleared when a scenario or job is queued for execution and upon start of an execution mode.
  • Input entities marked to update with progress are cleared if the clear_input setting is configured as True (default setting for LOAD mode). To retain the input values, configure clear_input as False.

During execution, progress entity values are transferred from the model to the view when the model calls to send_progress_update. However, if the execution mode sets clear_input=True, progress result entities are not updated during execution and remain empty.

Scenario Status Result Entity Values Input Entity Values Marked for Progress Updates
Queued for Execution Cleared Cleared if clear_input=True / Retained if clear_input=False
Start of an Execution Mode Cleared Cleared if clear_input=True / Retained if clear_input=False
During Execution Updated in progress events except if clear_input=True Updated in progress events
After Execution Updated in Insight data repository except if clear_input=True Updated in Insight data repository

Conceptually, the clear_input=True setting corresponds to a LOAD mode which should not update result entities at all. The annotation lifting it to a progress result entity doesn't change this concept.

When the execution is complete, the final results are displayed:
  • If the model completes without errors the data is replaced with the new data.
  • If execution is cancelled or fails to execute, the original data is retained.

© 2001-2025 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.