lmjtfy.git / packages / ask / src / README.md
1# Chapter 7½: inside ask/src
2
3`lib.rs`, top to bottom:
4
51. **The page's small rules**: `MAX_INPUT_CHARS`, `THRESHOLD` and `is_yes`,
6   `SURE` and `is_sure`, `likelihood`, and `clean` (what is done to an input
7   before it is asked: trimmed, and cut to 500 characters).
82. **Reading the kind**: `ALSO`, `kind_probability`, `readings`, and
9   `question_id`, which is how four facts share one question.
103. **The questions**: `fact_question` (the eight from chapter 7, word for
11   word), `drafted_question` (what the LLM wrote, as a Jev question), and
12   `check`.
134. **The request**: `Wanted`, `wanted`, and `Prepared`, which holds the exact
14   bytes that will be sent.
155. **The answers**: `learned`, `Judged`, `judged`, and the `Outcome` of a
16   call, with `send` for a live call and `read` for a kept one.
17
18`tests.rs` checks, among other things, that the body the page shows is the
19body the client sends (`the_request_shown_is_the_request_sent`), against a
20scripted transport, so no Jev key is needed.
21
22> **Try it.** `cargo test -p ask`.
23
24| File | What |
25| --- | --- |
26| [lib.rs](lib.rs) | The questions put to Jev, the request, and the record of each call. |
27| [tests.rs](tests.rs) | Requests, answers and kept responses, against a scripted transport. |
28
29← Previous: [Chapter 7, ask/](../) · Up: [ask](../) · Next: [Chapter 8, llm/](../../llm/) →