Skip to content

Conversation

@martinpopel
Copy link
Contributor

  • CorefCluster -> CorefEntity
  • mention.cluster -> mention.entity
  • cluster.cluster_id -> entity.eid
  • cluster.cluster_type -> entity.etype
  • for cluster in doc.coref_clusters.values(): -> for entity in doc.coref_entities:
  • for cluster_id, cluster in data.coref_clusters.items(): -> for eid, entity in doc.eid_to_entity:
  • rename also clusters/cluster -> entities/entity almost everywhere else (variable and parameter names, comments,...)
  • new udapi.core.block methods process_coref_mention and process_coref_entity
There is no need to iterate over all bundles/trees/nodes if a given block overrides only process_coref_entity(). Also, the detection of "No processing activity defined in block" had to be adapted to the new methods process_coref_entity and process_coref_mention. TODO: benchmark if calling process_node directly from process_document is actually faster than calling it via process_bundle and process_tree.
@martinpopel martinpopel merged commit 702e9b1 into master Apr 6, 2022
@martinpopel martinpopel deleted the rename-cluster-to-entity branch April 6, 2022 03:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants