Add product(s) to cart from DOM string
If I understood you right. I had some similar task in the past. I had form of all product variations in the table with textbox inputs for quantity. And they must be added multiple to cart.

The main function is commerce_cart_product_add_by_id($product_id, $quantity);

What I did:
I created custom field formatter for "Product reference" field and rendered it as table of variations with text inputs for quantity.
And on form submit I loop all products in foreach and add them to cart.

But if you don't want to create additional formatters there is another solution. 


You can use your hook hook_form_commerce_cart_add_to_cart_form_alter()
Render form elements for all your product variations there by custom code.
Replace form submit with your custom submit
Add products to cart in custom submit (call commerce_cart_product_add_by_id() in foreach).


Also you can write your text VariationID:LineItemOption:Quantity[_repeat] into some hidden textfield element. After submit you'll read this text in $form_state