Skip to content

Commit

Permalink
docs upd (#42)
Browse files Browse the repository at this point in the history
Co-authored-by: Max <max@oxyplay.com>
  • Loading branch information
FuzzyReason and oxyplay authored Jun 25, 2024
1 parent 59c62aa commit 7b37f4e
Show file tree
Hide file tree
Showing 36 changed files with 269 additions and 138 deletions.
17 changes: 15 additions & 2 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,12 @@ export default defineConfig({
{ label: 'Deployment',
items: [
{ label: 'Runpod Deployment', link: '/guides/deployment/runpod/' },
{ label: 'AWS Deployment', link: '/guides/deployment/aws/' },
{ label: 'AWS Deployment', items: [
{ label: 'Getting Started', link: '/guides/deployment/aws/getting-started' },
{ label: 'Launch from EC2', link: '/guides/deployment/aws/ec2/' },
{ label: 'Launch from Website', link: '/guides/deployment/aws/marketplace/' },
{ label: 'Usage', link: '/guides/deployment/aws/usage/' },
] },
]
},
{ label: 'Authentication',
Expand All @@ -98,7 +103,15 @@ export default defineConfig({
{ label: 'Version-specific Usage',
items: [
{ label: 'Self-hosted Refact', link: '/guides/version-specific/self-hosted/' },
{ label: 'Enterprise Refact', link: '/guides/version-specific/enterprise/' },
{ label: 'Enterprise Refact',
items: [
{ label: 'Getting Started', link: '/guides/version-specific/enterprise/getting-started' },
{ label: 'License', link: '/guides/version-specific/enterprise/license/' },
{ label: 'Users', link: '/guides/version-specific/enterprise/users/' },
{ label: 'Model Hosting', link: '/guides/version-specific/enterprise/model-hosting/' },
{ label: 'Plugins', link: '/guides/version-specific/enterprise/plugins/' },
]
},
{ label: 'Refact Teams', link: '/guides/version-specific/teams/' },
]
},
Expand Down
Binary file added src/assets/3-party-apis.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/active-license.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/ami.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/api-keys-link.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/assign-models-loras.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/chat-commands.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/enterprise-refact-users-create.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/instance_name.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/instance_type.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/assets/key_pair.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/launch_instance_marketplace.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/launch_instance_success.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/license-page.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/network_settings.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/refact_continue.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/refact_launch.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/refact_marketplace.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/refact_region.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/refact_terms.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/token_creation.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions src/content/docs/features/ai-chat.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ Context length depends on the plan you have chosen for your account:

This section outlines various commands that can be used in the AI chat. Below you can find information about functionality and usage of each command.

![Chat Commands](../../../assets/chat-commands.png)

### `@workspace`

- **Description**: Searches within VecDB for any specified query. This command allows you to search for any query within your repository/workspace.
Expand Down
4 changes: 3 additions & 1 deletion src/content/docs/features/ai-toolbox.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,6 @@ When entering the `/help` command, you will see your custom command in the list

![Refact Toolbox](../../../assets/custom_command.png)

All of the commands in the Toolbox are available in the `~/.cache/refact/customization.yaml` file. If you want to reset the Toolbox to the default, you can delete this file.
:::note
When using toolbox commands without the `/` symbol, the command will be executed in the chat interface. Also, the command will be executed in the toolbox window.
:::
101 changes: 0 additions & 101 deletions src/content/docs/guides/deployment/aws.md

This file was deleted.

47 changes: 47 additions & 0 deletions src/content/docs/guides/deployment/aws/ec2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
title: Deploying Refact.ai on AWS - Launch Through EC2
description: A page with instructions on how to deploy Refact on AWS.
---

When deploying Refact.ai through the Amazon EC2 Console, you will see the form with pre-filled values. Only two of these values need to be manually changed.

## Instance Name

The instance name is the name that will be used to identify the instance in the AWS console. This value needs to be entered manually.

![Instance Name](../../../../../assets/instance_name.png)

## Application and OS Images (Amazon Machine Image)

AMI (Amazon Machine Image) is the template that is responsible for containing the Refact.ai configurations. The AMI is pre-selected and does not need to be changed.

![AMI](../../../../../assets/ami.png)

## Instance Type

The instance type is pre-selected and does not need to be changed.

:::note
`g5` family instance types are recommended for production use. Contact Refact.ai team for recommendation on the amount of GPUs suitable for your use case.
:::

![Instance Type](../../../../../assets/instance_type.png)

## Key Pair (Optional)

The key pair is necessary for SSH connections to your EC2 instance.
To create a key pair press the `Create Key Pair` button.

![Key Pair](../../../../../assets/key_pair.png)

## Network Settings

The network settings are pre-selected and do not need to be changed.
The values should match the onees on the screenshot below.

![Network Settings](../../../../../assets/network_settings.png)

After verifying the settings, click on the `Launch Instance` button.
You will see the following screen, confirming that the instance is being created.

![Launch Instance](../../../../../assets/launch_instance_success.png)
23 changes: 23 additions & 0 deletions src/content/docs/guides/deployment/aws/getting-started.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
title: Deploying Refact.ai on AWS - Getting Started
description: A page with instructions on how to deploy Refact on AWS.
---

This guide provides step-by-step instructions for deploying Refact on AWS.

Navigate to Refact.ai Marketplace Page to deploy Refact on AWS.

1. On the Refact.ai Marketplace page, press **Continiue to Subscribe**.
![Refact.ai Marketplace Page](../../../../../assets/refact_marketplace.png)
2. Accept the terms and conditions.
![Refact.ai Marketplace Page](../../../../../assets/refact_terms.png)
3. Press the **Continue to Configuration** button.
![Continue to Configuration button](../../../../../assets/refact_continue.png)
4. Select the **Region** and **Software Version**. Sotware version reffers to the Refact version you want to deploy. By default, the latest version is selected.
![Select Region and Software Version](../../../../../assets/refact_region.png)

Press the **Continue to Launch** button. There are two options to proceed with in the drop-down menu. Follow one of the guides to launch Refact:
- [Launch through EC2](https://docs.refact.ai/guides/deployment/aws/ec2/) - this option is recommended for advanced users.
- [Launch from Website](https://docs.refact.ai/guides/deployment/aws/marketplace/) - this option is recommended for faster deployment.

![Launch Instance](../../../../../assets/refact_launch.png)
12 changes: 12 additions & 0 deletions src/content/docs/guides/deployment/aws/marketplace.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
title: Deploying Refact.ai on AWS - Through AWS Marketplace
description: A page with instructions on how to deploy Refact on AWS.
---

When selecting the option to deploy Refact.ai through the Marketplace page, you will be presented with a screen that will have everything pre-configured for you.

![Markeplace Launch](../../../../../assets/launch_instance_marketplace.png)

Once you click on the Launch button, you will be presented with a screen that will confirm that your instance is successfully deployed.

![Launch Confirmation](../../../../../assets/launch_instance_marketplace_confirmation.png)
16 changes: 16 additions & 0 deletions src/content/docs/guides/deployment/aws/usage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
title: Deploying Refact.ai on AWS - Usage
description: A page with instructions on how to deploy Refact on AWS.
---

In order to use your Refact.ai instance on AWS, you need to navigate to the AWS Console and locate the newly created instance.

![AWS Machine](../../../../../assets/aws_machine.png)

In the instance summary, locate the `Public IPv4 DNS`. This is the value you will need to use to access your instance.

After navigating to the instance, you will need to create an access token to use with Refact.ai.

![Token Creation](../../../../../assets/token_creation.png)

Once you have created the token, you need to activate your Refact.ai license. Navigate to the [License Activation Giude](https://docs.refact.ai/guides/version-specific/enterprise/license/) for more information.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Enterprise Refact Edition
title: Enterprise Refact Edition - Getting Started
description: What Enterprise Refact is and how it works.
---

Expand All @@ -8,8 +8,13 @@ The enterprise plan is designed for teams who want to have full control over the

## Prerequisites

- Docker with GPU support
- `docker-compose 1.29.2` or higher
:::note
This and the following step are required to deploy the Refact server in a local environment. If you are using services like AWS or Runpod, read one of the following guides:
- [Runpod Guide](https://docs.refact.ai/guides/deployment/runpod/)
- [AWS Guide](https://docs.refact.ai/guides/deployment/aws/getting-started)
:::

- Docker with GPU support. Follow the link to [install Docker](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/install-guide.html#docker). On Windows you need to install WSL 2 first. Follow the guide to [install WSL 2](https://docs.docker.com/desktop/install/windows-install).

## Pull Docker Image

Expand All @@ -23,7 +28,7 @@ If you have used the enterprise with a `beta` tag before, please ensure you use
:::
[Download](https://docs.refact.ai/docker-compose.yml) the `docker-compose.yml` file and run the docker `compose up` command in your terminal.

## Generating a Random Admin Password
## Generating a Random Admin Password (Optional)

The Refact server is designed to be safe to expose to the internet. To do it correctly, make sure you don't skip these two steps:
1. Generate a random password using the `openssl` utility:
Expand All @@ -41,28 +46,6 @@ The unencrypted HTTP is fine when using a local network or VPN. But the plugins
Server Web UI requires an admin password to log in. If you forgot the password, you can delete the container and run it again. The `docker-compose.yml` defines persistent volumes to store all the important data, they will survive container restart, kill/run cycle or upgrade.
### Activating the License
Enter your license key in Settings -> License. Once it's activated you will see the number of users and the expiration date for your license.
If you don't have an enterprise license key, please [contact the Refact team](https://refact.ai/contact/), and will arrange it for you.
### Access Control
Managing users is possible through the Access Control tab.
Click "Add new user" and the user and their unique API key will be generated automatically.
You can also add the team for each user.
![Login](../../../../assets/enterprise-users.png)
### Enabling vLLM
With the enterprise version of Refact, you can use an inference engine that uses PagedAttention from the vLLM library. It works faster and supports continuous batching, which means it can start work on new inference tasks, while continuing to serve other clients at the same time.
To enable vLLM select the Refact/1.6B/vllm model from the list of available models.
## Setting up the plugins
For VS Code: go to “Settings” and specify the server address and Refact API key provided by your admin.
For JetBrains: go to “Settings” and specify the server address and the Refact API key provided by your admin.
## User Management
Once you connect the API key, start writing code, and code suggestions from a selected model will appear automatically.
To find out how to manage users, refer to the [User Creation](https://docs.refact.ai/guides/version-specific/enterprise/users/#create-a-user) section.
17 changes: 17 additions & 0 deletions src/content/docs/guides/version-specific/enterprise/license.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
title: Enterprise Refact Edition - Activating the License
description: How to set up plugins for Enterprise Refact Edition
---

## Enter your license key
Navigate to the **License** page through the **Settings** drown menu in the top right corner and input your license key.

![License Page](../../../../../assets/license-page.png)

## Check Activation
After activation, you will see the **number of users** and the **expiration date** for your license.

![Active License](../../../../../assets/active-license.png)

## Need an Enterprise License?
If you don't have an enterprise license key, please [contact](https://refact.ai/contact/) the Refact team to get one.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
title: Enterprise Refact Edition - Model Hosting
description: What Enterprise Refact is and how it works.
---

Refact Enterprise Refact is a version that is optimized for enterprise use cases. It allows you to use all of the models avaliable in Refact.ai Self-hosted and also supports vLLM models.

### Enabling vLLM

With the enterprise version of Refact, you can use an inference engine that uses `PagedAttention` from the vLLM library. It works faster and supports continuous batching, which means it can start work on new inference tasks, while continuing to serve other clients at the same time.

To enable vLLM select one the available vLLM models in the **Model Hosting** page. The full list of available models can be found on the [Supported Models page](https://docs.refact.ai/supported-models/).

:::note
vLLM models are suitable for a fast inference. The limiatation with the vLLM models is that they **don't support sharding**.
:::
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: Enterprise Refact Edition - Setting Up Plugins
description: How to set up plugins for Enterprise Refact Edition
---

- **VS Code**: go to **Settings** and specify the **server address** and **Refact API key** provided by your admin.
- **JetBrains**: go to **Settings** and specify the **server address** and the **Refact API key** provided by your admin.

Once you connect the API key, start writing code, and code suggestions from a selected model will appear automatically.
Loading

0 comments on commit 7b37f4e

Please sign in to comment.