Templates Overview¶
The Mistaber encoding plugin uses four standardized templates for generating checkpoint artifacts. These templates ensure consistent documentation across all encoding sessions.
Template Architecture¶
graph LR
subgraph "Encoding Pipeline"
CP[Corpus Prep] --> |generates| CR[Corpus Report]
HLL[HLL Encode] --> |generates| ER[Encoding Report]
VAL[Validate] --> |generates| VR[Validation Report]
REV[Review] --> |generates| RP[Review Package]
end
subgraph "Templates"
T1[corpus-report.md]
T2[encoding-report.md]
T3[validation-report.md]
T4[review-package.md]
end
T1 -.-> CR
T2 -.-> ER
T3 -.-> VR
T4 -.-> RP
Template Files¶
| Template | Purpose | Generated By | Approx. Size |
|---|---|---|---|
corpus-report.md |
Source compilation report | corpus-prep skill | ~250 lines |
encoding-report.md |
Rule encoding report | hll-encode skill | ~310 lines |
validation-report.md |
Test results report | validate skill | ~570 lines |
review-package.md |
Final review package | review skill | ~500 lines |
Template Location¶
Templates are stored in the plugin's templates/ directory:
mistaber-skills/
└── templates/
├── corpus-report.md
├── encoding-report.md
├── validation-report.md
└── review-package.md
Template Variables¶
All templates use a consistent variable syntax with curly braces:
| Variable | Description | Example |
|---|---|---|
{SIMAN} |
Siman number | 87 |
{SEIF} |
Seif number | 3 |
{TIMESTAMP} |
ISO 8601 timestamp | 2026-01-25T10:30:00Z |
{TOPIC_TITLE} |
Topic description | Basar BeChalav - Fish with Milk |
{HEBREW_TEXT} |
Hebrew source text | Original Hebrew |
{ENGLISH_TRANSLATION} |
English translation | Translation text |
{RULE_ID} |
Rule identifier | r_87_3_dag_sakana |
{WORLD} |
World name | mechaber |
{PREDICATE} |
Predicate expression | issur(M, achiila, W) |
Template Structure¶
Each template follows a consistent structure:
- Header: Title, timestamp, status
- Executive Summary: Key metrics table
- Content Sections: Phase-specific content
- Checkpoint Criteria: Verification checklist
- Approval Section: Approval instructions
Example Structure¶
# {Report Type}: YD {SIMAN}:{SEIF}
**{Action}:** {TIMESTAMP}
**Status:** Pending Review
---
## Executive Summary
| Metric | Value |
|--------|-------|
| Reference | YD {SIMAN}:{SEIF} |
| [Additional metrics...] |
---
## [Content Sections]
[Phase-specific content...]
---
## Checkpoint Review Criteria
Please verify the following before approval:
- [ ] [Verification item 1]
- [ ] [Verification item 2]
- [ ] [Verification item 3]
---
## Approval
**Status:** Pending Review
To approve, respond with:
> "Approved" or "{Type} approved"
To request changes:
> "Needs revision: [specific feedback]"
---
*Generated by Mistaber Encoding Pipeline*
Template Usage by Phase¶
Phase 1: Corpus Preparation¶
Template: corpus-report.md
Content Sections:
- Primary Source (Hebrew + English)
- Atomic Statements extraction
- Commentary Layer (4 tiers)
- Derivation Chain
- Machloket identification
- Semantic Enrichment
- Gap Analysis
- Questions for Review
Key Variables:
| Variable | Content |
|---|---|
{HEBREW_TEXT} |
SA text in Hebrew |
{ENGLISH_TRANSLATION} |
English translation |
{MERMAID_DIAGRAM} |
Derivation chain diagram |
{SHACH_TEXT} |
Shach commentary excerpt |
{TAZ_TEXT} |
Taz commentary excerpt |
Phase 2: HLL Encoding¶
Template: encoding-report.md
Content Sections:
- Statement → Rule Mapping
- World Distribution
- Base World Rules
- Mechaber World Rules
- Rema World Rules
- Machloket Encoding
- Pre-Compile Validation
- World Inheritance Diagram
- Output File Preview
Key Variables:
| Variable | Content |
|---|---|
{BASE_WORLD_RULES} |
Rules for base world |
{MECHABER_RULES} |
Mechaber-specific rules |
{REMA_RULES} |
Rema-specific rules |
{MACHLOKET_MARKERS} |
Machloket marker facts |
Phase 3: Validation¶
Template: validation-report.md
Content Sections:
- Phase A: Compilation Validation
- Phase B: Semantic Validation
- Phase C: Behavioral Testing
- Phase D: Query Verification
- Test Scenarios
- Validation Results Summary
Key Variables:
| Variable | Content |
|---|---|
{COMPILER_ERROR_OUTPUT} |
Error messages if any |
{SAMPLE_ANSWER_SET_ATOMS} |
Clingo output atoms |
{TEST_NAME} |
Individual test names |
{SETUP_FACTS} |
Test setup facts |
{QUERY} |
Test query |
{EXPECTED_RESULT} |
Expected output |
{ACTUAL_RESULT} |
Actual output |
Phase 4: Review¶
Template: review-package.md
Content Sections:
- Component 1: Source Verification
- Component 2: Encoding Review
- Component 3: Validation Evidence
- Component 4: Review Checklists
- Component 5: Questions & Concerns
- Interactive Testing Section
- Output Files
- Final Approval
Key Variables:
| Variable | Content |
|---|---|
{SESSION_ID} |
Unique session identifier |
{APPROVER} |
Checkpoint approver |
{DERIVATION_CHAIN_MERMAID} |
Full derivation diagram |
{CONCERNS_STATUS} |
Outstanding concerns |
Generated Artifacts¶
Templates generate artifacts in .mistaber-artifacts/:
| Artifact | Template | Format |
|---|---|---|
corpus-report-YD-{SIMAN}-{SEIF}.md |
corpus-report.md | Markdown |
corpus-sources-YD-{SIMAN}-{SEIF}.yaml |
(structured data) | YAML |
corpus-chain-YD-{SIMAN}-{SEIF}.mermaid |
(diagram only) | Mermaid |
encoding-report-YD-{SIMAN}-{SEIF}.md |
encoding-report.md | Markdown |
encoding-mapping-YD-{SIMAN}-{SEIF}.yaml |
(structured data) | YAML |
validation-report-YD-{SIMAN}-{SEIF}.md |
validation-report.md | Markdown |
validation-results-YD-{SIMAN}-{SEIF}.yaml |
(structured data) | YAML |
test-scenarios-YD-{SIMAN}-{SEIF}.yaml |
(test definitions) | YAML |
review-package-YD-{SIMAN}-{SEIF}.md |
review-package.md | Markdown |
Approval Workflows¶
Each template includes an approval section:
Approval Response¶
Revision Request¶
Rejection (Review only)¶
Review Checklists¶
Templates include standardized checklists:
Halachic Accuracy (Review Package)¶
| Check | Description |
|---|---|
| H1 | Ruling accurately represents SA text |
| H2 | All conditions from source captured |
| H3 | Machloket positions accurately encoded |
| H4 | Makor chain reaches authoritative source |
| H5 | Commentary interpretations correct |
| H6 | Madrega levels appropriate |
| H7 | No rulings invented or inferred |
| H8 | World assignments match authority |
Technical Accuracy (Review Package)¶
| Check | Description |
|---|---|
| T1 | Predicates correctly chosen |
| T2 | Arity matches predicate definition |
| T3 | Variables properly scoped |
| T4 | NAF used appropriately |
| T5 | World inheritance correct |
| T6 | Overrides properly structured |
| T7 | All rules have unique IDs |
| T8 | File structure follows conventions |
Related Documentation¶
- Customization Guide - Template customization
- Corpus Prep Skill - Uses corpus-report template
- HLL Encode Skill - Uses encoding-report template
- Validate Skill - Uses validation-report template
- Review Skill - Uses review-package template