The official Python SDK for hDeepSeek Private AI.
Project description
hSeek Python SDK (hseek)
The official Python SDK for Hussain's Private AI Bridge (hDeepSeek).
Features
- Ultra-simple Initialization: Automatically loads your API key from
.env. - Auto-Memory Management: Just pass a
session_idstring and the SDK handles the rest. - Full Control: Toggle
thinkingandsearchon a per-message basis. - Async & Sync Support: Built-in
ClientandAsyncClient. - Streaming Support: Real-time character-by-character output via
.stream_chat().
Installation
pip install hseek-api
Quick Start
Make sure you have a .env file with your secret key:
MY_SECRET_API_KEY=your_super_secret_key_here
Basic Example (Sync)
from hseek import Client
ai = Client()
response = ai.chat(
"Hello! How are you?",
session_id="user_123",
thinking=True
)
print(response.text)
# If thinking=True, you can also print(response.thinking_text)
Streaming Example (Async)
import asyncio
from hseek import AsyncClient
async def main():
ai = AsyncClient()
async for chunk in ai.stream_chat("Write a long story.", session_id="user_123"):
# chunk is an HSeekResponse object that updates in real-time
print(chunk.text, end="", flush=True)
asyncio.run(main())
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
hseek_api-1.1.0.tar.gz
(7.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file hseek_api-1.1.0.tar.gz.
File metadata
- Download URL: hseek_api-1.1.0.tar.gz
- Upload date:
- Size: 7.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6f91577e6bc880af64276474158612b2d1513c8f3b2bc58fb029c02a8b06c611
|
|
| MD5 |
fb15d8479eb07d5f744218737ec2c250
|
|
| BLAKE2b-256 |
abeabac1c874a92bebfb0ac63b422c5ad795346736bbc6246cf1814ea0608c71
|
File details
Details for the file hseek_api-1.1.0-py3-none-any.whl.
File metadata
- Download URL: hseek_api-1.1.0-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b017327441f027dc330c31320758d6fb4607eb29e5d2b0b96ac5c059cdbf7f0
|
|
| MD5 |
9f3ab3b7be54af805a7b20dd70b68478
|
|
| BLAKE2b-256 |
656efc48b0062c3ce81f9e9907a00993fd169dc9b62da59bfa7e4a599ef860ea
|