Git Product home page Git Product logo

claude-3's Introduction

Claude-3 API โ˜๏ธ

Meet Claude 3 Haiku, a speed demon that processes 30 pages in a blink, an intellect setting new benchmarks, and a visionary deciphering photos to technical diagrams. Perfect for roleplaying โœจ

Features ๐ŸŒŸ

  • Simple API (OpenAI)
  • No Cost
  • Easy Integration, suitable for any Frontend

Requirements

  • python3 or nodejs (Optional)
  • openai (Optional)
  • Galaxy API Key get here ๐Ÿ†“

Front-End Integration

If you're using it through any front-end, for Librechats, Sillytavern, JanitorAI etc.

  1. Replace the Proxy url to https://galaxyapi.onrender.com
  2. Put your own galaxy API Key ๐Ÿ”
  3. That's it!

Examples

curl https://galaxyapi.onrender.com/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $GALAXYAI_API_KEY" \
  -d '{
    "model": "claude-3-haiku-20240307",
    "messages": [
      {
        "role": "system",
        "content": "You are a helpful assistant."
      },
      {
        "role": "user",
        "content": "Hello!"
      }
    ]
  }'

Python

from openai import OpenAI
client = OpenAI(apikey="galaxy-secret-key-here")
client.base_url = "https://galaxyapi.onrender.com/v1"

completion = client.chat.completions.create(
  model="claude-3-haiku-20240307",
  messages=[
    {"role": "system", "content": "You are a helpful assistant."},
    {"role": "user", "content": "Hello!"}
  ]
)

print(completion.choices[0].message)

NodeJS

import OpenAI from "openai";

const openai = new OpenAI({
  apiKey: 'GALAXY_API_KEY',
  baseURL: 'https://galaxyapi.onrender.com/v1'
})

async function main() {
  const completion = await openai.chat.completions.create({
    messages: [{ role: "system", content: "You are a helpful assistant." }],
    model: "claude-3-haiku-20240307",
  });

  console.log(completion.choices[0]);
}

main();

ContactUS โœ‹

Having Issues, Feel free to report it by creating the issue or report it here.

claude-3's People

Contributors

galaxyapi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.