Background and foreground
Most agreements separate background IP, which each party brings in, from foreground IP, which the collaboration creates. The background side needs clear limits on how the other party may use it during and after the project. Ownership of foreground IP can go to one party, be split by field, or be held jointly, and each choice carries consequences. Under US patent law, joint owners of a patent can generally use and license it without the other's consent and without sharing the proceeds, unless an agreement says otherwise, and the rules differ in other countries. Inventorship, by contrast, is decided by law based on who actually contributed to the claimed invention, and a contract cannot change it.
Running the collaboration
Day-to-day terms matter as much as the ownership clause. Set out how information is shared and marked, who may file patent applications and who pays for them, and whether either side may publish results. Records of who contributed what, and when, help settle inventorship and ownership questions later. When the partners are competitors, information sharing and restrictions on each other's activities can raise antitrust issues. It also helps to decide early how disagreements between the partners will be resolved, since a stalled collaboration is a poor moment to negotiate a forum. Gather your list of background technology, the project scope, and any existing licenses that might limit what you can contribute.
When the project stops
Projects sometimes end before they finish, through a change in priorities, a failed milestone, or an acquisition. The agreement should address what happens to work in progress, whether either party can continue alone, and which licenses survive termination. Confidentiality obligations usually need to outlast the project itself. With a draft joint development agreement, we test the draft against a few likely scenarios, including a successful product, an abandoned project, and the sale of one party, and adjust the terms that break under them.