fabioravila / rivescript-csharp Goto Github PK
View Code? Open in Web Editor NEWA RiveScript interpreter for C# .Net. RiveScript is a scripting language for chatterbots. http://www.rivescript.com
License: MIT License
A RiveScript interpreter for C# .Net. RiveScript is a scripting language for chatterbots. http://www.rivescript.com
License: MIT License
rivescript-js has a deparse and stringfy function that allows you to extract the in-memory representation of the brain memory to a JSON notation, and vice versa
My idea is to create an object that represents this JSON in a structured way, besides allowing it to be easily converted to JSON notation.
Methods to implement:
For more details of deparse: https://github.com/aichaos/rivescript-js/tree/master/eg/deparse
What about publishing a Nuget package?
Make construtor with more options like in rivescript-js#rivescript-hash-options
The current csharp object handler is a first work code just to have something to say.
The definitive has to be better
Like in rivescript-java RSBot Demo RSBot.java
Implement some functions of rivescript-js
Write test of rsts to fill up set os tests
Inspired on rivescript-java#33
As my initial code is based on the rivescript-java version, I think it's a good idea to try to keep the code of the two similar versions in terms of implementation and organization.
This would make it easier to replicate localized corrections in the java version for csharp, given the low usage of the csharp version relative to java.
especially this commit: Refactorings for 0.8.0 release
Caro Fabio, por favor verifique seu código na linha 1867 em relação ao trecho abaixo cuja declaração da string value precede o teste da existência da chave no dicionário vars!
Obrigado.
//string value = vars[var].ToLower().ReplaceRegex("[^a-z0-9 ]+", "");
//BUG: tem que testar se contem primeiro!!!
//string value = Util.StripNasties(vars[var].ToLower(), utf8);
// Have this?
if (vars.ContainsKey(var))
{
string value = Util.StripNasties(vars[var].ToLower(), utf8);
regexp = regexp.Replace(tag, value);
}
else
{
regexp = regexp.Replace(tag, "undefined");
}
Implement freezeUservars and thawUservars functions of rivescript-js
From RiveScript-JS #122 and Rivescript-Java #9, ordering of triggers with a common %Previous are sorted incorrectly.
See the linked issue for details.
Like in reply-fetching-methods
Implement setSubroutine function like does JS ans Pearl version.
This allows you to insert procedures directly into without having to write macros
The method of using Rot13 to do substitutions does not seem to be robust.
Attached are the RS files I was using. This is taken partially from the Eliza template on the RiveScript website.
Input: he's an idiot
Actual output: Why are you concerned over my vfbus31tor an idiot?
Expected output: Use: https://www.rivescript.com/try with the Eliza template (the default one) - this shouldn't match anything at all
Some modifications are made on rsjava lib, so i will catch-up
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.