{"id":13407521,"url":"https://github.com/aichaos/aiml2rs","last_synced_at":"2026-01-19T18:36:09.765Z","repository":{"id":3251077,"uuid":"4288890","full_name":"aichaos/aiml2rs","owner":"aichaos","description":"Tools to convert AIML code into RiveScript code.","archived":false,"fork":false,"pushed_at":"2016-12-16T08:46:53.000Z","size":1568,"stargazers_count":18,"open_issues_count":0,"forks_count":6,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-07-31T20:27:32.656Z","etag":null,"topics":["aiml","rivescript"],"latest_commit_sha":null,"homepage":null,"language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aichaos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-05-10T19:35:14.000Z","updated_at":"2021-12-28T05:01:55.000Z","dependencies_parsed_at":"2022-08-23T14:30:27.881Z","dependency_job_id":null,"html_url":"https://github.com/aichaos/aiml2rs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aichaos%2Faiml2rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aichaos%2Faiml2rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aichaos%2Faiml2rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aichaos%2Faiml2rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aichaos","download_url":"https://codeload.github.com/aichaos/aiml2rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243577815,"owners_count":20313705,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aiml","rivescript"],"created_at":"2024-07-30T20:00:41.451Z","updated_at":"2026-01-19T18:36:09.666Z","avatar_url":"https://github.com/aichaos.png","language":"Perl","funding_links":[],"categories":["Tools"],"sub_categories":["Language Converters"],"readme":"aiml2rs\n=======\n\nTools to convert AIML code into RiveScript code -- and back!\n\nScripts\n=======\n\nThe `aiml2rs.pl` script does all the magic of converting Alice AIML code into\nRiveScript code.\n\nThe `rs2aiml.pl` script does the opposite: converting RiveScript code back\ninto AIML code.\n\nHow to Use\n==========\n\nPlace all your `*.aiml` files in the `aiml/` directory, and then run the\nscript. It will attempt to convert all the AIML code into RiveScript, and\nwill output the results into the `rs/` directory.\n\nFor rs2aiml, place your `*.rs` files in the `rs-in/` dirctory, and then run\n`rs2aiml.pl`. It will attempt to convert the RS code into AIML, and output\nthe results into `aiml-out/`.\n\nCaveats\n=======\n\nThere are some things that this converter won't be able to translate\nautomatically. These are:\n\n1) Embedded `\u003crandom\u003e` tags are not supported. Currently none of the RiveScript\ninterpreters are able to handle embedded random tags either.\n\n2) Complicated conditionals. There are only a couple of these in Alice's AIML\nset. Simple conditions should work though (ones where there is only one\n`\u003ccondition\u003e` tag, and it takes up the entirety of the template). Embedded\nconditions? Forget about it.\n\nFor the cases that `aiml2rs` doesn't handle automatically, it will print out the\nAIML file name and `\u003cpattern\u003e` where the anomoly occurred, so that you can go\nand enter it in manually. `aiml2rs` won't attempt to generate RiveScript code for\ntriggers that have issues like this.\n\nWhen converting from RiveScript back to AIML, the following limitations exist:\n\n1) Nested parenthesis groups in triggers will be skipped. These are triggers\nwhere you include optionals INSIDE an alternation group, or any similar combination.\nThese kinds of triggers can't be permutated cleanly, so are skipped.\n\n2) Nested `\u003cset\u003e` tags will be skipped (ie. `\u003cset fav\u003cstar1\u003e=\u003cstar2\u003e\u003e`, because\nAIML doesn't support this.\n\n3) Any conditionals besides a simple `\u003cget variable\u003e == value` will result in\nthe entire reply being skipped, because AIML doesn't support any kind of\ncondition except `==` on user variables.\n\nAlice AIML Quirks\n=================\n\nThere are a number of patterns in the Alice AIML set that are invalid (they\ncontain foreign symbols for example). These patterns will be skipped when\nconverting to RiveScript (a warning is given during the conversion process).\n\nTroubleshooting\n===============\n\nIf the script crashes with an error that originated from `XML::Parser`, it is\nmost likely because an invalid character appeared in the AIML input (for example\na Unicode symbol). The error message is hard to read, but it will point you to\nthe line number in the AIML document where the error occurred.\n\nThe Alice set included in this repo was downloaded on May 9, 2012 and the Unicode\nsymbols in it were removed. If you use your own AIML set and get these errors,\nyou'll have to fix them yourself.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faichaos%2Faiml2rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faichaos%2Faiml2rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faichaos%2Faiml2rs/lists"}