Data Extraction Scope: "Sequence contains No elements"

HI team,

@loginerror @alexcabuz @Palaniyappan

I need to process invoices and receipts using MAchine learning extractor, i need to calculate only total amount from all the documents.
i am sharing my workflow right here !!

I need to classify the documents which invoice or receipt. So i am using keyword classifiers inside the classify document scope. But i am not getting any classification results which is empty. So that my data extraction scope throws an error like

“message”: “Data Extraction Scope: Sequence contains no elements”,
“level”: “Error”,
“logType”: “Default”,
“timeStamp”: “23:43:33”,
“processVersion”: “1.0.0”,
“jobId”: “6d9309e0-572e-4116-ad3c-e7215540fbb7”,
“robotName”: “SRIRAM_CHIVO”,
“machineId”: 0,
“fileName”: “Main”

I guess if there is no data learning path it should open the present validation station right?

please guide me guys on this.
images also available in the Zip file as Invoices folder.

regards, (324.7 KB)

Anybody help me on this ? please

Hello @Sriram07

Please try to start from this sample workflow: How to use the IntelligentOCR Package

It already contains the machine learning extractor configured properly.

For classification:

  • if you do not need classification (you already know the incoming files are invoices) then you can use the Data Extraction Scope parameter DocumentTypeID instead of classificaiton result and give it the doc type id string (you can find in the taxonomy manager once you click on that document type, right above the doc type name editing box). In this case, please remove the Classify Document Scope completely as well as the Train Classifiers Scope as they are not needed.
  • if you need classification, to start from scratch with the keyword based classifier you need to run the flow a few times. When no classification is given, open the validation station, select the right document type, and select the right keywords (document title or keyword that uniquely signifies that document type) as evidence for document type. Then the train classifiers scope will ensure that the the keyword based classifier learns that new evidence keyword, and when found in a subsequent document, it will report it as such.

All these are covered in the above example, please use it as reference.


1 Like


Thanks for the response.

I have a folder which contains both invoices and receipts. So i need to classify for sure because i need to extract different info for different documents.

So that i create one empty file as learning.json and using the keyword based classifiers inside the classify document scope.

Now i am running the workflow, then anyway there is no data inside the learning path right ? so obviously classification Results.Any would be zero right?
if there is no classification so robot should open a present validation station for the keyword of the docs right? And than it will train in the classifiers scope and it will update on the learning file for the further docs? right?

My understanding is correct?right?

But problem in my workflow is in if condition is Classification Results.any and then part is further process after classification in else part write line activity “No classification so no extraction started”.
So always my robot goes for else part only because of no classifications.

So @Ioana_Gligan please guide me on this. it is eating my head. how can i come out of this?


on the if then condition, do Data Extraction Scope then display the validation station.
on the else condition, do nothing and display the validation station. It will ask you to select evidence for your document type - and select the Invoice keyword or the Receipt keyword, as it is the case.

I also recomment switching to OmniPage OCR or at least Microsoft OCR for the digitization part, as Tesseract is not giving the best results in your use case.

Please look at how the sample workflow I mentioned above is built for that if part…

1 Like

@Ioana_Gligan the above reply was very helpful and its worked, thanks for that.

And problem is everyTime for all the documents Else part is only exceuting that opening the validation station for all the files and after that it in else part nothing is there because data extraction scope is in then part only right? So i am not getting any results to export into excel.

Summary that for all the files in the if condition classification results.Any is failed and it gets into else part validation station and so on. for the successful flow it should enter into the then part right?

And also there is no data in the learning path because classifier trainer also in then part only.

Please advise me @Ioana_Gligan

i am learning something interesting , very thankful to you @Ioana_Gligan


1 Like

classifier trainer should be in, after the validation station, for both then / and else. So is the validation station.

So after each individual file processed (automatically or by hand), you should have a validation station, and you should have a train classifiers scope.

This way it continuously learns :slight_smile:

1 Like

Sorry for the late reply @Ioana_Gligan

Thank you so much for your time and efforts!!!

I will implement as per you advise in my workflow and let you know the results @Ioana_Gligan


1 Like

@Ioana_Gligan it’s working like charm!!!
Thank you so much for making me understand the concepts and for your best guidance!!!

1 Like

Anytime, @Sriram07 !

Happy bot building!


1 Like

Having an another doubt that , while creating a fields for the types there is a check box with value of “is a multi value” in the name field right?

What it meant by multi value? what kind of values are considered as multi value?

And another query that can i use orchestrator in a community edition, can we schedule a bot for some specific time like un-Attended bots , because bot should automatically execute at everyday early morning without any interaction from developers.

@Ioana_Gligan any advise on above question please!!!

Hello @Sriram07,

Multi-Value declares that the field may contain multiple values.
Imagine the case when you want to extract all Cities from a document. In this case, you would either have to declare X fields (City 1, City 2, … City N, where N is the maximum number of cities you could expect in a document), OR, you could declare one field called Cities, and check the Multi-Value checkbox.

You will notice that each field can potentially have multiple reported values. This is where different instances of the values go and are found in the final extraction results.

Related to the Orchestrator question, maybe @loginerror can help?



1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.

Hi @Sriram07

And another query that can i use orchestrator in a community edition, can we schedule a bot for some specific time like un-Attended bots , because bot should automatically execute at everyday early morning without any interaction from developers

Yes, the Orchestrator instance allows you to have 1 unattended robot running on a schedule.
It also gives you 2 attended robot licenses, but these cannot be scheduled via Orchestrator.