semvec/pypi-packages huggingface dataset:
singlebase 0.1.1
Singlebase.cloud Python SDK
Requires Python: >=3.10.0

# Singlebase Python SDK

Singlebase's Python SDK

## Usage 

### Install 

```
pip install singlebase
```

### Create Client

```py

from singlebase import Client as create_client

API_URL = "https://cloud.singlebaseapis.com/api/[[ACCESS-PATH-KEY]]"
API_KEY = "[[YOUR-SECURE-API-KEY]]"

# create client
sb_client = create_client(
    api_url=API_URL, 
    api_key=API_KEY
)

```

### Methods

#### Sync 

- `client.dispatch(payload:dict)`
- `client.db(action:str, collection:str, payload:dict={})`
- `client.auth(action:str, payload:dict={})`
- `client.storage(action:str, payload:dict={})`
- `client.genai(action:str, payload:dict={})`
- `client.vectordb(action:str, payload:dict={})`


#### Async 

- `client.dispatch_async(payload:dict)`
- `client.db_async(action:str, collection:str, payload:dict={})`
- `client.auth_async(action:str, payload:dict={})`
- `client.storage_async(action:str, payload:dict={})`
- `client.genai_async(action:str, payload:dict={})`
- `client.vectordb_async(action:str, payload:dict={})`



### Examples

```py

### === Datastore

# db.fetch (fetch all)
res = sbc_client.db("fetch", "articles") 

# res:Result|ResultOK|ResultError
if res.ok:
  for entry:dict in res.data: # res.data:[dict, ...]
    _key = entry.get("_key")
    title = entry.get("title")
    print(f" Article _key: {_key} - Title: {title}")

# db.fetch by _key 
res = sbc_client.db("fetch", "articles", {"_key": 1234}) 

# db.fetch by criteria. returns 5 entries
res = sbc_client.db("fetch", "articles", {
  "filter": {
    "author": "author-name",
  },
  "limit": 5
}) 


# db.insert
res = sb_client.db('insert', 'articles', {"title": "Hello", "content": "..."})

# res:Result|ResultOK|ResultError
if res.ok:
  print("Document created. _key: %s" % res.data[0].get("_key"))

# db.update
sb_client.db("update", 'articles', {"_key": "124", "summary": "something"})

# db.upsert
sb_client.db("upsert", 'articles', {
    "filter": { 
      "slug": "my-unique-slug"
    },
    "update": {
      "count:$inc": True
    },
    "insert": {
      "slug": "my-unique-slug",
      "title": "Hello",
      "content": "World"
    }
  })

# db.count
sb_client.db("count", 'articles')

# db.delete
sb_client.db("delete", 'articles', {"_key": "124"})

# db.archive
sb_client.db("archive", 'articles', {"_key": "124"})

# db.restore
sb_client.db("restore", 'articles', {"_key": "124"})

# ------------

### === Auth

# auth.signin
sb_client.auth('signin', {"email": "", "password": ""})
# all other methods follow the same pattern

# ------------

### === Storage

# storage.get
sbc_client.storage('get', {"_key": 1234})

# storage.delete
sbc_client.storage('delete', {"_key": 1234})

sbc_client.storage('convert_to_md', {"_key": 1234})

# ------------

### === GenAI

# genai.summarize
sbc_client.genai('summarize', {"input": "long-text..."})

# genai.gentext 
sbc_client.genai('gentext', {"input": "the prompt"})

# genai.qna - Knowledge Base/Q&A
sbc_client.genai('qna', {
  "collection": "articles",
  "_key": "datakey",
  "input": "the question",
})


---
wrecked 1.0.21
Bindings for the wrecked terminal graphics library
Requires Python: >=3.6

# wrecked_bindings
Python bindings for the wrecked terminal interface library.<br/>
[![PyPI - Downloads](https://img.shields.io/pypi/dw/wrecked?style=flat-square)](https://pypi.org/project/wrecked/)
[![PyPI](https://img.shields.io/pypi/v/wrecked?style=flat-square)](https://pypi.org/project/wrecked/)
[![PyPI - License](https://img.shields.io/pypi/l/wrecked?style=flat-square)](https://burnsomni.net/project/wrecked_bindings/?branch=master&path=LICENSE)

## Installation
Can be installed through pip
```
pip install wrecked
```

## Usage
```python
import wrecked

# Instantiates the environment. Turns off input echo.
top_rect = wrecked.init()

# create a rectangle to put text in.
new_rect = top_rect.new_rect(width=16, height=5)

# Add a string to the center of the rectangle
new_rect.set_string(2, 3, "Hello World!")

# Make that rectangle blue
new_rect.set_bg_color(wrecked.BLUE)

