-
Notifications
You must be signed in to change notification settings - Fork 1
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: define JSON schema for amplitude model format #30
Conversation
@IlyaSegal maybe this schema is helpful for #6? |
So much fun. Copilot can take use of it, and write parts of the file. |
If the schema can validate #6, we can merge it. |
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.
Nice! Do you know if json
schemas can be nested? - i has been discussed at HS3 for long time
Do you mean schema composition? It's essentially already happening through the |
good moment to merge? |
Just needs a PR approval ;) |
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.
Very nice:-)
@mmikhasenko if you approve this PR, it should merge automatically |
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
Defined a JSON schema based on the example
Lc2ppiK.json
while understanding the format. The model is directly evaluated in VSCode — give it a try, by messing up some of the values and hovering over the keys to see their descriptions.Admittedly, JSON schema has less features than I thought. Particularly, I had hoped to build
enum
s for for instance the function names from the functions that are defined underfunctions
. As far as I understand, that cannot be done dynamically with JSON schema. Still, there are some fancy things you can do, like validating whether spin definitions are valid.