Skip to content

Commit e6499c7

Browse files
committed
feat: merge main
2 parents dae8d6c + d84ad62 commit e6499c7

File tree

115 files changed

+10530
-9843
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+10530
-9843
lines changed

.env.example

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,14 @@
1-
SUPABASE_URL=http://localhost:8000
2-
SUPABASE_API_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyAgCiAgICAicm9sZSI6ICJhbm9uIiwKICAgICJpc3MiOiAic3VwYWJhc2UtZGVtbyIsCiAgICAiaWF0IjogMTY0MTc2OTIwMCwKICAgICJleHAiOiAxNzk5NTM1NjAwCn0.dc_X5iR_VP_qT0zsiyj_I_OZ2T9FtRU2BBNWN8Bu4GE
1+
# Supabase Configures
2+
SUPABASE_URL=supabase_url
3+
SUPABASE_SERVICE_KEY=supabase_service_key
4+
5+
# OPTIONAL - Github Apps Configures
6+
X_GITHUB_APP_ID=github_app_id
7+
X_GITHUB_APPS_CLIENT_ID=github_apps_client_id
8+
X_GITHUB_APPS_CLIENT_SECRET=github_apps_client_secret
9+
10+
# OpenAI API KEY
11+
OPENAI_API_KEY=openapi_api_key
12+
13+
# Tavily Api Key
14+
TAVILY_API_KEY=tavily_api_key

.github/workflows/aws-preview.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,15 @@ jobs:
3939
- run: sam build --use-container --config-file .aws/petercat-preview.toml
4040

4141
# Prevent prompts and failure when the stack is unchanged
42-
- run: sam deploy --no-confirm-changeset --no-fail-on-empty-changeset --config-file .aws/petercat-preview.toml
42+
- run: |
43+
sam deploy \
44+
--no-confirm-changeset \
45+
--no-fail-on-empty-changeset \
46+
--config-file .aws/petercat-preview.toml \
47+
--parameter-overrides GitHubAppID=${{ secrets.X_GITHUB_APP_ID }} \
48+
GithubAppsClientId=${{ secrets.X_GITHUB_APPS_CLIENT_ID }} \
49+
GithubAppsClientSecret=${{ secrets.X_GITHUB_APPS_CLIENT_SECRET }} \
50+
OpenAIAPIKey=${{ secrets.OPENAI_API_KEY }} \
51+
SupabaseServiceKey=${{ secrets.SUPABASE_SERVICE_KEY }} \
52+
SupabaseUrl=${{ secrets.SUPABASE_URL }} \
53+
TavilyAPIKey=${{ secrets.TAVILY_API_KEY }}

.github/workflows/aws-prod.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,15 @@ jobs:
3535
- run: sam build --use-container --config-file .aws/petercat-prod.toml
3636

3737
# Prevent prompts and failure when the stack is unchanged
38-
- run: sam deploy --no-confirm-changeset --no-fail-on-empty-changeset --config-file .aws/petercat-prod.toml
38+
- run: |
39+
sam deploy \
40+
--no-confirm-changeset \
41+
--no-fail-on-empty-changeset \
42+
--config-file .aws/petercat-prod.toml \
43+
--parameter-overrides GitHubAppID=${{ secrets.X_GITHUB_APP_ID }} \
44+
GithubAppsClientId=${{ secrets.X_GITHUB_APPS_CLIENT_ID }} \
45+
GithubAppsClientSecret=${{ secrets.X_GITHUB_APPS_CLIENT_SECRET }} \
46+
OpenAIAPIKey=${{ secrets.OPENAI_API_KEY }} \
47+
SupabaseServiceKey=${{ secrets.SUPABASE_SERVICE_KEY }} \
48+
SupabaseUrl=${{ secrets.SUPABASE_URL }} \
49+
TavilyAPIKey=${{ secrets.TAVILY_API_KEY }}

.gitignore

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,22 @@
22
__pycache__/
33
*.pyc
44
# dependencies
5-
/node_modules
6-
/.pnp
7-
.pnp.js
5+
node_modules/
86

97
server/temp/
108

9+
venv
10+
1111
# testing
1212
/coverage
1313

1414
# next.js
15-
/.next/
16-
/out/
15+
.next/
16+
out/
17+
1718

1819
# production
19-
/build
20+
build
2021

2122
# misc
2223
.DS_Store
@@ -26,6 +27,7 @@ server/temp/
2627
npm-debug.log*
2728
yarn-debug.log*
2829
yarn-error.log*
30+
.yarnrc.yml
2931

3032
# local env files
3133
.env*.local

.vercelignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
docker/
22
lui/
3+
server/

bin/act

-16.5 MB
Binary file not shown.

client/.env.example

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
SELF_PATH=/client/
2+
SUPABASE_URL=http://localhost:8000
3+
SUPABASE_API_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyAgCiAgICAicm9sZSI6ICJhbm9uIiwKICAgICJpc3MiOiAic3VwYWJhc2UtZGVtbyIsCiAgICAiaWF0IjogMTY0MTc2OTIwMCwKICAgICJleHAiOiAxNzk5NTM1NjAwCn0.dc_X5iR_VP_qT0zsiyj_I_OZ2T9FtRU2BBNWN8Bu4GE
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

app/page.tsx renamed to client/app/page.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ import { Assistant } from 'petercat-lui';
1010

1111
declare type Bot = Tables<'bots'>;
1212

13+
const ASSISTANT_API_HOST = process.env.NEXT_PUBLIC_ASSISTANT_API_HOST;
14+
1315
export default function Home() {
1416
const { data: bots, isLoading, error } = useBotList();
1517
if (isLoading) {
@@ -21,7 +23,7 @@ export default function Home() {
2123

2224
return (
2325
<div>
24-
<Assistant host="https://api.petercat.chat" />
26+
<Assistant host={ASSISTANT_API_HOST} />
2527

2628
<div className="container mx-auto max-w-[1024px]">
2729
<div className="mt-8">
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

next.config.js renamed to client/next.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
// module.exports = withBundleAnalyzer({})
55

66
module.exports = {
7+
...process.env.NEXT_STANDALONE ? { output: "standalone" } :{},
78
webpack: (config) => {
89
config.resolve.fallback = { http: false, https: false, net: false, tls: false };
910

client/package.json

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
{
2+
"name": "bot-meta",
3+
"version": "0.0.0",
4+
"private": true,
5+
"scripts": {
6+
"bootstrap": "yarn",
7+
"dev": "next dev",
8+
"build": "next build",
9+
"build:docker": "docker build -t bot-meta .",
10+
"start": "next start",
11+
"lint": "next lint",
12+
"format": "prettier --write \"app\""
13+
},
14+
"engines": {
15+
"node": ">=18"
16+
},
17+
"dependencies": {
18+
"@auth0/nextjs-auth0": "^3.3.0",
19+
"@next/bundle-analyzer": "^13.4.19",
20+
"@nextui-org/react": "^2.2.9",
21+
"@supabase/supabase-js": "^2.32.0",
22+
"@tanstack/react-query": "^5.17.19",
23+
"@types/node": "20.4.5",
24+
"@types/react": "18.2.17",
25+
"@types/react-dom": "18.2.7",
26+
"ai": "^2.1.28",
27+
"autoprefixer": "10.4.14",
28+
"axios": "^1.6.7",
29+
"concurrently": "^8.2.2",
30+
"dayjs": "^1.11.10",
31+
"petercat-lui": "^0.0.4",
32+
"eslint": "8.46.0",
33+
"eslint-config-next": "13.4.12",
34+
"framer-motion": "^10.16.15",
35+
"https-proxy-agent": "^7.0.2",
36+
"immer": "^10.0.3",
37+
"langchain": "^0.0.187",
38+
"lodash": "^4.17.21",
39+
"next": "14.0.1",
40+
"openai": "^4.24.7",
41+
"postcss": "8.4.27",
42+
"react": "18.2.0",
43+
"react-dom": "18.2.0",
44+
"react-toastify": "^9.1.3",
45+
"tailwindcss": "3.3.3",
46+
"typescript": "5.1.6",
47+
"use-immer": "^0.9.0",
48+
"zod": "^3.22.3",
49+
"zod-to-json-schema": "^3.21.4"
50+
},
51+
"devDependencies": {
52+
"@svgr/webpack": "^8.1.0",
53+
"@types/lodash": "^4.14.202",
54+
"prettier": "3.0.0"
55+
},
56+
"repository": "https://github.com/ant-xuexiao/bot-combo.git"
57+
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

tailwind.config.js renamed to client/tailwind.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
const {nextui} = require("@nextui-org/react");
33
module.exports = {
44
content: [
5-
'./pages/**/*.{js,ts,jsx,tsx,mdx}',
5+
'./app/pages/**/*.{js,ts,jsx,tsx,mdx}',
66
'./components/**/*.{js,ts,jsx,tsx,mdx}',
77
'./app/**/*.{js,ts,jsx,tsx,mdx}',
88
"./node_modules/@nextui-org/theme/dist/**/*.{js,ts,jsx,tsx}",
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)