Skip to content

Commit

Permalink
Merge pull request kubeagi#482 from nkwangleiGIT/main
Browse files Browse the repository at this point in the history
Add ray build file and update readme
  • Loading branch information
nkwangleiGIT authored Jan 2, 2024
2 parents c8518fb + be07bef commit a2fd073
Show file tree
Hide file tree
Showing 9 changed files with 2,072 additions and 33 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codespell.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ jobs:
with:
ignore_words_file: .github/.codespellignore
check_filenames: true
skip: go.*,**/*.drawio,./deploy/charts/*,./config/crd/*
skip: go.*,**/*.drawio,./deploy/charts/*,./config/crd/*,./deploy/llms/*

2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ If you don't have a kubernetes cluster, you can schedule a [kind cluster](https:

Visit our [online documents](http://kubeagi.k8s.com.cn/docs/intro)

Read [user guide](http://kubeagi.k8s.com.cn/docs/UserGuide/intro)

## CLI

We provide a Command Line Tool `arctl` to interact with `arcadia`. See [here](./pkg/arctl/README.md) for more details.
Expand Down
9 changes: 7 additions & 2 deletions apiserver/service/chat.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ import (
"github.com/kubeagi/arcadia/apiserver/pkg/requestid"
)

const (
// Time interval to check if the chat stream should be closed if no more message arrives
WaitTimeoutForChatStreaming = 5
)

// @BasePath /chat

// @Summary chat with application
Expand Down Expand Up @@ -101,14 +106,14 @@ func chatHandler() gin.HandlerFunc {
// Use a ticker to check if there is no data arrived and close the stream
// TODO: check if any better solution for this?
hasData := true
ticker := time.NewTicker(5 * time.Second)
ticker := time.NewTicker(WaitTimeoutForChatStreaming * time.Second)
quit := make(chan struct{})
defer close(quit)
go func() {
for {
select {
case <-ticker.C:
// If there is no generated data within 5 seconds, just close it
// If there is no generated data within WaitTimeoutForChatStreaming seconds, just close it
if !hasData {
close(respStream)
}
Expand Down
4 changes: 2 additions & 2 deletions deploy/charts/arcadia/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: arcadia
description: A Helm chart(KubeBB Component) for KubeAGI Arcadia
type: application
version: 0.1.56
appVersion: "0.0.1"
version: 0.2.1
appVersion: "0.1.0"

keywords:
- LLMOps
Expand Down
10 changes: 5 additions & 5 deletions deploy/charts/arcadia/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ global:
# @param imagePullPolcy ImagePullPolicy
# @param resources Resources to be used
controller:
image: kubeagi/arcadia:v0.1.0-20231219-874e2b1
image: kubeagi/arcadia:v0.1.0-20231230-c8518fb
imagePullPolicy: IfNotPresent
resources:
limits:
Expand All @@ -20,7 +20,7 @@ controller:
# @section graphql and bff server
# related project: https://github.com/kubeagi/arcadia/tree/main/apiserver
apiserver:
image: kubeagi/arcadia:v0.1.0-20231219-874e2b1
image: kubeagi/arcadia:v0.1.0-20231230-c8518fb
enableplayground: false
port: 8081
ingress:
Expand All @@ -38,7 +38,7 @@ apiserver:
portal:
enabled: true
kubebbEnabled: true
image: kubeagi/portal:v0.1.0-20231216-df45bd2
image: kubeagi/portal:v0.1.0-20231229-f7b210e
port: 80
ingress:
path: kubeagi-portal-public
Expand All @@ -48,7 +48,7 @@ portal:
fastchat:
image:
repository: kubeagi/arcadia-fastchat
# Use either v0.1.0 or vllm-v0.1.0(with vllm enabled)
# Use either v0.1.0 or vllm-v0.1.0 (with vllm enabled)
tag: v0.1.0
ingress:
enabled: true
Expand Down Expand Up @@ -113,7 +113,7 @@ chromadb:
# Related project: https://github.com/kubeagi/arcadia/tree/main/data-processing
dataprocess:
enabled: true
image: kubeagi/data-processing:v0.1.0-20231219-874e2b1
image: kubeagi/data-processing:v0.1.0-20231230-c8518fb
port: 28888
config:
llm:
Expand Down
23 changes: 0 additions & 23 deletions deploy/charts/postgre-oci.yaml

This file was deleted.

8 changes: 8 additions & 0 deletions deploy/llms/Dockerfile.fastchat-worker-ray
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
ARG BASE_IMAGE_VERSION="vllm-v0.1.0"
FROM kubeagi/arcadia-fastchat-worker:${BASE_IMAGE_VERSION}

# Allow to use environment variable to set ray & python version to pass the version check
# for now, ray: 2.9.0, python: 3.9.x
# this utils.py file is from ray 2.9.0 ray-ml image
# search 'KubeAGI' in utils.py for what's changed
COPY utils.py /usr/local/lib/python3.9/dist-packages/ray/_private/utils.py
Loading

0 comments on commit a2fd073

Please sign in to comment.