Skip to main content

A Doc2Vec based Embedding Model.

Project description

Swarmauri Logo

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


Doc2Vec Embedding

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.0.dev7.tar.gz (6.9 kB view details)

Uploaded Source

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_embedding_doc2vec-0.7.0.dev7.tar.gz.

File metadata

File hashes

Hashes for swarmauri_embedding_doc2vec-0.7.0.dev7.tar.gz
Algorithm Hash digest
SHA256 493d78b43e594c3b44abcc24a1d3406ba88477b0ed366d7ddaf07ac1a1c9bef7
MD5 bc6babbe328292934227431b726a79c5
BLAKE2b-256 bd9d72268a7227cd27738a648fdb2888dd56773988dc9823e74fa622dfb10001

See more details on using hashes here.

File details

Details for the file swarmauri_embedding_doc2vec-0.7.0.dev7-py3-none-any.whl.

File metadata

File hashes

Hashes for swarmauri_embedding_doc2vec-0.7.0.dev7-py3-none-any.whl
Algorithm Hash digest
SHA256 456e887ea13a96f6df4e93bc449f1eb18be29c1172a134f094d9c68b8f859b08
MD5 049fc3d3f75157a1851fbcd3cc029498
BLAKE2b-256 06bd9566fb00ce5f950c1d6a1dc93024fabbe6f7ced90bb14349cf5bf081d8d7

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