if youre in phoenix Az area I can help you
before going hog wild, we need to determine if the cdi is really the cause. You say it run good and bad, we need more details on this.
does it cold start fine
does it idle cold fine
does rev cold fine
does it have its poor running condition after its been running for awhile
answer same as above when hot have hour+ of riding
does it show the same conditions repetitively/ consistently