diff --git a/src/Requests/CreateCompletionRequest.php b/src/Requests/CreateCompletionRequest.php index 4b0d927..0f0d214 100644 --- a/src/Requests/CreateCompletionRequest.php +++ b/src/Requests/CreateCompletionRequest.php @@ -45,6 +45,10 @@ public function resolveEndpoint(): string public function defaultBody(): array { + if(! isset($metadata['user_id'])) { + $metadata['user_id'] = uniqid(); + } + return [ 'model' => 'claude-2', 'prompt' => $this->prompt,