Help us write test cases for Ashtadhyayi sutras

41 views
Skip to first unread message

Arun

unread,
Feb 19, 2023, 4:08:05 PM2/19/23
to sanskrit-programmers, ambuda-discuss, shabda-...@googlegroups.com, sams...@googlegroups.com
(please forward widely)

Ambuda's prakriya program is progressing well and now has strong support for various upasargas, षत्व, णत्व, सुट्-आगम, and other details. We'll update our live demo soon to reflect these behind-the-scenes changes.

If you want to support our work technically, one easy way to help is to create test cases for the Ashtadhyayi's sutras. This work is fast, low-commitment, and very important.

If you know Sanskrit but cannot program:

1. Pick a sutra that does not have a test already. You can find tests by examining the files that start with `pada_`.

2. Find examples and counterexamples for your sutra through texts like the Kashika Vrtti or the Siddhantakaumudi.

3. Create a GitHub issue with the examples and counterexamples you've found.

If you know Sanskrit and can program:

Requirements:
- basic programming knowledge. Our code is in Rust, but you don't need to know any Rust to contribute.
- basic familiarity with a command line
- basic familiarity with traditional grammar concepts like लकार and उपदेश
- enough knowledge of Sanskrit to identify words in commentaries like the Kashika Vrtti.
- also, run the setup instructions here.
- basic familiarity with SLP1 transliteration

1. Pick a sutra that does not have a test already. You can check which sutras we have through grep. For example, you can run "grep -r 8_3_69 ." to check if sutra 8.3.69 already has tests.

2. Create a unit test for your sutra. You can follow the examples in this directory, focusing on files that start with `pada_`. You can find words to test by consulting standard texts like the Kashika Vrtti or the Siddhanta Kaumudi.

3. Check that your tests pass or fail by running `cargo test --test pada_1_3`, or whatever adhyaya/pada you wish to test. If the test fails, put `#[ignore]` on the top of it -- you can grep through our repo for examples.

4. Submit a pull request with your changes.

If you run into any difficulties with Rust, please post a message on the #vidyut channel on our Discord server.

Arun

Arun

unread,
Feb 19, 2023, 7:28:28 PM2/19/23
to sanskrit-programmers, ambuda-discuss, shabda-...@googlegroups.com, sams...@googlegroups.com
PS: As illustration, here's a simple self-contained example of how these tests look for various sutras in adhyaya 3 pada 1:


All of the examples in each test case here come from the Kashika Vrtti. The specific notation for each dhatu can be found in our dhatupatha.tsv file.
Reply all
Reply to author
Forward
0 new messages