BLLIP / bllip-parser

BLLIP reranking parser (also known as Charniak-Johnson parser, Charniak parser, Brown reranking parser) See http://pypi.python.org/pypi/bllipparser/ for Python module.
http://bllip.cs.brown.edu/
227 stars 53 forks source link

Python 3 version in the works? #26

Closed cayorodriguez closed 8 years ago

cayorodriguez commented 9 years ago

Hi, Are you planning on a Python3 version? It shouldn't be too difficult to port it, basically fixing prints, "open" for "file", and mainly fixing iterable vs. list indexing. Thanks

Carlos

dmcc commented 9 years ago

I would definitely like BLLIP to run in Python 3. I will try to triage this soon, but not sure when I will have time to dig into it. So if someone is looking to get involved, this would be an awesome way to help out...

cayorodriguez commented 9 years ago

Hi, I'll take a look at it as soon as I have more time (project deadline now).

Best,

Carlos

On Tue Jan 20 2015 at 17:07:38 David McClosky notifications@github.com wrote:

I would definitely like BLLIP to run in Python 3. I will try to triage this soon, but not sure when I will have time to dig into it. So if someone is looking to get involved, this would be an awesome way to help out...

— Reply to this email directly or view it on GitHub https://github.com/BLLIP/bllip-parser/issues/26#issuecomment-70679004.

pkclaus commented 9 years ago

Greetings,

I am a german student of computational linguistics, working in Heidelberg for the past year, at the Heidelberg institute for theoretical studies (HITS). In our work process, we were updating a coreference resolution toolkit used by the nlp group. (https://github.com/smartschat/cort)

While doing so, I've tried updating the BLLIP Parser for usage with Python3. There is an updated version of it, mainly converted with 2to3, with some changes to the RerankingParser and the so-files. So far, the parser has been successfully working with calls to 1-best parsing. While it surely is not perfect, it may be a start when trying to use BLLIP with a Python3 environment.

If this version could prove useful, maybe I could create a pull request?

Regards, P. Claus

dmcc commented 9 years ago

Thanks and yes, this sounds like a useful pull request, @pkclaus. Can you say more about which features (if any) aren't accessible/working in your version?

Please see the contributing guidelines and sign the CLA so this could be merged with the main branch.

PS. @cayorodriguez, were you able to make any progress on this?

dmcc commented 8 years ago

I may have some time to work on this soon. @pkclaus, do you think you'll be able to make a pull request?

pkclaus commented 8 years ago

@dmcc The pull request has been created, and all the changes that were made for using bllip-parser in a python3 environment have been briefly documented in the txt-file within the commit. Hopefully this should provide some sort of rough starting point. The signed CLA should be on its way momentarily. Is it sufficient to scan and send the CLA to the provided mail address?

Best Regards!

dmcc commented 8 years ago

Thanks @pkclaus! I think it's sufficient to scan the CLA. I'll look over the pull request and work on merging it in.

dmcc commented 8 years ago

With bf933c7 and 53c412ca6282d9b101f1a3f9438f069553f54aa3, Python 3 should be supported in the main branch (with the exception of Python 3.5 until swig 3.0.8 is released) and tested on Travis-CI. After a little more testing, I'll make an official release. Please let me know if you run into any issues.

dmcc commented 8 years ago

Integration testing now tests Python 2.6, 2.7, and 3.4 and I've added a number of new tests to cover most of the main code paths, so I'm comfortable saying that BLLIP Parser is ready for broader testing on Python 3. Please open a issue if you run into any problems.