reification based on examples
- Dominant language
- Haskell
- Stars
- 28
- Forks
- 10
- PR merge metrics
- No merged PRs in 30d
Description
Would be great to automate the schema creation - even if it's crude at first, as a developer tool.
Admittedly, in many cases this may be an anti-pattern, however it can quickly aide in the creation of a schema - particularly when working with poorly documented API's, or when building parsers on one side of an integration, which must agree with an existing implementation.
Ideally i see this as a function `[JSON] -> Schema`, which can then be rendered out to a file.
Even if this is just the primitive assignments without any fancy string subtypes or other features, it should be reasonable to generate a schema which would fit all provided examples, Quickcheck could assist this process using existing `Gen a -> [a]` functions.
the rapid development advantages here could make this a great utility, even with appropriate warnings that the schema itself should be treated as the source of truth.
Contributor guide
Research direction
The issue names no files or tests; begin by locating the existing Schema and JSON entry points in the repository. Review how schemas are rendered to files and how QuickCheck generators are represented, then define the smallest accepted JSON-to-schema behavior and confirm that generated schemas cover the provided examples.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell, json
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100