isnady 0.1.5 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +612 -612
  2. package/index.js +1 -1
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -1,612 +1,612 @@
1
- <!-- generated from README.md by tools/sync_readme.py — edit README.md, not this file -->
2
- <h1 align="center">📜 isnady &nbsp;<sub>إسناد</sub></h1>
3
-
4
- <p align="center">
5
- <strong>Hadith search built around the isnad, the chain of transmission</strong><br>
6
- <sub>Search the collections, read every chain narrator by narrator, and see how the scholars read it</sub>
7
- </p>
8
-
9
- <p align="center">
10
- <a href="https://pypi.org/project/isnady/">
11
- <img src="https://img.shields.io/badge/PyPI-v0.1.5-1D4777?style=for-the-badge&logo=pypi&logoColor=white" alt="PyPI">
12
- </a>
13
- <img src="https://img.shields.io/pypi/pyversions/isnady?style=for-the-badge&color=A47E24&logo=python&logoColor=white" alt="Python">
14
- <img src="https://img.shields.io/badge/Platform-Windows%20%7C%20Linux%20%7C%20macOS-5B6878?style=for-the-badge" alt="Platform">
15
- <a href="https://www.npmjs.com/package/isnady">
16
- <img src="https://img.shields.io/badge/npm-v0.1.5-14304F?style=for-the-badge&logo=npm" alt="npm">
17
- </a>
18
- <img src="https://img.shields.io/badge/License-MIT-D6B25E?style=for-the-badge" alt="License">
19
- </p>
20
-
21
- <p align="center">
22
- <a href="#-why-isnady">Why</a> •
23
- <a href="#-install">Install</a> •
24
- <a href="#-quick-start">Quick Start</a> •
25
- <a href="#-search">Search</a> •
26
- <a href="#-narrators">Narrators</a> •
27
- <a href="#-hadith-scholars">Scholars</a> •
28
- <a href="#-books">Books</a> •
29
- <a href="#-shia-rijal">Shia Rijal</a> •
30
- <a href="#-statistics">Statistics</a> •
31
- <a href="#-learn">Learn</a> •
32
- <a href="#-search-by-meaning-ai">Meaning (AI)</a> •
33
- <a href="#-chains-of-transmission">Chains</a> •
34
- <a href="#-educational-by-design">Educational</a> •
35
- <a href="#-appearance">Appearance</a> •
36
- <a href="#-data-and-licences">Data</a> •
37
- <a href="#%EF%B8%8F-cli">CLI</a> •
38
- <a href="#-screenshots">Screenshots</a> •
39
- <a href="#%EF%B8%8F-roadmap">Roadmap</a>
40
- </p>
41
-
42
- <p align="center">
43
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/search-arabic.png" alt="Searching النيات finds بالنيات in Sahih al-Bukhari 1, with the chain above the text" width="850">
44
- </p>
45
-
46
- > **Pre-alpha (0.1.5).** Search and chains of transmission work today, on data you import
47
- > in one command. Narrators, scholars, gradings and the rest are being built, in the open.
48
-
49
- ---
50
-
51
-
52
- > **About this npm package.** `npm install isnady` installs a small JavaScript library that will grow into
53
- > isnady's API for the web (isnady.net); it does **not** install the isnady application. The application is
54
- > installed with Python (`pip install isnady`, or the one-line installers below) or downloaded as a desktop
55
- > app from the [GitHub Releases](https://github.com/bayramkotan/isnady/releases/latest) page. The npm package
56
- > always carries the same version number as the application.
57
- >
58
- > ```js
59
- > import { info, version } from "isnady";
60
- > console.log(version); // the isnady version, the same as on PyPI and GitHub
61
- > console.log(info()); // { name, version, dataLoaded, homepage }
62
- > ```
63
-
64
- ## 🎯 Why isnady
65
-
66
- A hadith is two things: the text (*matn*) and the chain of people who passed it on
67
- (*isnad*). Most hadith sites let you search the text and show a grade. isnady is built
68
- the other way round: the chain comes first, because that is where the scholars of hadith
69
- did their work.
70
-
71
- - **The chain is read, not typed in.** isnady reads the chain from the Arabic text itself:
72
- who narrated to whom, with which words, and whether it reaches the Prophet.
73
- - **Nothing is guessed.** Where the wording cannot be read with confidence, the chain is
74
- kept whole and marked, never split wrongly. A missing link is shown as missing.
75
- - **Every fact has a source.** Every hadith, text and grade records where it came from,
76
- under which licence.
77
- - **Grades are shown as the scholars gave them.** Each grade keeps its scholar's name and
78
- wording; isnady does not merge them or invent its own.
79
- - **Window and command line, same engine.** Everything the window does, the command line
80
- does too, with the same results.
81
-
82
- ---
83
-
84
- ## 📦 Install
85
-
86
- ### Desktop application
87
-
88
- Download isnady for your system from the **[latest release](https://github.com/bayramkotan/isnady/releases/latest)** —
89
- everything included, the AI features too:
90
-
91
- | System | File |
92
- |---|---|
93
- | Windows 10/11 | `isnady-<version>-windows-portable.exe` — Windows may say the publisher is unknown (the app is not signed): *More info → Run anyway* |
94
- | Linux | `isnady-<version>-linux-x86_64.AppImage` — make it executable (`chmod +x`) and run it |
95
- | macOS, Apple silicon / Intel | `isnady-<version>-macos-arm64.zip` / `…-macos-x86_64.zip` — unzip and run `isnady.app`; the first time, right-click it and choose *Open* (it is not notarized) |
96
-
97
- All three are **portable**: nothing is installed, each runs from wherever it is. Put a folder named
98
- `isnady-data` beside the file and isnady keeps its databases and settings there — isnady on a USB stick.
99
-
100
- Put isnady on the desktop and in the applications menu with **Tools → Create Desktop Shortcut** (or
101
- `iy shortcut`): the shortcut starts isnady the way it is installed — the AppImage, the application, or the
102
- `isnady-gui` command of a Python install.
103
-
104
- ### With Python
105
-
106
- One line, on any system. Install isnady wherever you like — for all users, for yourself, in a
107
- virtual environment, with pipx: the same line installs it, and later updates every copy where it
108
- is, asking for administrator rights only when a copy needs them. Nothing is ever removed.
109
-
110
- ```bash
111
- # Linux and macOS
112
- curl -fsSL https://raw.githubusercontent.com/bayramkotan/isnady/main/install.sh | bash
113
- ```
114
-
115
- ```powershell
116
- # Windows (PowerShell)
117
- irm https://raw.githubusercontent.com/bayramkotan/isnady/main/install.ps1 | iex
118
- ```
119
-
120
- Or with pip:
121
-
122
- ```bash
123
- pip install isnady
124
- isnady # or the short name: iy
125
- ```
126
-
127
- Run inside a clone of this repository, the installer makes an editable (developer) install of
128
- that clone instead.
129
-
130
- The same program answers to several names: **`iy`** to type, **`isnady`** to read, and
131
- `isnady-cli` kept from the first releases. Without arguments it opens the window; with
132
- arguments it is the command line. On Windows, **`isnady-gui`** opens the window without a
133
- console.
134
-
135
- <details>
136
- <summary><b>🐧 On Linux, pip may refuse to install</b></summary>
137
- <br>
138
-
139
- Most current distributions mark the system Python as *externally managed* (PEP 668), so a
140
- plain `pip install` stops with `error: externally-managed-environment`. Two ways around it:
141
-
142
- ```bash
143
- # Isolated — recommended, no system packages touched
144
- pipx install isnady
145
-
146
- # Into your user site — needs the override flag
147
- pip install isnady --break-system-packages --no-cache-dir -U
148
- ```
149
-
150
- </details>
151
-
152
- ### Something not right?
153
-
154
- `iy update` updates every copy of isnady where it is installed. `iy doctor` lists every copy and
155
- which one each command really starts — an older copy in the user folder can start before a newer
156
- one elsewhere, so every copy is kept at the same version. The same report is under
157
- **Help → Check Installation**. If an old copy starts even for `iy update`, run
158
- `python3 -s -m isnady update` (Windows: `py -s -m isnady update`).
159
-
160
- ### Upgrading
161
-
162
- ```bash
163
- iy update
164
- ```
165
-
166
- Your data stays where it is; a newer isnady upgrades the database in place the first time
167
- it opens it.
168
-
169
- ---
170
-
171
- ## 🚀 Quick Start
172
-
173
- isnady ships without hadith data: you choose the sources. One command brings in Sahih
174
- al-Bukhari and Sunan Abi Dawud in Arabic and Turkish from the open
175
- [fawazahmed0/hadith-api](https://github.com/fawazahmed0/hadith-api) collection (public
176
- domain):
177
-
178
- ```bash
179
- iy import fawazahmed0 https://cdn.jsdelivr.net/gh/fawazahmed0/hadith-api@1/editions.json \
180
- --book bukhari --book abudawud --language ara --language tur --license Unlicense
181
- ```
182
-
183
- Or open the window with `iy` and choose **File → Data Sources**: every built-in collection
184
- (al-Bukhari, Muslim, Abu Dawud, al-Tirmidhi, al-Nasa'i, Ibn Maja, the Muwatta and three
185
- forty-hadith books) and the Taqrib import with one click — or **Import all** — in the
186
- languages you tick. You can add your own files or links there too, and move the data
187
- folder anywhere you like.
188
-
189
- On the command line:
190
-
191
- ```bash
192
- iy search النيات # Arabic, with or without diacritics
193
- iy search "niyetlere göre" # Turkish, English, any imported language
194
- iy chain bukhari 1 # one chain, narrator by narrator
195
- ```
196
-
197
- Importing takes a minute or two; the search index and the chains are built as part of it.
198
-
199
- To identify the narrators in those chains, add Ibn Hajar's *Taqrib al-Tahdhib* — 8,824
200
- narrators with his verdict on each — from the [OpenITI](https://github.com/OpenITI) corpus:
201
-
202
- ```bash
203
- iy import taqrib https://raw.githubusercontent.com/OpenITI/0875AH/master/data/0852IbnHajarCasqalani/0852IbnHajarCasqalani.TaqribTahdhib/0852IbnHajarCasqalani.TaqribTahdhib.JK000121-ara1.completed
204
- iy narrator الزهري
205
- ```
206
-
207
- ---
208
-
209
- ## 🔎 Search
210
-
211
- | | |
212
- |:--|:--|
213
- | **Arabic without diacritics** | `الاعمال` finds `الأَعْمَالُ`. Alef forms, alef maqsura, hamza seats and ta marbuta are treated alike, so you type the way you normally write |
214
- | **Attached prefixes** | `النيات` finds `بالنيات`, because Arabic joins bi-, wa-, fa- and al- to the word. *Whole words only* turns this off |
215
- | **Latin-script text** | Case and accents are ignored: `NIYET`, `niyet` and `nîyet` are one word; `Muʿādh`, `Mu'adh` and `Muadh` too |
216
- | **Match** | All words, any word, or the exact phrase |
217
- | **Filters** | Book and language; the language filter also chooses which translations appear |
218
- | **Grades** | Shown under each hadith with the scholar's name, exactly as given |
219
- | **Highlighting** | On the original, diacritised text, diacritics included |
220
-
221
- Results appear at once and fill in as you read; the window never waits for them.
222
-
223
- ### 👥 Narrators
224
-
225
- The **Narrators** page lists every narrator of the imported rijal work — 8,824 from Ibn
226
- Hajar's *Taqrib* — searchable in Arabic or in Latin letters (`Abu Hurayra`, `Zuhri`, `Ibn Umar`),
227
- and filtered by tabaqa, rank and book. For each narrator: Ibn Hajar's verdict and its rank, the
228
- tabaqa and death year, the books his hadith appear in, **whom he narrates from and who
229
- narrates from him** in the imported chains, the compilers who narrate from him directly, and
230
- every hadith whose chain includes him. On the Isnad Chains page a click on a narrator's name
231
- opens him here.
232
-
233
- Each narrator — and each scholar — is shown by the name he is **known by** (al-A'mash, Ibn 'Umar,
234
- Abu Hurayra), with his full name and every part of it laid out: name, lineage, kunya, by-name,
235
- nisbas, client of; the part he is known by is marked ★.
236
-
237
- <p align="center">
238
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/narrators.png" alt="Narrators — 'Abdullah b. 'Umar: Ibn Hajar's verdict, tabaqa, death year, teachers and students in the chains" width="850">
239
- </p>
240
-
241
- ### 🎓 Hadith Scholars
242
-
243
- The scholars whose work is in the imported data, and what the data measures of it:
244
- **compilers** (their collection, the teachers their chains begin with, the Companions they end
245
- with), **graders** (how they grade, and how far they agree with each other on the same hadith —
246
- agreement, Cohen's kappa, and a strictness index: the classical *mutashaddid* / *mutasahil*,
247
- measured), and **critics** of narrators (Ibn Hajar's twelve ranks). On Sunan Abi Dawud, for
248
- example, Zubair 'Ali Za'i grades most strictly (−0.21) and agrees with al-Albani on 70% of the
249
- hadith; the page also flags a pair of graders whose 98% agreement suggests the source did not keep
250
- them independent.
251
-
252
- <p align="center">
253
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/scholars.png" alt="Hadith Scholars — al-Albani: his grades on Sunan Abi Dawud and his agreement with the other graders" width="850">
254
- </p>
255
-
256
- ### 📚 Books
257
-
258
- isnady is not only for searching: the **Books** section opens every imported work and reads it in
259
- its own order. A hadith collection reads chapter by chapter, each hadith with its card (chain,
260
- narrators, other narrations, grades) and the languages you choose; Ibn Hajar's *Taqrib* reads
261
- letter by letter and name by name, each entry with its narrator a click away. Find within a
262
- chapter, go to the previous or next one, and isnady remembers where you were. From any search
263
- result, **In its book** opens the hadith where it stands, among the hadith of its chapter.
264
-
265
- Books are not tied to hadith collections: a work is a tree of any depth (volume, book, chapter,
266
- section) whose leaves are hadith, narrators' entries or paragraphs — so the commentaries, manuals
267
- of fiqh and other works of the scholars can be read the same way as they are added.
268
-
269
- <p align="center">
270
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/books.png" alt="Books — reading Sahih al-Bukhari chapter by chapter, Arabic and Turkish, each hadith with its chain" width="850">
271
- </p>
272
-
273
- ```bash
274
- iy book # the books
275
- iy book bukhari # its chapters
276
- iy book bukhari 2 --language Turkish
277
- iy book taqrib 1
278
- ```
279
-
280
- ### 🕌 Shia Rijal
281
-
282
- The Imami tradition's judgments on narrators, on its own terms: al-Najashi's *Rijal* — 1,266
283
- authors and narrators — read along the two axes of the Imami critics, **reliability** (thiqa;
284
- praised — *jalil*, *wajh*, *'ayn*; weak) and **creed** (Imami, or Waqifi, Fathi, Zaydi, *'ammi* …),
285
- which together give the classical four: an Imami *thiqa*, a praised narrator (*mamduh*), a *thiqa*
286
- of another school (*muwaththaq*), a weak one. The critic's own words are always shown; a creed he
287
- does not state stays unknown; nothing is mapped onto Ibn Hajar's twelve ranks. Checked on four
288
- blind samples of entries, each round's misses corrected. The book itself reads in **Books**, and
289
- the Shia narrators are kept apart from the (Sunni) chains: no chain link is matched to them.
290
-
291
- <p align="center">
292
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/shia-rijal.png" alt="Shia Rijal — al-Najashi on 'Ali b. al-Husayn b. Babawayh: his words and their reading on the Imami scale" width="850">
293
- </p>
294
-
295
- Next: al-Tusi's *Rijal* and *Fihrist*, al-'Allama al-Hilli's *Khulasat al-aqwal*, Ibn Dawud's
296
- *Rijal*, al-Kashshi's reports, and the Four Books with their chains.
297
-
298
- ### 📊 Statistics
299
-
300
- Measured in depth, each figure with what it means and how sure it is. Grades are ordered
301
- categories, so they are never turned into numbers or averaged. The first tab, **Graders**, takes
302
- the scholars who graded a book (al-Albani, Shu'ayb al-Arna'ut, Zubair 'Ali Za'i, Muhammad Muhyi
303
- al-Din 'Abd al-Hamid on Sunan Abi Dawud) and shows:
304
-
305
- - agreement of every pair — same grade, Cohen's kappa and the ordinal kappa — with 95% intervals,
306
- and Krippendorff's alpha for all of them together;
307
- - a **Dawid–Skene model** of each hadith's true grade: each grader's confusion matrix (how he grades
308
- a hadith of each true grade) and, for every hadith, how sure the model is;
309
- - **strictness** — the classical *mutashaddid* and *mutasahil*, measured by order only, with intervals;
310
- - the **disputed hadith**, where the scholars are furthest apart — a double-click opens one in its book.
311
-
312
- Two graders who agree far too often to be independent (98.1%) count as one voice in the model,
313
- and the page says so. Results are computed once and kept in a file. `iy stats graders`.
314
- Narrators, books, hadith, chains, correlations and the models follow, tab by tab.
315
-
316
- <p align="center">
317
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/statistics.png" alt="Statistics — the graders of Sunan Abi Dawud: Krippendorff's alpha, agreement with intervals, the model's certainty" width="850">
318
- </p>
319
-
320
- ### 🎓 Learn
321
-
322
- The terms of hadith and its sciences, written for isnady with their classical sources: 81 terms —
323
- the grades (sahih, hasan, da'if, mawdu', shadhdh, munkar, mu'allal), the kinds of hadith by their
324
- chain (mutawatir, mursal, munqati', mu'allaq, mudallas …), chain and text (mutaba'a, shahid,
325
- takhrij, madar), the ways of receiving (sama', ijaza, haddathana, 'an), judging narrators (the
326
- twelve ranks of Ibn Hajar, thiqa, saduq, majhul, matruk, mudallis), generations, the parts of an
327
- Arabic name, Imami rijal, the books, and isnady's own measures. Each with its Arabic, a one-line
328
- and a longer definition in **English or Turkish**, related terms one click away, and its source.
329
- The grades on every result explain themselves when you point at them. `iy term mursal --lang tr`.
330
-
331
- <p align="center">
332
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/learn.png" alt="Learn — the term mursal: Arabic, definition, related terms and source" width="850">
333
- </p>
334
-
335
- ### 🧠 Search by meaning (AI)
336
-
337
- Choose **Match → By meaning (AI)** to find hadith that say the same thing in other words or in
338
- another language: `komşu hakları` finds the hadith on the neighbour's rights, a Turkish sentence
339
- finds its Arabic original, and `إنما الأعمال بالنيات` gathers the narrations of the hadith on
340
- intentions from every imported book. Each result shows how close it is in meaning (0–1), which
341
- says nothing about authenticity.
342
-
343
- The model is learnt on your computer from the texts you imported — Arabic beside its
344
- translations is a parallel corpus, and cross-lingual latent semantic analysis learns the
345
- concepts the languages share. Nothing is downloaded and no outside model is used. Measured on
346
- al-Bukhari and Abu Dawud: for hadith the model never saw while learning, a Turkish translation
347
- finds its Arabic original first 68% of the time and among the first ten 93% of the time (chance:
348
- 0.8%). For an exact quotation the ordinary word search stays the better tool.
349
-
350
- The same step finds the **other narrations of each hadith** across the imported books
351
- (takhrij): every result card says where else it is narrated — *Also narrated in: Sahih
352
- al-Bukhari 5070 · 6689 · 6953 | Sunan Abi Dawud 2201* — and each number opens that hadith.
353
- Only the texts are compared, never the chains; upright numbers share the text, italic ones
354
- probably report the same event from the same Companion. In blind, hand-checked samples 34 of
355
- 35 pairs of the first kind and 18 of 20 of the second were right.
356
-
357
- ```bash
358
- pip install "isnady[ai]" # numpy and scipy
359
- iy ai build # a few seconds; or Tools → Build AI Indexes
360
- iy search --mode meaning "komşu hakları"
361
- iy tahric bukhari 1 # the other narrations of a hadith
362
- ```
363
-
364
- ---
365
-
366
- ## 🔗 Chains of transmission
367
-
368
- Every Arabic text is read for its chain:
369
-
370
- ```
371
- Sahih al Bukhari 1
372
- 1. حدثنا (narrated to us) الْحُمَيْدِيُّ عَبْدُ اللَّهِ بْنُ الزُّبَيْرِ
373
- 2. حدثنا (narrated to us) سُفْيَانُ
374
- 3. حدثنا (narrated to us) يَحْيَى بْنُ سَعِيدٍ الْأَنْصَارِيُّ
375
- 4. أخبرني (informed me) مُحَمَّدُ بْنُ إِبْرَاهِيمَ التَّيْمِيُّ
376
- 5. سمع (heard) عَلْقَمَةَ بْنَ وَقَّاصٍ اللَّيْثِيَّ
377
- 6. سمعت (I heard) عُمَرَ بْنَ الْخَطَّابِ
378
- -> the Prophet
379
- ```
380
-
381
- In the window, each result shows its chain as a row of names ending at the Prophet, and
382
- **View chain** opens it as a timeline from the book to the Prophet, with the Arabic text
383
- below: the chain in lighter ink, the text of the hadith in full ink.
384
-
385
- ### 👤 Who each narrator is
386
-
387
- With Ibn Hajar's *Taqrib al-Tahdhib* imported, every name in a chain is matched to a
388
- narrator, and the chain shows what Ibn Hajar says of him: his verdict in his own words, its
389
- rank on Ibn Hajar's twelve-step scale, the narrator's *tabaqa* (generation) and his death
390
- year.
391
-
392
- A name is linked only when the evidence leaves one person: the words of the name, the book
393
- marks (a narrator in al-Bukhari must be one Ibn Hajar marks خ), the order of generations
394
- along the chain, and the last link before the Prophet being a Companion. When several
395
- narrators remain — "Sufyan" can be al-Thawri or Ibn 'Uyayna — the chain says so and names
396
- how many, rather than choosing one. Today about half of all names are identified; in blind,
397
- hand-checked samples of the identified ones, the last fifty were all correct.
398
-
399
- Names are kept exactly as written, with the clarifications the compilers added
400
- (*"— yaʿnī Ibn Muḥammad —"*, *"mawlā Ibn ʿAbbās"*), because identifying each narrator is
401
- a separate step that comes next.
402
-
403
- <details>
404
- <summary><b>📊 How well it reads today</b></summary>
405
- <br>
406
-
407
- Measured on Sahih al-Bukhari and Sunan Abi Dawud (12,852 chains):
408
-
409
- | | Bukhari | Abu Dawud | Both |
410
- |:--|:--:|:--:|:--:|
411
- | Split into narrators | 85.5% | 71.9% | 79.9% |
412
- | Of those, reaching the Prophet | | | 78.3% |
413
- | Narrators per chain | | | 5.0 |
414
-
415
- In a blind, hand-checked sample of 30 chains: **no wrong narrator**, 27 complete.
416
-
417
- The rest are kept whole, each with its reason: *tahwil* (ح, a second chain joining), two
418
- teachers at one link (*qiran*), a second chain after the first, or wording that could not be
419
- read with confidence. Abu Dawud uses *qiran* and *tahwil* far more often than Bukhari, which
420
- is why its share is lower. One known limit: a last narrator introduced only by *qāla*
421
- ("قال قال عبد الله") is not added, because the same words also begin stories.
422
-
423
- </details>
424
-
425
- ---
426
-
427
- ## 🎓 Educational by Design
428
-
429
- isnady teaches the science it uses. Every transmission term in a chain explains itself:
430
-
431
- | Term | Reads | What the critics took it to mean |
432
- |:--:|:--|:--|
433
- | حدثنا | narrated to us | The teacher recited it to a group: heard directly |
434
- | حدثني | narrated to me | Recited to the narrator alone: heard directly |
435
- | أخبرنا | informed us | Often a text read back to the teacher (*ʿarḍ*) |
436
- | أنبأنا | told us | Later often transmission by permission (*ijāza*) |
437
- | سمعت | I heard | Direct hearing, stated explicitly |
438
- | قرأت على | I read to | The narrator read the text back to the teacher |
439
- | عن | from | Does not say how it was received (*ʿanʿana*); connected when the two could have met and the narrator is not known for *tadlīs* |
440
- | أن | that | Treated by most critics like ʿan (*muʾannan*) |
441
-
442
- The Learn section — hadith terminology, grading, *jarḥ wa taʿdīl* and the classical works,
443
- each shown on real hadith and real chains — is on the roadmap.
444
-
445
- ---
446
-
447
- ## 🎨 Appearance
448
-
449
- Seven themes, chosen in **Edit → Preferences → Themes** — each shown as a small live isnady window —
450
- or in **View → Theme**: *Lapis* (lapis and gold of illuminated manuscripts) and *Lapis Night*, which
451
- "Follow system" switches between; *Paper* (warm cream and ink, for long reading); *Slate* (quiet and
452
- modern, with a light sidebar); *Emerald*; *Midnight* (deep dark with teal); and *High Contrast*
453
- (black, white and yellow, for low vision). `iy config set view.theme paper`.
454
-
455
- Every script has its own reading font, size, colour and line spacing — Arabic, Latin,
456
- Cyrillic, Bengali and Tamil today, more as sources in other scripts arrive. The light and
457
- the dark theme each keep their own colours, and the interface font can be changed too.
458
- **Edit → Preferences** (Ctrl + ,) applies every change at once; each row has its own
459
- Default button.
460
-
461
- <p align="center">
462
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/preferences.png" alt="Preferences — font, size, line spacing and colour for each script" width="760">
463
- </p>
464
-
465
- The same settings from the command line:
466
-
467
- ```bash
468
- iy config list --prefix text.arabic # what is set, and what is changed
469
- iy config set text.arabic.size 22
470
- iy config set text.latin.family "Noto Serif"
471
- iy config set colors.dark.gilt "#5A4A1E" # matched words in the dark theme
472
- iy config reset text.arabic # back to the defaults
473
- ```
474
-
475
- Settings live in `settings.json` in the isnady data folder, shared by the window and the
476
- command line.
477
-
478
- ---
479
-
480
- ## 📚 Data and licences
481
-
482
- isnady reads open formats and keeps the source of everything:
483
-
484
- - **Supported now:** the [fawazahmed0/hadith-api](https://github.com/fawazahmed0/hadith-api)
485
- JSON format, from a file or a URL, with or without authentication (username and
486
- password, bearer token, or API key; credentials are never stored).
487
- - **Rijal:** Ibn Hajar's *Taqrib al-Tahdhib* in OpenITI mARkdown — each narrator's name,
488
- kunya, verdict, rank, tabaqa, death year and book marks, read by the rules Ibn Hajar sets
489
- out in his own introduction. The OpenITI release does not state its licence in the
490
- repository, so it is kept as tier C (used on your computer, never redistributed) until
491
- it is confirmed.
492
- - **Coming:** CSV, SQL/SQLite, OpenITI mARkdown, REST APIs and Shamela, so any collection
493
- you have can be brought in.
494
-
495
- Every source records a licence **tier**: **A** may be redistributed, **B** may be
496
- redistributed under its conditions, **C** may not. Sources you add yourself stay on your
497
- computer. **Help → Licences** lists every source in your database with its licence.
498
-
499
- ---
500
-
501
- ## ⌨️ CLI
502
-
503
- Everything the window does also works without it — on a server, over SSH, or in a
504
- script. The command line never loads Qt.
505
-
506
- | Short | Full | What it does |
507
- |:------|:-----|:-------------|
508
- | `iy` | `isnady` | Open the window |
509
- | `iy search WORDS` | `isnady search WORDS` | Search; `--mode all\|any\|phrase`, `--whole-words`, `--book`, `--language`, `--limit` |
510
- | `iy chain BOOK NUMBER` | `isnady chain bukhari 1` | One chain, narrator by narrator, with who each one is; `--raw` adds the wording |
511
- | `iy isnads` | `isnady isnads` | Read every chain and report per book; `--rebuild` reads them again |
512
- | `iy ai build` | `isnady ai build` | Learn the meaning index from the imported texts (`iy ai status` to check) |
513
- | `iy import najashi FILE` | `isnady catalog import najashi` | al-Najashi's Rijal: Shia narrators read on the Imami scale, and the book |
514
- | `iy shortcut` | `isnady shortcut --no-desktop` | A desktop and applications-menu shortcut, with isnady's icon |
515
- | `iy term [NAME]` | `isnady term --search tadlis` | The glossary: a term's meaning, English or Turkish (`--lang tr`) |
516
- | `iy stats graders` | `isnady stats graders --book abudawud` | The graders of a book in depth: agreement, model, strictness |
517
- | `iy book [KEY [CHAPTER]]` | `isnady book bukhari 2` | The books; a book's chapters; a chapter read in order |
518
- | `iy scholar [NAME]` | `isnady scholar albani` | The scholars in the data, or one of them with his measured statistics |
519
- | `iy tahric BOOK NUMBER` | `isnady tahric bukhari 1` | Other narrations of a hadith in the imported books (takhrij) |
520
- | `iy search --mode meaning WORDS` | `isnady search --mode meaning "komşu hakları"` | Search by meaning and across languages |
521
- | `iy narrator NAME` | `isnady narrator "Ibn Umar"` | A narrator: Ibn Hajar's verdict and rank, tabaqa, death year, books, other names; with `--limit 1` also teachers, students and hadith |
522
- | `iy import FORMAT FILE-OR-URL` | `isnady import …` | Import a source; `--book`, `--language`, `--license`, `--user`, `--token-env`, `--api-key-env` |
523
- | `iy catalog list` | `isnady catalog list` | Built-in sources and your own, with what is imported — the same as File → Data Sources |
524
- | `iy catalog import ID` | `isnady catalog import fawaz-muslim --language tur` | Import a listed source; `remove`, `add`, `delete` manage the list |
525
- | `iy catalog import --all` | `isnady catalog import --all --language ara` | Every built-in source at once |
526
- | `iy datadir [FOLDER]` | `isnady datadir /data/isnady` | Show or change where the database and settings live; `--as-is`, `--default` |
527
- | `iy formats` | `isnady formats` | Formats that can be imported |
528
- | `iy sources` | `isnady sources` | Imported sources, their licence and tier |
529
- | `iy stats` | `isnady stats` | Hadith, texts, grades and chains per book |
530
- | `iy remove KEY` | `isnady remove KEY` | Remove a source and everything imported from it |
531
- | `iy config list\|get\|set\|reset` | `isnady config …` | Appearance and other settings — the same as Edit → Preferences |
532
- | `iy update` | `isnady update` | Update every copy of isnady where it is installed (system, user, venv, pipx, clone) |
533
- | `iy doctor` | `isnady doctor` | Every copy of isnady on this computer and which one each command starts |
534
- | `iy -V` | `isnady -V` | Show the version (also `-v`, `--version`, `version`) |
535
- | `iy -h` | `isnady -h` | Show help |
536
-
537
- ```console
538
- $ iy search niyet --book abudawud --limit 1
539
- 43 hadith found in 8 ms
540
-
541
- Sunan Abu Dawud #472
542
- grades: Al-Albani: Hasan; Muhammad Muhyi Al-Din Abdul Hamid: Hasan; Shuaib Al Arnaut: Daif; Zubair Ali Zai: Daif
543
- [Turkish] Ebu Hureyre (r.a.); Resulullah (Sallallahu aleyhi ve Sellem)'in şöyle buyurduğunu rivayet etmiştir: "Bir kimse mescid'e hangi [niyet]le gelirse nasibi ondan ibarettir"
544
- ```
545
-
546
- ---
547
-
548
- ## 📸 Screenshots
549
-
550
- <p align="center">
551
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chain.png" alt="Isnad Chains — the chain of Sahih al-Bukhari 1 as a timeline from the book to the Prophet" width="850">
552
- </p>
553
- <p align="center">
554
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/search-grades.png" alt="Search — Sunan Abi Dawud with each scholar's grade and the chain above the text" width="850">
555
- </p>
556
- <p align="center">
557
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chain-dark.png" alt="Dark theme — a seven-narrator chain from Sunan Abi Dawud" width="850">
558
- </p>
559
- <p align="center">
560
- <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chains-overview.png" alt="Chains overview — per-book statistics and what was kept whole" width="850">
561
- </p>
562
-
563
- ---
564
-
565
- ## 🗺️ Roadmap
566
-
567
- - **Narrators** — the other half of the names identified through teachers and students
568
- (al-Mizzi's *Tahdhib al-Kamal*), the verdicts of other critics beside Ibn Hajar's, and
569
- whether each link could have met the next.
570
- - **Hadith scholars** — their lives in full, and more scholars as more collections and grades
571
- are imported.
572
- - **Shia rijal** — narrator verdicts from the Shia rijal works, beside the Sunni view.
573
- - **Learn** — the sciences of hadith, shown on real hadith and real chains.
574
- - **More sources and formats** — and adding your own from inside the window.
575
- - **Glossary** — every Arabic term of hadith and the Islamic sciences explained where it
576
- appears: hover or click a term, read its meaning in the interface language.
577
- - **isnady.net** — the same engine on the web.
578
-
579
- ---
580
-
581
- ## 🔁 Versions and releases
582
-
583
- One version number on GitHub, PyPI and npm, always. A release builds the Python package and the Windows,
584
- Linux and macOS applications first; only when every build succeeds is anything published — PyPI, then the
585
- [GitHub Release](https://github.com/bayramkotan/isnady/releases) with every file and its checksum. What each
586
- version brought is in the [CHANGELOG](https://github.com/bayramkotan/isnady/blob/main/CHANGELOG.md). The
587
- README on npm is made from this one.
588
-
589
- ## 🏗️ Build from Source
590
-
591
- ```bash
592
- git clone https://github.com/bayramkotan/isnady.git
593
- cd isnady
594
- pip install -e .
595
- iy
596
- ```
597
-
598
- Python 3.10 or newer and PySide6. The command line alone needs no PySide6.
599
-
600
- ---
601
-
602
-
603
- The desktop application of your own system: `pip install ".[ai]" pyinstaller`, then
604
- `python packaging/build_app.py linux|windows|macos VERSION`.
605
-
606
- ## 📝 License
607
-
608
- MIT for the application code. Hadith data comes from separate sources, each under its own
609
- licence, recorded with the data and listed under **Help → Licences**.
610
-
611
- The Arabic and reading typeface is [Amiri](https://github.com/aliftype/amiri) by Khaled
612
- Hosny, bundled under the SIL Open Font License 1.1 (`src/isnady/assets/fonts/OFL.txt`).
1
+ <!-- generated from README.md by tools/sync_readme.py — edit README.md, not this file -->
2
+ <h1 align="center">📜 isnady &nbsp;<sub>إسناد</sub></h1>
3
+
4
+ <p align="center">
5
+ <strong>Hadith search built around the isnad, the chain of transmission</strong><br>
6
+ <sub>Search the collections, read every chain narrator by narrator, and see how the scholars read it</sub>
7
+ </p>
8
+
9
+ <p align="center">
10
+ <a href="https://pypi.org/project/isnady/">
11
+ <img src="https://img.shields.io/badge/PyPI-v0.1.7-1D4777?style=for-the-badge&logo=pypi&logoColor=white" alt="PyPI">
12
+ </a>
13
+ <img src="https://img.shields.io/pypi/pyversions/isnady?style=for-the-badge&color=A47E24&logo=python&logoColor=white" alt="Python">
14
+ <img src="https://img.shields.io/badge/Platform-Windows%20%7C%20Linux%20%7C%20macOS-5B6878?style=for-the-badge" alt="Platform">
15
+ <a href="https://www.npmjs.com/package/isnady">
16
+ <img src="https://img.shields.io/badge/npm-v0.1.7-14304F?style=for-the-badge&logo=npm" alt="npm">
17
+ </a>
18
+ <img src="https://img.shields.io/badge/License-MIT-D6B25E?style=for-the-badge" alt="License">
19
+ </p>
20
+
21
+ <p align="center">
22
+ <a href="#-why-isnady">Why</a> •
23
+ <a href="#-install">Install</a> •
24
+ <a href="#-quick-start">Quick Start</a> •
25
+ <a href="#-search">Search</a> •
26
+ <a href="#-narrators">Narrators</a> •
27
+ <a href="#-hadith-scholars">Scholars</a> •
28
+ <a href="#-books">Books</a> •
29
+ <a href="#-shia-rijal">Shia Rijal</a> •
30
+ <a href="#-statistics">Statistics</a> •
31
+ <a href="#-learn">Learn</a> •
32
+ <a href="#-search-by-meaning-ai">Meaning (AI)</a> •
33
+ <a href="#-chains-of-transmission">Chains</a> •
34
+ <a href="#-educational-by-design">Educational</a> •
35
+ <a href="#-appearance">Appearance</a> •
36
+ <a href="#-data-and-licences">Data</a> •
37
+ <a href="#%EF%B8%8F-cli">CLI</a> •
38
+ <a href="#-screenshots">Screenshots</a> •
39
+ <a href="#%EF%B8%8F-roadmap">Roadmap</a>
40
+ </p>
41
+
42
+ <p align="center">
43
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/search-arabic.png" alt="Searching النيات finds بالنيات in Sahih al-Bukhari 1, with the chain above the text" width="850">
44
+ </p>
45
+
46
+ > **Pre-alpha (0.1.7).** Search and chains of transmission work today, on data you import
47
+ > in one command. Narrators, scholars, gradings and the rest are being built, in the open.
48
+
49
+ ---
50
+
51
+
52
+ > **About this npm package.** `npm install isnady` installs a small JavaScript library that will grow into
53
+ > isnady's API for the web (isnady.net); it does **not** install the isnady application. The application is
54
+ > installed with Python (`pip install isnady`, or the one-line installers below) or downloaded as a desktop
55
+ > app from the [GitHub Releases](https://github.com/bayramkotan/isnady/releases/latest) page. The npm package
56
+ > always carries the same version number as the application.
57
+ >
58
+ > ```js
59
+ > import { info, version } from "isnady";
60
+ > console.log(version); // the isnady version, the same as on PyPI and GitHub
61
+ > console.log(info()); // { name, version, dataLoaded, homepage }
62
+ > ```
63
+
64
+ ## 🎯 Why isnady
65
+
66
+ A hadith is two things: the text (*matn*) and the chain of people who passed it on
67
+ (*isnad*). Most hadith sites let you search the text and show a grade. isnady is built
68
+ the other way round: the chain comes first, because that is where the scholars of hadith
69
+ did their work.
70
+
71
+ - **The chain is read, not typed in.** isnady reads the chain from the Arabic text itself:
72
+ who narrated to whom, with which words, and whether it reaches the Prophet.
73
+ - **Nothing is guessed.** Where the wording cannot be read with confidence, the chain is
74
+ kept whole and marked, never split wrongly. A missing link is shown as missing.
75
+ - **Every fact has a source.** Every hadith, text and grade records where it came from,
76
+ under which licence.
77
+ - **Grades are shown as the scholars gave them.** Each grade keeps its scholar's name and
78
+ wording; isnady does not merge them or invent its own.
79
+ - **Window and command line, same engine.** Everything the window does, the command line
80
+ does too, with the same results.
81
+
82
+ ---
83
+
84
+ ## 📦 Install
85
+
86
+ ### Desktop application
87
+
88
+ Download isnady for your system from the **[latest release](https://github.com/bayramkotan/isnady/releases/latest)** —
89
+ everything included, the AI features too:
90
+
91
+ | System | File |
92
+ |---|---|
93
+ | Windows 10/11 | `isnady-<version>-windows-portable.exe` — Windows may say the publisher is unknown (the app is not signed): *More info → Run anyway* |
94
+ | Linux | `isnady-<version>-linux-x86_64.AppImage` — make it executable (`chmod +x`) and run it |
95
+ | macOS, Apple silicon / Intel | `isnady-<version>-macos-arm64.zip` / `…-macos-x86_64.zip` — unzip and run `isnady.app`; the first time, right-click it and choose *Open* (it is not notarized) |
96
+
97
+ All three are **portable**: nothing is installed, each runs from wherever it is. Put a folder named
98
+ `isnady-data` beside the file and isnady keeps its databases and settings there — isnady on a USB stick.
99
+
100
+ Put isnady on the desktop and in the applications menu with **Tools → Create Desktop Shortcut** (or
101
+ `iy shortcut`): the shortcut starts isnady the way it is installed — the AppImage, the application, or the
102
+ `isnady-gui` command of a Python install.
103
+
104
+ ### With Python
105
+
106
+ One line, on any system. Install isnady wherever you like — for all users, for yourself, in a
107
+ virtual environment, with pipx: the same line installs it, and later updates every copy where it
108
+ is, asking for administrator rights only when a copy needs them. Nothing is ever removed.
109
+
110
+ ```bash
111
+ # Linux and macOS
112
+ curl -fsSL https://raw.githubusercontent.com/bayramkotan/isnady/main/install.sh | bash
113
+ ```
114
+
115
+ ```powershell
116
+ # Windows (PowerShell)
117
+ irm https://raw.githubusercontent.com/bayramkotan/isnady/main/install.ps1 | iex
118
+ ```
119
+
120
+ Or with pip:
121
+
122
+ ```bash
123
+ pip install isnady
124
+ isnady # or the short name: iy
125
+ ```
126
+
127
+ Run inside a clone of this repository, the installer makes an editable (developer) install of
128
+ that clone instead.
129
+
130
+ The same program answers to several names: **`iy`** to type, **`isnady`** to read, and
131
+ `isnady-cli` kept from the first releases. Without arguments it opens the window; with
132
+ arguments it is the command line. On Windows, **`isnady-gui`** opens the window without a
133
+ console.
134
+
135
+ <details>
136
+ <summary><b>🐧 On Linux, pip may refuse to install</b></summary>
137
+ <br>
138
+
139
+ Most current distributions mark the system Python as *externally managed* (PEP 668), so a
140
+ plain `pip install` stops with `error: externally-managed-environment`. Two ways around it:
141
+
142
+ ```bash
143
+ # Isolated — recommended, no system packages touched
144
+ pipx install isnady
145
+
146
+ # Into your user site — needs the override flag
147
+ pip install isnady --break-system-packages --no-cache-dir -U
148
+ ```
149
+
150
+ </details>
151
+
152
+ ### Something not right?
153
+
154
+ `iy update` updates every copy of isnady where it is installed. `iy doctor` lists every copy and
155
+ which one each command really starts — an older copy in the user folder can start before a newer
156
+ one elsewhere, so every copy is kept at the same version. The same report is under
157
+ **Help → Check Installation**. If an old copy starts even for `iy update`, run
158
+ `python3 -s -m isnady update` (Windows: `py -s -m isnady update`).
159
+
160
+ ### Upgrading
161
+
162
+ ```bash
163
+ iy update
164
+ ```
165
+
166
+ Your data stays where it is; a newer isnady upgrades the database in place the first time
167
+ it opens it.
168
+
169
+ ---
170
+
171
+ ## 🚀 Quick Start
172
+
173
+ isnady ships without hadith data: you choose the sources. One command brings in Sahih
174
+ al-Bukhari and Sunan Abi Dawud in Arabic and Turkish from the open
175
+ [fawazahmed0/hadith-api](https://github.com/fawazahmed0/hadith-api) collection (public
176
+ domain):
177
+
178
+ ```bash
179
+ iy import fawazahmed0 https://cdn.jsdelivr.net/gh/fawazahmed0/hadith-api@1/editions.json \
180
+ --book bukhari --book abudawud --language ara --language tur --license Unlicense
181
+ ```
182
+
183
+ Or open the window with `iy` and choose **File → Data Sources**: every built-in collection
184
+ (al-Bukhari, Muslim, Abu Dawud, al-Tirmidhi, al-Nasa'i, Ibn Maja, the Muwatta and three
185
+ forty-hadith books) and the Taqrib import with one click — or **Import all** — in the
186
+ languages you tick. You can add your own files or links there too, and move the data
187
+ folder anywhere you like.
188
+
189
+ On the command line:
190
+
191
+ ```bash
192
+ iy search النيات # Arabic, with or without diacritics
193
+ iy search "niyetlere göre" # Turkish, English, any imported language
194
+ iy chain bukhari 1 # one chain, narrator by narrator
195
+ ```
196
+
197
+ Importing takes a minute or two; the search index and the chains are built as part of it.
198
+
199
+ To identify the narrators in those chains, add Ibn Hajar's *Taqrib al-Tahdhib* — 8,824
200
+ narrators with his verdict on each — from the [OpenITI](https://github.com/OpenITI) corpus:
201
+
202
+ ```bash
203
+ iy import taqrib https://raw.githubusercontent.com/OpenITI/0875AH/master/data/0852IbnHajarCasqalani/0852IbnHajarCasqalani.TaqribTahdhib/0852IbnHajarCasqalani.TaqribTahdhib.JK000121-ara1.completed
204
+ iy narrator الزهري
205
+ ```
206
+
207
+ ---
208
+
209
+ ## 🔎 Search
210
+
211
+ | | |
212
+ |:--|:--|
213
+ | **Arabic without diacritics** | `الاعمال` finds `الأَعْمَالُ`. Alef forms, alef maqsura, hamza seats and ta marbuta are treated alike, so you type the way you normally write |
214
+ | **Attached prefixes** | `النيات` finds `بالنيات`, because Arabic joins bi-, wa-, fa- and al- to the word. *Whole words only* turns this off |
215
+ | **Latin-script text** | Case and accents are ignored: `NIYET`, `niyet` and `nîyet` are one word; `Muʿādh`, `Mu'adh` and `Muadh` too |
216
+ | **Match** | All words, any word, or the exact phrase |
217
+ | **Filters** | Book and language; the language filter also chooses which translations appear |
218
+ | **Grades** | Shown under each hadith with the scholar's name, exactly as given |
219
+ | **Highlighting** | On the original, diacritised text, diacritics included |
220
+
221
+ Results appear at once and fill in as you read; the window never waits for them.
222
+
223
+ ### 👥 Narrators
224
+
225
+ The **Narrators** page lists every narrator of the imported rijal work — 8,824 from Ibn
226
+ Hajar's *Taqrib* — searchable in Arabic or in Latin letters (`Abu Hurayra`, `Zuhri`, `Ibn Umar`),
227
+ and filtered by tabaqa, rank and book. For each narrator: Ibn Hajar's verdict and its rank, the
228
+ tabaqa and death year, the books his hadith appear in, **whom he narrates from and who
229
+ narrates from him** in the imported chains, the compilers who narrate from him directly, and
230
+ every hadith whose chain includes him. On the Isnad Chains page a click on a narrator's name
231
+ opens him here.
232
+
233
+ Each narrator — and each scholar — is shown by the name he is **known by** (al-A'mash, Ibn 'Umar,
234
+ Abu Hurayra), with his full name and every part of it laid out: name, lineage, kunya, by-name,
235
+ nisbas, client of; the part he is known by is marked ★.
236
+
237
+ <p align="center">
238
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/narrators.png" alt="Narrators — 'Abdullah b. 'Umar: Ibn Hajar's verdict, tabaqa, death year, teachers and students in the chains" width="850">
239
+ </p>
240
+
241
+ ### 🎓 Hadith Scholars
242
+
243
+ The scholars whose work is in the imported data, and what the data measures of it:
244
+ **compilers** (their collection, the teachers their chains begin with, the Companions they end
245
+ with), **graders** (how they grade, and how far they agree with each other on the same hadith —
246
+ agreement, Cohen's kappa, and a strictness index: the classical *mutashaddid* / *mutasahil*,
247
+ measured), and **critics** of narrators (Ibn Hajar's twelve ranks). On Sunan Abi Dawud, for
248
+ example, Zubair 'Ali Za'i grades most strictly (−0.21) and agrees with al-Albani on 70% of the
249
+ hadith; the page also flags a pair of graders whose 98% agreement suggests the source did not keep
250
+ them independent.
251
+
252
+ <p align="center">
253
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/scholars.png" alt="Hadith Scholars — al-Albani: his grades on Sunan Abi Dawud and his agreement with the other graders" width="850">
254
+ </p>
255
+
256
+ ### 📚 Books
257
+
258
+ isnady is not only for searching: the **Books** section opens every imported work and reads it in
259
+ its own order. A hadith collection reads chapter by chapter, each hadith with its card (chain,
260
+ narrators, other narrations, grades) and the languages you choose; Ibn Hajar's *Taqrib* reads
261
+ letter by letter and name by name, each entry with its narrator a click away. Find within a
262
+ chapter, go to the previous or next one, and isnady remembers where you were. From any search
263
+ result, **In its book** opens the hadith where it stands, among the hadith of its chapter.
264
+
265
+ Books are not tied to hadith collections: a work is a tree of any depth (volume, book, chapter,
266
+ section) whose leaves are hadith, narrators' entries or paragraphs — so the commentaries, manuals
267
+ of fiqh and other works of the scholars can be read the same way as they are added.
268
+
269
+ <p align="center">
270
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/books.png" alt="Books — reading Sahih al-Bukhari chapter by chapter, Arabic and Turkish, each hadith with its chain" width="850">
271
+ </p>
272
+
273
+ ```bash
274
+ iy book # the books
275
+ iy book bukhari # its chapters
276
+ iy book bukhari 2 --language Turkish
277
+ iy book taqrib 1
278
+ ```
279
+
280
+ ### 🕌 Shia Rijal
281
+
282
+ The Imami tradition's judgments on narrators, on its own terms: al-Najashi's *Rijal* — 1,266
283
+ authors and narrators — read along the two axes of the Imami critics, **reliability** (thiqa;
284
+ praised — *jalil*, *wajh*, *'ayn*; weak) and **creed** (Imami, or Waqifi, Fathi, Zaydi, *'ammi* …),
285
+ which together give the classical four: an Imami *thiqa*, a praised narrator (*mamduh*), a *thiqa*
286
+ of another school (*muwaththaq*), a weak one. The critic's own words are always shown; a creed he
287
+ does not state stays unknown; nothing is mapped onto Ibn Hajar's twelve ranks. Checked on four
288
+ blind samples of entries, each round's misses corrected. The book itself reads in **Books**, and
289
+ the Shia narrators are kept apart from the (Sunni) chains: no chain link is matched to them.
290
+
291
+ <p align="center">
292
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/shia-rijal.png" alt="Shia Rijal — al-Najashi on 'Ali b. al-Husayn b. Babawayh: his words and their reading on the Imami scale" width="850">
293
+ </p>
294
+
295
+ Next: al-Tusi's *Rijal* and *Fihrist*, al-'Allama al-Hilli's *Khulasat al-aqwal*, Ibn Dawud's
296
+ *Rijal*, al-Kashshi's reports, and the Four Books with their chains.
297
+
298
+ ### 📊 Statistics
299
+
300
+ Measured in depth, each figure with what it means and how sure it is. Grades are ordered
301
+ categories, so they are never turned into numbers or averaged. The first tab, **Graders**, takes
302
+ the scholars who graded a book (al-Albani, Shu'ayb al-Arna'ut, Zubair 'Ali Za'i, Muhammad Muhyi
303
+ al-Din 'Abd al-Hamid on Sunan Abi Dawud) and shows:
304
+
305
+ - agreement of every pair — same grade, Cohen's kappa and the ordinal kappa — with 95% intervals,
306
+ and Krippendorff's alpha for all of them together;
307
+ - a **Dawid–Skene model** of each hadith's true grade: each grader's confusion matrix (how he grades
308
+ a hadith of each true grade) and, for every hadith, how sure the model is;
309
+ - **strictness** — the classical *mutashaddid* and *mutasahil*, measured by order only, with intervals;
310
+ - the **disputed hadith**, where the scholars are furthest apart — a double-click opens one in its book.
311
+
312
+ Two graders who agree far too often to be independent (98.1%) count as one voice in the model,
313
+ and the page says so. Results are computed once and kept in a file. `iy stats graders`.
314
+ Narrators, books, hadith, chains, correlations and the models follow, tab by tab.
315
+
316
+ <p align="center">
317
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/statistics.png" alt="Statistics — the graders of Sunan Abi Dawud: Krippendorff's alpha, agreement with intervals, the model's certainty" width="850">
318
+ </p>
319
+
320
+ ### 🎓 Learn
321
+
322
+ The terms of hadith and its sciences, written for isnady with their classical sources: 81 terms —
323
+ the grades (sahih, hasan, da'if, mawdu', shadhdh, munkar, mu'allal), the kinds of hadith by their
324
+ chain (mutawatir, mursal, munqati', mu'allaq, mudallas …), chain and text (mutaba'a, shahid,
325
+ takhrij, madar), the ways of receiving (sama', ijaza, haddathana, 'an), judging narrators (the
326
+ twelve ranks of Ibn Hajar, thiqa, saduq, majhul, matruk, mudallis), generations, the parts of an
327
+ Arabic name, Imami rijal, the books, and isnady's own measures. Each with its Arabic, a one-line
328
+ and a longer definition in **English or Turkish**, related terms one click away, and its source.
329
+ The grades on every result explain themselves when you point at them. `iy term mursal --lang tr`.
330
+
331
+ <p align="center">
332
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/learn.png" alt="Learn — the term mursal: Arabic, definition, related terms and source" width="850">
333
+ </p>
334
+
335
+ ### 🧠 Search by meaning (AI)
336
+
337
+ Choose **Match → By meaning (AI)** to find hadith that say the same thing in other words or in
338
+ another language: `komşu hakları` finds the hadith on the neighbour's rights, a Turkish sentence
339
+ finds its Arabic original, and `إنما الأعمال بالنيات` gathers the narrations of the hadith on
340
+ intentions from every imported book. Each result shows how close it is in meaning (0–1), which
341
+ says nothing about authenticity.
342
+
343
+ The model is learnt on your computer from the texts you imported — Arabic beside its
344
+ translations is a parallel corpus, and cross-lingual latent semantic analysis learns the
345
+ concepts the languages share. Nothing is downloaded and no outside model is used. Measured on
346
+ al-Bukhari and Abu Dawud: for hadith the model never saw while learning, a Turkish translation
347
+ finds its Arabic original first 68% of the time and among the first ten 93% of the time (chance:
348
+ 0.8%). For an exact quotation the ordinary word search stays the better tool.
349
+
350
+ The same step finds the **other narrations of each hadith** across the imported books
351
+ (takhrij): every result card says where else it is narrated — *Also narrated in: Sahih
352
+ al-Bukhari 5070 · 6689 · 6953 | Sunan Abi Dawud 2201* — and each number opens that hadith.
353
+ Only the texts are compared, never the chains; upright numbers share the text, italic ones
354
+ probably report the same event from the same Companion. In blind, hand-checked samples 34 of
355
+ 35 pairs of the first kind and 18 of 20 of the second were right.
356
+
357
+ ```bash
358
+ pip install "isnady[ai]" # numpy and scipy
359
+ iy ai build # a few seconds; or Tools → Build AI Indexes
360
+ iy search --mode meaning "komşu hakları"
361
+ iy tahric bukhari 1 # the other narrations of a hadith
362
+ ```
363
+
364
+ ---
365
+
366
+ ## 🔗 Chains of transmission
367
+
368
+ Every Arabic text is read for its chain:
369
+
370
+ ```
371
+ Sahih al Bukhari 1
372
+ 1. حدثنا (narrated to us) الْحُمَيْدِيُّ عَبْدُ اللَّهِ بْنُ الزُّبَيْرِ
373
+ 2. حدثنا (narrated to us) سُفْيَانُ
374
+ 3. حدثنا (narrated to us) يَحْيَى بْنُ سَعِيدٍ الْأَنْصَارِيُّ
375
+ 4. أخبرني (informed me) مُحَمَّدُ بْنُ إِبْرَاهِيمَ التَّيْمِيُّ
376
+ 5. سمع (heard) عَلْقَمَةَ بْنَ وَقَّاصٍ اللَّيْثِيَّ
377
+ 6. سمعت (I heard) عُمَرَ بْنَ الْخَطَّابِ
378
+ -> the Prophet
379
+ ```
380
+
381
+ In the window, each result shows its chain as a row of names ending at the Prophet, and
382
+ **View chain** opens it as a timeline from the book to the Prophet, with the Arabic text
383
+ below: the chain in lighter ink, the text of the hadith in full ink.
384
+
385
+ ### 👤 Who each narrator is
386
+
387
+ With Ibn Hajar's *Taqrib al-Tahdhib* imported, every name in a chain is matched to a
388
+ narrator, and the chain shows what Ibn Hajar says of him: his verdict in his own words, its
389
+ rank on Ibn Hajar's twelve-step scale, the narrator's *tabaqa* (generation) and his death
390
+ year.
391
+
392
+ A name is linked only when the evidence leaves one person: the words of the name, the book
393
+ marks (a narrator in al-Bukhari must be one Ibn Hajar marks خ), the order of generations
394
+ along the chain, and the last link before the Prophet being a Companion. When several
395
+ narrators remain — "Sufyan" can be al-Thawri or Ibn 'Uyayna — the chain says so and names
396
+ how many, rather than choosing one. Today about half of all names are identified; in blind,
397
+ hand-checked samples of the identified ones, the last fifty were all correct.
398
+
399
+ Names are kept exactly as written, with the clarifications the compilers added
400
+ (*"— yaʿnī Ibn Muḥammad —"*, *"mawlā Ibn ʿAbbās"*), because identifying each narrator is
401
+ a separate step that comes next.
402
+
403
+ <details>
404
+ <summary><b>📊 How well it reads today</b></summary>
405
+ <br>
406
+
407
+ Measured on Sahih al-Bukhari and Sunan Abi Dawud (12,852 chains):
408
+
409
+ | | Bukhari | Abu Dawud | Both |
410
+ |:--|:--:|:--:|:--:|
411
+ | Split into narrators | 85.5% | 71.9% | 79.9% |
412
+ | Of those, reaching the Prophet | | | 78.3% |
413
+ | Narrators per chain | | | 5.0 |
414
+
415
+ In a blind, hand-checked sample of 30 chains: **no wrong narrator**, 27 complete.
416
+
417
+ The rest are kept whole, each with its reason: *tahwil* (ح, a second chain joining), two
418
+ teachers at one link (*qiran*), a second chain after the first, or wording that could not be
419
+ read with confidence. Abu Dawud uses *qiran* and *tahwil* far more often than Bukhari, which
420
+ is why its share is lower. One known limit: a last narrator introduced only by *qāla*
421
+ ("قال قال عبد الله") is not added, because the same words also begin stories.
422
+
423
+ </details>
424
+
425
+ ---
426
+
427
+ ## 🎓 Educational by Design
428
+
429
+ isnady teaches the science it uses. Every transmission term in a chain explains itself:
430
+
431
+ | Term | Reads | What the critics took it to mean |
432
+ |:--:|:--|:--|
433
+ | حدثنا | narrated to us | The teacher recited it to a group: heard directly |
434
+ | حدثني | narrated to me | Recited to the narrator alone: heard directly |
435
+ | أخبرنا | informed us | Often a text read back to the teacher (*ʿarḍ*) |
436
+ | أنبأنا | told us | Later often transmission by permission (*ijāza*) |
437
+ | سمعت | I heard | Direct hearing, stated explicitly |
438
+ | قرأت على | I read to | The narrator read the text back to the teacher |
439
+ | عن | from | Does not say how it was received (*ʿanʿana*); connected when the two could have met and the narrator is not known for *tadlīs* |
440
+ | أن | that | Treated by most critics like ʿan (*muʾannan*) |
441
+
442
+ The Learn section — hadith terminology, grading, *jarḥ wa taʿdīl* and the classical works,
443
+ each shown on real hadith and real chains — is on the roadmap.
444
+
445
+ ---
446
+
447
+ ## 🎨 Appearance
448
+
449
+ Seven themes, chosen in **Edit → Preferences → Themes** — each shown as a small live isnady window —
450
+ or in **View → Theme**: *Lapis* (lapis and gold of illuminated manuscripts) and *Lapis Night*, which
451
+ "Follow system" switches between; *Paper* (warm cream and ink, for long reading); *Slate* (quiet and
452
+ modern, with a light sidebar); *Emerald*; *Midnight* (deep dark with teal); and *High Contrast*
453
+ (black, white and yellow, for low vision). `iy config set view.theme paper`.
454
+
455
+ Every script has its own reading font, size, colour and line spacing — Arabic, Latin,
456
+ Cyrillic, Bengali and Tamil today, more as sources in other scripts arrive. The light and
457
+ the dark theme each keep their own colours, and the interface font can be changed too.
458
+ **Edit → Preferences** (Ctrl + ,) applies every change at once; each row has its own
459
+ Default button.
460
+
461
+ <p align="center">
462
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/preferences.png" alt="Preferences — font, size, line spacing and colour for each script" width="760">
463
+ </p>
464
+
465
+ The same settings from the command line:
466
+
467
+ ```bash
468
+ iy config list --prefix text.arabic # what is set, and what is changed
469
+ iy config set text.arabic.size 22
470
+ iy config set text.latin.family "Noto Serif"
471
+ iy config set colors.dark.gilt "#5A4A1E" # matched words in the dark theme
472
+ iy config reset text.arabic # back to the defaults
473
+ ```
474
+
475
+ Settings live in `settings.json` in the isnady data folder, shared by the window and the
476
+ command line.
477
+
478
+ ---
479
+
480
+ ## 📚 Data and licences
481
+
482
+ isnady reads open formats and keeps the source of everything:
483
+
484
+ - **Supported now:** the [fawazahmed0/hadith-api](https://github.com/fawazahmed0/hadith-api)
485
+ JSON format, from a file or a URL, with or without authentication (username and
486
+ password, bearer token, or API key; credentials are never stored).
487
+ - **Rijal:** Ibn Hajar's *Taqrib al-Tahdhib* in OpenITI mARkdown — each narrator's name,
488
+ kunya, verdict, rank, tabaqa, death year and book marks, read by the rules Ibn Hajar sets
489
+ out in his own introduction. The OpenITI release does not state its licence in the
490
+ repository, so it is kept as tier C (used on your computer, never redistributed) until
491
+ it is confirmed.
492
+ - **Coming:** CSV, SQL/SQLite, OpenITI mARkdown, REST APIs and Shamela, so any collection
493
+ you have can be brought in.
494
+
495
+ Every source records a licence **tier**: **A** may be redistributed, **B** may be
496
+ redistributed under its conditions, **C** may not. Sources you add yourself stay on your
497
+ computer. **Help → Licences** lists every source in your database with its licence.
498
+
499
+ ---
500
+
501
+ ## ⌨️ CLI
502
+
503
+ Everything the window does also works without it — on a server, over SSH, or in a
504
+ script. The command line never loads Qt.
505
+
506
+ | Short | Full | What it does |
507
+ |:------|:-----|:-------------|
508
+ | `iy` | `isnady` | Open the window |
509
+ | `iy search WORDS` | `isnady search WORDS` | Search; `--mode all\|any\|phrase`, `--whole-words`, `--book`, `--language`, `--limit` |
510
+ | `iy chain BOOK NUMBER` | `isnady chain bukhari 1` | One chain, narrator by narrator, with who each one is; `--raw` adds the wording |
511
+ | `iy isnads` | `isnady isnads` | Read every chain and report per book; `--rebuild` reads them again |
512
+ | `iy ai build` | `isnady ai build` | Learn the meaning index from the imported texts (`iy ai status` to check) |
513
+ | `iy import najashi FILE` | `isnady catalog import najashi` | al-Najashi's Rijal: Shia narrators read on the Imami scale, and the book |
514
+ | `iy shortcut` | `isnady shortcut --no-desktop` | A desktop and applications-menu shortcut, with isnady's icon |
515
+ | `iy term [NAME]` | `isnady term --search tadlis` | The glossary: a term's meaning, English or Turkish (`--lang tr`) |
516
+ | `iy stats graders` | `isnady stats graders --book abudawud` | The graders of a book in depth: agreement, model, strictness |
517
+ | `iy book [KEY [CHAPTER]]` | `isnady book bukhari 2` | The books; a book's chapters; a chapter read in order |
518
+ | `iy scholar [NAME]` | `isnady scholar albani` | The scholars in the data, or one of them with his measured statistics |
519
+ | `iy tahric BOOK NUMBER` | `isnady tahric bukhari 1` | Other narrations of a hadith in the imported books (takhrij) |
520
+ | `iy search --mode meaning WORDS` | `isnady search --mode meaning "komşu hakları"` | Search by meaning and across languages |
521
+ | `iy narrator NAME` | `isnady narrator "Ibn Umar"` | A narrator: Ibn Hajar's verdict and rank, tabaqa, death year, books, other names; with `--limit 1` also teachers, students and hadith |
522
+ | `iy import FORMAT FILE-OR-URL` | `isnady import …` | Import a source; `--book`, `--language`, `--license`, `--user`, `--token-env`, `--api-key-env` |
523
+ | `iy catalog list` | `isnady catalog list` | Built-in sources and your own, with what is imported — the same as File → Data Sources |
524
+ | `iy catalog import ID` | `isnady catalog import fawaz-muslim --language tur` | Import a listed source; `remove`, `add`, `delete` manage the list |
525
+ | `iy catalog import --all` | `isnady catalog import --all --language ara` | Every built-in source at once |
526
+ | `iy datadir [FOLDER]` | `isnady datadir /data/isnady` | Show or change where the database and settings live; `--as-is`, `--default` |
527
+ | `iy formats` | `isnady formats` | Formats that can be imported |
528
+ | `iy sources` | `isnady sources` | Imported sources, their licence and tier |
529
+ | `iy stats` | `isnady stats` | Hadith, texts, grades and chains per book |
530
+ | `iy remove KEY` | `isnady remove KEY` | Remove a source and everything imported from it |
531
+ | `iy config list\|get\|set\|reset` | `isnady config …` | Appearance and other settings — the same as Edit → Preferences |
532
+ | `iy update` | `isnady update` | Update every copy of isnady where it is installed (system, user, venv, pipx, clone) |
533
+ | `iy doctor` | `isnady doctor` | Every copy of isnady on this computer and which one each command starts |
534
+ | `iy -V` | `isnady -V` | Show the version (also `-v`, `--version`, `version`) |
535
+ | `iy -h` | `isnady -h` | Show help |
536
+
537
+ ```console
538
+ $ iy search niyet --book abudawud --limit 1
539
+ 43 hadith found in 8 ms
540
+
541
+ Sunan Abu Dawud #472
542
+ grades: Al-Albani: Hasan; Muhammad Muhyi Al-Din Abdul Hamid: Hasan; Shuaib Al Arnaut: Daif; Zubair Ali Zai: Daif
543
+ [Turkish] Ebu Hureyre (r.a.); Resulullah (Sallallahu aleyhi ve Sellem)'in şöyle buyurduğunu rivayet etmiştir: "Bir kimse mescid'e hangi [niyet]le gelirse nasibi ondan ibarettir"
544
+ ```
545
+
546
+ ---
547
+
548
+ ## 📸 Screenshots
549
+
550
+ <p align="center">
551
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chain.png" alt="Isnad Chains — the chain of Sahih al-Bukhari 1 as a timeline from the book to the Prophet" width="850">
552
+ </p>
553
+ <p align="center">
554
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/search-grades.png" alt="Search — Sunan Abi Dawud with each scholar's grade and the chain above the text" width="850">
555
+ </p>
556
+ <p align="center">
557
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chain-dark.png" alt="Dark theme — a seven-narrator chain from Sunan Abi Dawud" width="850">
558
+ </p>
559
+ <p align="center">
560
+ <img src="https://raw.githubusercontent.com/bayramkotan/isnady/main/assets/screenshots/chains-overview.png" alt="Chains overview — per-book statistics and what was kept whole" width="850">
561
+ </p>
562
+
563
+ ---
564
+
565
+ ## 🗺️ Roadmap
566
+
567
+ - **Narrators** — the other half of the names identified through teachers and students
568
+ (al-Mizzi's *Tahdhib al-Kamal*), the verdicts of other critics beside Ibn Hajar's, and
569
+ whether each link could have met the next.
570
+ - **Hadith scholars** — their lives in full, and more scholars as more collections and grades
571
+ are imported.
572
+ - **Shia rijal** — narrator verdicts from the Shia rijal works, beside the Sunni view.
573
+ - **Learn** — the sciences of hadith, shown on real hadith and real chains.
574
+ - **More sources and formats** — and adding your own from inside the window.
575
+ - **Glossary** — every Arabic term of hadith and the Islamic sciences explained where it
576
+ appears: hover or click a term, read its meaning in the interface language.
577
+ - **isnady.net** — the same engine on the web.
578
+
579
+ ---
580
+
581
+ ## 🔁 Versions and releases
582
+
583
+ One version number on GitHub, PyPI and npm, always. A release builds the Python package and the Windows,
584
+ Linux and macOS applications first; only when every build succeeds is anything published — PyPI, then the
585
+ [GitHub Release](https://github.com/bayramkotan/isnady/releases) with every file and its checksum. What each
586
+ version brought is in the [CHANGELOG](https://github.com/bayramkotan/isnady/blob/main/CHANGELOG.md). The
587
+ README on npm is made from this one.
588
+
589
+ ## 🏗️ Build from Source
590
+
591
+ ```bash
592
+ git clone https://github.com/bayramkotan/isnady.git
593
+ cd isnady
594
+ pip install -e .
595
+ iy
596
+ ```
597
+
598
+ Python 3.10 or newer and PySide6. The command line alone needs no PySide6.
599
+
600
+ ---
601
+
602
+
603
+ The desktop application of your own system: `pip install ".[ai]" pyinstaller`, then
604
+ `python packaging/build_app.py linux|windows|macos VERSION`.
605
+
606
+ ## 📝 License
607
+
608
+ MIT for the application code. Hadith data comes from separate sources, each under its own
609
+ licence, recorded with the data and listed under **Help → Licences**.
610
+
611
+ The Arabic and reading typeface is [Amiri](https://github.com/aliftype/amiri) by Khaled
612
+ Hosny, bundled under the SIL Open Font License 1.1 (`src/isnady/assets/fonts/OFL.txt`).
package/index.js CHANGED
@@ -6,7 +6,7 @@
6
6
  * database (used by both the Python and JavaScript packages) exists.
7
7
  */
8
8
 
9
- export const version = "0.1.5";
9
+ export const version = "0.1.7";
10
10
  export const name = "isnady";
11
11
 
12
12
  /** Returns basic package information. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "isnady",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "Hadith search with full isnad chains, narrator biographies, jarh wa ta'dil verdicts and reliability scores",
5
5
  "type": "module",
6
6
  "main": "./index.js",