An open API service indexing awesome lists of open source software.

https://github.com/samzhangjy/observerx

🤖️ Node.js framework for instantly building GPT bot applications.
https://github.com/samzhangjy/observerx

bot bot-framework chatgpt framework gpt gpt-3 gpt-4 gpt-api javascript nodejs typescript

Last synced: 4 months ago
JSON representation

🤖️ Node.js framework for instantly building GPT bot applications.

Awesome Lists containing this project

README

        

![banner](assets/banner.jpg)

[![Contributors][contributors-shield]][contributors-url]
[![Forks][forks-shield]][forks-url]
[![Stargazers][stars-shield]][stars-url]
[![Issues][issues-shield]][issues-url]
[![MIT License][license-shield]][license-url]





ObserverX

ObserverX


Your AI mate.


Explore the docs »




View Demo
·
Report Bug
·
Request Feature


Table of Contents



  1. About The Project


  2. Getting Started


  3. Roadmap

  4. Contributing

  5. License

## About The Project

ObserverX is a bot framework bundled with various builtin features, including:

- Dynamic database loading
- Instant history search for bot
- Ready-to-deploy admin panel
- Multiple deployable platforms
- Fully customizable

ObserverX is currently built on top of GPT-3.5 / GPT-4's `function` API and may support other
bots in the future.

## Getting Started

Follow the steps below to start a console session with the bot.

### Prerequisites

- Node.js 18.17.1 or higher

### Installation

1. Get an OpenAI API key at .
2. Install ObserverX
```sh
npm install @observerx/core @observerx/console @observerx/database @observerx/plugin-default
```
3. Create `index.js` and fill in the following content:
```js
import PlatformConsole from '@observerx/console';
import { addEntities, getDataSource } from '@observerx/database';
import ObserverX from '@observerx/core';
import pluginDefault from '@observerx/plugin-default';

addEntities(...ObserverX.getDatabaseEntities());
const dataSource = getDataSource();

await dataSource.initialize();

const platform = new PlatformConsole(dataSource);

platform.start({
model: 'GPT-3.5',
parentId: 'CONSOLE',
prompt: 'default',
plugins: [pluginDefault],
});
```
4. Create `.env` in the same folder as `index.js` and fill in the following content:
```properties
OPENAI_API_KEY=
OPENAI_BASE_PATH=

DATABASE_HOST=
DATABASE_USERNAME=
DATABASE_PASSWORD=
DATABASE_NAME=
DATABASE_PORT=
```
Note that you **must** use Postgres as the database.
5. Run `index.js`:
```sh
node index.js
```
...and you're ready to go!

## Roadmap

See the [open issues](https://github.com/samzhangjy/ObserverX/issues) for a full list of proposed features (and known issues).

## Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.

You can contribute to ObserverX by [opening an issue](https://github.com/samzhangjy/ObserverX/issues) or [starting a pull request](https://github.com/samzhangjy/ObserverX/pulls)

## License

Distributed under the MIT License. See `LICENSE` for more information.

[contributors-shield]: https://img.shields.io/github/contributors/samzhangjy/ObserverX.svg?style=for-the-badge
[contributors-url]: https://github.com/samzhangjy/ObserverX/graphs/contributors
[forks-shield]: https://img.shields.io/github/forks/samzhangjy/ObserverX.svg?style=for-the-badge
[forks-url]: https://github.com/samzhangjy/ObserverX/network/members
[stars-shield]: https://img.shields.io/github/stars/samzhangjy/ObserverX.svg?style=for-the-badge
[stars-url]: https://github.com/samzhangjy/ObserverX/stargazers
[issues-shield]: https://img.shields.io/github/issues/samzhangjy/ObserverX.svg?style=for-the-badge
[issues-url]: https://github.com/samzhangjy/ObserverX/issues
[license-shield]: https://img.shields.io/github/license/samzhangjy/ObserverX.svg?style=for-the-badge
[license-url]: https://github.com/samzhangjy/ObserverX/blob/main/LICENSE