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.15.tar.gz (18.7 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.15-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: text2doc-0.1.15.tar.gz
  • Upload date:
  • Size: 18.7 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.15.tar.gz
Algorithm Hash digest
SHA256 a2fecbb9f70344daf4d0d17f960f5170394b53fa1eedab35b1850e72ccf66f9c
MD5 1436e6e10bf1d5ebf03cd09a54a5f691
BLAKE2b-256 43750bfddb0341d5ea3eb9f7ca12f0024af877d3f92cb3b41657a09a8ae0a892

See more details on using hashes here.

File details

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

File metadata

  • Download URL: text2doc-0.1.15-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.15-py3-none-any.whl
Algorithm Hash digest
SHA256 09d47df50c0b994b8bfc289617d97aac0ff59f20bbbb5185bff463e44994b9bd
MD5 c725d1475f1628d194cad8c9b0a2ce72
BLAKE2b-256 f02a88a32e1874908b8ae59ded913570f6e0352d4d7df2bbb5c2b4192ba5cb32

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