Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Obtain object id and uri through reasoning #2

Open
selBaez opened this issue Apr 12, 2022 · 0 comments
Open

Obtain object id and uri through reasoning #2

selBaez opened this issue Apr 12, 2022 · 0 comments
Assignees

Comments

@selBaez
Copy link
Member

selBaez commented Apr 12, 2022

The brain has a capability to assign object ids by maximising object permanence. This means that if during one episode at location A, there were 5 chairs identified with ids 1-5, then the next episode at location A, when 3 chairs are detected the new detestions will be assigned ids 1-3, therefore assuming the same chairs stayed in the location.

This functionality is currently part of the brain processing, but we now want it to be part of the linking/disambiguation module. Therefore, it should be something like this:

# Get ids of existing objects in this location
memory = brain.location_reasoner.get_location_memory(capsule)
object_id, memory = get_object_id(memory, capsule['object']['type'])

capsule['object']['id'] = object_id
capsule['object']['uri'] =  str(self._rdf_builder.create_resource_uri('LW',
                                             casefold_text(f"{capsule['object']['type']} {objct_id}", format='triple')))

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

No branches or pull requests

2 participants