-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: kerthcet <[email protected]>
- Loading branch information
Showing
24 changed files
with
1,131 additions
and
2,597 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: Initialization Workflow | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
init: | ||
uses: kerthcet/github-workflow-as-kube/.github/workflows/[email protected] | ||
secrets: | ||
AGENT_TOKEN: ${{ secrets.AGENT_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Event Workflow | ||
|
||
on: | ||
issues: | ||
types: | ||
- opened | ||
issue_comment: | ||
types: | ||
- created | ||
pull_request_target: | ||
types: | ||
- opened | ||
- synchronize | ||
- labeled | ||
- unlabeled | ||
|
||
jobs: | ||
event-handler: | ||
uses: kerthcet/github-workflow-as-kube/.github/workflows/[email protected] | ||
secrets: | ||
AGENT_TOKEN: ${{ secrets.AGENT_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
FROM python:3.10-slim | ||
|
||
RUN mkdir -p /app/llmaz | ||
RUN mkdir -p /app/llmboard | ||
WORKDIR /app | ||
|
||
COPY requirements.txt . | ||
RUN python -m pip install --upgrade pip && \ | ||
pip install -r requirements.txt | ||
|
||
COPY main.py . | ||
COPY llmaz/ ./llmaz | ||
COPY llmboard/ ./llmboard | ||
|
||
EXPOSE 7860 | ||
CMD ["python", "main.py"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,7 @@ | ||
# Console for LLMAZ | ||
# ChatUI for LLMs on llmaz | ||
|
||
A dashboard for [llmaz](https://github.com/InftyAI/llmaz) to interact with LLM workloads. | ||
A console for [llmaz](https://github.com/InftyAI/llmaz) to interact with LLM workloads. | ||
|
||
## How to deploy | ||
|
||
Run `make launch` then visit `http://localhost:7860` for Console. | ||
|
||
![console](./docs/asserts/preview.jpg) | ||
|
||
## 👏 Contributors | ||
|
||
Thanks to all these contributors. You're the heroes. | ||
|
||
<a href="https://github.com/InftyAI/llmaz-webui/graphs/contributors"> | ||
<img src="https://contrib.rocks/image?repo=InftyAI/llmaz-webui" /> | ||
</a> |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# GVKs | ||
group = "llmaz.io" | ||
version = "v1alpha1" | ||
openmodel_plural = "openmodels" | ||
|
||
# object label keys. | ||
label_key_family_name = "llmaz.io/model-family-name" | ||
label_key_model_name = "llmaz.io/model-name" | ||
|
||
# Model hubs. | ||
huggingface = "Huggingface" | ||
modelscope = "ModelScope" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from dataclasses import dataclass | ||
|
||
|
||
@dataclass(frozen=True) | ||
class InferenceService: | ||
name: str | ||
namespace: str | ||
model_family_name: str | ||
model_name: str |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from kubernetes import client | ||
from kubernetes.client import CustomObjectsApi | ||
|
||
from llmboard.libs.consts import group, version, openmodel_plural | ||
|
||
|
||
def get_openmodel_objects(api: CustomObjectsApi, namespace: None): | ||
try: | ||
if namespace: | ||
# TODO: we do not support namespaced models yet. | ||
raise NotImplementedError("do not support namespaced models yet") | ||
else: | ||
response = api.list_cluster_custom_object( | ||
group=group, | ||
version=version, | ||
plural=openmodel_plural, | ||
) | ||
return response.get("items", []) | ||
except client.exceptions.ApiException as e: | ||
print(f"Error fetching OpenModel objects: {e}") | ||
return [] |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
from kubernetes import config | ||
from llmboard.libs.models import get_openmodel_objects | ||
|
||
|
||
class Engine: | ||
def __init__(self) -> None: | ||
# config.load_incluster_config() | ||
pass | ||
|
||
def get_models(self): | ||
# objs = get_openmodel_objects() | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import gradio as gr | ||
|
||
from llmboard.webui.engine import Engine | ||
from llmboard.webui.webui_chat import create_chat_webui | ||
from llmboard.webui.webui_market import create_market_webui | ||
|
||
|
||
def launch_webui() -> gr.Blocks: | ||
engine = Engine() | ||
|
||
with gr.Blocks(title="llmboard") as blocks: | ||
# TODO: Model Market Tab, list and create serving services. | ||
# create_market_webui(engine) | ||
# Serving Tab | ||
create_chat_webui(engine) | ||
|
||
return blocks |
Oops, something went wrong.