Skip to content

Conversation

@breuleux
Copy link
Member

  • Update to serieux 0.3.8
  • Use FileBacked from serieux as a backing for FileCollection
  • Replace Finder by Index, make it more generic
  • Sort papers by latest venue

@breuleux breuleux force-pushed the better-index branch 2 times, most recently from 89382ba to 9be4698 Compare January 27, 2026 18:19
@satyaog satyaog self-assigned this Jan 27, 2026
Comment on lines +24 to +28
def index(self, entry: T):
for name, fn in self.indexers.items():
idx = self.indexes[name]
for value in fn(entry):
idx[value] = entry
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would the following be useful to avoid unexpected replacement of an entry?

Suggested change
def index(self, entry: T):
for name, fn in self.indexers.items():
idx = self.indexes[name]
for value in fn(entry):
idx[value] = entry
def index(self, entry: T):
for name, fn in self.indexers.items():
idx = self.indexes[name]
for value in fn(entry):
assert value not in idx or idx[value] == entry
idx[value] = entry

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Collisions aren't necessarily a big deal here, they might happen for titles, but that's not really going to break anything.

@breuleux breuleux merged commit dfcce9b into mila-iqia:v3 Jan 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants