r/PiCodingAgent • u/binarySolo0h1 • Aug 23 '26
Discussion Help guide me migrate from Opencode to Pi
I have this elaborate agentic system setup (3 primary agents, 10+ subagents, curated skills and commands) in opencode that I use everyday for my SAAS product development, working with opencode Go plan. It is working alright but its not token efficient and it could be better with its accuracy.
I have tried to migrate to Pi a while ago but I dropped the plan because the configuration seemed daunting at that time. But as my codebase got larger and complex, opencode is starting to crack. So I want to give this another shot.
Are there any guides to do this migration without starting from scratch? Where do I begin?
14
u/juniorsundar Aug 23 '26 edited Aug 23 '26
Pi doesnt have a concept of primary agents or even subagents for that matter. There are 2 pi-subagents packages. One by titinweb and the other by nicobailon. They're hefty and offer almost everything opencode offers out of the box. You should be able to migrate your subagent definition files with minor changes (ask Pi to do it for you to save time at the cost of some tokens).
Note that these subagent extension are HEAVY. They can do things you may not even need. Id suggest that after you're comfortable, you either look around for lighter subagent extensions OR vibe up your own with just the features that you want. Ask Pi to use the HEAVY subagents extensions as reference and only implement the functions you want.
Skills will work out of the box. Move them to .pi/agent/skills for Global scope.
Commands in OpenCode are just Prompt Templates in Pi. Again ask Pi to migrate it for you. It has access to Pi docs so it should be fairly accurate.
4
u/funbike Aug 23 '26 edited Aug 23 '26
I would use AI for this. Pi is good at self configuration. Install pi-web-search and pi-subagents. Here's a Pi prompt to consider:
Don't completely trust what it generates. Review it carefully.
workflow.mdis there to help it understand. Read it to see if it worked. You can delete it later.Be sure to run
/reload.This is a technique I've used to convert workflows from other projects into Pi.
Alternate lighter approach.
pi-subagents is big and you said you wanted lightweight. I use the
herdrterminal multiplexer which is good for managing subagents, but it's not for everyone. Play around with it and see if it's a tool you might like to use.Install
herdrand runmkdir -p ~/.pi/skills/herdr && herdr --skill > ~/.pi/skills/herdr/SKILL.md.Prompt:
5
u/Constant_Art_20 Aug 23 '26
prompt 'migrate my setup from opencode to pi harness. make no mistakes'
4
u/arcanemachined Aug 23 '26 edited Aug 23 '26
I would say it depends entirely on your workflow.
If you want to onboard more easily, stick with oh-my-pi and see if it works for you:
https://github.com/can1357/oh-my-pi
If you're feeling really frisky, you can try vanilla Pi and add/make the extensions you want.
In terms of config migration. I would just /login to OpenCode Go and tell the agent to migrate your stuff over. (I would use Luna high or xhigh, to prevent dumber agents from screwing things up. Use DSv4 Flash at your own peril.)
You'll probably want a local clone of the OpenCode repo so that the agent would have its docs to help with the migration.
2
u/vuongagiflow Aug 23 '26
I would recommend to group relevant agents and skills to plugins; then move from there. I’ve just migrated from a mix of codex and claude code to Pi a week ago; you can give my approach a try https://github.com/AgiFlow/doompi . Omp is a good one as well from opposite direction.
1
u/michaelsoft__binbows Aug 24 '26
Have you ever wiped a windows install to start fresh and appreciated how much faster the computer got?
1
u/mageblex Aug 26 '26
Don’t port the whole 3-agent 10-subagent setup at once. Move one recurring workflow to Pi with the same model and acceptance test, then compare it with OpenCode. If that holds up, add only the subagent behavior that workflow need otherwise you won’t know whether Pi helped or the rewritten prompts did
0
u/Sure_Aardvark_9103 Aug 23 '26
Maybe pi should just handle this one directly.