Re: [Pharo-users] [vwnc] Parsing in Smalltalk

2019-12-02 Thread Steffen Märcker

Dear Sean,

thanks for bringing this up and for the interesting link [1]. I'll have a  
look. Meanwhile, I am still on both lists. ;-)



Steffen Märcker wrote

I wrote a PetitParserGenerator that takes the DSL and builds a
PetitParser.


I don't know how I could've missed this gem! I hope Steffen is still
subscribed. I googled "PetitParserGenerator", but only found these ML  
posts

:/


It was easy to miss, since I never actually posted that code. Here's what  
I've done:


From Xtreams.PEG syntax:
- PetitParserGenerater > PetitParser code
- PetitParserParser> PetitParser instance

I can send you that code. It should be straight forward to adapt it for  
PP2. However, I moved away from Xtreams own PEG flavor to Bryan Ford's  
original PEG syntax (close but more common) and programmed for Xtreams, PP  
and PP2:


From Bryan Ford's original PEG syntax:
1. Xtreams Grammer and Actor that build an Xtreams parser
2. PP(2)PEGParserParser that builds a PP(2) parser instance
3. PP(2)PEGParserCompiler that builds PP(2) parser classes

All three are available for VW in the Cincom's public repository:
- Xtreasm-Parsing (8.2-3,stm): +PEG parser +some fixes to Xtreams parser
- PetitParser-PEG (1.11,stm)
- PetitParser2-PEG (1.11,stm)

And 2, 3 for Pharo on GitHub, e.g.
- https://github.com/kursjan/petitparser2/tree/master/PetitParser2-PEG

Speaking of, I just noticed that translator form Xtreams.PEG to PEG is  
missing to complete the picture here. ;-)



IIRC Xtreams can take a BNF and generate a parser.


As far as I know, there is no BNF-like parser generator for Xtreams,  
available.



wouldn't mind a two step BNF -> Xtreams -> PP process.


Is it an option for you to convert your BNF to PEG manually?

Best regards,
Steffen



[Pharo-users] thesis on using ML for Pharo code completion

2019-12-02 Thread Myroslava Romaniuk via Pharo-users
--- Begin Message ---
Hi everyone

I'm starting work on a thesis on using ML for Pharo completion, in
particular n-gram language models, and I wrote a little blog post with some
details and research questions that I have. Here's a link:
https://medium.com/@myroslavarm/using-ml-for-pharo-autocompletion-ideas-80a362258bc3
.

Any feedback or ideas on the topic (and research questions) are most
welcome.

Best regards,
Myroslava
--- End Message ---