Skip to main content

Python client for the Simba Knowledge management System

Project description

Simba Client (formerly simba_sdk)

A Python client for interacting with the Simba document processing API.

Installation

Using pip

pip install simba-client

Development Installation

# Clone the repository
git clone https://github.com/GitHamza0206/simba.git
cd simba

# Install dependencies with Poetry
poetry install

Quick Start

from simba_sdk import SimbaClient

# Initialize the client
client = SimbaClient(
    api_url="https://your-api.example.com",
    api_key="your-api-key"
)

# Upload a document
with open("document.pdf", "rb") as f:
    result = client.documents.create_from_file(f, "document.pdf")
    document_id = result["document_id"]

# Parse a document synchronously
parsing_result = client.parser.parse_sync(document_id)

# Parse a document asynchronously
task = client.parser.parse(document_id)
task_id = task["task_id"]

# Check the status of a parsing task
task_status = client.parser.get_task(task_id)

# Generate an embedding for semantic search
embedding_result = client.embedding.embed_document(document_id)

# Perform a similarity search
search_results = client.embedding.get_similarity_search(
    document_id, 
    "financial projections for next quarter",
    limit=3
)

Features

  • Document Management: Upload, download, list, and delete documents
  • Document Parsing: Extract structured data from documents, including tables, forms, and entities
  • Document Embeddings: Generate vector embeddings for documents to enable semantic search
  • Authentication: Secure API access with API keys
  • Error Handling: Robust error handling for API requests

Documentation

For more detailed information, check out the documentation:

Development

Setup Development Environment

# Clone the repository
git clone https://github.com/yourusername/simba-client.git
cd simba-client

# Install dependencies with Poetry
poetry install

Run Tests

poetry run pytest

Build Documentation

poetry run sphinx-build docs/source docs/build

License

This project is licensed under the MIT License.

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

simba_client-0.3.0.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

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

simba_client-0.3.0-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file simba_client-0.3.0.tar.gz.

File metadata

  • Download URL: simba_client-0.3.0.tar.gz
  • Upload date:
  • Size: 8.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.11.5 Darwin/24.3.0

File hashes

Hashes for simba_client-0.3.0.tar.gz
Algorithm Hash digest
SHA256 d94b28adf380b5b323e2e065d9665e3811737bcca761f201d7d23ebdad09046b
MD5 9f199878d68ce49d9919932d00b3b390
BLAKE2b-256 3eade61eefb1e29c5f9dae0f9946c1fc45859cad8f978a881b5e183fbb75ce00

See more details on using hashes here.

File details

Details for the file simba_client-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: simba_client-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 9.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.11.5 Darwin/24.3.0

File hashes

Hashes for simba_client-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c031216422d8ff9f181124352312634958398fe97d0ff257b0ce56ef5d836ed2
MD5 8eba7c85944e6e97fc3b6bcf9d467da7
BLAKE2b-256 39bf053b8a23a9fa542b894681b624d9d2fce763558c5c908dc4ccf14cea3b11

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