Skip to content

Commit bc9c2bd

Browse files
KfreeZzhlsunshine
andauthored
Add Codegen example for GMC (#60)
* add codegen example for GMC Signed-off-by: KfreeZ <[email protected]> * move chatQnA resource to chatqa namespace Signed-off-by: KfreeZ <[email protected]> --------- Signed-off-by: KfreeZ <[email protected]> Co-authored-by: Steve Zhang <[email protected]>
1 parent 019272a commit bc9c2bd

File tree

2 files changed

+72
-23
lines changed

2 files changed

+72
-23
lines changed

microservices-connector/config/samples/chatQnA_v2.yaml

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ metadata:
88
app.kubernetes.io/name: gmconnector
99
app.kubernetes.io/managed-by: kustomize
1010
name: chatqa
11-
namespace: gmcsample
11+
namespace: chatqa
1212
spec:
1313
routerConfig:
1414
name: router
15-
nameSpace: gmcsample
15+
nameSpace: chatqa
1616
serviceName: router-service
1717
config:
18-
no_proxy: ".gmcsample.svc.cluster.local"
18+
no_proxy: ".chatqa.svc.cluster.local"
1919
http_proxy: http://child-jf.intel.com:912
2020
https_proxy: http://child-jf.intel.com:912
2121
nodes:
@@ -24,20 +24,20 @@ spec:
2424
steps:
2525
- name: Embedding
2626
internalService:
27-
nameSpace: gmcsample
27+
nameSpace: chatqa
2828
serviceName: embedding-service
2929
config:
30-
no_proxy: ".gmcsample.svc.cluster.local"
30+
no_proxy: ".chatqa.svc.cluster.local"
3131
http_proxy: http://child-jf.intel.com:912
3232
https_proxy: http://child-jf.intel.com:912
33-
tei_endpoint: "http://tei-embedding-service.gmcsample.svc.cluster.local:6006"
33+
tei_endpoint: "http://tei-embedding-service.chatqa.svc.cluster.local:6006"
3434
endpoint: /v1/embeddings
3535
- name: TeiEmbedding
3636
internalService:
37-
nameSpace: gmcsample
37+
nameSpace: chatqa
3838
serviceName: tei-embedding-service
3939
config:
40-
no_proxy: ".gmcsample.svc.cluster.local"
40+
no_proxy: ".chatqa.svc.cluster.local"
4141
http_proxy: http://child-jf.intel.com:912
4242
https_proxy: http://child-jf.intel.com:912
4343
gmcTokenSecret: gmc-tokens
@@ -48,39 +48,39 @@ spec:
4848
- name: Retriever
4949
data: $response
5050
internalService:
51-
nameSpace: gmcsample
51+
nameSpace: chatqa
5252
serviceName: retriever-redis-server
5353
config:
54-
no_proxy: ".gmcsample.svc.cluster.local"
54+
no_proxy: ".chatqa.svc.cluster.local"
5555
http_proxy: http://child-jf.intel.com:912
5656
https_proxy: http://child-jf.intel.com:912
57-
RedisUrl: redis://redis-vector-db.gmcsample.svc.cluster.local:6379
57+
RedisUrl: redis://redis-vector-db.chatqa.svc.cluster.local:6379
5858
IndexName: rag-redis
59-
tei_endpoint: "http://tei-embedding-service.gmcsample.svc.cluster.local:6006"
59+
tei_endpoint: "http://tei-embedding-service.chatqa.svc.cluster.local:6006"
6060
endpoint: /v1/retrieval
6161
- name: VectorDB
6262
internalService:
63-
nameSpace: gmcsample
63+
nameSpace: chatqa
6464
serviceName: redis-vector-db
6565
isDownstreamService: true
6666
- name: Reranking
6767
data: $response
6868
internalService:
69-
nameSpace: gmcsample
69+
nameSpace: chatqa
7070
serviceName: reranking-service
7171
config:
72-
no_proxy: ".gmcsample.svc.cluster.local"
72+
no_proxy: ".chatqa.svc.cluster.local"
7373
http_proxy: http://child-jf.intel.com:912
7474
https_proxy: http://child-jf.intel.com:912
75-
tei_reranking_endpoint: http://tei-reranking-service.gmcsample.svc.cluster.local:8808
75+
tei_reranking_endpoint: http://tei-reranking-service.chatqa.svc.cluster.local:8808
7676
gmcTokenSecret: gmc-tokens
7777
endpoint: /v1/reranking
7878
- name: TeiReranking
7979
internalService:
80-
nameSpace: gmcsample
80+
nameSpace: chatqa
8181
serviceName: tei-reranking-service
8282
config:
83-
no_proxy: ".gmcsample.svc.cluster.local"
83+
no_proxy: ".chatqa.svc.cluster.local"
8484
http_proxy: http://child-jf.intel.com:912
8585
https_proxy: http://child-jf.intel.com:912
8686
gmcTokenSecret: gmc-tokens
@@ -91,21 +91,21 @@ spec:
9191
- name: Llm
9292
data: $response
9393
internalService:
94-
nameSpace: gmcsample
94+
nameSpace: chatqa
9595
serviceName: llm-service
9696
config:
97-
no_proxy: "tgi-service.gmcsample.svc.cluster.local"
97+
no_proxy: ".chatqa.svc.cluster.local"
9898
http_proxy: http://child-jf.intel.com:912
9999
https_proxy: http://child-jf.intel.com:912
100-
tgi_endpoint: http://tgi-service.gmcsample.svc.cluster.local:9009
100+
tgi_endpoint: http://tgi-service.chatqa.svc.cluster.local:9009
101101
gmcTokenSecret: gmc-tokens
102102
endpoint: /v1/chat/completions
103103
- name: Tgi
104104
internalService:
105-
nameSpace: gmcsample
105+
nameSpace: chatqa
106106
serviceName: tgi-service
107107
config:
108-
no_proxy: "tgi-service.gmcsample.svc.cluster.local"
108+
no_proxy: ".chatqa.svc.cluster.local"
109109
http_proxy: http://child-jf.intel.com:912
110110
https_proxy: http://child-jf.intel.com:912
111111
gmcTokenSecret: gmc-tokens
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Copyright (C) 2024 Intel Corporation
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
apiVersion: gmc.opea.io/v1alpha3
5+
kind: GMConnector
6+
metadata:
7+
labels:
8+
app.kubernetes.io/name: gmconnector
9+
app.kubernetes.io/managed-by: kustomize
10+
name: codegen
11+
namespace: codegen
12+
spec:
13+
routerConfig:
14+
name: router
15+
nameSpace: codegen
16+
serviceName: router-service
17+
config:
18+
no_proxy: ".codegen.svc.cluster.local"
19+
http_proxy: http://child-jf.intel.com:912
20+
https_proxy: http://child-jf.intel.com:912
21+
nodes:
22+
root:
23+
routerType: Sequence
24+
steps:
25+
- name: Llm
26+
data: $response
27+
internalService:
28+
nameSpace: codegen
29+
serviceName: llm-service
30+
config:
31+
no_proxy: ".codegen.svc.cluster.local"
32+
http_proxy: http://child-jf.intel.com:912
33+
https_proxy: http://child-jf.intel.com:912
34+
tgi_endpoint: http://tgi-service.codegen.svc.cluster.local:9009
35+
gmcTokenSecret: gmc-tokens
36+
endpoint: /v1/chat/completions
37+
- name: Tgi
38+
internalService:
39+
nameSpace: codegen
40+
serviceName: tgi-service
41+
config:
42+
no_proxy: ".codegen.svc.cluster.local"
43+
http_proxy: http://child-jf.intel.com:912
44+
https_proxy: http://child-jf.intel.com:912
45+
gmcTokenSecret: gmc-tokens
46+
hostPath: /root/GMC/data/tgi
47+
modelId: ise-uiuc/Magicoder-S-DS-6.7B
48+
endpoint: /generate
49+
isDownstreamService: true

0 commit comments

Comments
 (0)