Skip to main content

Swarmauri Community Dale-Chall Readability Tool

Project description

Swarmauri Logo

PyPI - Downloads Hits PyPI - Python Version PyPI - License PyPI - swarmauri_tool_dalechallreadability


Swarmauri Tool Dale-Chall Readability

Tool wrapper around textstat to compute the Dale–Chall readability score for a block of text via the Swarmauri tool interface.

Features

  • Accepts an input_text parameter and returns {"dale_chall_score": <float>}.
  • Uses textstat.dale_chall_readability_score under the hood.
  • Input validation ensures the required parameter is present before calculation.

Prerequisites

  • Python 3.10 or newer.
  • textstat and pyphen dictionaries (installed automatically). Some textstat metrics may download additional word lists on first use.

Installation

# pip
pip install swarmauri_tool_dalechallreadability

# poetry
poetry add swarmauri_tool_dalechallreadability

# uv (pyproject-based projects)
uv add swarmauri_tool_dalechallreadability

Quickstart

from swarmauri_tool_dalechallreadability import DaleChallReadabilityTool

text = "This is a simple sentence for testing purposes."
tool = DaleChallReadabilityTool()
result = tool({"input_text": text})
print(result)

Usage in Tool Chains

from swarmauri_tool_dalechallreadability import DaleChallReadabilityTool

def grade_paragraph(paragraph: str) -> float:
    tool = DaleChallReadabilityTool()
    score = tool({"input_text": paragraph})["dale_chall_score"]
    return score

Tips

  • Dale–Chall scores roughly map to U.S. grade levels; lower scores indicate easier reading.
  • Pre-clean text (remove markup, normalize whitespace) for consistent scoring.
  • Combine with Swarmauri measurements or parsers to evaluate readability across multiple documents.

Want to help?

If you want to contribute to swarmauri-sdk, read up on our guidelines for contributing that will help you get started.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file swarmauri_tool_dalechallreadability-0.10.0.dev7.tar.gz.

File metadata

  • Download URL: swarmauri_tool_dalechallreadability-0.10.0.dev7.tar.gz
  • Upload date:
  • Size: 7.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_tool_dalechallreadability-0.10.0.dev7.tar.gz
Algorithm Hash digest
SHA256 bbd3f0e101b66ec593adcd877603bded80492bf20585e51126ab7dbcdc7672f8
MD5 ab85a0429e0ab61847180a98f553879b
BLAKE2b-256 3e015322953633923acde4eb3954e7472149a922ff5ce3c1aacc320bb75daa6c

See more details on using hashes here.

File details

Details for the file swarmauri_tool_dalechallreadability-0.10.0.dev7-py3-none-any.whl.

File metadata

  • Download URL: swarmauri_tool_dalechallreadability-0.10.0.dev7-py3-none-any.whl
  • Upload date:
  • Size: 8.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_tool_dalechallreadability-0.10.0.dev7-py3-none-any.whl
Algorithm Hash digest
SHA256 a5584eb5a9b12e51063bcea582bcbbe2dd779cccf8aed9cb9e2464d339cf1502
MD5 480a21485ef82707d31d3d77f809d46c
BLAKE2b-256 a9b11b1d577abfb31292a12327a612840f2522d0001c6d4617afe42f1c807abe

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page