Conversation
Reviewer's GuideThis PR consolidates several standalone architecture docs into a single centralized Class diagram for updated module relationships in architecture.mdclassDiagram
class lib {
<<module>>
}
class html {
<<module>>
+convert_html_tables()
+html_table_to_markdown()
}
class table {
<<module>>
+reflow_table()
+split_cells()
+SEP_RE
}
class wrap {
<<module>>
+wrap_text()
+is_fence()
}
class lists {
<<module>>
+renumber_lists()
}
class breaks {
<<module>>
+format_breaks()
+THEMATIC_BREAK_LEN
}
class ellipsis {
<<module>>
+replace_ellipsis()
}
class fences {
<<module>>
+compress_fences()
+attach_orphan_specifiers()
}
class footnotes {
<<module>>
+convert_footnotes()
}
class process {
<<module>>
+process_stream()
+process_stream_no_wrap()
}
class io {
<<module>>
+rewrite()
+rewrite_no_wrap()
}
lib --> html
lib --> table
lib --> wrap
lib --> lists
lib --> breaks
lib --> ellipsis
lib --> fences
lib --> process
lib --> io
html ..> wrap : uses is_fence
table ..> reflow : uses parse_rows, etc.
lists ..> wrap : uses is_fence
breaks ..> wrap : uses is_fence
ellipsis ..> wrap : uses tokenize_markdown
process ..> html : uses convert_html_tables
process ..> table : uses reflow_table
process ..> wrap : uses wrap_text, is_fence
process ..> fences : uses compress_fences, attach_orphan_specifiers
process ..> ellipsis : uses replace_ellipsis
process ..> footnotes : uses convert_footnotes
io ..> process : uses process_stream, process_stream_no_wrap
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Summary by CodeRabbit
WalkthroughUpdate all documentation links referencing HTML table support and module relationships to point to consolidated sections within Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant CLI
participant process_stream_inner
participant Modules
participant Rayon
participant Output
User->>CLI: Invoke mdtablefix with files
CLI->>Rayon: Dispatch files for parallel processing
Rayon->>process_stream_inner: Process each file stream
process_stream_inner->>Modules: Handle tables, HTML, code fences, footnotes
Modules-->>process_stream_inner: Return processed content
process_stream_inner->>Output: Send aligned Markdown
Output-->>User: Print ordered results
Estimated code review effort🎯 2 (Simple) | ⏱️ ~15 minutes Possibly related PRs
Poem
✨ Finishing Touches
🧪 Generate unit tests
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Hey @leynos - I've reviewed your changes - here's some feedback:
- Consider adding a table of contents or quick navigation at the top of docs/architecture.md to help readers find sections in this very long document.
- Double-check that all intra-doc links (e.g. to HTML table support and footnote conversion) match the actual heading IDs and won’t result in broken anchors.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Consider adding a table of contents or quick navigation at the top of docs/architecture.md to help readers find sections in this very long document.
- Double-check that all intra-doc links (e.g. to HTML table support and footnote conversion) match the actual heading IDs and won’t result in broken anchors.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
There was a problem hiding this comment.
Actionable comments posted: 8
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (4)
README.md(1 hunks)docs/architecture.md(1 hunks)docs/markdown-stream-processor.md(2 hunks)src/table.rs(1 hunks)
📓 Path-based instructions (3)
**/*.rs
📄 CodeRabbit Inference Engine (AGENTS.md)
**/*.rs: Comments must use en-GB-oxendict spelling and grammar.
Function documentation must include clear examples.
Every module must begin with a module level (//!) comment explaining the module's purpose and utility.
Document public APIs using Rustdoc comments (///) so documentation can be generated with cargo doc.
Place function attributes after doc comments.
Do not usereturnin single-line functions.
Prefer immutable data and avoid unnecessarymutbindings.
Handle errors with theResulttype instead of panicking where feasible.
Avoidunsafecode unless absolutely necessary and document any usage clearly.
Clippy warnings MUST be disallowed.
Lints must not be silenced except as a last resort.
Lint rule suppressions must be tightly scoped and include a clear reason.
Preferexpectoverallow.
Prefer.expect()over.unwrap().
Useconcat!()to combine long string literals rather than escaping newlines with a backslash.
Use predicate functions for conditional criteria with more than two branches.
Fix any warnings emitted during tests in the code itself rather than silencing them.
Where a function is too long, extract meaningfully named helper functions adhering to separation of concerns and CQRS.
Where a function has too many parameters, group related parameters in meaningfully named structs.
Where a function is returning a large error consider usingArcto reduce the amount of data returned.
Comment why, not what. Explain assumptions, edge cases, trade-offs, or complexity. Don't echo the obvious.
Use functions and composition. Avoid repetition by extracting reusable logic. Prefer generators or comprehensions, and declarative code to imperative repetition when readable.
Small, meaningful functions. Functions must be small, clear in purpose, single responsibility, and obey command/query segregation.
Name things precisely. Use clear, descriptive variable and function names. For booleans, prefer names withis,has, orshould.
Structure log...
Files:
src/table.rs
⚙️ CodeRabbit Configuration File
**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.
Adhere to single responsibility and CQRS
Place function attributes after doc comments.
Do not use
returnin single-line functions.Move conditionals with >2 branches into a predicate function.
Avoid
unsafeunless absolutely necessary.Every module must begin with a
//!doc comment that explains the module's purpose and utility.Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar
Lints must not be silenced except as a last resort.
#[allow]is forbidden.- Only narrowly scoped
#[expect(lint, reason = "...")]is allowed.- No lint groups, no blanket or file-wide suppression.
- Include
FIXME:with link if a fix is expected.Use
rstestfixtures for shared setup and to avoid repetition between tests.Replace duplicated tests with
#[rstest(...)]parameterised cases.Prefer
mockallfor mocks/stubs.Prefer
.expect()over.unwrap()Ensure that any API or behavioural changes are reflected in the documentation in
docs/Ensure that any completed roadmap steps are recorded in the appropriate roadmap in
docs/Files must not exceed 400 lines in length
- Large modules must be decomposed
- Long match statements or dispatch tables should be decomposed by domain and collocated with targets
- Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.
Files:
src/table.rs
docs/**/*.md
📄 CodeRabbit Inference Engine (AGENTS.md)
docs/**/*.md: Reference: Use the markdown files within thedocs/directory as a knowledge base and source of truth for project requirements, dependency choices, and architectural decisions.
Update: When new decisions are made, requirements change, libraries are added/removed, or architectural patterns evolve, proactively update the relevant file(s) in thedocs/directory to reflect the latest state.
Documentation must use en-GB-oxendict spelling and grammar (with the exception of "license" which is to be left unchanged for community consistency).
Files:
docs/markdown-stream-processor.mddocs/architecture.md
**/*.md
📄 CodeRabbit Inference Engine (AGENTS.md)
**/*.md: Validate Markdown files usingmake markdownlint.
Runmake fmtafter any documentation changes to format all Markdown files and fix table markup.
Validate Mermaid diagrams in Markdown files by runningmake nixie.
Markdown paragraphs and bullet points must be wrapped at 80 columns.
Code blocks must be wrapped at 120 columns.
Tables and headings must not be wrapped.
Use dashes (-) for list bullets.
Use GitHub-flavoured Markdown footnotes ([^1]) for references.
Files:
docs/markdown-stream-processor.mdREADME.mddocs/architecture.md
⚙️ CodeRabbit Configuration File
**/*.md: * Avoid 2nd person or 1st person pronouns ("I", "you", "we")
- Use en-GB-oxendict (-ize / -our) spelling and grammar
- Paragraphs and bullets must be wrapped to 80 columns, except where a long URL would prevent this (in which case, silence MD013 for that line)
- Code blocks should be wrapped to 120 columns.
- Headings must not be wrapped.
- Documents must start with a level 1 heading
- Headings must correctly increase or decrease by no more than one level at a time
- Use GitHub-flavoured Markdown style for footnotes and endnotes.
- Numbered footnotes must be numbered by order of appearance in the document.
Files:
docs/markdown-stream-processor.mdREADME.mddocs/architecture.md
🪛 LanguageTool
docs/architecture.md
[style] ~72-~72: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ... | 1 | 22 | | 3 | 4 | Code fences are passed through verbatim: rust | not | a | ...
(REP_PASSIVE_VOICE)
[typographical] ~88-~88: Two consecutive dots
Context: ...level process_stream_opts helper. Set Options { footnotes: true, ..Default::default() } when calling `proc...
(DOUBLE_PUNCTUATION)
[typographical] ~121-~121: Consider inserting a comma for improved readability.
Context: ... When the final lines of a document form a numbered list they are replaced with fo...
(INITIAL_ADVP_COMMA)
[uncategorized] ~121-~121: Possible missing comma found.
Context: ...nal lines of a document form a numbered list they are replaced with footnote definit...
(AI_HYDRA_LEO_MISSING_COMMA)
[style] ~152-~152: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...ed, and complex nested or styled tables are not supported. After conversion each HTML table is re...
(REP_PASSIVE_VOICE)
[uncategorized] ~153-~153: Possible missing comma found.
Context: ... styled tables are not supported. After conversion each HTML table is represented as a Mar...
(AI_HYDRA_LEO_MISSING_COMMA)
[style] ~153-~153: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...orted. After conversion each HTML table is represented as a Markdown table so the usual reflow...
(REP_PASSIVE_VOICE)
[uncategorized] ~154-~154: Use a comma before ‘so’ if it connects two independent clauses (unless they are closely connected and short).
Context: ...table is represented as a Markdown table so the usual reflow algorithm can align it...
(COMMA_COMPOUND_SENTENCE_2)
[uncategorized] ~265-~265: Use a comma before ‘so’ if it connects two independent clauses (unless they are closely connected and short).
Context: ...orker gathers its output before printing so results appear in the original order. T...
(COMMA_COMPOUND_SENTENCE_2)
🧰 Additional context used
📓 Path-based instructions (3)
**/*.rs
📄 CodeRabbit Inference Engine (AGENTS.md)
**/*.rs: Comments must use en-GB-oxendict spelling and grammar.
Function documentation must include clear examples.
Every module must begin with a module level (//!) comment explaining the module's purpose and utility.
Document public APIs using Rustdoc comments (///) so documentation can be generated with cargo doc.
Place function attributes after doc comments.
Do not usereturnin single-line functions.
Prefer immutable data and avoid unnecessarymutbindings.
Handle errors with theResulttype instead of panicking where feasible.
Avoidunsafecode unless absolutely necessary and document any usage clearly.
Clippy warnings MUST be disallowed.
Lints must not be silenced except as a last resort.
Lint rule suppressions must be tightly scoped and include a clear reason.
Preferexpectoverallow.
Prefer.expect()over.unwrap().
Useconcat!()to combine long string literals rather than escaping newlines with a backslash.
Use predicate functions for conditional criteria with more than two branches.
Fix any warnings emitted during tests in the code itself rather than silencing them.
Where a function is too long, extract meaningfully named helper functions adhering to separation of concerns and CQRS.
Where a function has too many parameters, group related parameters in meaningfully named structs.
Where a function is returning a large error consider usingArcto reduce the amount of data returned.
Comment why, not what. Explain assumptions, edge cases, trade-offs, or complexity. Don't echo the obvious.
Use functions and composition. Avoid repetition by extracting reusable logic. Prefer generators or comprehensions, and declarative code to imperative repetition when readable.
Small, meaningful functions. Functions must be small, clear in purpose, single responsibility, and obey command/query segregation.
Name things precisely. Use clear, descriptive variable and function names. For booleans, prefer names withis,has, orshould.
Structure log...
Files:
src/table.rs
⚙️ CodeRabbit Configuration File
**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.
Adhere to single responsibility and CQRS
Place function attributes after doc comments.
Do not use
returnin single-line functions.Move conditionals with >2 branches into a predicate function.
Avoid
unsafeunless absolutely necessary.Every module must begin with a
//!doc comment that explains the module's purpose and utility.Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar
Lints must not be silenced except as a last resort.
#[allow]is forbidden.- Only narrowly scoped
#[expect(lint, reason = "...")]is allowed.- No lint groups, no blanket or file-wide suppression.
- Include
FIXME:with link if a fix is expected.Use
rstestfixtures for shared setup and to avoid repetition between tests.Replace duplicated tests with
#[rstest(...)]parameterised cases.Prefer
mockallfor mocks/stubs.Prefer
.expect()over.unwrap()Ensure that any API or behavioural changes are reflected in the documentation in
docs/Ensure that any completed roadmap steps are recorded in the appropriate roadmap in
docs/Files must not exceed 400 lines in length
- Large modules must be decomposed
- Long match statements or dispatch tables should be decomposed by domain and collocated with targets
- Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.
Files:
src/table.rs
docs/**/*.md
📄 CodeRabbit Inference Engine (AGENTS.md)
docs/**/*.md: Reference: Use the markdown files within thedocs/directory as a knowledge base and source of truth for project requirements, dependency choices, and architectural decisions.
Update: When new decisions are made, requirements change, libraries are added/removed, or architectural patterns evolve, proactively update the relevant file(s) in thedocs/directory to reflect the latest state.
Documentation must use en-GB-oxendict spelling and grammar (with the exception of "license" which is to be left unchanged for community consistency).
Files:
docs/markdown-stream-processor.mddocs/architecture.md
**/*.md
📄 CodeRabbit Inference Engine (AGENTS.md)
**/*.md: Validate Markdown files usingmake markdownlint.
Runmake fmtafter any documentation changes to format all Markdown files and fix table markup.
Validate Mermaid diagrams in Markdown files by runningmake nixie.
Markdown paragraphs and bullet points must be wrapped at 80 columns.
Code blocks must be wrapped at 120 columns.
Tables and headings must not be wrapped.
Use dashes (-) for list bullets.
Use GitHub-flavoured Markdown footnotes ([^1]) for references.
Files:
docs/markdown-stream-processor.mdREADME.mddocs/architecture.md
⚙️ CodeRabbit Configuration File
**/*.md: * Avoid 2nd person or 1st person pronouns ("I", "you", "we")
- Use en-GB-oxendict (-ize / -our) spelling and grammar
- Paragraphs and bullets must be wrapped to 80 columns, except where a long URL would prevent this (in which case, silence MD013 for that line)
- Code blocks should be wrapped to 120 columns.
- Headings must not be wrapped.
- Documents must start with a level 1 heading
- Headings must correctly increase or decrease by no more than one level at a time
- Use GitHub-flavoured Markdown style for footnotes and endnotes.
- Numbered footnotes must be numbered by order of appearance in the document.
Files:
docs/markdown-stream-processor.mdREADME.mddocs/architecture.md
🪛 LanguageTool
docs/architecture.md
[style] ~72-~72: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ... | 1 | 22 | | 3 | 4 | Code fences are passed through verbatim: rust | not | a | ...
(REP_PASSIVE_VOICE)
[typographical] ~88-~88: Two consecutive dots
Context: ...level process_stream_opts helper. Set Options { footnotes: true, ..Default::default() } when calling `proc...
(DOUBLE_PUNCTUATION)
[typographical] ~121-~121: Consider inserting a comma for improved readability.
Context: ... When the final lines of a document form a numbered list they are replaced with fo...
(INITIAL_ADVP_COMMA)
[uncategorized] ~121-~121: Possible missing comma found.
Context: ...nal lines of a document form a numbered list they are replaced with footnote definit...
(AI_HYDRA_LEO_MISSING_COMMA)
[style] ~152-~152: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...ed, and complex nested or styled tables are not supported. After conversion each HTML table is re...
(REP_PASSIVE_VOICE)
[uncategorized] ~153-~153: Possible missing comma found.
Context: ... styled tables are not supported. After conversion each HTML table is represented as a Mar...
(AI_HYDRA_LEO_MISSING_COMMA)
[style] ~153-~153: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...orted. After conversion each HTML table is represented as a Markdown table so the usual reflow...
(REP_PASSIVE_VOICE)
[uncategorized] ~154-~154: Use a comma before ‘so’ if it connects two independent clauses (unless they are closely connected and short).
Context: ...table is represented as a Markdown table so the usual reflow algorithm can align it...
(COMMA_COMPOUND_SENTENCE_2)
[uncategorized] ~265-~265: Use a comma before ‘so’ if it connects two independent clauses (unless they are closely connected and short).
Context: ...orker gathers its output before printing so results appear in the original order. T...
(COMMA_COMPOUND_SENTENCE_2)
⏰ Context from checks skipped due to timeout of 240000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build-test
| - `html::convert_html_tables` transforms basic HTML tables into Markdown so they | ||
| can be reflowed like regular tables. See | ||
| [HTML table support](html-table-support.md). | ||
| [HTML table support](architecture.md#html-table-support-in-mdtablefix). | ||
| - `wrap::wrap_text` applies optional line wrapping. It relies on the |
There was a problem hiding this comment.
🧹 Nitpick (assertive)
Collapse the ‘See’ stub into the preceding sentence.
Avoids an unnecessary paragraph break and an orphaned word.
- can be reflowed like regular tables. See
- [HTML table support](architecture.md#html-table-support-in-mdtablefix).
+ can be reflowed like regular tables. See \
+ [HTML table support](architecture.md#html-table-support-in-mdtablefix).📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| - `html::convert_html_tables` transforms basic HTML tables into Markdown so they | |
| can be reflowed like regular tables. See | |
| [HTML table support](html-table-support.md). | |
| [HTML table support](architecture.md#html-table-support-in-mdtablefix). | |
| - `wrap::wrap_text` applies optional line wrapping. It relies on the | |
| - `html::convert_html_tables` transforms basic HTML tables into Markdown so they | |
| can be reflowed like regular tables. See \ | |
| [HTML table support](architecture.md#html-table-support-in-mdtablefix). | |
| - `wrap::wrap_text` applies optional line wrapping. It relies on the |
🤖 Prompt for AI Agents
In docs/markdown-stream-processor.md around lines 14 to 17, the phrase "See
[HTML table support](architecture.md#html-table-support-in-mdtablefix)" should
be merged into the previous sentence to avoid an unnecessary paragraph break and
orphaned word. Combine the sentences so that the reference is part of the same
sentence describing the function of `html::convert_html_tables`.
| After scanning all lines, the processor performs optional post-processing steps | ||
| such as ellipsis replacement and footnote conversion. See | ||
| [footnote conversion](footnote-conversion.md) for details. The function then | ||
| returns the updated stream for writing to disk or further manipulation. | ||
| [footnote conversion](architecture.md#footnote-conversion) for details. The | ||
| function then returns the updated stream for writing to disk or further | ||
| manipulation. |
There was a problem hiding this comment.
🧹 Nitpick (assertive)
Inline the footnote-conversion reference to remove the dangling ‘See’.
-such as ellipsis replacement and footnote conversion. See
-[footnote conversion](architecture.md#footnote-conversion) for details. The
-function then returns the updated stream for writing to disk or further
-manipulation.
+such as ellipsis replacement and footnote conversion. See \
+[footnote conversion](architecture.md#footnote-conversion) for details. The
+function then returns the updated stream for writing to disk or further
+manipulation.📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| After scanning all lines, the processor performs optional post-processing steps | |
| such as ellipsis replacement and footnote conversion. See | |
| [footnote conversion](footnote-conversion.md) for details. The function then | |
| returns the updated stream for writing to disk or further manipulation. | |
| [footnote conversion](architecture.md#footnote-conversion) for details. The | |
| function then returns the updated stream for writing to disk or further | |
| manipulation. | |
| After scanning all lines, the processor performs optional post-processing steps | |
| such as ellipsis replacement and footnote conversion. See \ | |
| [footnote conversion](architecture.md#footnote-conversion) for details. The | |
| function then returns the updated stream for writing to disk or further | |
| manipulation. |
🤖 Prompt for AI Agents
In docs/markdown-stream-processor.md around lines 76 to 80, the phrase "See
[footnote conversion](architecture.md#footnote-conversion)" creates a dangling
reference. Inline the footnote conversion explanation directly in the sentence
to remove the dangling 'See', making the text flow naturally without requiring
the reader to look elsewhere.
| See | ||
| [HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix) | ||
| . |
There was a problem hiding this comment.
🧹 Nitpick (assertive)
Join the split sentence and remove the orphan full stop.
The current layout renders an isolated “See” line and a dangling “.” on its own
line, tripping markdownlint (MD010/MD032).
-See
-[HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix)
-.
+See [HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix).📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| See | |
| [HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix) | |
| . | |
| See [HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix). |
🤖 Prompt for AI Agents
In README.md around lines 162 to 164, the sentence is split causing an isolated
"See" line and a dangling period on the next line, which triggers markdownlint
warnings. Join the split sentence into a single line by moving the link and the
period to the same line as "See" to form a complete sentence without orphan
punctuation.
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 2
♻️ Duplicate comments (1)
README.md (1)
162-164: Join the split sentence once and for all.The orphan “See” and full stop still violate MD010/MD032.
-See -[HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix) -. +See [HTML table support for more details](docs/architecture.md#html-table-support-in-mdtablefix).
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (10)
README.md(1 hunks)docs/architecture.md(1 hunks)docs/footnote-conversion.md(0 hunks)docs/html-table-support.md(0 hunks)docs/markdown-stream-processor.md(0 hunks)docs/module-relationships.md(0 hunks)docs/rayon-concurrency.md(0 hunks)docs/unicode-width.md(0 hunks)src/table.rs(1 hunks)src/wrap.rs(1 hunks)
💤 Files with no reviewable changes (6)
- docs/unicode-width.md
- docs/markdown-stream-processor.md
- docs/footnote-conversion.md
- docs/rayon-concurrency.md
- docs/module-relationships.md
- docs/html-table-support.md
🧰 Additional context used
📓 Path-based instructions (2)
**/*.rs
⚙️ CodeRabbit Configuration File
**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.
Adhere to single responsibility and CQRS
Place function attributes after doc comments.
Do not use
returnin single-line functions.Move conditionals with >2 branches into a predicate function.
Avoid
unsafeunless absolutely necessary.Every module must begin with a
//!doc comment that explains the module's purpose and utility.Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar
Lints must not be silenced except as a last resort.
#[allow]is forbidden.- Only narrowly scoped
#[expect(lint, reason = "...")]is allowed.- No lint groups, no blanket or file-wide suppression.
- Include
FIXME:with link if a fix is expected.Use
rstestfixtures for shared setup and to avoid repetition between tests.Replace duplicated tests with
#[rstest(...)]parameterised cases.Prefer
mockallfor mocks/stubs.Prefer
.expect()over.unwrap()Ensure that any API or behavioural changes are reflected in the documentation in
docs/Ensure that any completed roadmap steps are recorded in the appropriate roadmap in
docs/Files must not exceed 400 lines in length
- Large modules must be decomposed
- Long match statements or dispatch tables should be decomposed by domain and collocated with targets
- Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.
Files:
src/table.rssrc/wrap.rs
**/*.md
⚙️ CodeRabbit Configuration File
**/*.md: * Avoid 2nd person or 1st person pronouns ("I", "you", "we")
- Use en-GB-oxendict (-ize / -our) spelling and grammar
- Paragraphs and bullets must be wrapped to 80 columns, except where a long URL would prevent this (in which case, silence MD013 for that line)
- Code blocks should be wrapped to 120 columns.
- Headings must not be wrapped.
- Documents must start with a level 1 heading
- Headings must correctly increase or decrease by no more than one level at a time
- Use GitHub-flavoured Markdown style for footnotes and endnotes.
- Numbered footnotes must be numbered by order of appearance in the document.
Files:
README.mddocs/architecture.md
🪛 LanguageTool
docs/architecture.md
[style] ~81-~81: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ... | 1 | 22 | | 3 | 4 | Code fences are passed through verbatim: rust | not | a | ...
(REP_PASSIVE_VOICE)
[typographical] ~97-~97: Two consecutive dots
Context: ...level process_stream_opts helper. Set Options { footnotes: true, ..Default::default() } when calling `proc...
(DOUBLE_PUNCTUATION)
[typographical] ~130-~130: Consider inserting a comma for improved readability.
Context: ... When the final lines of a document form a numbered list, they are replaced with f...
(INITIAL_ADVP_COMMA)
[style] ~161-~161: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...ed, and complex nested or styled tables are not supported. After conversion, each HTML table is r...
(REP_PASSIVE_VOICE)
[style] ~162-~162: You have used the passive voice repeatedly in nearby sentences. To make your writing clearer and easier to read, consider using active voice.
Context: ...rted. After conversion, each HTML table is represented as a Markdown table, so the usual reflo...
(REP_PASSIVE_VOICE)
🔇 Additional comments (1)
src/table.rs (1)
3-4: Link is now rustdoc-friendly – good fix.
The clickable reference resolves the previous nit.
| delimiters. | ||
| - `html::convert_html_tables` transforms basic HTML tables into Markdown so \ | ||
| they can be reflowed like regular tables. See \ | ||
| [HTML table support](#html-table-support-in-mdtablefix). | ||
| - `wrap::wrap_text` applies optional line wrapping. It relies on the | ||
| `unicode-width` crate for accurate character widths. | ||
|
|
||
| The function maintains a small state machine that tracks whether it is inside a |
There was a problem hiding this comment.
🧹 Nitpick (assertive)
Wrap long list items to ≤ 80 columns.
Lines in this range overshoot the style limit for prose files. Hard-wrap to maintain consistency with the project’s Markdown guidelines.
🤖 Prompt for AI Agents
In docs/architecture.md around lines 24 to 31, the lines describing the
functions exceed the 80-column limit for prose files. Reformat these lines by
hard-wrapping the text so that no line is longer than 80 characters, ensuring
the content remains clear and consistent with the project's Markdown style
guidelines.
| //! Unicode width handling follows the "Unicode Width Handling" section in | ||
| //! `docs/architecture.md` and uses the `unicode-width` crate for accurate | ||
| //! display calculations. |
There was a problem hiding this comment.
🧹 Nitpick (assertive)
Turn the plain file path into a clickable Rustdoc link.
Make the reference navigable and keep it on one logical line to avoid MD013 warnings.
-//! Unicode width handling follows the "Unicode Width Handling" section in
-//! `docs/architecture.md` and uses the `unicode-width` crate for accurate
-//! display calculations.
+//! Unicode width handling follows the \
+//! ["Unicode Width Handling"](../../docs/architecture.md#unicode-width-handling) \
+//! section and uses the `unicode-width` crate for accurate display calculations.📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| //! Unicode width handling follows the "Unicode Width Handling" section in | |
| //! `docs/architecture.md` and uses the `unicode-width` crate for accurate | |
| //! display calculations. | |
| //! Unicode width handling follows the \ | |
| //! ["Unicode Width Handling"](../../docs/architecture.md#unicode-width-handling) \ | |
| //! section and uses the `unicode-width` crate for accurate display calculations. |
🤖 Prompt for AI Agents
In src/wrap.rs around lines 3 to 5, the file path `docs/architecture.md` in the
Rustdoc comment should be converted into a clickable link. Replace the plain
text path with a Markdown link format using backticks and square brackets,
keeping the entire reference on a single line to avoid MD013 lint warnings.
Summary
docs/architecture.mdTesting
make fmtmake lintmake testmake markdownlintmake nixiehttps://chatgpt.com/codex/tasks/task_e_687ed23b14c4832289d79a74a82102d3
Summary by Sourcery
Consolidate architecture documentation into a single file and update all references accordingly
Documentation: