What about publications?
Generally, a patent application should be filed before your manuscript is published. This can take the form of a provisional patent application which protects the technology for one year at minimum cost. And, it can usually be completed quickly so it can be prepared and filed even after you’ve submitted a manuscript for publication.