EagleFiler’s database acts as a backup for the Finder tags, which are somewhat fragile due to the way they are stored. If the Finder tags are lost (e.g. when transferring a file over a network, editing a file with an application that doesn’t support tags, or backingup using a product that doesn’t support extended attributes), EagleFiler will automatically restore the tags from the database the next time you open the library.
I’m not sure I understand what you’re trying to do. You want to sync a different .eflibrary file that’s unrelated to the one in place next to Files? That’s what I take “library file” to mean, but it doesn’t make sense to me. Or you want to sync a folder within the Files folder?
The documentation quoted is about what happens if tags on files within Files are lost. If the tags are wiped out, EagleFiler will restore from the database in the .eflibrary. If they’re present but changed, it will take that as the truth and update the database.
Another process does the syncing and could replace existing files. The replacement file may have no tags, or just one tag; will have the same name; but may be different in size.
So, under what circumstances does EF restore missing tags? Does the tagless file have to be the same (existing) file (same checksum) or can it be a replacement file?
It doesn’t matter whether the file’s contents are different. EagleFiler will restore the tags if the file’s extended attributes (where the tags are stored) have been lost. If the xattrs are still there but different than what EagleFiler expected, it take that to mean that you changed the tags yourself (outside of EagleFiler) and sync those changes back into EagleFiler.