semvec/pypi-packages huggingface dataset:
sb-db-common 0.0.9
A set of db wrappers
Requires Python: >=3.12

# Db Common Lib  
Mainly for myself, switching between different database providers all the time, I wanted a consistent interface.   
Thats what this is for.  
More consistent (Think ADO.NET) db connectivity  

## Overview
Links psgsql, mysql, mssql and sqlite in a common interface  
Unit tests provided to show usage  

## Usage
Connection string format is: `<provider>://<username>:<password>@<host>/<database>`  
The supported providers are:
`sqlite, mysql, mssql, pgsql`

The providers self-register. Call `SessionFactory.register()` before use.

```
with SessionFactory.connect(<connection string>) as session:
    id = session.execute_lastrowid("insert into test(name) values (:name);", {"name": "bob"})
    session.execute("update test set name = :name where id = :id", {"id": id, "name": "bob1"})
```

The session closes and commits automatically when it goes out of scope.  
For more control, manually call commit and rollback.

The queries are db specific, but the mechanisms are the same for all.  
Major differences are the different field types, the parameter specification and in the use of identity columns across the different db's.  
Remember to add `returning <field>` to the insert statement for pgsql or you won't get the identity back.  

### Differences 
#### sqlite
```
CREATE TABLE test(
    id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, 
    name TEXT
);
```
`INSERT INTO test(name) VALUES (:name)`
#### mysql 
```
CREATE TABLE test(
    id INT NOT NULL PRIMARY KEY AUTO_INCREMENT, 
    name VARCHAR(50) NULL
);
```
`INSERT INTO test(name) VALUES (%(name)s);`
#### pgsql
```
CREATE TABLE test(
    id INT NOT NULL PRIMARY KEY GENERATED ALWAYS AS IDENTITY, 
    name VARCHAR(50) NULL
 );
 ```
`INSERT INTO test(name) VALUES (%(name)s) RETURNING id;`

#### mssql
```
CREATE TABLE test(
    id INT IDENTITY(1,1) NOT NULL PRIMARY KEY, 
    name VARCHAR(50) NULL
 );
 ```
`INSERT INTO test(name) output inserted.id VALUES (%(name)s);`

Integrated security is supported, either by passing in a windows username / password, or by setting `trusted_connection=yes` - username / password are then optional, it will then ignore them if provided, and will use the current logged in user.  

## Building
`python -m build `

## Deploying
`python -m twine upload --repository pypi dist/*`
vectorstores 0.1.2.dev50
Project for uploading vector embeddings directly to weaviate.
Requires Python: >=3.11

# vectorstores

Utilities for pushing vectors and metadata into a Weaviate instance. The package ships a `WeaviateVectorStore` implementation plus a simple `VectorStore` interface you can build on.

## Installation

```bash
pip install vectorstores
```

## Quickstart

```python
import weaviate
from vectorstores import WeaviateVectorStore

# create a client (configure URL/auth to match your deployment)
client = weaviate.connect_to_local()  # or weaviate.connect_to_wcs(...)

store = WeaviateVectorStore(
    client=client,
    index_name="MyIndex",
    text_key="text",
)

# add data (stores text plus optional metadata; vectors can be provided explicitly)
ids = store.add_vector(
    vectors=["Hello world", "Another sample"],
    metadatas=[{"topic": "greeting"}, {"topic": "example"}],
)
print(ids)

# delete by id
store.delete(ids=[ids[0]])
```

### Notes
- If you want multi-tenancy, pass `use_multi_tenancy=True` when constructing the store and provide `tenant=...` to write/delete calls.
- If you already have embeddings and want to bypass internal embedding, pass them via `vectors` and supply matching `metadatas`/`ids`.

## Development

Create a virtual environment and install dependencies with tests:

```bash
python3 -m venv .venv
source .venv/bin/activate
pip install -e .[tests]
```

Run checks:

```bash
ruff check .
mypy .
pytest
```

## Building and uploading to PyPI

1) Clean old artifacts (optional but recommended):
```bash
rm -rf dist build *.egg-info
```
2) Build the wheel and sdist:
```bash
python -m build
```
3) Upload to PyPI with Twine:
```bash
twine upload dist/*
```
Make sure your PyPI credentials are configured (e.g., via `~/.pypirc` or environment variables) before running the upload.
cegalprizm-pythontoolpro 2.8.0
Python API for interfacing with Petrel
Requires Python: >=3.6

# Introduction

A Python library for interfacing with Petrel.

# Usage

Python Tool Pro requires a connection to be established from the preferred client-side Python IDE to the Python Tool Pro server in Petrel. Petrel domain objects are accessed from the external Python IDE and the scripts are executed outside of Petrel. The results of the Python scripts are then streamed back to Petrel.

# Basic Example - Open connection

```python
from cegalprizm.pythontool import PetrelConnection
petrel = PetrelConnection()
project_name = petrel.get_current_project_name()
print(f'Name of currently active Petrel project is "{project_name}"')
petrel.close()
```


# Further information and examples
Please see the Cegal Prizm Documentation site [here](https://docs.prizm.cegal-geo.com/products/python-tool-pro/Introduction.html)

# License
Copyright (2025) Cegal, AS. This library (the "Software") may not be used except in connection with the Licensees use of the Cegal Prizm Hub pursuant to an Agreement (defined below) between Licensee (defined below) and Cegal, AS. ("Cegal"). This Software shall be deemed part of the "Subscription Services" under the Agreement. Licensees use of the Software must comply at all times with any restrictions applicable to the Subscription Services, generally, and must be used in accordance with any applicable documentation. If you have not agreed to an Agreement or otherwise do not agree to these terms, you may not use the Software. This license terminates automatically upon the termination of the Agreement or Licensees breach of these terms. Agreement: the agreement between Cegal and Licensee governing the use of the Cegal Prizm Hub, which shall be, with respect to Cegal, and the Cegal Terms of Service located at https://cegal.com/about/terms-and-conditions , in each case unless Licensee has entered into a separate written agreement with Cegal governing the use of the applicable Cegal Services. Licensee: the user of the Software, or, if the Software is being used on behalf of a company, the company.



Petrel * is a mark of SLB
Python™ is a trademark of the Python Software Foundation