MCPcopy
hub / github.com/fauxpilot/fauxpilot

github.com/fauxpilot/fauxpilot @main sqlite

repository ↗ · DeepWiki ↗
39 symbols 149 edges 14 files 7 documented · 18%
README

FauxPilot

This is an attempt to build a locally hosted alternative to GitHub Copilot. It uses the SalesForce CodeGen models inside of NVIDIA's Triton Inference Server with the FasterTransformer backend.

Prerequisites

You'll need:

  • Docker
  • docker compose >= 1.28
  • An NVIDIA GPU with Compute Capability >= 6.0 and enough VRAM to run the model you want.
  • nvidia-docker
  • curl and zstd for downloading and unpacking the models.

Note that the VRAM requirements listed by setup.sh are total -- if you have multiple GPUs, you can split the model across them. So, if you have two NVIDIA RTX 3080 GPUs, you should be able to run the 6B model by putting half on each GPU.

Support and Warranty

lmao

Okay, fine, we now have some minimal information on the wiki and a discussion forum where you can ask questions. Still no formal support or warranty though!

Setup

This section describes how to install a Fauxpilot server and clients.

Setting up a FauxPilot Server

Run the setup script to choose a model to use. This will download the model from Huggingface/Moyix in GPT-J format and then convert it for use with FasterTransformer.

Please refer to How to set-up a FauxPilot server.

Client configuration for FauxPilot

We offer some ways to connect to FauxPilot Server. For example, you can create a client by how to open the Openai API, Copilot Plugin, REST API.

Please refer to How to set-up a client.

Terminology

  • API: Application Programming Interface
  • CC: Compute Capability
  • CUDA: Compute Unified Device Architecture
  • FT: Faster Transformer
  • JSON: JavaScript Object Notation
  • gRPC: Remote Procedure call by Google
  • GPT-J: A transformer model trained using Ben Wang's Mesh Transformer JAX
  • REST: REpresentational State Transfer

Core symbols most depended-on inside this repo

prepare_tensor
called by 16
copilot_proxy/utils/codegen.py
replace
called by 4
converter/codegen_gptj_convert.py
pb2torch
called by 3
python_backend/model.py
json
called by 3
copilot_proxy/utils/errors.py
torch2pb
called by 2
python_backend/model.py
generate
called by 2
copilot_proxy/utils/codegen.py
random_completion_id
called by 2
copilot_proxy/utils/codegen.py
trim_with_stopwords
called by 1
copilot_proxy/utils/codegen.py

Shape

Function 18
Method 14
Class 5
Route 2

Languages

Python100%

Modules by API surface

copilot_proxy/utils/codegen.py11 symbols
tests/python_backend/test_setup.py7 symbols
python_backend/model.py6 symbols
copilot_proxy/app.py5 symbols
copilot_proxy/utils/errors.py3 symbols
converter/huggingface_gptj_convert.py3 symbols
converter/codegen_gptj_convert.py2 symbols
copilot_proxy/models.py1 symbols
converter/triton_config_gen.py1 symbols

Dependencies from manifests, versioned

fastapi0.82.0 · 1×
numpy1.23.2 · 1×
pexpect4.8.0 · 1×
pytest7.2.1 · 1×
requests2.28.2 · 1×
sse-starlette1.1.6 · 1×
tokenizers0.12.1 · 1×
uvicorn0.18.3 · 1×

For agents

$ claude mcp add fauxpilot \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact