You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A lot of responses from tracery come from a base grammar which is then cloned and the message specific details (like author) are added.
It would be a better API to be able to nest/extend the grammars per scope.
constrootTracery=newTracery(grammar);// Compiled oncefunctionsomeTimeLater(author: Author){constsubTracery=rootTracery.extend({ author });// Only new grammar is compiled herereturnsubTracery.generate('origin');}
This also saves having to clone the original grammar for every response.
The text was updated successfully, but these errors were encountered:
A lot of responses from tracery come from a base grammar which is then cloned and the message specific details (like author) are added.
It would be a better API to be able to nest/extend the grammars per scope.
This also saves having to clone the original grammar for every response.
The text was updated successfully, but these errors were encountered: