Skip to content

Instantly share code, notes, and snippets.

@DevJohnC
Created June 18, 2014 23:44
Show Gist options
  • Select an option

  • Save DevJohnC/c515b9eeb06409f8da39 to your computer and use it in GitHub Desktop.

Select an option

Save DevJohnC/c515b9eeb06409f8da39 to your computer and use it in GitHub Desktop.
class Program
{
static void Main()
{
var moduleDir = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Modules");
if (!Directory.Exists(moduleDir))
Directory.CreateDirectory(moduleDir);
var config = FrameworkConfig.CreateServerDefault();
var appDomainManager = new AppDomainManager();
config.DomainManagers.Add(appDomainManager);
config.ModuleLoaders.Add(new FileSystemLoader(moduleDir), appDomainManager);
var startupInfo = Framework.Bootstrap(config);
// generally, nothing so far has started any threads (apps maybe have)
// so keep this thread alive to keep the application running, maybe consider
// a loop that passes user input text to the NLP
Console.ReadLine();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment