Do I write my undergrad institution as my affiliation or no affiliation, or my company or both?
The guidelines are
When the work reported in the paper used resources and support from the university, your affiliation is the university.
When the work reported in the paper used resources and support from the company, your affiliation is the company.
In cooperative projects, a dual affiliation could be listed.
One of the co-authors (the primary author) should direct you further.
How did you get the position at this company? Is this through a partnership with a professor at your university or is it a job that you got on your own?
There are many factors at play in this, so it is hard to tell if you should list your undergraduate institution and/or the company. Most important is who you worked directly under, and if this person and/or the research that you are doing has any affiliation with your undergraduate studies. You could maybe list the undergraduate institution as an affiliation (and you should especially if this is sponsored by a professor there), but it may be better to mention affiliation with the company instead if there are other factors at play (like you work at this company full time or in the long term). So it really could go either way depending on your specific situation.
TLDR, "rule of thumb":
- If this is more affiliated with your undergraduate institution (including through a professor is how you got this opportunity), use your undergraduate university
- If you are directly, formally employed with the company (and especially if this is not related to any research you are doing with faculty at your institution), you could maybe list affiliation with your undergraduate university BUT your affiliation should be primarily with the company