MCPcopy Index your code
hub / github.com/Agora-Lab-AI/Bing-Chat-API

github.com/Agora-Lab-AI/Bing-Chat-API @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
66 symbols 251 edges 15 files 27 documented · 41%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Bing Chat API Documentation

Multi-Modality

Bing Chat API

An all-inclusive API endpoint that harnesses the power of ChatGPT-4 for text completions, GPT-4 Vision for vision tasks, and DALL-E 3 for image creation. This comprehensive API is designed to provide a seamless experience for users looking to integrate advanced AI capabilities into their applications. Future integrations will include Windows Copilot, offering a way to control Windows in a manner similar to open-interpreter.

Installation 🐠


You can install the Bing Chat API using pip:

pip3 install --upgrade bing-chat

Usage 🐡


ChatGPT-4 Usage:

import logging
from bing-chat import BingChat

if __name__ == "__main__":
    logging.basicConfig(level=logging.INFO)
    chat = BingChat("")
    initial_message = "Hello, Bing!"
    messages = chat.run(initial_message)
    print("Chat history:", messages)

Disclaimer: Using this API excessively or in ways that violate Bing's terms of service may result in your account being banned. Always ensure you're adhering to platform guidelines and use the API responsibly.

BingChat Documentation

Table of Contents

  1. Introduction
  2. BingChat Class
  3. Initialization Parameters
  4. Methods and Usage
  5. run Method
  6. Examples
  7. Example 1: Creating a BingChat Instance and Running a Chat Session
  8. Additional Information
  9. References and Resources

(And so on...)

Features 🌊


  • Easy to Use: With just a few lines of code, you can start generating text completions.
  • Customizable: Provide your own creative prompts to generate unique text completions.
  • Real-Time Updates: The API provides real-time logging information about the chat session.
  • Multimodal Capabilities: The API integrates ChatGPT-4 for text, GPT-4 Vision for vision tasks, and DALL-E 3 for image creation, offering a wide range of functionalities in a single endpoint.
  • Future Windows Copilot Integration: Upcoming features will allow users to control Windows functionalities, making it a versatile tool for various applications.
  • **Future voice activation for sending prompts

License 📜


Bing Chat API is licensed under the MIT License. See the LICENSE file for more details.

Todo

  • [ ] Add Automatic cookie finding seamlessly
  • [ ] Simplify endpoints for ease of use
  • [ ] Integrate more advanced features of ChatGPT-4
  • [ ] Create tests for BingChat
  • [ ] Implement human feedback loop for improved chat sessions
  • [ ] Support different output formats
  • [ ] Develop integration with Windows Copilot for enhanced control over Windows functionalities
  • [ ] Develop voice activation for sending prompts

This documentation provides a comprehensive guide on how to interact with the Bing Chat API, leveraging the combined capabilities of ChatGPT-4, GPT-4 Vision, and DALL-E 3.

Core symbols most depended-on inside this repo

close
called by 9
src/bing_chat/chathub.py
p_hist
called by 9
src/bing_chat/main.py
files
called by 8
src/bing_chat/BingUtils.py
append_identifier
called by 6
src/bing_chat/utilities.py
create
called by 5
src/bing_chat/BingGPT.py
guess_locale
called by 4
src/bing_chat/utilities.py
import_data
called by 3
src/bing_chat/BingUtils.py
import_next
called by 3
src/bing_chat/BingUtils.py

Shape

Method 40
Function 16
Class 10

Languages

Python100%

Modules by API surface

src/bing_chat/BingUtils.py23 symbols
src/bing_chat/BingGPT.py12 symbols
src/bing_chat/main.py9 symbols
src/bing_chat/chathub.py8 symbols
src/bing_chat/utilities.py4 symbols
src/bing_chat/request.py3 symbols
src/bing_chat/conversation.py3 symbols
test_base.py1 symbols
src/bing_chat/locale.py1 symbols
src/bing_chat/exceptions.py1 symbols
src/bing_chat/conversation_style.py1 symbols

For agents

$ claude mcp add Bing-Chat-API \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact