Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Renaming comments #97

Merged
merged 2 commits into from
Dec 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -151,14 +151,14 @@ COPY server/punica_kernels/ .
ENV TORCH_CUDA_ARCH_LIST="8.0;8.6+PTX"
RUN python setup.py build

# Text Generation Inference base image
# LoRAX base image
FROM nvidia/cuda:11.8.0-base-ubuntu20.04 as base

# Conda env
ENV PATH=/opt/conda/bin:$PATH \
CONDA_PREFIX=/opt/conda

# Text Generation Inference base env
# LoRAX base env
ENV HUGGINGFACE_HUB_CACHE=/data \
HF_HUB_ENABLE_HF_TRANSFER=1 \
PORT=80
Expand Down
4 changes: 2 additions & 2 deletions clients/python/lorax/errors.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from typing import Dict


# Text Generation Inference Errors
# LoRAX Errors
class ValidationError(Exception):
def __init__(self, message: str):
super().__init__(message)
Expand Down Expand Up @@ -74,7 +74,7 @@ def parse_error(status_code: int, payload: Dict[str, str]) -> Exception:
Exception: parsed exception

"""
# Try to parse a Text Generation Inference error
# Try to parse a LoRAX error
message = payload["error"]
if "error_type" in payload:
error_type = payload["error_type"]
Expand Down
42 changes: 0 additions & 42 deletions clients/python/tests/test_inference_api.py

This file was deleted.

2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- Load the latest Swagger UI code and style from npm using unpkg.com -->
<script src="https://unpkg.com/swagger-ui-dist@3/swagger-ui-bundle.js"></script>
<link rel="stylesheet" type="text/css" href="https://unpkg.com/swagger-ui-dist@3/swagger-ui.css"/>
<title>Text Generation Inference API</title>
<title>LoRAX API</title>
</head>
<body>
<div id="swagger-ui"></div> <!-- Div to hold the UI component -->
Expand Down
28 changes: 14 additions & 14 deletions docs/openapi.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"openapi": "3.0.3",
"info": {
"title": "Text Generation Inference",
"description": "Text Generation Webserver",
"title": "LoRAX",
"description": "LoRAX",
"contact": {
"name": "Olivier Dehaene"
"name": "Travis Addair"
},
"license": {
"name": "Apache 2.0",
Expand All @@ -16,7 +16,7 @@
"/": {
"post": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Generate tokens if `stream == false` or a stream of token if `stream == true`",
"description": "Generate tokens if `stream == false` or a stream of token if `stream == true`",
Expand Down Expand Up @@ -105,7 +105,7 @@
"/generate": {
"post": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Generate tokens",
"description": "Generate tokens",
Expand Down Expand Up @@ -189,7 +189,7 @@
"/generate_stream": {
"post": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Generate a stream of token using Server-Sent Events",
"description": "Generate a stream of token using Server-Sent Events",
Expand Down Expand Up @@ -273,7 +273,7 @@
"/health": {
"get": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Health check method",
"description": "Health check method",
Expand All @@ -283,7 +283,7 @@
"description": "Everything is working fine"
},
"503": {
"description": "Text generation inference is down",
"description": "LoRAX is down",
"content": {
"application/json": {
"schema": {
Expand All @@ -302,10 +302,10 @@
"/info": {
"get": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Text Generation Inference endpoint info",
"description": "Text Generation Inference endpoint info",
"summary": "LoRAX endpoint info",
"description": "LoRAX endpoint info",
"operationId": "get_model_info",
"responses": {
"200": {
Expand All @@ -324,7 +324,7 @@
"/metrics": {
"get": {
"tags": [
"Text Generation Inference"
"LoRAX"
],
"summary": "Prometheus metrics scrape endpoint",
"description": "Prometheus metrics scrape endpoint",
Expand Down Expand Up @@ -850,8 +850,8 @@
},
"tags": [
{
"name": "Text Generation Inference",
"description": "Hugging Face Text Generation Inference API"
"name": "LoRAX",
"description": "LoRAX API"
}
]
}
2 changes: 1 addition & 1 deletion launcher/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "lorax-launcher"
description = "Text Generation Launcher"
description = "LoRAX Launcher"
version.workspace = true
edition.workspace = true
authors.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion router/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "lorax-router"
description = "Text Generation Webserver"
description = "LoRAX Webserver"
build = "build.rs"
version.workspace = true
edition.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion router/client/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use std::cmp::min;
use tonic::transport::{Channel, Uri};
use tracing::instrument;

/// Text Generation Inference gRPC client
/// LoRAX gRPC client
#[derive(Debug, Clone)]
pub struct Client {
stub: LoraxServiceClient<Channel>,
Expand Down
4 changes: 2 additions & 2 deletions router/client/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Text Generation gRPC client library
//! LoRAX gRPC client library

mod client;
#[allow(clippy::derive_partial_eq_without_eq)]
Expand All @@ -19,7 +19,7 @@ use tonic::Status;

#[derive(Error, Debug, Clone)]
pub enum ClientError {
#[error("Could not connect to Text Generation server: {0}")]
#[error("Could not connect to LoRAX server: {0}")]
Connection(String),
#[error("Server error: {0}")]
Generation(String),
Expand Down
2 changes: 1 addition & 1 deletion router/client/src/sharded_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use tonic::transport::Uri;
use tracing::instrument;

#[derive(Debug, Clone)]
/// Text Generation Inference gRPC multi client
/// LoRAX gRPC multi client
pub struct ShardedClient {
clients: Vec<Client>,
}
Expand Down
2 changes: 1 addition & 1 deletion router/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// Text Generation Inference Webserver
/// LoRAX Webserver
mod adapter;
mod health;
mod infer;
Expand Down
2 changes: 1 addition & 1 deletion router/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// Text Generation Inference webserver entrypoint
/// LoRAX webserver entrypoint
use axum::http::HeaderValue;
use clap::Parser;
use lorax_client::{ClientError, ShardedClient};
Expand Down
20 changes: 10 additions & 10 deletions router/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ use utoipa_swagger_ui::SwaggerUi;
/// Generate tokens if `stream == false` or a stream of token if `stream == true`
#[utoipa::path(
post,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/",
request_body = CompatGenerateRequest,
responses(
Expand Down Expand Up @@ -77,10 +77,10 @@ async fn compat_generate(
}
}

/// Text Generation Inference endpoint info
/// LoRAX endpoint info
#[utoipa::path(
get,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/info",
responses((status = 200, description = "Served model info", body = Info))
)]
Expand All @@ -91,11 +91,11 @@ async fn get_model_info(info: Extension<Info>) -> Json<Info> {

#[utoipa::path(
get,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/health",
responses(
(status = 200, description = "Everything is working fine"),
(status = 503, description = "Text generation inference is down", body = ErrorResponse,
(status = 503, description = "LoRAX is down", body = ErrorResponse,
example = json ! ({"error": "unhealthy", "error_type": "healthcheck"})),
)
)]
Expand All @@ -117,7 +117,7 @@ async fn health(mut health: Extension<Health>) -> Result<(), (StatusCode, Json<E
/// Generate tokens
#[utoipa::path(
post,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/generate",
request_body = GenerateRequest,
responses(
Expand Down Expand Up @@ -307,7 +307,7 @@ async fn generate(
/// Generate a stream of token using Server-Sent Events
#[utoipa::path(
post,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/generate_stream",
request_body = GenerateRequest,
responses(
Expand Down Expand Up @@ -503,7 +503,7 @@ async fn generate_stream(
/// Prometheus metrics scrape endpoint
#[utoipa::path(
get,
tag = "Text Generation Inference",
tag = "LoRAX",
path = "/metrics",
responses((status = 200, description = "Prometheus Metrics", body = String))
)]
Expand Down Expand Up @@ -566,10 +566,10 @@ pub async fn run(
)
),
tags(
(name = "Text Generation Inference", description = "Hugging Face Text Generation Inference API")
(name = "LoRAX", description = "LoRAX API")
),
info(
title = "Text Generation Inference",
title = "LoRAX",
license(
name = "Apache 2.0",
url = "https://www.apache.org/licenses/LICENSE-2.0"
Expand Down
4 changes: 2 additions & 2 deletions server/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Text Generation Inference Python gRPC Server
# LoRAX Python gRPC Server

A Python gRPC server for Text Generation Inference
A Python gRPC server for LoRAX

## Install

Expand Down
Loading