public void MonitorWatsonConversationTraining(LexiconWorkspace workspace)
        {
            workspace.WatsonConversationManager.IsTraining = true;

            WatsonSyncQueue syncQueue = ScriptableObject.CreateInstance <WatsonSyncQueue>();

            syncQueue.workspace = workspace;

            syncQueue.Enqueue(WatsonWorkspaceStatus.CreateInstance(workspace));

            syncQueue.OnCompleteAction = WatsonCompleteConversationTraining.CreateInstance(workspace);
            syncQueue.OnQueueFinished += CleanUp;

            syncQueue.Process();

            watsonConversationSyncQueues.Add(syncQueue);
        }
        void HandleSuccessCallback(Workspace watsonWorkspace, Dictionary <string, object> customData)
        {
            if (watsonWorkspace != null)
            {
                workspace.WatsonConversationManager.SyncStatus = watsonWorkspace.status;

                if (!string.Equals(watsonWorkspace.status, "Available", StringComparison.OrdinalIgnoreCase))
                {
                    // TODO: Use retry here.
                    queue.Insert(TimerSyncAction.CreateInstance(10), 0);
                    queue.Insert(WatsonWorkspaceStatus.CreateInstance(workspace), 1);
                }

                succeeded = true;
                isDone    = true;
                return;
            }

            succeeded = false;
            isDone    = true;
        }