mirror of
https://github.com/wassname/Open-Assistant.git
synced 2026-07-07 00:06:32 +08:00
Add realistic seed data json and update seed_data to properly label task payloads (#613)
* modifies seed_data script to properly label taks types as prompteror assistant * added realistic data json * pre-commit changes * update realistic_seed_data.json 5000 messages -> 450 messages * pre-commit changes * modifies seed_data script to properly label taks types as prompteror assistant * added realistic data json * pre-commit changes * update realistic_seed_data.json 5000 messages -> 450 messages * pre-commit changes * changed DEBUG_USE_SEED_DATA_PATH to realistic_seed_data, merged with main, ran pre-commit * Delete 2023_01_10_2052-06cc56417e69_.py Co-authored-by: Andreas Köpf <andreas.koepf@provisio.com>
This commit is contained in:
+12
-5
@@ -143,11 +143,18 @@ if settings.DEBUG_USE_SEED_DATA:
|
||||
)
|
||||
conversation_messages = pr.fetch_message_conversation(parent_message)
|
||||
conversation = prepare_conversation(conversation_messages)
|
||||
task = tr.store_task(
|
||||
protocol_schema.AssistantReplyTask(conversation=conversation),
|
||||
message_tree_id=parent_message.message_tree_id,
|
||||
parent_message_id=parent_message.id,
|
||||
)
|
||||
if msg.role == "assistant":
|
||||
task = tr.store_task(
|
||||
protocol_schema.AssistantReplyTask(conversation=conversation),
|
||||
message_tree_id=parent_message.message_tree_id,
|
||||
parent_message_id=parent_message.id,
|
||||
)
|
||||
else:
|
||||
task = tr.store_task(
|
||||
protocol_schema.PrompterReplyTask(conversation=conversation),
|
||||
message_tree_id=parent_message.message_tree_id,
|
||||
parent_message_id=parent_message.id,
|
||||
)
|
||||
tr.bind_frontend_message_id(task.id, msg.task_message_id)
|
||||
message = pr.store_text_reply(
|
||||
msg.text, msg.task_message_id, msg.user_message_id, review_count=5, review_result=True
|
||||
|
||||
@@ -23,7 +23,7 @@ class Settings(BaseSettings):
|
||||
DEBUG_SKIP_API_KEY_CHECK: bool = False
|
||||
DEBUG_USE_SEED_DATA: bool = False
|
||||
DEBUG_USE_SEED_DATA_PATH: Optional[FilePath] = (
|
||||
Path(__file__).parent.parent / "test_data/generic/test_generic_data.json"
|
||||
Path(__file__).parent.parent / "test_data/realistic/realistic_seed_data.json"
|
||||
)
|
||||
DEBUG_ALLOW_SELF_LABELING: bool = False # allow users to label their own messages
|
||||
DEBUG_SKIP_EMBEDDING_COMPUTATION: bool = False
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user