🕊️ OpenCopilot: Build and embed open-source AI Copilots into your product with ease
Documentation: docs.opencopilot.dev
🕊️ OpenCopilot Overview
Copilots are becoming the new paradigm how to build successful LLM-based applications, as seen by Github, Shopify, Brex, Hubspot, etc Copilots. Yet, building a Copilot that goes beyond a Twitter demo is time-consuming, unreliable and overly complex. Moreover, existing solutions such as Microsoft Copilot Stack are closed-source. Today, building an LLM-app feels like:
OpenCopilot solves this problem so building your own Copilot becomes intuitive, fast and reliable - all so you can build your copilot in a single day. For example, you can build Copilots such as:
🛠️ Developer tooling Copilot
- Example: Ready Player Me Copilot
- Implementation: Code
💾 SaaS Copilot
- Example: HubSpot ChatSpot
💳 E-commerce Copilot
- Example: Shopify Copilot
See more use cases in docs.
⚡ Quickstart
As prerequisites, you need to have Python 3.8+ and pip installed.
1. Install the OpenCopilot Python package
pip install opencopilot-ai
2. Create a new python file to set up a minimal Copilot
For example, you can create an AWS CLI Copilot using the following code by adding it to a copilot.py file. Make sure to replace openai_api_key with your 🔑 own OpenAI API key.
from opencopilot import OpenCopilot
PROMPT = """
You are an Amazon Web Services (AWS) CLI copilot. You are an interactive version of AWS CLI documentation and chat with developers who need help using it.
Your mission is to be a reliable companion throughout the developer journey - always ready to answer questions and share insights.
=========
{context}
=========
{history}
User: {question}
AWS CLI Copilot answer in Markdown:
"""
copilot = OpenCopilot(
copilot_name="AWS CLI Copilot",
openai_api_key="your-openai-api-key",
# You can also use gpt-4 for improved accuracy
# or Llama 2 locally (https://docs.opencopilot.dev/create/opensource-llms#running-an-llm)
llm="gpt-3.5-turbo-16k",
prompt=PROMPT,
)
# Download and embed the knowledge base from given URL
copilot.add_data_urls(
[
"https://awsdocs.s3.amazonaws.com/cli/latest/aws-cli.pdf",
]
)
# Run the copilot
copilot()
3. Run the Copilot
python copilot.py
4. Chat with the Copilot
You can chat with your copilot in the UI at localhost:3000/ui or using the CLI:
opencopilot chat "Hello, who are you?"
5. Create your own copilot
After seeing how easy it is to set up a copilot, you can now create your own and level it up step by step. For this, see docs.opencopilot.dev, or check a more detailed example of the AWS copilot in the examples directory.
🔍 Stack Overview
OpenCopilot provides one coherent end-to-end stack which is purposely designed for building a variety of copilots. From LLM selection (OSS LLMs upcoming), knowledge base, monitoring, evaluation, etc - it covers all the needs to build a useful copilot.
See our docs on Stack Overview to learn more about each part of the OpenCopilot stack.
Analytics
OpenCopilot collects library usage data to improve the product and your experience. We collect events regarding errors and your usage of copilot features, and never collect your code, prompts, knowledge base documents, or LLM outputs. To understand what is tracked, check out the tracking code.
You can opt out of tracking by setting the environment variable OPENCOPILOT_DO_NOT_TRACK=True:
export OPENCOPILOT_DO_NOT_TRACK=True
Getting help
If you have any questions about OpenCopilot, feel free to do any of the following:
- Join our Discord and ask.
- Report bugs or feature requests in GitHub issues.
- Directly email Taivo, Co-founder & CTO of OpenCopilot:
taivo@opencopilot.dev.
Metadata
Release files for opencopilot-ai 0.3.8
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| opencopilot-ai-0.3.8.tar.gz | 163.5 kB | Without provenance | Details for opencopilot-ai-0.3.8.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| opencopilot_ai-0.3.8-py3-none-any.whl | Python 3 | none | any | Details for opencopilot_ai-0.3.8-py3-none-any.whl |
Total release size: 406.7 kB
Release files / opencopilot-ai-0.3.8.tar.gz
| Download URL | opencopilot-ai-0.3.8.tar.gz |
|---|---|
| Size | 163.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b83b7050b808821df63f1918ab7abdffceab839749a15313b62a38ab328836f7
|
|
BLAKE2b-256 checksum How to use checksums |
3cb538ef0c670c6b6ec94d3d523f109f4cb056bcac5e9bcaac83ab92bfc946ae
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.0
|
Release files / opencopilot_ai-0.3.8-py3-none-any.whl
| Download URL | opencopilot_ai-0.3.8-py3-none-any.whl |
|---|---|
| Size | 243.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5c40bd69db9264140fa3ff59076af5b0c790bb364b81eabb583d40a26519881d
|
|
BLAKE2b-256 checksum How to use checksums |
c180989b3bf53a72651bf2c88839183276773671d29058272a02fa32180e8c55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.0
|
Security for opencopilot-ai 0.3.8
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.