# And finally underline the text of the rectangle
new_rect.set_underline_flag()

# Draw the environment
top_rect.draw()

# take down the environment, and turn echo back on.
wrecked.kill()
```
clockwise 1.0.4
A simple timing library for Python
Requires Python: >=3.0
Keywords: profiling

# clockwise 🕰️
Simple but expressive timing package in Python

## Installation
```
pip install clockwise
```

## Minimal Example
```
import clockwise

@clockwise.timing("time-as-decorator")
def foo(a: int): 
   return a + 4

def main():
    for i in range(10):
        foo(i)

    with clockwise.timing_context("time-as-context"):
        foo(1)

    clockwise.print_timings() 

if __name__ == '__main__':
    main()
```

## Debug Mode
The profiling is skipped when running in optimized mode using the `-O` or `-OO` tags.
stock-historic-data 0.1.1
A project to fetch and store historic and live stock data using the Yahoo Finance API.
Requires Python: >=3.6

# Stock Historic Data

This project is designed to fetch and store historic and live stock data using the Yahoo Finance API. The data is stored in SQLite databases and can be accessed via a Flask web application.

## Functionality

For a detailed walkthrough of the project's functionality, you can watch the following YouTube video:

[![Stock Historic Data Functionality](https://img.youtube.com/vi/4hRqNl2Iyz8/0.jpg)](https://www.youtube.com/watch?v=4hRqNl2Iyz8)

### Route: /
- Stock Historic Data Visualization Chart
- Data from Historic Database

![Historic Data Chart](https://github.com/abhiwer/stock_historic_data/blob/main/src/images/HistoricDataChart.png?raw=true)

### Route: /live
- Stock Live Data Visualization and sending data to live_database

![Live Data Chart](https://github.com/abhiwer/stock_historic_data/blob/main/src/images/LiveDataChart.png?raw=true)

### Route: /onlylive
- Only Tick per second Data for Data Visualization 

![Only Live Data Chart](https://github.com/abhiwer/stock_historic_data/blob/main/src/images/OnlyDataLive.png?raw=true)

## Installation

1. Clone the repository:
    ```sh
    git clone https://github.com/abhiwer/stock_historic_data.git
    cd stock_historic_data
    ```

2. Create and activate a virtual environment:
    ```sh
    python -m venv env
    source env/bin/activate  # On Windows use `env\Scripts\activate`
    ```

3. Install the dependencies:
    ```sh
    pip install -r requirements.txt
    ```

## Usage

1. Run the application:
    ```sh
    flask run
    ```

2. Open your browser and navigate to:
    - `http://127.0.0.1:5000/` for Stock Historic Data Visualization Chart
    - `http://127.0.0.1:5000/live` for Stock Live Data Visualization
    - `http://127.0.0.1:5000/onlylive` for Only Tick per second Data Visualization

## Endpoints

- `/`: Main page to view historic data.
- `/live`: Page to view live data.
- `/onlylive`: Page to view only live data.
- `/get_dates`: API to get a range of dates.
- `/get_currencies`: API to get the list of supported currencies.
- `/get_updatetheliveDB`: API to update the live database.
- `/get_updatethehistoricDB`: API to update the historic database.

## License

This project is licensed under the MIT License.

![Alt text](https://github.com/abhiwer/stock_historic_data/blob/main/src/images/OnlyDataLive.png?raw=true)
apres 0.3.23
External bindings for apres MIDI library
Requires Python: >=3.7

# Apres bindings
Python bindings for the Apres MIDI library<br/>
[![PyPI - Downloads](https://img.shields.io/pypi/dw/apres?style=flat-square)](https://pypi.org/project/apres/)
[![PyPI](https://img.shields.io/pypi/v/apres?style=flat-square)](https://pypi.org/project/apres/)
[![License](https://img.shields.io/pypi/l/apres?style=flat-square)](https://burnsomni.net/project/apres_bindings/?branch=master&path=LICENSE)

## Installation
Can be installed through pip
```
pip install apres
```
## Usage Examples
Load a Song
```python
from apres import MIDI
midi = MIDI("/path/to/file.mid")
```

Create a new MIDI
```python
from apres import MIDI
midi = MIDI()
```

Creating a song
```python
from apres import MIDI, NoteOnEvent, NoteOffEvent

# Create an empty MIDI file.
midi = MIDI()

# Press midi note 64 (Middle E) on the first track (0) at the first position (0 ticks)
midi.add_event(NoteOnEvent(channel=0, note=64, velocity=100), tick=0, track=0)

# Release midi note 64 (Middle E) on the first track (0) one beat later (120 ticks)
midi.add_event(NoteOffEvent(channel=0, note=64), wait=120, track=0)

# Save it to a file
midi.save("beep.mid")
```