Go to file
Kelvin Chiu b185161aa9
fix: set default value for the message owner (#597)
2023-07-23 09:38:52 +08:00
.github ci: add crowdin configuration file and i18n files (#595) 2023-07-22 21:10:14 +08:00
ai feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
assets docs: created a draft version of README.md (#7) 2023-06-23 15:10:16 +08:00
casdoor feat: add Github CI (#590) 2023-07-22 10:17:17 +08:00
conf ci: fix crowdin configs 2023-07-22 12:39:01 +08:00
controllers Add getDefaultModelProvider() 2023-07-22 23:22:38 +08:00
i18n ci: add crowdin configuration file and i18n files (#595) 2023-07-22 21:10:14 +08:00
object Add getDefaultModelProvider() 2023-07-22 23:22:38 +08:00
proxy feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
routers feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
storage feat: add Github CI (#590) 2023-07-22 10:17:17 +08:00
util feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
video feat: add Github CI (#590) 2023-07-22 10:17:17 +08:00
web fix: set default value for the message owner (#597) 2023-07-23 09:38:52 +08:00
xlsx Add license headers 2023-07-16 12:51:52 +08:00
.gitignore Add base code. 2023-06-22 16:01:56 +08:00
.releaserc.json feat: add CI (#593) 2023-07-22 18:42:02 +08:00
LICENSE Initial commit 2023-06-22 15:46:47 +08:00
README.md ci: fix crowdin configs 2023-07-22 12:39:01 +08:00
go.mod feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
go.sum feat: add chat page (#589) 2023-07-22 11:14:07 +08:00
main.go feat: add chat page (#589) 2023-07-22 11:14:07 +08:00

README.md

📦 Casibase

A pioneering customizable open-source Domain Knowledge Base (DKB) powered by ChatGPT, Casbin, and Casdoor.

semantic-release docker pull casbin/casibase GitHub Workflow Status (branch) GitHub Release Docker Image Version (latest semver)

Go Report Card license GitHub issues GitHub stars GitHub forks Crowdin Discord

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

0-Architecture-casibase

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

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 Organization1-Add-organization

  • Configure information about the Organization2-Configure-information-organization

  • Add a member to a newly created organization3-Check-user4-Add-member-to-organization

  • Configure member information (remember its Name as well as Password)5-Configure-new-user

  • Create a new Application6-Add-application

  • Configuring Application Information (Remember Name, ClientID and ClientSecret. Change RedirectURLs to http://localhost:14000/callback)7-Configure-new-application

casibase configuration

Get the code

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

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)

    clientId = <Your_clientId_in_Casdoor_configuration>
    clientSecret = <Your_clientSecret_in_Casdoor_configuration>
    casdoorDbName = casdoor
    casdoorOrganization = "casibase"
    casdoorApplication = "app-casibase"
    
  • Frontend (casibase\web\src\Conf.js)

    export const AuthConfig = {
      ......
      clientId: <Your_clientId_in_Casdoor_configuration>,
      ......
    };
    

Run casnode

  • Backend (casibase)

    go run main.go
    
  • Frontend (casibase\web)

    yarn install
    yarn start
    

Preview

Access the login view via the following link:

http://localhost:13001

8-Preview-base-wordsets

9-Preview-casibase-stores

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