Introduction
MAgIC is the benchmark to assess LLM-powered multi-agents' capabilities including cognition, adaptability, rationality and collaboration. Based on it, you can quantitatively measure your own LLM's ability and compare it with the cutting-edge LLMs.
Installation
pip install MAgIC_LLM==0.8.0
Need to assign the OPENAI_API_KEY, if you are trying to use openai api
export OPENAI_API_KEY=""
Usage
To assess your own large language model, follow the below instructions
import MAgIC_LLM
import time
import openai
import google.generativeai as palm
import cohere
from anthropic import Anthropic, HUMAN_PROMPT, AI_PROMPT
# Here we use GPT-4-turbo as the example
def chatbox(messages,temperature,max_tokens):
time.sleep(9)
response = openai.ChatCompletion.create(model="gpt-4-1106-preview",
messages=messages,
temperature = temperature,
n=3,
max_tokens=max_tokens)
response = response['choices'][0]['message']['content']
#print(response)
return response
# configure the path you want to save the assessment results
path = 'result.json'
# Here is the name of your own LLM
test_player_model_name = 'My_LLM'
MAgIC_LLM.run(chatbox,path,test_player_model_name,PGM=False)
If any interruption happens in the process, you can just simple re-excute your programme and it will continue to assess your LLM from the point where interruption happens.
Currently, PGM method can be used to enhance your own LLM, the usage is below:
MAgIC_LLM.run(chatbox,path,test_player_model_name,PGM=True)
License
MIT License
Metadata
Release files for MAgIC-LLM 0.8.0
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 |
|---|---|---|---|---|
| MAgIC_LLM-0.8.0.tar.gz | 116.4 kB | Without provenance | Details for MAgIC_LLM-0.8.0.tar.gz |
Release files / MAgIC_LLM-0.8.0.tar.gz
| Download URL | MAgIC_LLM-0.8.0.tar.gz |
|---|---|
| Size | 116.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d05b3a1e151f3a870c67686ef23af1e759584b232058f2fc774b3205f51398e8
|
|
BLAKE2b-256 checksum How to use checksums |
ff87ad94d05a1f60fb4b8d59b6b7d35615e98b2e100303e5025e7d1d37f81b40
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.12
|
Security for MAgIC-LLM 0.8.0
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.