aiondemand / aiondemand/AIOD-rest-api

Add all back-relationships.

未關閉
#128 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
enhancement priority
主要語言
Python
星號
36
分支
77
PR 合併指標
30 天內沒有已合併 PR

描述

- Setting `Organisation.members` should result in `Person.member_of` being filled for the corresponding person
- `Dataset.funder` -> `Person.funded_dataset` / `Organisation.funded_dataset`
- ...
Same principle holds for many relations.

**Relationships between non-abstract classes**
For some relationships, this is rather straight-forward. As long as both entities are not abstract (e.g. Organisation and Person), you can easily create the relationship.

**Relationships from/to an abstract class**
It's more difficult when one of the classes is abstract (e.g. Dataset.funder -> Agent.funded_dataset). In this case, we create the back-relationship on `AgentTable`. But then, the back-relation will not be visible on `Organisation`, because `Organisation` is an `Agent`, which has a one-to-one relationship to `AgentTable` (here, the `AgentTable` is serialized to an identifier). We need to make sure that `Organisation.agent_table.funded_dataset` is serialized to `Organisation.funded_dataset`. This is already solved for `is_part_of` -> `has_part`, and `relevant_resource` -> `relevant_to`. See `ResourceTable` and `AbstractAIResource`. Notably: `deserialized_path="ai_resource_identifier",`

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。