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

Tracery Support #19

Open
tra38 opened this issue Dec 20, 2016 · 1 comment
Open

Tracery Support #19

tra38 opened this issue Dec 20, 2016 · 1 comment

Comments

@tra38
Copy link
Contributor

tra38 commented Dec 20, 2016

Should Calyx support files written in Tracery? It seems that Tracery grammars are more common lately, and Calyx should probably support them to stay relevant (especially as one of the rationales for #7 is to eventually handle Tracery grammars). There did seem to be an abortive attempt at building a gem to handle Tracery so this might be a rather ambitious project. There's also the possibility that the Tracery grammar may be so complex that it might be better to treat it as its own separate library (and to treat Calyx as a dependency of that library).

@maetl
Copy link
Owner

maetl commented Dec 20, 2016

I would be interested in this. Interoperability between tools is a good goal to aim for.

I’ve already experimented with parsing the old style of Tracery grammars in Calyx and it works fine—it can be done with simple string rewriting operations. The problems here are related to native JavaScript string functions being called—for it to work as a general library, we’d need to introduce a compatibility layer that maps JavaScript to Ruby (eg: rule.toUpperCase => rule.upcase).

Also, the next version of Tracery looks like it will have a bunch of new syntax and conventions to handle. I haven’t looked into it yet, but just going by the progress @galaxykate is posting online, it looks like a greatly expanded range of features.

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