Skip to content
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

Integrate with pyre incremental and adapt the TypeWriter search strategy #7

Open
stroxler opened this issue Dec 9, 2021 · 1 comment

Comments

@stroxler
Copy link
Collaborator

stroxler commented Dec 9, 2021

It would be interesting to see how well the TypeWriter algorithm (https://software-lab.org/publications/TypeWriter_arXiv_1912.03768.pdf) for searching type annotation suggestions works against type4py. We might get dramatically better results for two reasons:

  • type4py's ML model seems to perform quite a bit better
  • today's pyre incremental is orders of magnitude faster than pyre was when the TypeWriter paper was written, so we may be able to try many more combinations and get correspondingly better results

At one point we'd considered hacking this very quickly as an internal project in my company, but we ran out of time. I think it would be better done open-source anyway because then

  • it would be easier to try out against external projects
  • we could publish our results with code if they are interesting enough to be worth a paper
  • the entire OSS community could benefit

I'm unsure if I can find time to prioritize this in the next 6 months at work but it's a little more likely if I treat it as a side project, which would also open the door to an informal weekend hackathon as a way to kick it off :)

I could do this in a separate repository or inside of type4py. What do you think @mir-am ? And does this sound interesting to you?

@mir-am
Copy link
Member

mir-am commented Dec 10, 2021

@stroxler
Thanks for your interest in Type4Py and sharing your ideas.
Yes, it is indeed an interesting idea. We very welcome contributions.
We actually had a similar idea to yours, i.e., using a type checker (mypy) to validate Type4Py's predictions.
I prefer to implement this idea inside Type4Py's repo on another branch. I am also glad to help you to incorporate the idea into Type4Py.
It may be worth mentioning that I used pyre qurey to infer type annotations for augmenting the dataset of Type4Py (see here). Regarding this, I have a couple of questions about using pyre, which I will ask later in this thread.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants