fix: bot identity reflects the A.L.I.C.E./AIML lineage, not Mycroft - #23
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greetings, human! The automated checks are complete. 👾I've aggregated the results of the automated checks for this PR below. 🔍 LintThe data has been harvested! Check the findings below. 🌾 ❌ ruff: issues found — see job log ⚖️ License CheckChecking for any potential legal hurdles. 🚧 ✅ No license violations found. Policy: Apache 2.0 (universal donor). StrongCopyleft / NetworkCopyleft / WeakCopyleft / Other / Error categories fail. MPL allowed. 🔌 Skill Tests (ovoscope)Ensuring the skill provides a consistent and delightful experience. 💖 ✅ 7/7 passed ✅ TestAimlPersonaSpeaksThroughPipeline — 3/3 🚌 Bus CoverageEnsuring the skill's internal gears are meshing correctly on the bus. ⚙️ 📊 CoverageChecking the insulation of our logic. 🏠 Per-file coverage (2 files)
Full report: download the 🔨 Build TestsEnsuring the code is correctly packaged and ready. 📦 ✅ All versions pass
Powered by OVOS scripts and a bit of magic. ✨ |
test_e2e_persona_pipeline.py checked msg.msg_type == "speak", but the stack now emits "ovos.utterance.speak" (see ovos_spec_tools.messages.SpecMessage.SPEAK). This fails identically on unmodified dev - reproduced by running the class before this change - so it is a pre-existing defect, not something introduced by other work in this repo. It blocks CI on every PR that touches this test file, since the two tests in TestAimlPersonaSpeaksThroughPipeline never find a "speak" message and fail on "Expected at least one 'speak' message".
cfb9d11 to
ff4c67a
Compare
setBotPredicate calls hardcoded "Mycroft" for name and genus, and age was computed from mycroft-core's creation year. A prior version of this fix replaced those with generic "OVOS" branding, but AIML is a historical chatbot language with its own lineage worth preserving: it was authored by Dr. Richard S. Wallace as the pattern-matching engine behind A.L.I.C.E. (Artificial Linguistic Internet Computer Entity), an ELIZA successor that won the Loebner Prize three times. The defaults now name that lineage instead - name/genus/family describe A.L.I.C.E. and AIML, and age derives from ALICE_BIRTH_YEAR (1995, when A.L.I.C.E. "came to life" per https://en.wikipedia.org/wiki/Artificial_Linguistic_Internet_Computer_Entity) instead of an arbitrary org creation date. No unsourced biographical detail about Wallace (e.g. a hometown) was invented. Deployed and probed live with real questions, which caught two problems the predicate-value assertions alone couldn't see because the bug is in how a value renders inside the corpus's sentence frames, not in the value itself: "botmaster" is a role word the corpus interpolates a name into (e.g. "My <bot botmaster> is <bot master>.", "WHO IS YOUR BOTMASTER" -> "My <botmaster> is <master>."), not a name slot. Setting it to "Dr. Richard S. Wallace" produced "My Dr. Richard S. Wallace is Dr. Richard S. Wallace." - grammatical nonsense. botmaster now stays "master" (the original role word) and the person goes in "master" instead, rendering "My master is Dr. Richard S. Wallace." birthplace/location/city were never set at all, so "WHERE ARE YOU FROM" rendered "I am originally from . Now I live in . Where are you?" with empty holes, and similarly for "I am presently domiciled at <location>." Grepped every <bot name="..."/> reference across the bundled corpus (101 distinct predicates) against what this plugin actually sets; birthplace/ location/city/birthday/phylum were reachable but unset, so they now default to values describing the bot itself (it runs on the internet; phylum "software" completes the kingdom/phylum/class/order/family/genus/species taxonomy chain already partly set) rather than a guess about Wallace's whereabouts, since no source gives him a hometown or birthday. 87 of the 101 corpus predicates remain unset by design (secondary details like favorite foods/movies/hobbies, not core identity, out of scope for this fix) - see the PR description for the full list. All predicates remain overridable via config, the int() guard around the birth year still can't crash construction, and every value is still coerced with str(). Regression tests assert both the predicate values and (new) the actual rendered answer text via continue_chat, so a correct-value-wrong-slot regression like the botmaster one fails the suite even when the underlying predicate value looks right in isolation. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
ff4c67a to
14dd267
Compare
This plugin's bot identity predicates (name, genus, age, and the rest) were hardcoded to "Mycroft", which is wrong for a plugin that isn't Mycroft. An earlier version of this fix replaced those with generic "OVOS" branding, but AIML is a historical chatbot language with its own real lineage worth keeping: it's the pattern-matching engine Dr. Richard S. Wallace built for A.L.I.C.E. (Artificial Linguistic Internet Computer Entity), an ELIZA successor that won the Loebner Prize three times. The defaults now describe that lineage instead of a generic brand.
A.L.I.C.E. "came to life" on November 23, 1995 (https://en.wikipedia.org/wiki/Artificial_Linguistic_Internet_Computer_Entity), which is what the age and birthday predicates now derive from, replacing the earlier arbitrary org-creation-date default. AIML itself was formally released in 2001 and developed by Wallace and a free-software community through 2002, per the same source family (https://en.wikipedia.org/wiki/Artificial_Intelligence_Markup_Language).
Deploying this and actually talking to the bot surfaced two problems that predicate-value assertions alone couldn't catch, because the bug was in how a correct value renders inside the corpus's sentence frames, not in the value itself. First, "botmaster" is a role word the corpus interpolates a name into ("My is ."), not a name slot - an earlier version of this PR put "Dr. Richard S. Wallace" there and produced "My Dr. Richard S. Wallace is Dr. Richard S. Wallace." That's fixed now: botmaster stays "master" (the original role word) and the person's name lives in "master", rendering "My master is Dr. Richard S. Wallace." Second, birthplace/location/city were never set at all, so "WHERE ARE YOU FROM" rendered with empty holes ("I am originally from . Now I live in . Where are you?"). Those now default to values that describe the bot itself - it runs on the internet - rather than a guess about Wallace's whereabouts, since no source gives him a hometown or birthday.
I grepped every
<bot name="..."/>reference across the bundled AIML corpus (101 distinct predicates) against what this plugin actually sets. Beyond the ones above, this PR also fills "phylum" ("software"), completing the kingdom/phylum/class/order/family/genus/species taxonomy chain that was previously missing one rank. 87 of the 101 corpus predicates remain unset by design - things like favorite foods, movies, sports teams, hobbies, and similar secondary personality flourishes (favoritefood, favoritemovie, hockeyteam, kindmusic, looklike, and so on) that aren't core identity and are out of scope for a Mycroft-attribution fix; they render as empty holes today exactly as they did before this PR, which is a pre-existing gap in the bundled corpus integration, not a regression from this change.Every predicate is still overridable via config, the
try/exceptguard around a badbot_birth_yearconfig value still prevents that from crashing plugin construction, and every value is still coerced withstr(). The regression tests now assert both predicate values and the actual rendered reply text viacontinue_chatfor natural questions (name, botmaster/master, where-are-you-from), so a value that's correct but lands in the wrong template slot fails the suite instead of passing silently.