How to merge RevisionGroup?

Hi:
For example,like the document.
Test.docx (28.7 KB)

Document docOriginal = new Document("Test.docx");
RevisionGroupCollection originalGroup = docOriginal.Revisions.Groups;

I can get the RevisionGroupCollection,but I want to get like this:

‘which’ change to ‘where’
‘documents’ change to ‘article’
insert ‘goodbye’
delete ‘the 666server’
insert ‘I can’

For insertion and deletion, I know how to do. For changes, I don’t know how to get this. I don’t know which insertion and which deletion to merge.
Can you help me achieve it?Could you please give me an example.
Thanks

@JohnKj I am afraid there is no association between revisions. For example revisions in your document are represented like this:

<w:del w:id="0" w:author="wei wan" w:date="2023-10-11T16:25:00Z">
	<w:r w:rsidDel="003C62E2">
		<w:rPr>
			<w:rFonts w:ascii="inherit" w:eastAsia="宋体" w:hAnsi="inherit" w:cs="Open Sans"/>
			<w:color w:val="333333"/>
			<w:szCs w:val="21"/>
		</w:rPr>
		<w:delText xml:space="preserve">which </w:delText>
	</w:r>
</w:del>
<w:ins w:id="1" w:author="wei wan" w:date="2023-10-11T16:25:00Z">
	<w:r w:rsidR="003C62E2">
		<w:rPr>
			<w:rFonts w:ascii="inherit" w:eastAsia="宋体" w:hAnsi="inherit" w:cs="Open Sans"/>
			<w:color w:val="333333"/>
			<w:szCs w:val="21"/>
		</w:rPr>
		<w:t xml:space="preserve">where </w:t>
	</w:r>
</w:ins>

As you can see there is two separate revision - deletion and insertion. There is no relation between them.

Is ‘w:id=0’ or ‘w:id=1’ nique value in a document? If it is a unique value,I can make a judgment.If there is an id value and another id+1 value exists.If the ‘id’ is insert and the ‘id+1’ is delete, I can consider them as changes? or If the ‘id’ is delete and the ‘id+1’ is insert, I can consider them as changes?
Is it possible based on this? If possible, how should you write the code.Can you give me an example?

Now,RevisionGroup is separated by insertion and deletion.Whether can I get RevisionGroup according to the order in the document?
For example,the documnet which I upload.
I want to get the RevisionGroup order like this:

‘which’ deletion
‘where’ insertion
‘documents’ deletion
‘article’ insertion
‘goodbye’ insertion
‘the 666server’ deletion
‘I can’ insertion

Now,the order is:

‘which’ deletion
‘documents’ deletion
‘the 666server’ deletion
‘where’ insertion
‘article’ insertion
‘goodbye’ insertion
‘I can’ insertion

@JohnKj I have linked your request to the appropriate issue WORDSNET-25870 in our defect tracking system. Currently, Aspose.Words does not sort the resulting groups in any way when enumerating RevisionGroup -s. The groups are enumerated in the order of their collection: first Deletion, then Insertion, then Move and so on… MS Word enumerates groups in the order of their revision id.