use crate::{
transformer::{
Condition, ConditionMap, LanguageTransformer, Rule, RuleI18n, RuleType, SuffixRule,
},
transforms::inflection,
};
use fancy_regex::Regex;
use std::sync::LazyLock;
// impl From<Vec<SuffixRule>> for Vec<Rule> {
// fn from(value: Vec<SuffixRule>) -> Self {
// value.into_iter().map(|v| v.into()).collect::<Vec<Rule>>()
// }
// }
#[derive(Debug, thiserror::Error)]
enum TransformTestError<'a> {
#[error("{term} should have term candidate {src} with rule {rule} with reasons {reasons:?}")]
MissingTransformation {
src: &'static str,
term: &'static str,
rule: &'static str,
reasons: &'a [&'static str],
},
}
pub(crate) struct TransformTest {
pub(crate) term: &'static str,
pub(crate) sources: Vec<LanguageTransformerTestCase>,
}
pub(crate) struct LanguageTransformerTestCase {
pub(crate) inner: &'static str,
pub(crate) rule: &'static str,
pub(crate) reasons: Vec<&'static str>,
}
#[derive(Debug)]
pub(crate) struct HasTermReasons {
pub(crate) reasons: Vec<String>,
pub(crate) rules: usize,
}
#[derive(Debug, thiserror::Error)]
pub(crate) enum HasTermReasonsError {
#[error("No transformation from '{src}' to '{term}' with rule '{rule}'.\nRejected candidates:\n{}", .rejected.join("\n"))]
NoMatch {
src: String,
term: String,
rule: String,
rejected: Vec<String>,
},
#[error("Trace length mismatch: expected {expected}, found {found}")]
TraceLengthMismatch { expected: usize, found: usize },
#[error("Reason {index}: expected '{expected}', found '{found}'")]
ReasonMismatch {
index: usize,
expected: String,
found: String,
},
}
#[derive(Debug)]
pub enum IrregularVerbSuffix {
ใฆ,
ใ,
ใใ,
ใใ,
}
impl std::fmt::Display for IrregularVerbSuffix {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{self:?}")
}
}
pub fn irregular_verb_inflections(
suffix: IrregularVerbSuffix,
conditions_in: &'static [&'static str],
conditions_out: &'static [&'static str],
) -> Vec<SuffixRule> {
let suffix_str = suffix.to_string();
let iku_inflections = IKU_VERBS.iter().map(|verb| {
let first_char = verb.chars().next().unwrap();
let transformed: &'static str = format!("{first_char}ใฃ{suffix_str}").leak();
inflection(
transformed,
verb,
conditions_in,
conditions_out,
RuleType::Suffix,
)
});
let godan_inflections = GODAN_U_SPECIAL_VERBS.iter().map(|verb| {
let transformed: &'static str = format!("{verb}{suffix_str}").leak();
inflection(
transformed,
verb,
conditions_in,
conditions_out,
RuleType::Suffix,
)
});
let fu_inflections = FU_VERB_TE_CONJUGATIONS.iter().map(|[verb, te_root]| {
let transformed: &'static str = format!("{te_root}{suffix_str}").leak();
inflection(
transformed,
verb,
conditions_in,
conditions_out,
RuleType::Suffix,
)
});
iku_inflections
.chain(godan_inflections)
.chain(fu_inflections)
.map(|v| v.into())
.collect()
}
#[cfg(test)]
mod inflection_tests {
use fancy_regex::Regex;
use pretty_assertions::assert_eq;
use crate::{
ja::ja_transforms::irregular_verb_inflections,
transformer::{DeinflectFnType, RuleDeinflectFnTrait, RuleType, SuffixRule},
transforms::inflection,
};
// #[test]
// pub fn irregular_verb_suffix() {
// #[rustfmt::skip]
// let te_test = [
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใฃใฆ$").unwrap(), deinflected: "ใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่กใฃใฆ$").unwrap(), deinflected: "่กใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("้ใฃใฆ$").unwrap(), deinflected: "้ใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅพใฃใฆ$").unwrap(), deinflected: "ๅพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใฆ$").unwrap(), deinflected: "ใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใจใใฆ$").unwrap(), deinflected: "ใจใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่ซใใฆ$").unwrap(), deinflected: "่ซใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ไนใใฆ$").unwrap(), deinflected: "ไนใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆใใฆ$").unwrap(), deinflected: "ๆใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅใใฆ$").unwrap(), deinflected: "ๅใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่จชใใฆ$").unwrap(), deinflected: "่จชใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅฎฃใใฆ$").unwrap(), deinflected: "ๅฎฃใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆฐใใฆ$").unwrap(), deinflected: "ๆฐใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("็ตฆใใฆ$").unwrap(), deinflected: "็ตฆใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่ณใใฆ$").unwrap(), deinflected: "่ณใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆบ่ฉใใฆ$").unwrap(), deinflected: "ๆบ่ฉใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใฎใใใใฆ$").unwrap(), deinflected: "ใฎใใพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใใฆ$").unwrap(), deinflected: "ใใพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใจใใฆ$").unwrap(), deinflected: "ใใใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใฆ"], conditions_out: &["v5"] }
// ];
// #[rustfmt::skip]
// let ta_test = [
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใฃใ$").unwrap(), deinflected: "ใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่กใฃใ$").unwrap(), deinflected: "่กใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("้ใฃใ$").unwrap(), deinflected: "้ใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅพใฃใ$").unwrap(), deinflected: "ๅพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใ$").unwrap(), deinflected: "ใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใจใใ$").unwrap(), deinflected: "ใจใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่ซใใ$").unwrap(), deinflected: "่ซใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ไนใใ$").unwrap(), deinflected: "ไนใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆใใ$").unwrap(), deinflected: "ๆใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅใใ$").unwrap(), deinflected: "ๅใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่จชใใ$").unwrap(), deinflected: "่จชใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๅฎฃใใ$").unwrap(), deinflected: "ๅฎฃใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆฐใใ$").unwrap(), deinflected: "ๆฐใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("็ตฆใใ$").unwrap(), deinflected: "็ตฆใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("่ณใใ$").unwrap(), deinflected: "่ณใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ๆบ่ฉใใ$").unwrap(), deinflected: "ๆบ่ฉใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใฎใใใใ$").unwrap(), deinflected: "ใฎใใพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใใ$").unwrap(), deinflected: "ใใพใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] },
// SuffixRule { rule_type: RuleType::Suffix, is_inflected: Regex::new("ใใใจใใ$").unwrap(), deinflected: "ใใใใ", deinflect_fn: DeinflectFnType::GenericSuffix, conditions_in: &["-ใ"], conditions_out: &["v5"] }
// ];
// let ใฆ = irregular_verb_inflections(super::IrregularVerbSuffix::ใฆ, &["-ใฆ"], &["v5"]);
// assert_eq!(ใฆ, te_test);
// let ใ = irregular_verb_inflections(super::IrregularVerbSuffix::ใ, &["-ใ"], &["v5"]);
// assert_eq!(ใ, ta_test);
// }
#[test]
pub fn suffix() {
let test = SuffixRule {
rule_type: RuleType::Suffix,
is_inflected: Regex::new("ใใใฐ$").unwrap(),
deinflected: "ใ",
inflected_str: Some("ใใใฐ".to_string()),
deinflect_fn: crate::transformer::DeinflectFnType::GenericSuffix,
conditions_in: &["-ใฐ"],
conditions_out: &["adj-i"],
};
let sr = inflection("ใใใฐ", "ใ", &["-ใฐ"], &["adj-i"], RuleType::Suffix);
assert_eq!(sr, test.clone().into());
assert_eq!(sr.deinflect("้ฃในใใฐ"), test.deinflect("้ฃในใใฐ"));
}
}
pub(crate) static JP_TRANSFORM_TESTS: LazyLock<[&TransformTest; 14]> = LazyLock::new(|| {
[
&*JP_ADJ_TESTS,
&*JP_ICHIDAN_VERB_TESTS,
&*JP_VERB_U_TESTS,
&*JP_VERB_KU_TESTS,
&*JP_VERB_GU_TESTS,
&*JP_VERB_SU_TESTS,
&*JP_VERB_TSU_TESTS,
&*JP_VERB_NU_TESTS,
&*JP_VERB_BU_TESTS,
&*JP_VERB_MU_TESTS,
&*JP_IRREGULAR_VERB_SURU_TESTS,
&*JP_IRREGULAR_VERB_KURU_TESTS,
&*JP_ZURU_VERB_TESTS,
&*JP_EE_ENDING_TESTS,
]
});
pub(crate) static JP_ADJ_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "ๆใใ",
sources: vec![
LanguageTransformerTestCase {
inner: "ๆใใใ",
rule: "adj-i",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใใ",
rule: "adj-i",
reasons: vec!["-ใใใ"],
},
LanguageTransformerTestCase {
inner: "ๆใ้ใใ",
rule: "adj-i",
reasons: vec!["-้ใใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใฃใใ",
rule: "adj-i",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใฃใใ",
rule: "adj-i",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใฆ",
rule: "adj-i",
reasons: vec!["-ใฆ"],
},
LanguageTransformerTestCase {
inner: "ๆใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใชใ",
rule: "adj-i",
reasons: vec!["negative"],
},
LanguageTransformerTestCase {
inner: "ๆใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใฃใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใใใพใใ",
rule: "adj-i",
reasons: vec!["-ใพใ", "negative"],
},
LanguageTransformerTestCase {
inner: "ๆใใใใใพใใใงใใ",
rule: "adj-i",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใๆฐ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ๆใใใ",
rule: "adj-i",
reasons: vec!["-ใใ"],
},
],
});
pub(crate) static JP_VERB_U_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "่ฒทใ",
sources: vec![
LanguageTransformerTestCase {
inner: "่ฒทใ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆ",
rule: "v5",
reasons: vec!["-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใ",
rule: "v5",
reasons: vec!["potential"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใ",
rule: "v5",
reasons: vec!["passive"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใ",
rule: "v5",
reasons: vec!["causative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใ",
rule: "v5",
reasons: vec!["short causative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใพใ",
rule: "v5",
reasons: vec!["short causative", "-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใใ",
rule: "v5",
reasons: vec!["causative", "potential or passive"],
},
LanguageTransformerTestCase {
inner: "่ฒทใ",
rule: "v5",
reasons: vec!["imperative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใ",
rule: "v5",
reasons: vec!["negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใใฃใ",
rule: "v5",
reasons: vec!["negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใงใใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใใฆ",
rule: "v5",
reasons: vec!["negative", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใ",
rule: "v5",
reasons: vec!["potential", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใชใ",
rule: "v5",
reasons: vec!["passive", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใชใ",
rule: "v5",
reasons: vec!["causative", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใชใ",
rule: "v5",
reasons: vec!["short causative", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใใชใ",
rule: "v5",
reasons: vec!["causative", "potential or passive", "negative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใฆ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใฐ",
rule: "v5",
reasons: vec!["-ใฐ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใ",
rule: "v5",
reasons: vec!["-ใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใกใ",
rule: "v5",
reasons: vec!["-ใกใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใกใใ",
rule: "v5",
reasons: vec!["-ใกใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใกใพใ",
rule: "v5",
reasons: vec!["-ใกใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใใ",
rule: "v5",
reasons: vec!["-ใชใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใ",
rule: "v5",
reasons: vec!["-ใใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใ้ใใ",
rule: "v5",
reasons: vec!["-้ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใ",
rule: "v5",
reasons: vec!["-ใใ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใฌ",
rule: "v5",
reasons: vec!["-ใฌ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใฃใ",
rule: "v5",
reasons: vec!["-ใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใฐใใ",
rule: "v5",
reasons: vec!["-ใใฐใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใจใใ",
rule: "v5",
reasons: vec!["-ใใจใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใญใฐ",
rule: "v5",
reasons: vec!["-ใญใฐ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใซใ",
rule: "v5",
reasons: vec!["-ใญใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใ",
rule: "v5",
reasons: vec!["continuative"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใ",
rule: "v5",
reasons: vec!["-ใพใ", "volitional"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใฃใ",
rule: "v5",
reasons: vec!["-ใพใ", "volitional slang"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใ",
rule: "v5",
reasons: vec!["volitional"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใฃใ",
rule: "v5",
reasons: vec!["volitional slang"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใใใ",
rule: "v5",
reasons: vec!["short causative", "passive"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใจใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใใงใใ",
rule: "v5",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใชใใฉใ",
rule: "v5",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใจใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใฃใฆใใพใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใพใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใฐ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใฐ"],
},
LanguageTransformerTestCase {
inner: "่ฒทใใพใใใใฃใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
],
});
pub(crate) static JP_ICHIDAN_VERB_TESTS: LazyLock<TransformTest> =
LazyLock::new(|| TransformTest {
term: "้ฃในใ",
sources: vec![
LanguageTransformerTestCase {
inner: "้ฃในใ",
rule: "v1",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใ",
rule: "v1",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใ",
rule: "v1",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใ",
rule: "v1",
reasons: vec!["-ใพใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆ",
rule: "v1",
reasons: vec!["-ใฆ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใ",
rule: "v1",
reasons: vec!["potential or passive"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใ",
rule: "v1",
reasons: vec!["potential or passive"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใ",
rule: "v1",
reasons: vec!["causative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["short causative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใพใ",
rule: "v1",
reasons: vec!["short causative", "-ใพใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใใใ",
rule: "v1",
reasons: vec!["causative", "potential or passive"],
},
LanguageTransformerTestCase {
inner: "้ฃในใ",
rule: "v1",
reasons: vec!["imperative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใ",
rule: "v1",
reasons: vec!["negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใ",
rule: "v1",
reasons: vec!["-ใพใ", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใใฃใ",
rule: "v1",
reasons: vec!["negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใใงใใ",
rule: "v1",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใใฆ",
rule: "v1",
reasons: vec!["negative", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใชใ",
rule: "v1",
reasons: vec!["potential or passive", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใชใ",
rule: "v1",
reasons: vec!["potential or passive", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใชใ",
rule: "v1",
reasons: vec!["causative", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใชใ",
rule: "v1",
reasons: vec!["short causative", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใใใชใ",
rule: "v1",
reasons: vec!["causative", "potential or passive", "negative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใฆ",
rule: "v1",
reasons: vec!["-ใพใ", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใฐ",
rule: "v1",
reasons: vec!["-ใฐ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใกใ",
rule: "v1",
reasons: vec!["-ใกใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใกใใ",
rule: "v1",
reasons: vec!["-ใกใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใกใพใ",
rule: "v1",
reasons: vec!["-ใกใพใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใใ",
rule: "v1",
reasons: vec!["-ใชใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใ",
rule: "v1",
reasons: vec!["-ใใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃใน้ใใ",
rule: "v1",
reasons: vec!["-้ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใ",
rule: "v1",
reasons: vec!["-ใใ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใ",
rule: "v1",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฌ",
rule: "v1",
reasons: vec!["-ใฌ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใ",
rule: "v1",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใใฃใ",
rule: "v1",
reasons: vec!["-ใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใฐใใ",
rule: "v1",
reasons: vec!["-ใใฐใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใจใใ",
rule: "v1",
reasons: vec!["-ใใจใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใญใฐ",
rule: "v1",
reasons: vec!["-ใญใฐ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใซใ",
rule: "v1",
reasons: vec!["-ใญใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "้ฃใน",
rule: "v1d",
reasons: vec!["continuative"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใใ",
rule: "v1",
reasons: vec!["-ใพใ", "volitional"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใใใฃใ",
rule: "v1",
reasons: vec!["-ใพใ", "volitional slang"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใ",
rule: "v1",
reasons: vec!["volitional"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใฃใ",
rule: "v1",
reasons: vec!["volitional slang"],
},
LanguageTransformerTestCase {
inner: "้ฃในใใพใ",
rule: "v1",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใพใ",
rule: "v1",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆใใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใจใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใใงใใ",
rule: "v1",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใชใใฉใ",
rule: "v1",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆใใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆใใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใจใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "้ฃในใฆใใพใ",
rule: "v1",
reasons: vec!["-ใฆ", "-ใใพใ"],
},
],
});
pub(crate) static JP_VERB_KU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "่กใ",
sources: vec![
LanguageTransformerTestCase {
inner: "่กใ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "่กใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆ",
rule: "v5",
reasons: vec!["-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["potential"],
},
LanguageTransformerTestCase {
inner: "่กใใใ",
rule: "v5",
reasons: vec!["passive"],
},
LanguageTransformerTestCase {
inner: "่กใใใ",
rule: "v5",
reasons: vec!["causative"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["short causative"],
},
LanguageTransformerTestCase {
inner: "่กใใใพใ",
rule: "v5",
reasons: vec!["short causative", "-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใใใ",
rule: "v5",
reasons: vec!["causative", "potential or passive"],
},
LanguageTransformerTestCase {
inner: "่กใ",
rule: "v5",
reasons: vec!["imperative"],
},
LanguageTransformerTestCase {
inner: "่กใใชใ",
rule: "v5",
reasons: vec!["negative"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใชใใฃใ",
rule: "v5",
reasons: vec!["negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใงใใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใชใใฆ",
rule: "v5",
reasons: vec!["negative", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่กใใชใ",
rule: "v5",
reasons: vec!["potential", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใใชใ",
rule: "v5",
reasons: vec!["passive", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใใชใ",
rule: "v5",
reasons: vec!["causative", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใใชใ",
rule: "v5",
reasons: vec!["short causative", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใใใใชใ",
rule: "v5",
reasons: vec!["causative", "potential or passive", "negative"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใฆ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใฆ"],
},
LanguageTransformerTestCase {
inner: "่กใใฐ",
rule: "v5",
reasons: vec!["-ใฐ"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["-ใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใกใ",
rule: "v5",
reasons: vec!["-ใกใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใกใใ",
rule: "v5",
reasons: vec!["-ใกใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใกใพใ",
rule: "v5",
reasons: vec!["-ใกใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใใชใใ",
rule: "v5",
reasons: vec!["-ใชใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใใ",
rule: "v5",
reasons: vec!["-ใใใ"],
},
LanguageTransformerTestCase {
inner: "่กใ้ใใ",
rule: "v5",
reasons: vec!["-้ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใใ",
rule: "v5",
reasons: vec!["-ใใ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใฌ",
rule: "v5",
reasons: vec!["-ใฌ"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใใฃใ",
rule: "v5",
reasons: vec!["-ใ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใฐใใ",
rule: "v5",
reasons: vec!["-ใใฐใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใจใใ",
rule: "v5",
reasons: vec!["-ใใจใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใ",
rule: "v5",
reasons: vec!["-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใญใฐ",
rule: "v5",
reasons: vec!["-ใญใฐ"],
},
LanguageTransformerTestCase {
inner: "่กใใซใ",
rule: "v5",
reasons: vec!["-ใญใฐ", "-ใ"],
},
LanguageTransformerTestCase {
inner: "่กใ",
rule: "v5",
reasons: vec!["continuative"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใ",
rule: "v5",
reasons: vec!["-ใพใ", "volitional"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใฃใ",
rule: "v5",
reasons: vec!["-ใพใ", "volitional slang"],
},
LanguageTransformerTestCase {
inner: "่กใใ",
rule: "v5",
reasons: vec!["volitional"],
},
LanguageTransformerTestCase {
inner: "่กใใฃใ",
rule: "v5",
reasons: vec!["volitional slang"],
},
LanguageTransformerTestCase {
inner: "่กใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใใใใ",
rule: "v5",
reasons: vec!["short causative", "passive"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใจใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใชใใงใใ",
rule: "v5",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใชใใฉใ",
rule: "v5",
reasons: vec!["negative", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆใใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใจใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใฃใฆใใพใ",
rule: "v5",
reasons: vec!["-ใฆ", "-ใใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใพใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใพใ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใใ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใฐ",
rule: "v5",
reasons: vec!["-ใพใ", "-ใฐ"],
},
LanguageTransformerTestCase {
inner: "่กใใพใใใใฃใ",
rule: "v5",
reasons: vec!["-ใพใ", "negative", "-ใ"],
},
],
});
pub(crate) static JP_VERB_GU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "ๆณณใ",
sources: vec![
LanguageTransformerTestCase {
inner: "ๆณณใ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "ๆณณใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
LanguageTransformerTestCase {
inner: "ๆณณใใ ",
rule: "v5",
reasons: vec!["-ใ"],
},
// Add all other test cases from the JavaScript 'ใ verbs' category
],
});
pub(crate) static JP_VERB_SU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "่ฉฑใ",
sources: vec![
LanguageTransformerTestCase {
inner: "่ฉฑใ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "่ฉฑใใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
// Add all other test cases from the JavaScript 'ใ verbs' category
],
});
pub(crate) static JP_VERB_TSU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "ๅพ
ใค",
sources: vec![
LanguageTransformerTestCase {
inner: "ๅพ
ใค",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "ๅพ
ใกใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
// Add all other test cases
],
});
pub(crate) static JP_VERB_NU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "ๆญปใฌ",
sources: vec![
LanguageTransformerTestCase {
inner: "ๆญปใฌ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "ๆญปใซใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
// Add all test cases
],
});
pub(crate) static JP_VERB_BU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "้ใถ",
sources: vec![
LanguageTransformerTestCase {
inner: "้ใถ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "้ใณใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
// Add all cases
],
});
pub(crate) static JP_VERB_MU_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "้ฃฒใ",
sources: vec![
LanguageTransformerTestCase {
inner: "้ฃฒใ",
rule: "v5",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "้ฃฒใฟใพใ",
rule: "v5",
reasons: vec!["-ใพใ"],
},
// Add all cases
],
});
pub(crate) static JP_IRREGULAR_VERB_SURU_TESTS: LazyLock<TransformTest> =
LazyLock::new(|| TransformTest {
term: "็บใ",
sources: vec![
LanguageTransformerTestCase {
inner: "็บใ",
rule: "vs",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "็บใพใ",
rule: "vs",
reasons: vec!["-ใพใ"],
},
// Add all ็บใ and ใใ cases
],
});
pub(crate) static JP_IRREGULAR_VERB_KURU_TESTS: LazyLock<TransformTest> =
LazyLock::new(|| TransformTest {
term: "ๆฅใ",
sources: vec![
LanguageTransformerTestCase {
inner: "ๆฅใ",
rule: "vk",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "ๆฅใพใ",
rule: "vk",
reasons: vec!["-ใพใ"],
},
// Add all ๆฅใ, ไพใ, ใใ cases
],
});
pub(crate) static JP_ZURU_VERB_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "่ซใใ",
sources: vec![
LanguageTransformerTestCase {
inner: "่ซใใ",
rule: "vz",
reasons: vec![],
},
LanguageTransformerTestCase {
inner: "่ซใใพใ",
rule: "vz",
reasons: vec!["-ใพใ"],
},
// Add all cases
],
});
pub(crate) static JP_EE_ENDING_TESTS: LazyLock<TransformTest> = LazyLock::new(|| TransformTest {
term: "ใใใ",
sources: vec![
LanguageTransformerTestCase {
inner: "ใใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
LanguageTransformerTestCase {
inner: "ใใใ",
rule: "adj-i",
reasons: vec!["-ใ"],
},
// Add all ใ ending cases
],
});
/// https://raw.githubusercontent.com/yomidevs/yomitan/c3bec65bc44a33b1b1686e5d81a6910e42889174/ext/js/language/ja/japanese-transforms.js
use indexmap::IndexMap;
use crate::transformer::{LanguageTransformDescriptor, Transform, TransformI18n, TransformMap};
pub(crate) const SHIMAU_ENGLISH_DESCRIPTION: &str = "1. Shows a sense of regret/surprise when you did have volition in doing something, but it turned out to be bad to do.\n2. Shows perfective/punctual achievement. This shows that an action has been completed.\n 3. Shows unintentional actionโโaccidentallyโ.\n";
pub(crate) const PASSIVE_ENGLISH_DESCRIPTION: &str = "1. Indicates an action received from an action performer.\n2. Expresses respect for the subject of action performer.\n";
pub(crate) const IKU_VERBS: [&str; 4] = ["ใใ", "่กใ", "้ใ", "ๅพใ"];
#[rustfmt::skip]
pub(crate) const GODAN_U_SPECIAL_VERBS: [&str; 12] = [
"ใใ", "ใจใ", "่ซใ", "ไนใ", "ๆใ", "ๅใ", "่จชใ",
"ๅฎฃใ", "ๆฐใ", "็ตฆใ", "่ณใ", "ๆบ่ฉใ",
];
#[rustfmt::skip]
pub(crate) const FU_VERB_TE_CONJUGATIONS: [[&str; 2]; 3] = [
["ใฎใใพใ", "ใฎใใใ"],
["ใใพใ", "ใใใ"],
["ใใใใ", "ใใใจใ"]
];
pub static JAPANESE_TRANSFORMS_DESCRIPTOR: LazyLock<LanguageTransformDescriptor> =
LazyLock::new(|| LanguageTransformDescriptor {
language: "ja",
conditions: &JP_CONDITIONS_MAP,
transforms: &JP_TRANSFORMS_MAP,
});
#[cfg(test)]
pub(crate) mod jp_transforms {
use crate::transformer::LanguageTransformer;
use super::*;
use pretty_assertions::assert_eq;
#[test]
fn len() {
assert_eq!(JAPANESE_TRANSFORMS_DESCRIPTOR.transforms.len(), 53);
assert_eq!(JAPANESE_TRANSFORMS_DESCRIPTOR.conditions.len(), 22);
}
#[test]
fn transforms() {
let mut lt = LanguageTransformer::new();
lt.add_descriptor(&JAPANESE_TRANSFORMS_DESCRIPTOR).unwrap();
for test in JP_TRANSFORM_TESTS.iter() {
let term = test.term;
for case in &test.sources {
let source = case.inner;
let rule = case.rule;
let expected_reasons = &case.reasons;
let result =
has_term_reasons(<, source, term, Some(rule), Some(expected_reasons));
if let Err(e) = result {
panic!("Failed: {e}");
}
}
}
}
}
pub(crate) fn has_term_reasons(
lt: &LanguageTransformer,
source: &str,
expected_term: &str,
expected_condition_name: Option<&str>,
expected_reasons: Option<&[&str]>,
) -> Result<HasTermReasons, HasTermReasonsError> {
let results = lt.transform(source);
//dbg!(&results);
let rule = expected_condition_name.unwrap_or("");
let mut rejected = Vec::new();
for result in results {
let mut rejection_reasons = Vec::new();
// Check term match
if result.text != expected_term {
rejection_reasons.push(format!(
"Term mismatch: expected '{}', got '{}'",
expected_term, result.text
));
}
// Check rule match if term matched
if result.text == expected_term {
if let Some(expected_name) = expected_condition_name {
let expected_conditions =
lt.get_condition_flags_from_single_condition_type(expected_name);
if !LanguageTransformer::conditions_match(result.conditions, expected_conditions) {
rejection_reasons.push(format!(
"Condition mismatch: expected {}({:b}), got {:b}",
expected_name, expected_conditions, result.conditions
));
}
}
}
// If we had any rejection reasons, log and continue
if !rejection_reasons.is_empty() {
rejected.push(format!(
"Candidate '{}' [conditions {:b}] rejected because:\n {}",
result.text,
result.conditions,
rejection_reasons.join("\n ")
));
continue;
}
// check trace reasons if we got this far
if let Some(expected) = expected_reasons {
if result.trace.len() != expected.len() {
return Err(HasTermReasonsError::TraceLengthMismatch {
expected: expected.len(),
found: result.trace.len(),
});
}
// Check individual reasons
for (i, (actual, expected)) in result.trace.iter().zip(expected.iter()).enumerate() {
if &actual.transform != expected {
return Err(HasTermReasonsError::ReasonMismatch {
index: i,
expected: (*expected).to_string(),
found: actual.transform.clone(),
});
}
}
}
// Success case
return Ok(HasTermReasons {
reasons: result.trace.iter().map(|f| f.transform.clone()).collect(),
rules: result.conditions,
});
}
// No matches found - return all rejection reasons
Err(HasTermReasonsError::NoMatch {
src: source.to_string(),
term: expected_term.to_string(),
rule: rule.to_string(),
rejected,
})
}
pub static JP_TRANSFORMS_MAP: LazyLock<TransformMap> = LazyLock::new(|| {
TransformMap(IndexMap::from([
(
"-ใฐ",
Transform {
name: "-ใฐ",
description: Some(
"1. Conditional form; shows that the previous stated condition's establishment is the condition for the latter stated condition to occur.\n2. Shows a trigger for a latter stated perception or judgment.\nUsage: Attach ใฐ to the hypothetical form (ไปฎๅฎๅฝข) of verbs and i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใฐ",
description: None,
}]),
rules: vec![
inflection("ใใใฐ", "ใ", &["-ใฐ"], &["adj-i"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใฆใฐ", "ใค", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใญใฐ", "ใฌ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ในใฐ", "ใถ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใฐ", "ใ", &["-ใฐ"], &["v1", "v5", "vk", "vs", "vz"], RuleType::Suffix),
inflection("ใใฐ", "", &["-ใฐ"], &["-ใพใ"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some("Contraction of -ใฐ."),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("ใ๏ฝใฐใใฎ็ญ็ธฎ"),
}]),
rules: vec![
inflection("ใใใ", "ใใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใใ", "ใใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใกใ", "ใฆใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใซใ", "ใญใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใณใ", "ในใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใฟใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
inflection("ใใ", "ใใฐ", &["-ใ"], &["-ใฐ"], RuleType::Suffix),
],
},
),
(
"-ใกใ",
Transform {
name: "-ใกใ",
description: Some(
"Contraction of ๏ฝใฆใฏ.\n1. Explains how something always happens under the condition that it marks.\n2. Expresses the repetition (of a series of) actions.\n3. Indicates a hypothetical situation in which the speaker gives a (negative) evaluation about the other party's intentions.\n4. Used in \"Must Not\" patterns like ๏ฝใฆใฏใใใชใ.\nUsage: Attach ใฏ after the ใฆ-form of verbs, contract ใฆใฏ into ใกใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใกใ",
description: Some("ใ๏ฝใฆใฏใใฎ็ญ็ธฎ"),
}]),
rules: vec![
inflection("ใกใ", "ใ", &["v5"], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใ", "ใค", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใฌ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใถ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใ", "ใใ", &["v5"], &["vz"], RuleType::Suffix),
inflection("ใใกใ", "ใใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("็บใกใ", "็บใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("ใใกใ", "ใใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ๆฅใกใ", "ๆฅใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ไพใกใ", "ไพใ", &["v5"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใกใใ",
Transform {
name: "-ใกใใ",
description: Some(
"Contraction of -ใใพใ.\nShows completion of an action with regret or accidental completion.\nUsage: Attach ใใพใ after the ใฆ-form of verbs, contract ใฆใใพใ into ใกใใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใกใใ",
description: Some("ใ๏ฝใฆใใพใใใฎใใใใ ใใๅฃ้ ญ่ช็่กจ็พ"),
}]),
rules: vec![
inflection("ใกใใ", "ใ", &["v5"], &["v1"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใใ", "ใค", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใฌ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใถ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใใ", "ใใ", &["v5"], &["vz"], RuleType::Suffix),
inflection("ใใกใใ", "ใใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("็บใกใใ", "็บใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("ใใกใใ", "ใใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ๆฅใกใใ", "ๆฅใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ไพใกใใ", "ไพใ", &["v5"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใกใพใ",
Transform {
name: "-ใกใพใ",
description: Some(
"Contraction of -ใใพใ.\nShows completion of an action with regret or accidental completion.\nUsage: Attach ใใพใ after the ใฆ-form of verbs, contract ใฆใใพใ into ใกใพใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใกใพใ",
description: Some("ใ๏ฝใฆใใพใใใฎ้ณๅคๅ"),
}]),
rules: vec![
inflection("ใกใพใ", "ใ", &["v5"], &["v1"], RuleType::Suffix),
inflection("ใใใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใพใ", "ใค", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใฃใกใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใพใ", "ใฌ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใพใ", "ใถ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใใพใ", "ใ", &["v5"], &["v5"], RuleType::Suffix),
inflection("ใใกใพใ", "ใใ", &["v5"], &["vz"], RuleType::Suffix),
inflection("ใใกใพใ", "ใใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("็บใกใพใ", "็บใ", &["v5"], &["vs"], RuleType::Suffix),
inflection("ใใกใพใ", "ใใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ๆฅใกใพใ", "ๆฅใ", &["v5"], &["vk"], RuleType::Suffix),
inflection("ไพใกใพใ", "ไพใ", &["v5"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใพใ",
Transform {
name: "-ใใพใ",
description: Some(
"Shows completion of an action with regret or accidental completion.\nUsage: Attach ใใพใ after the ใฆ-form of verbs.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใพใ",
description: Some(
"ใใฎๅไฝใใใฃใใ็ตใใใใใฎ็ถๆ
ใๅฎๆใใใใจใ่กจใใ็ตใใฃใใใจใๅผท่ชฟใใใใไธๆฌๆใงใใใๅฐใฃใใใจใซใชใฃใใใชใฉใฎๆฐๆใกใๆทปใใใใใใใจใใใใ",
),
}]),
rules: vec![
inflection("ใฆใใพใ", "ใฆ", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใงใใพใ", "ใง", &["v5"], &["-ใฆ"], RuleType::Suffix),
],
},
),
(
"-ใชใใ",
Transform {
name: "-ใชใใ",
description: Some(
"Polite imperative suffix.\nUsage: Attach ใชใใ after the continuative form (้ฃ็จๅฝข) of verbs.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใชใใ",
description: Some("ๅ่ฉใใชใใใใฎๅฝไปคๅฝข"),
}]),
rules: vec![
inflection("ใชใใ", "ใ", &["-ใชใใ"], &["v1"], RuleType::Suffix),
inflection("ใใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใกใชใใ", "ใค", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใซใชใใ", "ใฌ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใณใชใใ", "ใถ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใฟใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใใชใใ", "ใ", &["-ใชใใ"], &["v5"], RuleType::Suffix),
inflection("ใใชใใ", "ใใ", &["-ใชใใ"], &["vz"], RuleType::Suffix),
inflection("ใใชใใ", "ใใ", &["-ใชใใ"], &["vs"], RuleType::Suffix),
inflection("็บใชใใ", "็บใ", &["-ใชใใ"], &["vs"], RuleType::Suffix),
inflection("ใใชใใ", "ใใ", &["-ใชใใ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใชใใ", "ๆฅใ", &["-ใชใใ"], &["vk"], RuleType::Suffix),
inflection("ไพใชใใ", "ไพใ", &["-ใชใใ"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"Appearing that; looking like.\nUsage: Attach ใใ to the continuative form (้ฃ็จๅฝข) of verbs, or to the stem of adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("ใใใใๆงๅญใ ใใใใชใๆงๅญใ ใจใใใใจใใใชใใกๆงๆ
ใ่กจใๅฉๅ่ฉใ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใกใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใซใใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใณใใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใฟใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใใ",
Transform {
name: "-ใใใ",
description: Some(
"Shows something \"is too...\" or someone is doing something \"too much\".\nUsage: Attach ใใใ to the continuative form (้ฃ็จๅฝข) of verbs, or to the stem of adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใใ",
description: Some("็จๅบฆใ้ๅบฆใ่ถ
ใใ"),
}]),
rules: vec![
inflection("ใใใ", "ใ", &["v1"], &["adj-i"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v1"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใกใใใ", "ใค", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใซใใใ", "ใฌ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใณใใใ", "ใถ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใฟใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บใใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพใใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"-้ใใ",
Transform {
name: "-้ใใ",
description: Some(
"Shows something \"is too...\" or someone is doing something \"too much\".\nUsage: Attach ้ใใ to the continuative form (้ฃ็จๅฝข) of verbs, or to the stem of adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝ้ใใ",
description: Some("็จๅบฆใ้ๅบฆใ่ถ
ใใ"),
}]),
rules: vec![
inflection("้ใใ", "ใ", &["v1"], &["adj-i"], RuleType::Suffix),
inflection("้ใใ", "ใ", &["v1"], &["v1"], RuleType::Suffix),
inflection("ใ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใก้ใใ", "ใค", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใซ้ใใ", "ใฌ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใณ้ใใ", "ใถ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใฟ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใ้ใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใ้ใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใ้ใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บ้ใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใ้ใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅ้ใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพ้ใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"1. Expresses the feeling of desire or hope.\n2. Used in ...ใใใจๆใใพใ, an indirect way of saying what the speaker intends to do.\nUsage: Attach ใใ to the continuative form (้ฃ็จๅฝข) of verbs. ใใ itself conjugates as i-adjective.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("ใใใใจใใฎใใใงใใใใจใใใๅธๆใ้กๆใฎๆฐๆใกใใใใใใ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &["adj-i"], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใกใใ", "ใค", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใซใใ", "ใฌ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใณใใ", "ใถ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใฟใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["adj-i"], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["adj-i"], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &["adj-i"], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["adj-i"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &["adj-i"], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &["adj-i"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"1. Denotes the latter stated event is a continuation of the previous stated event.\n2. Assumes that a matter has been completed or concluded.\nUsage: Attach ใใ to the continuative form (้ฃ็จๅฝข) of verbs after euphonic change form, ใใฃใใ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("ไปฎๅฎใใใใใใปโฆใใใจใปใใใใจใซ"),
}]),
rules: vec![
inflection("ใใฃใใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
].into_iter().chain(irregular_verb_inflections(
IrregularVerbSuffix::ใใ,
&[],
&["v5"]
).into_iter().map(Into::into)).chain(std::iter::once(inflection("ใพใใใ", "ใพใ", &[], &["-ใพใ"], RuleType::Suffix))).collect(),
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"1. Shows two actions occurring back and forth (when used with two verbs).\n2. Shows examples of actions and states (when used with multiple verbs and adjectives).\nUsage: Attach ใใ to the continuative form (้ฃ็จๅฝข) of verbs after euphonic change form, ใใฃใใ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("ใใๅไฝใไพ็คบ็ใซใใใใใจใ่กจใใใ"),
}]),
rules: vec![
inflection("ใใฃใใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใฃใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
].into_iter().chain(irregular_verb_inflections(IrregularVerbSuffix::ใใ, &[], &["v5"]).into_iter().map(Into::into)).collect(),
},
),
(
"-ใฆ",
Transform {
name: "-ใฆ",
description: Some(
"ใฆ-form.\nIt has a myriad of meanings. Primarily, it is a conjunctive particle that connects two clauses together.\nUsage: Attach ใฆ to the continuative form (้ฃ็จๅฝข) of verbs after euphonic change form, ใใฆ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใฆ",
description: None,
}]),
rules: vec![
inflection("ใใฆ", "ใ", &["-ใฆ"], &["adj-i"], RuleType::Suffix),
inflection("ใฆ", "ใ", &["-ใฆ"], &["v1"], RuleType::Suffix),
inflection("ใใฆ", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใง", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใฆ", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใฃใฆ", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใฃใฆ", "ใค", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใฃใฆ", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใง", "ใฌ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใง", "ใถ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใง", "ใ", &["-ใฆ"], &["v5"], RuleType::Suffix),
inflection("ใใฆ", "ใใ", &["-ใฆ"], &["vz"], RuleType::Suffix),
inflection("ใใฆ", "ใใ", &["-ใฆ"], &["vs"], RuleType::Suffix),
inflection("็บใฆ", "็บใ", &["-ใฆ"], &["vs"], RuleType::Suffix),
inflection("ใใฆ", "ใใ", &["-ใฆ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใฆ", "ๆฅใ", &["-ใฆ"], &["vk"], RuleType::Suffix),
inflection("ไพใฆ", "ไพใ", &["-ใฆ"], &["vk"], RuleType::Suffix),
].into_iter()
.chain(irregular_verb_inflections(
IrregularVerbSuffix::ใฆ,
&["-ใฆ"],
&["v5"]
).into_iter().map(Into::into))
.chain(Vec::from_iter([inflection("ใพใใฆ", "ใพใ", &[], &["-ใพใ"], RuleType::Suffix)]))
.collect(),
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"1. Negative form of verbs.\n2. Continuative form (้ฃ็จๅฝข) of the particle ใฌ (nu).\nUsage: Attach ใ to the irrealis form (ๆช็ถๅฝข) of verbs.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("๏ฝใชใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใชใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใฐใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใพใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใฌ",
Transform {
name: "-ใฌ",
description: Some(
"Negative form of verbs.\nUsage: Attach ใฌ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใฌ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใฌ",
description: Some("๏ฝใชใ"),
}]),
rules: vec![
inflection("ใฌ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใชใฌ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใฐใฌ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใพใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฌ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใฌ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใฌ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใฌ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใฌ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใฌ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Negative form of verbs; a sound change of ใฌ.\nUsage: Attach ใ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("๏ฝใชใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &["-ใ"], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใค", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใชใ", "ใฌ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใฐใ", "ใถ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใพใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &["-ใ"], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใ", "ๆฅใ", &["-ใ"], &["vk"], RuleType::Suffix),
inflection("ไพใ", "ไพใ", &["-ใ"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใฐใใ",
Transform {
name: "-ใใฐใใ",
description: Some(
"Shows an action or condition is on the verge of occurring, or an excessive/extreme degree.\nUsage: Attach ใใฐใใ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใใฐใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใฐใใ",
description: Some("ไปใซใใใใชใใใใชใใใใ่พใใใฆใใใชใฃใฆใใชใใใใชใใพใๆใ่กจ็พ"),
}]),
rules: vec![
inflection("ใใฐใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใชใใฐใใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใฐใใฐใใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใพใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใฐใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใฐใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใฐใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใฐใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใจใใ",
Transform {
name: "-ใใจใใ",
description: Some(
"1. Shows the speaker's will or intention.\n2. Shows an action or condition is on the verge of occurring.\nUsage: Attach ใใจใใ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใใจใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใจใใ",
description: Some("โฆใใใใจใใใโฆใใใใจใใฆใใ"),
}]),
rules: vec![
inflection("ใใจใใ", "ใ", &["vs"], &["v1"], RuleType::Suffix),
inflection("ใใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใค", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใชใใจใใ", "ใฌ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใฐใใจใใ", "ใถ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใพใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใ", &["vs"], &["v5"], RuleType::Suffix),
inflection("ใใใจใใ", "ใใ", &["vs"], &["vz"], RuleType::Suffix),
inflection("ใใใจใใ", "ใใ", &["vs"], &["vs"], RuleType::Suffix),
inflection("็บใใจใใ", "็บใ", &["vs"], &["vs"], RuleType::Suffix),
inflection("ใใใจใใ", "ใใ", &["vs"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใจใใ", "ๆฅใ", &["vs"], &["vk"], RuleType::Suffix),
inflection("ไพใใจใใ", "ไพใ", &["vs"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Archaic.\n1. Shows an inference of a certain matter.\n2. Shows speaker's intention.\nUsage: Attach ใ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("โฆใ ใใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใชใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใฐใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใพใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"Negative form of verbs.\nUsage: Attach ใใ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("โฆใชใโฆ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใชใใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใฐใใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใพใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใญใฐ",
Transform {
name: "-ใญใฐ",
description: Some(
"1. Shows a hypothetical negation; if not ...\n2. Shows a must. Used with or without ใชใใฌ.\nUsage: Attach ใญใฐ to the irrealis form (ๆช็ถๅฝข) of verbs.\nใใ becomes ใใญใฐ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใญใฐ",
description: Some("ใใโฆใชใใชใใโฆใชใใใฐใชใใชใใ"),
}]),
rules: vec![
inflection("ใญใฐ", "ใ", &["-ใฐ"], &["v1"], RuleType::Suffix),
inflection("ใใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใค", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใชใญใฐ", "ใฌ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใฐใญใฐ", "ใถ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใพใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใ", &["-ใฐ"], &["v5"], RuleType::Suffix),
inflection("ใใญใฐ", "ใใ", &["-ใฐ"], &["vz"], RuleType::Suffix),
inflection("ใใญใฐ", "ใใ", &["-ใฐ"], &["vs"], RuleType::Suffix),
inflection("็บใญใฐ", "็บใ", &["-ใฐ"], &["vs"], RuleType::Suffix),
inflection("ใใญใฐ", "ใใ", &["-ใฐ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใญใฐ", "ๆฅใ", &["-ใฐ"], &["vk"], RuleType::Suffix),
inflection("ไพใญใฐ", "ไพใ", &["-ใฐ"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Adverbial form of i-adjectives.\n",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("ใๅฝขๅฎน่ฉใงใ็จ่จใธ็ถใใไพใใๅคงใใ่ฒใคใใฎใๅคงใใใใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &["-ใ"], &["adj-i"], RuleType::Suffix),
],
},
),
(
"causative",
Transform {
name: "causative",
description: Some(
"Describes the intention to make someone do something.\nUsage: Attach ใใใ to the irrealis form (ๆช็ถๅฝข) of ichidan verbs and ใใ.\nAttach ใใ to the irrealis form (ๆช็ถๅฝข) of godan verbs and ใใ.\nIt itself conjugates as an ichidan verb.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใใปใใใ",
description: Some("ใ ใใใซใใ่ก็บใใใใๆใ่กจใใๆใฎ่จใๆนใไพใใ่กใใใใใฎใใใใใ"),
}]),
rules: vec![
inflection("ใใใ", "ใ", &["v1"], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใค", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใชใใ", "ใฌ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใฐใใ", "ใถ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใพใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บใใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพใใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"short causative",
Transform {
name: "short causative",
description: Some(
"Contraction of the causative form.\nDescribes the intention to make someone do something.\nUsage: Attach ใ to the irrealis form (ๆช็ถๅฝข) of godan verbs.\nAttach ใใ to the dictionary form (็ตๆญขๅฝข) of ichidan verbs.\nใใ becomes ใใ, ใใ becomes ใใใ.\nIt itself conjugates as an godan verb.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใปใใ",
description: Some("ใ ใใใซใใ่ก็บใใใใๆใ่กจใใๆใฎ่จใๆนใไพใใ้ฃในใใใใฎใใใใใ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &["v5ss"], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v5ss"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใค", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใชใ", "ใฌ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใฐใ", "ใถ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใพใ", "ใ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v5sp"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v5ss"], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v5ss"], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["v5ss"], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &["v5ss"], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v5ss"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &["v5ss"], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &["v5ss"], &["vk"], RuleType::Suffix),
],
},
),
(
"imperative",
Transform {
name: "imperative",
description: Some(
"1. To give orders.\n2. (As ใใ) Represents the fact that it will never change no matter the circumstances.\n3. Express a feeling of hope.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "ๅฝไปคๅฝข",
description: Some("ๅฝไปคใฎๆๅณใ่กจใใใจใใฎๅฝขใไพใใ่กใใใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใฆ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใญ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใน", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"continuative",
Transform {
name: "continuative",
description: Some(
"Used to indicate actions that are (being) carried out.\nRefers to ้ฃ็จๅฝข, the part of the verb after conjugating with -ใพใ and dropping ใพใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ฃ็จๅฝข",
description: Some("ใๅ่ฉใชใฉใงใใใพใใใชใฉใซ็ถใใไพใใใในใ้ใใฆๆญฉใใพใใใฎใ้ใใใๆญฉใใใ"),
}]),
rules: vec![
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใก", "ใกใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใฆ", "ใฆใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใง", "ใงใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใซ", "ใซใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใญ", "ใญใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใฒ", "ใฒใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใณ", "ใณใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใธ", "ใธใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใน", "ในใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใฟ", "ใฟใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["v1d"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใก", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใซ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใณ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใฟ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("ๆฅ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพ", "ไพใ", &[], &["vk"], RuleType::Suffix),
],
},
),
(
"negative",
Transform {
name: "negative",
description: Some(
"1. Negative form of verbs.\n2. Expresses a feeling of solicitation to the other party.\nUsage: Attach ใชใ to the irrealis form (ๆช็ถๅฝข) of verbs, ใใชใ to the stem of i-adjectives. ใชใ itself conjugates as i-adjective. ใพใ becomes ใพใใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใชใ",
description: Some("ใใฎๅไฝใปไฝ็จใป็ถๆ
ใฎๆ็ซใๅฆๅฎใใใใจใ่กจใใใ"),
}]),
rules: vec![
inflection("ใใชใ", "ใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใชใ", "ใ", &["adj-i"], &["v1"], RuleType::Suffix),
inflection("ใใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใค", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใชใชใ", "ใฌ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใฐใชใ", "ใถ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใพใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใ", &["adj-i"], &["v5"], RuleType::Suffix),
inflection("ใใชใ", "ใใ", &["adj-i"], &["vz"], RuleType::Suffix),
inflection("ใใชใ", "ใใ", &["adj-i"], &["vs"], RuleType::Suffix),
inflection("็บใชใ", "็บใ", &["adj-i"], &["vs"], RuleType::Suffix),
inflection("ใใชใ", "ใใ", &["adj-i"], &["vk"], RuleType::Suffix),
inflection("ๆฅใชใ", "ๆฅใ", &["adj-i"], &["vk"], RuleType::Suffix),
inflection("ไพใชใ", "ไพใ", &["adj-i"], &["vk"], RuleType::Suffix),
inflection("ใพใใ", "ใพใ", &["-ใพใใ"], &["-ใพใ"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Nominalizing suffix of i-adjectives indicating nature, state, mind or degree.\nUsage: Attach ใ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("ใใจใ็จๅบฆใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"passive",
Transform {
name: "passive",
description: Some(
"Indicates that the subject is affected by the action of the verb.\nUsage: Attach ใใ to the irrealis form (ๆช็ถๅฝข) of godan verbs.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: None,
}]),
rules: vec![
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5d", "v5sp"], RuleType::Suffix),
inflection("ใใใ", "ใค", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใชใใ", "ใฌ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใฐใใ", "ใถ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใพใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใ", &["v1"], &["v5"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพใใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"1. Indicates a reality that has happened in the past.\n2. Indicates the completion of an action.\n3. Indicates the confirmation of a matter.\n4. Indicates the speaker's confidence that the action will definitely be fulfilled.\n5. Indicates the events that occur before the main clause are represented as relative past.\n6. Indicates a mild imperative/command.\nUsage: Attach ใ to the continuative form (้ฃ็จๅฝข) of verbs after euphonic change form, ใใฃใ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: None,
}]),
rules: vec![
inflection("ใใฃใ", "ใ", &["-ใ"], &["adj-i"], RuleType::Suffix),
inflection("ใ", "ใ", &["-ใ"], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใฃใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใฃใ", "ใค", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใฃใ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ ", "ใฌ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ ", "ใถ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ ", "ใ", &["-ใ"], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vz"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vs"], RuleType::Suffix),
inflection("็บใ", "็บใ", &["-ใ"], &["vs"], RuleType::Suffix),
inflection("ใใ", "ใใ", &["-ใ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใ", "ๆฅใ", &["-ใ"], &["vk"], RuleType::Suffix),
inflection("ไพใ", "ไพใ", &["-ใ"], &["vk"], RuleType::Suffix),
]
.into_iter()
.chain(irregular_verb_inflections(IrregularVerbSuffix::ใ, &["-ใ"], &["v5"]).into_iter().map(Into::into))
.chain([
inflection("ใพใใ", "ใพใ", &["-ใ"], &["-ใพใ"], RuleType::Suffix),
inflection("ใงใใ", "", &["-ใ"], &["-ใพใใ"], RuleType::Suffix),
inflection("ใใฃใ", "", &["-ใ"], &["-ใพใใ", "-ใ"], RuleType::Suffix)
]).collect(),
},
),
(
"-ใพใ",
Transform {
name: "-ใพใ",
description: Some(
"Polite conjugation of verbs and adjectives.\nUsage: Attach ใพใ to the continuative form (้ฃ็จๅฝข) of verbs.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใพใ",
description: None,
}]),
rules: vec![
inflection("ใพใ", "ใ", &["-ใพใ"], &["v1"], RuleType::Suffix),
inflection("ใใพใ", "ใ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใใพใ", "ใ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใใพใ", "ใ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใใพใ", "ใ", &["-ใพใ"], &["v5d", "v5s"], RuleType::Suffix),
inflection("ใกใพใ", "ใค", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใซใพใ", "ใฌ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใณใพใ", "ใถ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใฟใพใ", "ใ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใใพใ", "ใ", &["-ใพใ"], &["v5d"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &["-ใพใ"], &["vz"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &["-ใพใ"], &["vs"], RuleType::Suffix),
inflection("็บใพใ", "็บใ", &["-ใพใ"], &["vs"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &["-ใพใ"], &["vk"], RuleType::Suffix),
inflection("ๆฅใพใ", "ๆฅใ", &["-ใพใ"], &["vk"], RuleType::Suffix),
inflection("ไพใพใ", "ไพใ", &["-ใพใ"], &["vk"], RuleType::Suffix),
inflection("ใใใใพใ", "ใ", &["-ใพใ"], &["adj-i"], RuleType::Suffix),
],
},
),
(
"potential",
Transform {
name: "potential",
description: Some(
"Indicates a state of being (naturally) capable of doing an action.\nUsage: Attach (ใ)ใใ to the irrealis form (ๆช็ถๅฝข) of ichidan verbs.\nAttach ใ to the imperative form (ๅฝไปคๅฝข) of godan verbs.\nใใ becomes ใงใใ, ใใ becomes ใ(ใ)ใใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝ(ใ)ใใ",
description: None,
}]),
rules: vec![
inflection("ใใ", "ใ", &["v1"], &["v1", "v5d"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใฆใ", "ใค", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใญใ", "ใฌ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ในใ", "ใถ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใใ", "ใ", &["v1"], &["v5d"], RuleType::Suffix),
inflection("ใงใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ๅบๆฅใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"potential or passive",
Transform {
name: "potential or passive",
description: Some(
"Indicates that the subject is affected by the action of the verb.\n3. Indicates a state of being (naturally) capable of doing an action.\nUsage: Attach ใใใ to the irrealis form (ๆช็ถๅฝข) of ichidan verbs.\nใใ becomes ใใใใ, ใใ becomes ใใใใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใใ",
description: None,
}]),
rules: vec![
inflection("ใใใ", "ใ", &["v1"], &["v1"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vz"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("็บใใใ", "็บใ", &["v1"], &["vs"], RuleType::Suffix),
inflection("ใใใใ", "ใใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ๆฅใใใ", "ๆฅใ", &["v1"], &["vk"], RuleType::Suffix),
inflection("ไพใใใ", "ไพใ", &["v1"], &["vk"], RuleType::Suffix),
],
},
),
(
"volitional",
Transform {
name: "volitional",
description: Some(
"1. Expresses speaker's will or intention.\n2. Expresses an invitation to the other party.\n3. (Used in โฆใใใจใใ) Indicates being on the verge of initiating an action or transforming a state.\n4. Indicates an inference of a matter.\nUsage: Attach ใใ to the irrealis form (ๆช็ถๅฝข) of ichidan verbs.\nAttach ใ to the irrealis form (ๆช็ถๅฝข) of godan verbs after -o euphonic change form.\nAttach ใใใ to the stem of i-adjectives (4th meaning only).",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใปใใ",
description: Some("ไธปไฝใฎๆๅฟใ่กจใใ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใจใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใฎใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใผใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
inflection("ใพใใใ", "ใพใ", &[], &["-ใพใ"], RuleType::Suffix),
inflection("ใใใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"volitional slang",
Transform {
name: "volitional slang",
description: Some(
"Contraction of volitional form + ใ\n1. Expresses speaker's will or intention.\n2. Expresses an invitation to the other party.\nUsage: Replace final ใ with ใฃ of volitional form then add ใ.\nFor example: ่กใใใ -> ่กใใฃใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใฃใใปใใฃใ",
description: Some("ใใใใปใใใใใฎ็ญ็ธฎ"),
}]),
rules: vec![
inflection("ใใฃใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใจใฃใ", "ใค", &[], &["v5"], RuleType::Suffix),
inflection("ใฎใฃใ", "ใฌ", &[], &["v5"], RuleType::Suffix),
inflection("ใผใฃใ", "ใถ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใฃใ", "ใ", &[], &["v5"], RuleType::Suffix),
inflection("ใใใฃใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใใฃใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใใฃใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใใฃใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใใฃใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใใฃใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
inflection("ใพใใใฃใ", "ใพใ", &[], &["-ใพใ"], RuleType::Suffix),
],
},
),
(
"-ใพใ",
Transform {
name: "-ใพใ",
description: Some(
"Negative volitional form of verbs.\n1. Expresses speaker's assumption that something is likely not true.\n2. Expresses speaker's will or intention not to do something.\nUsage: Attach ใพใ to the dictionary form (็ตๆญขๅฝข) of verbs.\nAttach ใพใ to the irrealis form (ๆช็ถๅฝข) of ichidan verbs.\nใใ becomes ใใพใ, ใใ becomes ใใพใ.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใพใ",
description: Some(
"1. ๆใใกๆถใใใฎๆจ้ใใใใใ ใ๏ฝใชใใ ใใใใจๆณๅใใ\n2. ๆใใกๆถใใใฎๆๅฟใใใ๏ฝใชใใคใใใ ใใจใใๆฐๆใก",
),
}]),
rules: vec![
inflection("ใพใ", "", &[], &["v"], RuleType::Suffix),
inflection("ใพใ", "ใ", &[], &["v1"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &[], &["vz"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &[], &["vs"], RuleType::Suffix),
inflection("็บใพใ", "็บใ", &[], &["vs"], RuleType::Suffix),
inflection("ใใพใ", "ใใ", &[], &["vk"], RuleType::Suffix),
inflection("ๆฅใพใ", "ๆฅใ", &[], &["vk"], RuleType::Suffix),
inflection("ไพใพใ", "ไพใ", &[], &["vk"], RuleType::Suffix),
inflection("ใพใ", "", &[], &["-ใพใ"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"To do certain things in advance in preparation (or in anticipation) of latter needs.\nUsage: Attach ใใ to the ใฆ-form of verbs.\nAttach ใงใใ after ใชใ negative form of verbs.\nContracts to ใจใใปใฉใ in speech.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: None,
}]),
rules: vec![
inflection("ใฆใใ", "ใฆ", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใงใใ", "ใง", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใจใ", "ใฆ", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฉใ", "ใง", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใชใใงใใ", "ใชใ", &["v5"], &["adj-i"], RuleType::Suffix),
inflection("ใชใใฉใ", "ใชใ", &["v5"], &["adj-i"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"1. Indicates an action continues or progresses to a point in time.\n2. Indicates an action is completed and remains as is.\n3. Indicates a state or condition that can be taken to be the result of undergoing some change.\nUsage: Attach ใใ to the ใฆ-form of verbs. ใ can be dropped in speech.\nAttach ใงใใ after ใชใ negative form of verbs.\n(Slang) Attach ใใ to the ใฆ-form of verbs. Contracts to ใจใใปใงใ in speech.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: None,
}]),
rules: vec![
inflection("ใฆใใ", "ใฆ", &["v1"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฆใใ", "ใฆ", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฆใ", "ใฆ", &["v1p"], &["-ใฆ"], RuleType::Suffix),
inflection("ใงใใ", "ใง", &["v1"], &["-ใฆ"], RuleType::Suffix),
inflection("ใงใใ", "ใง", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใงใ", "ใง", &["v1p"], &["-ใฆ"], RuleType::Suffix),
inflection("ใจใ", "ใฆ", &["v5"], &["-ใฆ"], RuleType::Suffix),
inflection("ใชใใงใใ", "ใชใ", &["v1"], &["adj-i"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Attributive form (้ฃไฝๅฝข) of i-adjectives. An archaic form that remains in modern Japanese.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("้ฃไฝๅฝข"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Describes a person's appearance. Shows feelings of the person.\nUsage: Attach ใ or ๆฐ to the stem of i-adjectives.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: Some("โฆใงใใใใใชๆงๅญใใใใซใโฆใใใใใพใ"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ๆฐ", "ใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"-ใใ",
Transform {
name: "-ใใ",
description: Some(
"1. Shows subjectโs feelings contrast with what is thought/known about them.\n2. Indicates subject's behavior (stands out).\nUsage: Attach ใใ to the stem of i-adjectives. It itself conjugates as a godan verb.",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใ",
description: Some("ใใใซใใใฎ็ถๆ
ใซใใใจใใๅฐ่ฑกใ็ธๆใซไธใใใใใช่จๅใใใใ"),
}]),
rules: vec![
inflection("ใใ", "ใ", &["v5"], &["adj-i"], RuleType::Suffix),
],
},
),
(
"-ใ",
Transform {
name: "-ใ",
description: Some(
"Slang. A sound change of i-adjectives.\nai๏ผใใฐใ โ ใในใ\nui๏ผใใใ โ ใใฟใ/ใใใ\noi๏ผใใใ โ ใใใ",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใ",
description: None,
}]),
rules: vec![
inflection("ใญใ", "ใชใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฟใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใกใใ", "ใคใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใกใ", "ใคใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใพใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฃใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใกใใ", "ใกใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใงใ", "ใฉใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ในใ", "ใฐใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฆใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใญใ", "ใชใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฟใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใกใ", "ใคใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใพใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฃใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใงใ", "ใฉใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ในใ", "ใฐใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฆใ", "ใใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"n-slang",
Transform {
name: "n-slang",
description: Some(
"Slang sound change of r-column syllables to n (when before an n-sound, usually ใฎ or ใช)",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใช",
description: None,
}]),
rules: vec![
inflection("ใใชใใ", "ใใชใใ", &[], &["-ใชใใ"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใชใ", "ใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใชใใ", "ใใชใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใชใใ", "ใใชใใ", &[], &["-ใ"], RuleType::Suffix),
],
},
),
(
"imperative negative slang",
Transform {
name: "imperative negative slang",
description: None,
i18n: Some(vec![TransformI18n {
language: "ja",
name: "๏ฝใใช",
description: None,
}]),
rules: vec![
inflection("ใใช", "ใ", &[], &["v"], RuleType::Suffix),
],
},
),
(
"kansai-ben negative",
Transform {
name: "kansai-ben negative",
description: Some(
"Negative form of kansai-ben verbs",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใชใ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใธใ", "ใชใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใฒใ", "ใชใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใใใธใ", "ใใชใ", &[], &["adj-i"], RuleType::Suffix),
inflection("ใธใใใฃใ", "ใชใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใฒใใใฃใ", "ใชใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใฆใธใ", "ใฃใฆใชใ", &[], &["adj-i"], RuleType::Suffix),
],
},
),
(
"kansai-ben -ใฆ",
Transform {
name: "kansai-ben -ใฆ",
description: Some(
"-ใฆ form of kansai-ben verbs",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใฆ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใฆ", "ใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใจใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฉใใฆ", "ใ ใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฎใใฆ", "ใชใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใปใใฆ", "ใฏใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใผใใฆ", "ใฐใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใพใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใฃใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
],
},
),
(
"kansai-ben -ใ",
Transform {
name: "kansai-ben -ใ",
description: Some(
"-ใ form of kansai-ben terms",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใ", "ใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใจใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใฉใใ", "ใ ใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใฎใใ", "ใชใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใปใใ", "ใฏใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใผใใ", "ใฐใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใพใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
inflection("ใใใ", "ใใฃใ", &["-ใ"], &["-ใ"], RuleType::Suffix),
],
},
),
(
"kansai-ben -ใใ",
Transform {
name: "kansai-ben -ใใ",
description: Some(
"-ใใ form of kansai-ben terms",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใใ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใใ", "ใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใจใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใฉใใใ", "ใ ใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใฎใใใ", "ใชใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใปใใใ", "ใฏใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใผใใใ", "ใฐใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใพใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
],
},
),
(
"kansai-ben -ใใ",
Transform {
name: "kansai-ben -ใใ",
description: Some(
"-ใใ form of kansai-ben terms",
),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใใ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใใ", "ใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใจใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใฉใใใ", "ใ ใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใฎใใใ", "ใชใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใปใใใ", "ใฏใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใผใใใ", "ใฐใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใพใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
inflection("ใใใใ", "ใใฃใใ", &[], &[], RuleType::Suffix),
],
},
),
(
"kansai-ben -ใ",
Transform {
name: "kansai-ben -ใ",
description: Some("-ใ stem of kansai-ben adjectives"),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("้ฃ็จๅฝข (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใ", "ใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใจใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใฎใ", "ใชใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใผใ", "ใฐใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใพใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
inflection("ใใ
ใ", "ใใ", &[], &["-ใ"], RuleType::Suffix),
],
},
),
(
"kansai-ben adjective -ใฆ",
Transform {
name: "kansai-ben adjective -ใฆ",
description: Some("-ใฆ form of kansai-ben adjectives"),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใฆ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใฆ", "ใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใจใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใฎใใฆ", "ใชใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใผใใฆ", "ใฐใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใพใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
inflection("ใใ
ใใฆ", "ใใใฆ", &["-ใฆ"], &["-ใฆ"], RuleType::Suffix),
],
},
),
(
"kansai-ben adjective negative",
Transform {
name: "kansai-ben adjective negative",
description: Some("Negative form of kansai-ben adjectives"),
i18n: Some(vec![TransformI18n {
language: "ja",
name: "้ข่ฅฟๅผ",
description: Some("๏ฝใชใ (้ข่ฅฟๅผ)"),
}]),
rules: vec![
inflection("ใใชใ", "ใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใจใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใฎใใชใ", "ใชใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใผใใชใ", "ใฐใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใพใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
inflection("ใใ
ใใชใ", "ใใใชใ", &["adj-i"], &["adj-i"], RuleType::Suffix),
],
},
),
]))
});
#[rustfmt::skip]
pub(crate) static JP_CONDITIONS_MAP: LazyLock<ConditionMap> = LazyLock::new(|| { ConditionMap(IndexMap::from([ ( "v", Condition { name: "Verb", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ๅ่ฉ", }]), sub_conditions: Some(&[ "v1", "v5", "vk", "vs", "vz", ], ), }, ), ( "v1", Condition { name: "Ichidan verb", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ไธๆฎตๅ่ฉ", }]), sub_conditions: Some(&["v1d", "v1p"]), }, ), ( "v1d", Condition { name: "Ichidan verb, dictionary form", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไธๆฎตๅ่ฉใ่พๆธๅฝข", }]), sub_conditions: None, }, ), ( "v1p", Condition { name: "Ichidan verb, progressive or perfect form", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไธๆฎตๅ่ฉใ๏ฝใฆใใปใงใ", }], ), sub_conditions: None, }, ), ( "v5", Condition { name: "Godan verb", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ไบๆฎตๅ่ฉ", }], ), sub_conditions: Some(&["v5d", "v5s"], ), }, ), ( "v5d", Condition { name: "Godan verb, dictionary form", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไบๆฎตๅ่ฉใ็ตๆญขๅฝข", }], ), sub_conditions: None, }, ), ( "v5s", Condition { name: "Godan verb, short causative form", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไบๆฎตๅ่ฉใ๏ฝใใปใใ", }], ), sub_conditions: Some(&["v5ss", "v5sp"], ), }, ), ( "v5ss", Condition { name: "Godan verb, short causative form having ใใ ending (cannot conjugate with passive form)", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไบๆฎตๅ่ฉใ๏ฝใใ", }], ), sub_conditions: None, }, ), ( "v5sp", Condition { name: "Godan verb, short causative form not having ใใ ending (can conjugate with passive form)", is_dictionary_form: false, i18n: Some(vec![RuleI18n { language: "ja", name: "ไบๆฎตๅ่ฉใ๏ฝใ", }], ), sub_conditions: None, }, ), ( "vk", Condition { name: "Kuru verb", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ๆฅใๅ่ฉ", }], ), sub_conditions: None, }, ), ( "vs", Condition { name: "Suru verb", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ใใๅ่ฉ", }], ), sub_conditions: None, }, ), ( "vz", Condition { name: "Zuru verb", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ใใๅ่ฉ", }], ), sub_conditions: None, }, ), ( "adj-i", Condition { name: "Adjective with i ending", is_dictionary_form: true, i18n: Some(vec![RuleI18n { language: "ja", name: "ๅฝขๅฎน่ฉ", }], ), sub_conditions: None, }, ), ( "-ใพใ", Condition { name: "Polite -ใพใ ending", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใพใใ", Condition { name: "Polite negative -ใพใใ ending", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใฆ", Condition { name: "Intermediate -ใฆ endings for progressive or perfect tense", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใฐ", Condition { name: "Intermediate -ใฐ endings for conditional contraction", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใ", Condition { name: "Intermediate -ใ endings for adverbs", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใ", Condition { name: "-ใ form ending", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใ", Condition { name: "-ใ negative ending", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใชใใ", Condition { name: "Intermediate -ใชใใ ending (polite imperative)", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ( "-ใ", Condition { name: "Intermediate -ใ ending (conditional contraction)", is_dictionary_form: false, i18n: None, sub_conditions: None, }, ), ], ))});