gpt3datagen
1.0.0
GPT3Datagen เป็นแพ็คเกจ Python ที่สร้างข้อมูลปลอมสำหรับการปรับแต่งรุ่น openai
ของคุณ
_ ___ _ _
( )_ /'_ ) ( ) ( )_
__ _ _ | , _ )( _ ) _ ) | _ | | _ _ | , _ ) _ _ __ __ __ _
/' _ ` ( '_ ` | | _ ( _ < /' _ ` | /'_ ` )| | /' _ ` ) /'_ ` /' __ ` /' _ `
( ( _ ) || ( _ ) )| |_ ( ) _ ) |( ( _ | |( ( _ | || |_ ( ( _ | |( ( _ ) |( ___ /| ( ) |
` __ || ,__/' ` _ _ ) ` ____) ` _ _ , _ ) ` __,_) ` _ _ ) ` __,_) ` _ _ |` _ ___ )( _ ) ( _ )v0.1.0
( ) _ ) || | ( ) _ ) |
_ __ /'( _ ) _ __ /'
pip install -U gpt3datagen
อีกทางเลือกหนึ่งคำสั่งต่อไปนี้จะดึงและติดตั้งคอมมิชชันล่าสุดจากที่เก็บนี้พร้อมกับการพึ่งพา Python:
pip install git+https://github.com/donwany/gpt3datagen.git --use-pep517
หรือที่เก็บโคลน git:
git clone https://github.com/donwany/gpt3datagen.git
cd gpt3datagen
make install && pip install -e .
หากต้องการอัปเดตแพ็คเกจเป็นที่เก็บเวอร์ชันล่าสุดโปรดเรียกใช้:
pip install --upgrade --no-deps --force-reinstall git+https://github.com/donwany/gpt3datagen.git
รันต่อไปนี้เพื่อดูตัวเลือกที่มีอยู่ทั้งหมด:
gpt3datagen --help
gpt3datagen --version
รูปแบบเอาท์พุท: jsonl
, json
, csv
, tsv
, xlsx
gpt3datagen
--num_samples 500
--max_length 2048
--sample_type " classification "
--output_format " jsonl "
--output_dir .
gpt3datagen
--num_samples 500
--max_length 2048
--sample_type completion
--output_format csv
--output_dir .
gpt3datagen
--sample_type completion
--output_format jsonl
--output_dir .
gpt3datagen --sample_type completion -o . -f jsonl
gpt3datagen --sample_type news -o . -f jsonl
{ " prompt " : " <prompt text> nn###nn " , " completion " : " <ideal generated text> END " }
{ " prompt " : " <prompt text> nn###nn " , " completion " : " <ideal generated text> END " }
{ " prompt " : " <prompt text> nn###nn " , " completion " : " <ideal generated text> END " }
...
มีประโยชน์เฉพาะในกรณีที่คุณโคลนที่เก็บ
python prepare.py
--num_samples 500
--max_length 2048
--sample_type " classification "
--output_format " jsonl "
--output_dir .
python prepare.py
--num_samples 500
--max_length 2048
--sample_type " completion "
--output_format " csv "
--output_dir .
python prepare.py
--num_samples 500
--max_length 2048
--sample_type " completion "
--output_format " json "
--output_dir /Users/ < tsiameh > /Desktop
pip install --upgrade openai
export OPENAI_API_KEY= " <OPENAI_API_KEY> "
# validate sample datasets generated
openai tools fine_tunes.prepare_data -f < SAMPLE_DATA > .jsonl
openai tools fine_tunes.prepare_data -f < SAMPLE_DATA > .csv
openai tools fine_tunes.prepare_data -f < SAMPLE_DATA > .tsv
openai tools fine_tunes.prepare_data -f < SAMPLE_DATA > .json
openai tools fine_tunes.prepare_data -f < SAMPLE_DATA > .xlsx
openai tools fine_tunes.prepare_data -f /Users/ < tsiameh > /Desktop/data_prepared.jsonl
# fine-tune
openai api fine_tunes.create
-t < DATA_PREPARED > .jsonl
-m < BASE_MODEL: davinci, curie, ada, babbage >
# List all created fine-tunes
openai api fine_tunes.list
# For multiclass classification
openai api fine_tunes.create
-t < TRAIN_FILE_ID_OR_PATH >
-v < VALIDATION_FILE_OR_PATH >
-m < MODEL >
--compute_classification_metrics
--classification_n_classes < N_CLASSES >
# For binary classification
openai api fine_tunes.create
-t < TRAIN_FILE_ID_OR_PATH >
-v < VALIDATION_FILE_OR_PATH >
-m < MODEL >
--compute_classification_metrics
--classification_n_classes 2
--classification_positive_class < POSITIVE_CLASS_FROM_DATASET >
โปรดดูการสนับสนุน
GPT3Datagen ได้รับการปล่อยตัวภายใต้ใบอนุญาต MIT ดูรายละเอียดไฟล์ลิขสิทธิ์
Theophilus Siameh