Skip to content

Commit

Permalink
Merge pull request #11 from satrong/main
Browse files Browse the repository at this point in the history
更新文档
  • Loading branch information
sugarforever authored Mar 8, 2024
2 parents 4db735e + b5f9b19 commit a0f469c
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
DISABLE_VERCEL_ANALYTICS=false
OPENAI_API_KEY=
DATABASE_URL=/Users/xyz/private/chatollama.sqlite
DATABASE_URL=file:../../chatollama.sqlite
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ dist
.pnp.*

#sqlite
**/.sqlite
*.sqlite
*.sqlite-journal

tmp

Expand Down
43 changes: 38 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,31 @@ Feature list:
- Models management (list, download, delete)
- Chat with models

## Ollama Server

You will need an Ollama server running. You can run it in local environment following the installation guide of [Ollama](https://github.com/ollama/ollama).

By default, Ollama server is running on http://localhost:11434.

## Install ChromaDB and startup

```bash
#https://hub.docker.com/r/chromadb/chroma/tags

docker pull chromadb/chroma
docker run -d -p 8000:8000 chromadb/chroma
```
Now, ChromaDB is running on http://localhost:8000

## Setup

Make sure to install the dependencies:
1. Copy the `.env.example` file to `.env` file:

```bash
cp .env.example .env
```

2. Make sure to install the dependencies:

```bash
# npm
Expand All @@ -24,22 +46,33 @@ yarn install
bun install
```

## Ollama Server
3. Run a migration to create your database tables with Prisma Migrate
```bash
# npm
npm run prisma-migrate

You will need an Ollama server running. You can run it in local environment following the installation guide of [Ollama](https://github.com/ollama/ollama).
# pnpm
pnpm prisma-migrate

By default, Ollama server is running on http://localhost:11434.
# yarn
yarn prisma-migrate

# bun
bun run prisma-migrate
```

## Development Server

> Make sure both __[Ollama Server](#ollama-server)__ and __[ChromaDB](#install-chromadb-and-startup)__ are running.
Start the development server on `http://localhost:3000`:

```bash
# npm
npm run dev

# pnpm
pnpm run dev
pnpm dev

# yarn
yarn dev
Expand Down

0 comments on commit a0f469c

Please sign in to comment.