-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: nanopub client for storing user enrichments #307
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not very familiar with RDF. So this part is hard for me to review. I read the code and looked up the new packages you are using.
As a user of this Enricher, I do have some questions about the schema, and how I should use the Enricher. I am aware the data model for expressing user enrichments is not finished. So we can also wait for the final data model before explaining to me how I should use the Enricher.
description: z.string(), | ||
citation: z.string(), // Required or optional property? | ||
about: z.string().url(), | ||
creator: z.string().url(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where does this creator url come from? Is this a Clerk organization? They have GUIDs but no URLs. Or will we use a different system to connect the Clerk organization to this Enricher?
And do we need to save both the user and the community? Or only the community?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question! We will probably have to add a new field to the 'Communities' UI. Users can then provide their IRI. This IRI comes from some world-wide user identification system such as ORCID. It could also be that only community administrators need to provide this IRI; the IRI will then identify the community, not an individual user.
const addTextOptionsSchema = z.object({ | ||
description: z.string(), | ||
citation: z.string(), // Required or optional property? | ||
about: z.string().url(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm trying to understand what values should be placed in about
. Looking at the integration tests, this is a URI to the object. Or maybe a subpart of an object (for example, the description of an object)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this is the 'big unknown' in the design of the user enrichments at this moment. An enrichment is about a specific bit of information, such as the title or the date made of an object - it's not about the object as a whole. This means that the properties of an object need to have identifiers (= IRIs). But the props currently don't have these (not in the API, not in the underlying data). Kinsuk is looking into this. For the time being - while developing and testing - we can invent some identifiers (I'll discuss this with Kinsuk and make a proposal).
This PR introduces a new package, 'enricher'. The package allows us to store and retrieve user enrichments, i.e. information provided by users. Some notes:
Enricher
for storing an enrichment - seeenricher.integration.test.ts
for an example.