Skip to main content

BeautifulSoup Element Parser for Swarmauri.

Project description

Swarmauri Logo

PyPI - Downloads PyPI - Python Version PyPI - License PyPI - Version


BeautifulSoup Element Parser

A specialized parser that utilizes BeautifulSoup to extract specific HTML elements and their content from HTML documents.

Installation

pip install swarmauri_parser_beautifulsoupelement

Usage

The BeautifulSoupElementParser allows you to extract specific HTML elements from HTML content:

from swarmauri_parser_beautifulsoupelement.BeautifulSoupElementParser import BeautifulSoupElementParser

# Create a parser instance to extract paragraphs
parser = BeautifulSoupElementParser(element="p")

# HTML content to parse
html_content = "<div><p>First paragraph</p><p>Second paragraph</p></div>"

# Parse the content
documents = parser.parse(html_content)

# Access the extracted elements
for doc in documents:
    print(doc.content)  # Prints each paragraph element

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


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_parser_beautifulsoupelement-0.7.0.dev9.tar.gz.

File metadata

File hashes

Hashes for swarmauri_parser_beautifulsoupelement-0.7.0.dev9.tar.gz
Algorithm Hash digest
SHA256 9dd008038fddf72a39363bb918554c3457a8cf083852b79085edab1772d3a74c
MD5 889b01fe76da48653b00d30d1bde7d14
BLAKE2b-256 70e2c76ccdfbd56934fe2c7bee31bba0162a6e8c73f1dece645e2c185c10b12d

See more details on using hashes here.

File details

Details for the file swarmauri_parser_beautifulsoupelement-0.7.0.dev9-py3-none-any.whl.

File metadata

File hashes

Hashes for swarmauri_parser_beautifulsoupelement-0.7.0.dev9-py3-none-any.whl
Algorithm Hash digest
SHA256 247ec324476af67177a69d15d75f389f1ae6578ffda3823f87ef93ce3657cf07
MD5 e938555fbab6e261204d6c5f125a75fb
BLAKE2b-256 4448061e165f7807b39209d116be61b64b9acc199d483ce773db1def37a2d764

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