https://github.com/l2nce/casibase
Domain knowledge database powered by ChatGPT, Casbin and Casdoor
https://github.com/l2nce/casibase
Last synced: 2 months ago
JSON representation
Domain knowledge database powered by ChatGPT, Casbin and Casdoor
- Host: GitHub
- URL: https://github.com/l2nce/casibase
- Owner: L2ncE
- License: apache-2.0
- Created: 2023-06-23T13:55:02.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2023-06-26T06:40:15.000Z (almost 2 years ago)
- Last Synced: 2025-03-20T08:11:38.847Z (2 months ago)
- Language: JavaScript
- Homepage: https://ai.casbin.com
- Size: 1.86 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
📦⚡️ Casibase
A pioneering customizable open-source Domain Knowledge Base (DKB)
powered by ChatGPT, Casbin, and Casdoor.
## Architecture
casibase contains 4 parts:
| **Name** | **Description** | **Language** |
| -------------- | ------------------------------------------------- | --------------------------------------- |
| Frontend | User interface for the casibase application | JavaScript + React |
| Backend | Server-side logic and API for casibase | Golang + Beego + Python + Flask + MySQL |
| AI Model | Artificial intelligence model | Python + OpenAI |
| Knowledge Base | Storage for casibase application domain knowledge | pgvector |
## Demo Installation
casibase uses Casdoor to manage members. So you need to create an organization and an application for casibase in a Casdoor instance.
### Casdoor configuration
```shell
git clone https://github.com/casdoor/casdoor.git
```refer to: https://casdoor.org/docs/basic/server-installation
Follow these steps to setup Casdoor for casibase:
- Create an **Organization**
- Configure information about the **Organization**
- Add a member to a newly created organization
- Configure member information (remember its **Name** as well as **Password**)
- Create a new **Application**
- Configuring **Application** Information (Remember **Name, ClientID** and **ClientSecret**. Change **RedirectURLs** to http://localhost:14000/callback)
### casibase configuration
#### Get the code
```shell
git clone https://github.com/casbin/casibase.git
```#### Setup database
casibase will store its users, nodes and topics informations in a MySQL database named: `casibase`, will create it if not existed. The DB connection string can be specified at: https://github.com/casbin/casibase/blob/master/conf/app.conf
```ini
dataSourceName = root:123@tcp(localhost:3306)/
```Casnode uses XORM to connect to DB, so all DBs supported by XORM can also be used.
#### Custom config
- #### Backend (`casibase\conf\app.conf`)
```ini
clientId =
clientSecret =
casdoorDbName = casdoor
casdoorOrganization = "casibase"
casdoorApplication = "app-casibase"
```- #### Frontend (`casibase\web\src\Conf.js`)
```ini
export const AuthConfig = {
......
clientId: ,
......
};
```#### Run casnode
- #### Backend (`casibase`)
```shell
go run main.go
```- #### Frontend (`casibase\web`)
```shell
yarn install
yarn start
```#### Preview
Access the login view via the following link:
```shell
http://localhost:13001
```

The **casibase** demo is shown above, and in the future users can upload various **knowledge** files, **wordsets**, and **vectorsets** to achieve a **customized domain knowledge base**.