Skip to content

Commit 70c98b6

Browse files
committed
LocalLab Server Package v0.1.1 Released and Updated Docs
1 parent f000896 commit 70c98b6

File tree

6 files changed

+41
-30
lines changed

6 files changed

+41
-30
lines changed

CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# Changelog
22

3-
All notable changes for the version update from 0.0 to 0.1.0.
3+
All notable changes for version updates.
4+
5+
## [0.1.1] - 2024-02-25
6+
7+
### Fixed
8+
9+
- Fixed RuntimeError related to SemLock sharing in multiprocessing by clearing logger handlers in run_server_proc.
10+
- Updated Mermaid diagrams in README.md and docs/colab/README.md to wrap node labels in double quotes, improving compatibility with GitHub rendering.
11+
- Improved build status badge aesthetics in the README.
412

513
## [0.1.0] - 2024-02-23
614

README.md

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -51,39 +51,39 @@ Below is an illustration of LocalLab's architecture:
5151

5252
```mermaid
5353
graph TD;
54-
A[User] --> B[LocalLab Client (Python and Node.js)];
55-
B --> C[LocalLab Server];
56-
C --> D[Model Manager];
57-
D --> E[Hugging Face Models];
54+
A[User] --> B["LocalLab Client (Python and Node.js)"];
55+
B --> C["LocalLab Server"];
56+
C --> D["Model Manager"];
57+
D --> E["Hugging Face Models"];
5858
C --> F[Optimizations];
59-
C --> G[Resource Monitoring];
59+
C --> G["Resource Monitoring"];
6060
```
6161

6262
### Model Loading & Optimization Flow
6363

6464
```mermaid
6565
graph TD;
66-
A[Load Model Request] --> B{Check Resources};
67-
B -->|Sufficient| C[Load Model];
68-
B -->|Insufficient| D[Apply Optimizations];
66+
A["Load Model Request"] --> B[{"Check Resources"}];
67+
B -->|Sufficient| C["Load Model"];
68+
B -->|Insufficient| D["Apply Optimizations"];
6969
D --> E[Quantization];
70-
D --> F[Attention Slicing];
71-
D --> G[CPU Offloading];
72-
E & F & G --> H[Load Optimized Model];
73-
C & H --> I[Ready for Inference];
70+
D --> F["Attention Slicing"];
71+
D --> G["CPU Offloading"];
72+
E & F & G --> H["Load Optimized Model"];
73+
C & H --> I["Ready for Inference"];
7474
```
7575

7676
### Resource Management Flow
7777

7878
```mermaid
7979
graph TD;
80-
A[Client Request] --> B[Resource Monitor];
81-
B --> C{Check Resources};
82-
C -->|OK| D[Process Request];
83-
C -->|Low Memory| E[Optimize/Unload];
84-
C -->|GPU Full| F[CPU Fallback];
85-
E & F --> G[Continue Processing];
86-
D & G --> H[Return Response];
80+
A["Client Request"] --> B["Resource Monitor"];
81+
B --> C[{"Check Resources"}];
82+
C -->|OK| D["Process Request"];
83+
C -->|Low Memory| E["Optimize/Unload"];
84+
C -->|GPU Full| F["CPU Fallback"];
85+
E & F --> G["Continue Processing"];
86+
D & G --> H["Return Response"];
8787
```
8888

8989
## Google Colab Workflow
@@ -92,9 +92,9 @@ When deploying on Google Colab, LocalLab uses ngrok to create a public tunnel. T
9292

9393
```mermaid
9494
sequenceDiagram
95-
participant U as User (Colab)
96-
participant S as LocalLab Server
97-
participant N as Ngrok Tunnel
95+
participant U as "User (Colab)"
96+
participant S as "LocalLab Server"
97+
participant N as "Ngrok Tunnel"
9898
U->>S: Run start_server(ngrok=True)
9999
S->>N: Establish public tunnel
100100
N->>U: Return public URL

docs/colab/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@ The fastest way to get started is to use our [Interactive Colab Guide](./localla
4040

4141
```mermaid
4242
graph TD;
43-
A[User] --> B[LocalLab Client (Python and Node.js)];
44-
B --> C[LocalLab Server];
45-
C --> D[Model Manager];
46-
D --> E[Hugging Face Models];
43+
A[User] --> B["LocalLab Client (Python and Node.js)"];
44+
B --> C["LocalLab Server"];
45+
C --> D["Model Manager"];
46+
D --> E["Hugging Face Models"];
4747
C --> F[Optimizations];
48-
C --> G[Resource Monitoring];
48+
C --> G["Resource Monitoring"];
4949
```

locallab/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
LocalLab - A lightweight AI inference server
33
"""
44

5-
__version__ = "0.1.0"
5+
__version__ = "0.1.1"
66

77
from typing import Dict, Any, Optional
88

locallab/main.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -688,6 +688,9 @@ def run_server_proc(log_queue):
688688
sys.stdout = log_writer
689689
sys.stderr = log_writer
690690

691+
# Clear any existing logger handlers to avoid sharing SemLocks from a fork context
692+
logger.handlers.clear()
693+
691694
# Attach a logging handler to send log messages to the queue
692695
handler = logging.StreamHandler(log_writer)
693696
handler.setFormatter(logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s'))

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
setup(
77
name="locallab",
8-
version="0.1.0",
8+
version="0.1.1",
99
packages=find_packages(include=["locallab", "locallab.*"]),
1010
install_requires=[
1111
"fastapi>=0.68.0,<1.0.0",

0 commit comments

Comments
 (0)