Allow topics to override primary category
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 177
- Forks
- 87
- Avg merge
- 1m
- Merged PRs (30d)
- 1
Description
User Story
As a tool developer, I'd like to be able to override the category classification given to my tool. Specifically I'd like https://github.com/mnahkies/openapi-code-generator to be labelled as a "Code Generator" rather than a "Parser"
Context
Currently the category is assigned using https://www.npmjs.com/package/bayes which essentially uses the frequency of tokens in a provided text against the frequency of tokens in already classified text to assign a class.
However, because the current category/class distributions are pretty uneven (>30% are assigned to "Parsers") it seems to have ended up overly biasing assignment to "Parsers". For example, Redoc is assigned "User Interfaces" and "Parsers", but not "Documentation"
And these are all assigned to "Parsers" as well:
- OpenAPI Server Code Generator (oapi-codegen)
- OpenAPI Mocker
- docs
- php-openapi-faker
- ...
Rather than "Code Generator" / "Mock" / "Documentation" / "Testing Tools"
I'm not sure if this is inherent to the classification approach / problem space (eg: is the written language used for different types of tool lacking enough distinguishing tokens to give a good signal), or a negative feedback loop from the existing classifications, but either way I think it would be good to have a way to override this behavior.
I'm hopeful that introducing this would over time improve the accuracy of the classification using bayes as a result of the accurate manually labelled data.
Detailed Requirement
Propose adding a way to manually label a primary category for a tool. I see two main options:
- Field on the
tools.yamlentries likemanualCategoryOverride - Looking for new topics on the source entries like the existing
openapi3/openapi31ones that indicate the primary category
I see the primary benefit of the first option being that it gives control of curation to the maintainers of this repository, whilst the second option allows tool writers to self serve. It's possible that both might be desirable, especially to account for entries that aren't scrapped from Github (though I guess their categories are essentially manually configured already).
I think some amount of rationalization (eg: Testing vs Testing Tools) of the existing categories may be useful as well, and potentially adding a description of each category explaining what is in/out of scope for it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how the JavaScript application uses bayes to assign categories and how entries in tools.yaml are represented. Compare the proposed manualCategoryOverride field with topic-based overrides, including entries sourced outside GitHub. Done should include a settled precedence rule, category handling, and coverage for manually curated classifications.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100