How I built my own Sonnet-Deepseek fusion agent and run parallel tasks to convert a 5 year old vue2 project to vue3 in 30 minutes

Meta: Convert all .vue (hundreds) files from class-decorator-syntax to compositional API

Limitations with cursor as of now:

  1. $$$ I already spent $70 on cursor usage this month and I want to save $. I can only use sonnet 3.5 for agent mode, but deepseek has a very cheap API.

  2. Time. Traditional agent usage examining one file at the time takes too long. I do not need to wait for one file before going to another one.

Solution:
I made a fusion agent that combined cursor’s Sonnet 3.5 agent to do lint-checking and getting files from my codebase, with DeepSeek using Fireworks API to do the heavy lifting for converting.

Implementation:
A python script that sends an API request, logs results. Takes in a parameter of a filename, reads the content of a file, sends a request to FIreworks API with the content of file + basic prompt & predefined instructions (in my case, migration-guide.md) and then the python script overrides the content of the file with the response.

Python script can take one individual .vue file at the time, or accept many for parellell execution. You can also decide to run it as a background thread so the Cursor composer can convet your files faster since it does not need to wait for the completion of the python script.

I recommend batching the files since by default the composer agent stops at 25 tool calls. You can also use Claude desktop with a terminal access MCP to acheive the same thing, BUT:

I recommend batching perhaps 5 at the time, and then instruct the composer to wait for the respoonse, check lint errors, and then update the migration-guide.md that it will use in future batches with the appropriate corrections. If you insist on using Claude desktop (maybe have pro and would prefer using your daily limit instead of cursor, you can use eslint path/to/file.vue) (or whatever lint tool for your specific problem) to manually fetch lints and fix them.

“After executing the sript you will now see that it has been converted. Pleas check any lint errors on the file and fix them.
If you beleive it’s worth it, please update the composition-api-migration.md file with the added knowledge for lint-errors.
Once that’s complete, please execute the script agian on the next .vue file(s).”

Result:
All .vue files were coverted very fast, very cheaply (it didn’t even spend my free $1 credit on fireworks api!) and with little manual interventions afterward.

I’ll share a repo if anyone’s interested

Have a nice day!

1 Like

Your idea is very cool. If possible, I would like to get your code.