shellwork/ChatParts-llama3.1-8b

🤖 XJTLU-Software RAG GitHub Repository • 📊 ChatParts Dataset

shellwork/ChatParts-llama3.1-8b is a specialized dialogue model fine-tuned from Meta-Llama-3.1-8B-Instruct by the XJTLU-Software iGEM Competition team. This model is tailored for the synthetic biology domain, aiming to assist competition participants and researchers in efficiently collecting and organizing relevant information. It serves as the local model component of the XJTLU-developed Retrieval-Augmented Generation (RAG) software, enhancing search and summarization capabilities within synthetic biology data.

📚 Dataset Information

The model is trained on a comprehensive synthetic biology-specific dataset curated from multiple authoritative sources:

  • iGEM Wiki Pages (2004-2023): Comprehensive coverage of synthetic biology topics from over two decades of iGEM competitions.
  • Synthetic Biology Review Papers: More than 1,000 high-quality review articles providing in-depth insights into various aspects of synthetic biology.
  • iGEM Parts Registry Documentation: Detailed documentation of parts used in iGEM projects, facilitating accurate information retrieval.

In total, the dataset comprises over 200,000 question-answer pairs, meticulously assembled to cover a wide spectrum of synthetic biology topics. For more detailed information about the dataset, please visit our training data repository.

🛠️ How to Use

This repository supports usage with the transformers library. Below is a straightforward example of how to deploy the shellwork/ChatParts-llama3.1-8b model using transformers.

Requirements

  • Transformers Library: Ensure you have transformers version >= 4.43.0 installed. You can update your installation using:

    pip install --upgrade transformers
    

Example: Deploying with Transformers

import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
import json

# Load the tokenizer and model
tokenizer = AutoTokenizer.from_pretrained('shellwork/ChatParts-llama3.1-8b', trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
    'shellwork/ChatParts-llama3.1-8b',
    torch_dtype=torch.bfloat16,
    trust_remote_code=True,
    device_map='auto'
)

# Example context from synthetic biology literature
context = '''
Synthetic biology enables the design and construction of new biological parts, devices, and systems, or the re-design of existing natural biological systems.
'''

query = "What is the goal of synthetic biology?"

# Generate the response with fine-grained citations
result = model.query_longcite(
    context,
    query,
    tokenizer=tokenizer,
    max_input_length=128000,
    max_new_tokens=1024
)

# Display the results
print("Answer:\n{}\n".format(result['answer']))
print("Statement with citations:\n{}\n".format(
    json.dumps(result['statements_with_citations'], indent=2, ensure_ascii=False)
))
print("Context (divided into sentences):\n{}\n".format(result['splited_context']))

📄 License

This model is released under the Llama-3.1 License. For more details, please refer to the license information in the repository.

🔗 Additional Resources

  • RAG Software: Explore the full capabilities of our Retrieval-Augmented Generation software here.
  • Training Data: Access and review the extensive training dataset here .
  • Support & Contributions: For support or to contribute to the project, visit our GitHub Issues page.

Feel free to reach out through our GitHub repository for any questions, issues, or contributions related to shellwork/ChatParts-llama3.1-8b.

Downloads last month
24
Safetensors
Model size
8.03B params
Tensor type
BF16
·
Inference Examples
Unable to determine this model's library. Check the docs .

Model tree for shellwork/ChatParts-llama3.1-8b

Finetuned
(520)
this model

Dataset used to train shellwork/ChatParts-llama3.1-8b