Skip to main content

A Doc2Vec based Embedding Model.

Project description

Swamauri Logo

PyPI - Downloads Hits PyPI - Python Version PyPI - License PyPI - swarmauri_embedding_doc2vec


Swarmauri Embedding Doc2vec

A Gensim-based Doc2Vec implementation for document embedding in the Swarmauri ecosystem. This package provides document vectorization capabilities using the Doc2Vec algorithm.

Installation

pip install swarmauri_embedding_doc2vec

Usage

from swarmauri.embeddings.Doc2VecEmbedding import Doc2VecEmbedding

# Initialize the embedder
embedder = Doc2VecEmbedding(vector_size=3000)

# Prepare your documents
documents = ["This is the first document.", "Here is another document.", "And a third one"]

# Fit and transform documents
vectors = embedder.fit_transform(documents)

# Transform new documents
new_doc = "This is a new document"
vector = embedder.transform([new_doc])

# Save and load the model
embedder.save_model("doc2vec.model")
embedder.load_model("doc2vec.model")

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

swarmauri_embedding_doc2vec-0.7.4.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

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

swarmauri_embedding_doc2vec-0.7.4-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file swarmauri_embedding_doc2vec-0.7.4.tar.gz.

File metadata

File hashes

Hashes for swarmauri_embedding_doc2vec-0.7.4.tar.gz
Algorithm Hash digest
SHA256 8569cd4c51e8dbb10428aaafd155655b3c3ee6a3ecf5f1807ca67fcf3067f2e9
MD5 d0ceddaff09843dce620ac99c40243a6
BLAKE2b-256 1cac154f78d8ea2f3ac2c6716ad438a736c47caebd6429f3cff3c290742f6ed3

See more details on using hashes here.

File details

Details for the file swarmauri_embedding_doc2vec-0.7.4-py3-none-any.whl.

File metadata

File hashes

Hashes for swarmauri_embedding_doc2vec-0.7.4-py3-none-any.whl
Algorithm Hash digest
SHA256 678a0ddf8eb40ffdd32c62b5a2ea74a596cc7b313499c07e9cc0d129d8a79de7
MD5 8e5bf9945654c7fcb9cd8a5b6d8fe5c1
BLAKE2b-256 e80e5ea040043c55fed8b425d666a0bce77219fc87a877ea25333e2764773425

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