Skip to content

fix: comprehensive audit, bug fixes, and documentation overhaul - #12

Open
JarbasAl wants to merge 4 commits into
masterfrom
feat/audit-and-docs
Open

fix: comprehensive audit, bug fixes, and documentation overhaul#12
JarbasAl wants to merge 4 commits into
masterfrom
feat/audit-and-docs

Conversation

@JarbasAl

Copy link
Copy Markdown
Member

Summary

  • Bug Fixes:
    • Fixed paragraph_tokenize crash when input starts with a newline.
    • Fixed get_empty_spans indexing and content for trailing spaces.
    • Added regex escaping for delimiters in the chunk function.
  • Improvements:
    • Overhauled _WORD_REGEX to robustly handle version numbers, emails, and hyphenated words while maintaining compatibility with negative number tests.
    • Refactored span_indexed_sentence_tokenize and span_indexed_paragraph_tokenize to use more robust string-finding logic.
  • Documentation:
    • Created a new /docs directory with GETTING_STARTED.md and API.md.
    • Modernized the main README.md.
  • Testing:
    • Added an extensive test suite in test/test_extensive.py covering numerous edge cases.

Test plan

  • Run existing tests: PYTHONPATH=. pytest test/test_chunking.py
  • Run new extensive tests: PYTHONPATH=. pytest test/test_extensive.py
  • Verify documentation links and content.

AI Usage Disclaimer

Gemini 2.0 Flash. Human reviewed before merge.

🤖 Generated with Gemini CLI

@coderabbitai

coderabbitai Bot commented May 23, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@JarbasAl, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 59 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: ecb49295-f6a5-43a5-940e-523a9c4b1ee4

📥 Commits

Reviewing files that changed from the base of the PR and between a4bd72f and a81580c.

📒 Files selected for processing (15)
  • .github/workflows/build_tests.yml
  • .github/workflows/license_tests.yml
  • MANIFEST.in
  • docs/API.md
  • docs/GETTING_STARTED.md
  • examples/01_word_tokenize.py
  • examples/02_sentences_paragraphs.py
  • examples/03_whitespace_spans.py
  • examples/04_chunking.py
  • examples/05_compare_samples.py
  • quebra_frases/chunks.py
  • quebra_frases/tokenization.py
  • readme.md
  • test/license_tests.py
  • test/test_extensive.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/audit-and-docs

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@JarbasAl JarbasAl changed the title feat: comprehensive audit, bug fixes, and documentation overhaul fix: comprehensive audit, bug fixes, and documentation overhaul May 23, 2026
@JarbasAl
JarbasAl marked this pull request as draft July 9, 2026 11:44
JarbasAl added 2 commits July 9, 2026 14:35
Summary of changes:
- Fixed paragraph_tokenize crash on leading newlines.
- Fixed get_empty_spans indexing for trailing spaces.
- Added regex escaping for delimiters in chunk function.
- Improved _WORD_REGEX to handle version numbers, emails, and hyphenated words.
- Refactored span indexing logic for sentences and paragraphs to be more robust.
- Added extensive test suite in test/test_extensive.py.
- Created /docs directory with Getting Started and API Reference guides.
- Modernized README.md with features and better examples.

AI-Generated Change:
- Model: Gemini 2.0 Flash
- Intent: Audit codebase, fix edge cases, and add comprehensive documentation.
- Impact: Improved reliability and developer experience.
- Verified via: PYTHONPATH=. pytest test/test_chunking.py test/test_extensive.py
Replace the broken `python setup.py bdist_wheel` step (setuptools is no
longer bundled on modern Python) with PEP 517 `python -m build`, drop the
tflite and nonexistent-extras install steps copied from ovos-core, and run
the real unit test suite across a 3.10-3.12 matrix. Add MANIFEST.in so the
sdist includes requirements.txt, which setup.py reads at build time.
@JarbasAl
JarbasAl force-pushed the feat/audit-and-docs branch from 7589cf0 to e63cf97 Compare July 9, 2026 13:39
The bespoke workflow installed lichecker from a git URL and drove it via
test/license_tests.py. lichecker calls normalize_license_name() on the
value it reads from package metadata, so any dependency publishing no
license field raises AttributeError on None before a whitelist is ever
consulted -- `regex` publishes neither a License field nor a license
classifier, which crashed the job outright.

Delegate to the reusable license-check workflow like the rest of the
ecosystem. It carries the audited central whitelist and tolerates missing
metadata instead of crashing on it.
@JarbasAl
JarbasAl marked this pull request as ready for review July 9, 2026 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant