Skip to content

Commit 8e041e2

Browse files
STY: Add docstrings, fix formatting
1 parent 7b425f9 commit 8e041e2

File tree

13 files changed

+903
-15
lines changed

13 files changed

+903
-15
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,19 +66,19 @@ This guide will help you set up your environment to contribute to the `siren-ai`
6666
```
6767
6868
5. **Set up pre-commit hooks:**
69-
(Ensures code quality before commits. Run from the activated environment or use `uv run ...`)
69+
(Ensures code quality before commits)
7070
```bash
71-
pre-commit install
71+
uv run pre-commit install
7272
```
7373
You can also run all hooks manually:
7474
```bash
75-
pre-commit run --all-files
75+
uv run pre-commit run --all-files
7676
```
7777
7878
6. **Run tests:**
79-
(Verify the setup and SDK functionality. Run from the activated environment or use `uv run ...`)
79+
(Verify the setup and SDK functionality)
8080
```bash
81-
pytest
81+
uv run pytest
8282
```
8383
8484
7. **Start developing!**

examples/basic_usage.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
1+
"""Basic usage examples for the Siren SDK."""
2+
13
# examples/basic_usage.py
24

35
# This file will demonstrate basic usage of the SirenClient.
46

57
# from siren import SirenClient # This will work once the package is installed
68

79
# For local development, you might need to adjust sys.path:
8-
import sys
910
import os
10-
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
11+
import sys
12+
13+
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), "..")))
1114

1215
from siren.client import SirenClient
1316

1417
if __name__ == "__main__":
1518
print("Running Siren SDK basic usage example...")
16-
19+
1720
# Replace 'YOUR_API_KEY' with a real or test API key
1821
api_key = "YOUR_API_KEY"
1922
if api_key == "YOUR_API_KEY":

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ ignore = [
100100
"D212", # Conflicts with D213 (pydocstyle: Multi-line docstring summary should start at the first line)
101101
# "D100", # Missing docstring in public module
102102
# "D104", # Missing docstring in public package
103+
"E501", # Line too long (handled by formatter)
103104
]
104105
fixable = ["ALL"]
105106

siren/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Siren SDK for Python."""
2+
13
# siren/__init__.py
24

35
# This file makes the 'siren' directory a Python package.
@@ -7,4 +9,4 @@
79
# from .client import SirenClient
810
# from .templates import TemplateManager
911

10-
__version__ = "0.1.0" # Placeholder version
12+
__version__ = "0.1.0" # Placeholder version

siren/client.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
"""Siren API client implementation."""
2+
13
# siren/client.py
24

5+
36
class SirenClient:
7+
"""Client for interacting with the Siren API."""
8+
49
def __init__(self, api_key: str):
10+
"""Initialize the SirenClient.
11+
12+
Args:
13+
api_key: The API key for authentication.
14+
"""
515
self.api_key = api_key
616
# We will add base_url and other configurations later
717
print(f"SirenClient initialized with API key: {api_key[:5]}...")

siren/formatter.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Data formatting utilities for Siren SDK."""
2+
13
# siren/formatter.py
24

35
# This module will handle the format_for_human functionality.

siren/templates.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Template management for Siren SDK."""
2+
13
# siren/templates.py
24

35
# This module will handle template-related functionalities.

siren/utils.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Utility functions for the Siren SDK."""
2+
13
# siren/utils.py
24

35
# This module will contain utility functions for the SDK.

siren/webhooks.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Webhook handling for Siren SDK."""
2+
13
# siren/webhooks.py
24

35
# This module will handle webhook configurations and processing.

siren/workflows.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""Workflow management for Siren SDK."""
2+
13
# siren/workflows.py
24

35
# This module will handle workflow-related functionalities.

0 commit comments

Comments
 (0)