Skip to content

Commit 6c91135

Browse files
authored
Merge pull request #494 from jamosaur/eloquent-history-selects
Only select role, content and meta for eloquent chat history
2 parents 5bf1ddc + 22e91d6 commit 6c91135

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/Chat/History/EloquentChatHistory.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ protected function load(): void
3434

3535
/** @var Collection<int, Model> $messages */
3636
$messages = $model->newQuery()
37+
->select(['role', 'content', 'meta'])
3738
->where('thread_id', $this->threadId)
3839
->orderBy('id')
3940
->get();

0 commit comments

Comments
 (0)