Skip to main content

Convert text to formatted documents

Project description

python.text2doc.com

# Clean up any previous build artifacts
rm -rf build/ dist/ *.egg-info/

# Build the package
python -m pip install --upgrade pip build
python -m build

# Publish to PyPI (if needed)
python -m pip install --upgrade twine
python -m twine upload dist/*

Clean up the build artifacts and rebuild

rm -rf build/ dist/ src/text2doc.egg-info/
python -m pip install -e .
python -m build

text2doc implements a virtual file system in memory. This module provides an interface compatible with the os module and provides operations on files and directories stored in RAM rather than on disk.

Installation

pip install text2doc

Usage

from text2doc import text2doc

# Example usage
texts = ["This is a sample text.", "Another text to tokenize."]
tokenizer = YourTokenizer()  # Replace with your tokenizer instance
docs = text2doc(texts, tokenizer)
print(docs)

Development

Clean up any previous build artifacts

rm -rf build/ dist/ *.egg-info/

Build the package

python -m pip install --upgrade pip build
python -m build

Publish to PyPI (if needed)

python -m pip install --upgrade twine
python -m twine upload dist/*

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

text2doc-0.1.14.tar.gz (15.9 kB view details)

Uploaded Source

Built Distribution

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

text2doc-0.1.14-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file text2doc-0.1.14.tar.gz.

File metadata

  • Download URL: text2doc-0.1.14.tar.gz
  • Upload date:
  • Size: 15.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for text2doc-0.1.14.tar.gz
Algorithm Hash digest
SHA256 5ed11095c9de3e736882b68644c90fb8fb97ac18c3afec2371261e9fce47c3a7
MD5 dfc1735276f95e18828cfa8cb24de436
BLAKE2b-256 798da585bf9665b192f5b98d797b4ca74332217ac889e4b9528d876d2bd60a9b

See more details on using hashes here.

File details

Details for the file text2doc-0.1.14-py3-none-any.whl.

File metadata

  • Download URL: text2doc-0.1.14-py3-none-any.whl
  • Upload date:
  • Size: 7.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for text2doc-0.1.14-py3-none-any.whl
Algorithm Hash digest
SHA256 ab2116f32844ab96b4f2fd9262143f1a783a3854f78092261c904b184a010794
MD5 97b9ea3c691c175f3c669be8718e7bd6
BLAKE2b-256 c4f8f6d25167f1736d3515ddb7bf1427dc7f60dbcfa7fea52e0c96c9652d5603

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