CentreForDigitalHumanities / CentreForDigitalHumanities/Textcavator
Merge Corpus and CorpusConfiguration models?
- Dominant language
- Python
- Stars
- 12
- Forks
- 3
- Avg merge
- 3d 3m
- Merged PRs (30d)
- 9
Description
The [corpus database models](https://github.com/UUDigitalHumanitieslab/I-analyzer/blob/1dfa42b8aafab54108fa8e03bb43a7ace6527be7/backend/addcorpus/models.py) split a corpus into a `Corpus` and `CorpusConfiguration`. These models have a one-to-one relationship. (Corpus is the "reference" object, CorpusConfiguration contains all the settings. C.f. [documentation on corpus models](https://github.com/UUDigitalHumanitieslab/I-analyzer/blob/develop/documentation/Corpus-definitions.md#database-models)).
Originally, the main motivation for this separation was that when you load Python corpus definitions, you can just remove all `CorpusConfiguration` data and make a clean import. However, https://github.com/UUDigitalHumanitieslab/I-analyzer/pull/1515 makes the corpus import less destructive, so this isn't really needed.
I feel like this split just make things needlessly complicated, so perhaps we should merge the two models into a single `Corpus` model.
@JeltevanBoheemen what do you think?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with backend/addcorpus/models.py and the corpus model documentation, then read PR #1515 to understand how corpus imports changed. Trace the one-to-one relationship and import cleanup behavior before determining whether the models should be merged. Done would require an agreed design and corresponding updates to the documented model structure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- databases
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100