Skip to content

Web interface of an AI copilot based on GPT. Built in NextJs

License

Notifications You must be signed in to change notification settings

dayo4/web_ai_assistant

Repository files navigation

A web-based AI copilot powered by GPT. Fully built in Next.js.

Demo

You can check out the live web app here :

Tech stacks · Installation · Run Locally · Authors


Tech stacks

Installation

  1. Clone the repo

    git clone https://github.com/dayo4/web_ai_assistant.git
  2. Install dependencies

    yarn install
  3. Setup your supabase project

    • You'll first need a Supabase project which can be made via the Supabase dashboard
    • Run the following snippet in your project's SQL Editor
        create table profiles (
          id uuid default uuid_generate_v4() primary key,
          updated_at timestamp default now(),
          username text,
          full_name text,
          avatar_url text,
          website text
        );
      
        create table apps (
          id uuid default uuid_generate_v4() primary key,
          name text not null,
          description text,
          createdAt timestamp default now(),
          updatedAt timestamp default now(),
          slug text not null,
          logoUrl text
        );
      
        create table chats (
          id uuid default uuid_generate_v4() primary key,
          name text,
          createdAt timestamp default now(),
          updatedAt timestamp default now(),
          profileId uuid references profiles (id),
          appId uuid references apps (id),
          settings json
        );
      
        create table messages (
          id uuid default uuid_generate_v4() primary key,
          role public.message_role,
          content text,
          createdAt timestamp default now(),
          updatedAt timestamp default now(),
          profileId uuid references profiles (id),
          chatId uuid references chats (id)
        );
  4. Get an account from OpenAI and generate your own API key

  5. Rename .env.example to .env.local and populate with your values

Note: You should not commit your .env file or it will expose secrets that will allow others to control access to your various OpenAI and authentication provider accounts.

Run Locally

  1. Go to the project directory
  cd web_ai_assistant
  1. Start the web app
  yarn dev

Authors

About

Web interface of an AI copilot based on GPT. Built in NextJs

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published