Synchronized animation of separate models

Let’s say I have to characters modeled for a game I’m working on. They’re in two different .blend files and I want them to have a swordfight.

Could someone give me some pointers as to how I would best animate them both?
To make the animations fit together perfectly, I want them both in same scene, both without permanently fusing the models together into a single .blend file.

Ideally, I’d want to create a third .blend file that only references the models in the other two files and either save the animations of their armatures in the referenced .blend files or store them in the new .blend file in a way that allows me to export just the animations without the bones and meshes.

well, at some point you will need a file with both models, you can delete it when we are done, but it will be needed temporarily.

in the new file, append the models. Now, create a new action for each character (dopesheet, switch to action editor) – give it a name (like fight_1 and fight_2)
animate the fight.

save the file.

now, you could go into the master files for the two models, and append the appropriate action (the action for that character) from the temp file you just saved. Now the sword fight is saved in the master file for each character.

If you wanted to just have the actions in a blend file and no mesh data, you can create a new file, and apend both actions, and in the action editor, mark both actions to be saved, even if their are no users (click the F next to the actions name)

Now you can delete the file you used to make the actions.