spaCy
                                
                                
                                
                                    spaCy copied to clipboard
                            
                            
                            
                        Custom extensions for spans with equal boundaries
Description
This PR is the continuation of PR #9708 and aims to fix Issue #9706.
Big thanks to @nrodnova for working on the previous PR and creating the Issue ✨
At the moment, the keys of the underscore class only contain the start_char and end_char which makes it impossible to save custom attributes to spans with the same boundaries but with different labels/kb_id/id because they're overwriting each other. This PR adds three new keys to the underscore class for Span objects to make spans with different labels/kb_id/id unique.
Types of change
Bug fix
Checklist
- [x] I confirm that I have the right to submit this contribution under the project's MIT license.
 - [x] I ran the tests, and all new and existing tests passed.
 - [ ] My changes don't require a change to the documentation, or if they do, I've added all required information.